/*
  Copyright (C) 2013 Ariya Hidayat <ariya.hidayat@gmail.com>
  Copyright (C) 2013 Thaddee Tyl <thaddee.tyl@gmail.com>
  Copyright (C) 2013 Mathias Bynens <mathias@qiwi.be>
  Copyright (C) 2012 Ariya Hidayat <ariya.hidayat@gmail.com>
  Copyright (C) 2012 Mathias Bynens <mathias@qiwi.be>
  Copyright (C) 2012 Joost-Wim Boekesteijn <joost-wim@boekesteijn.nl>
  Copyright (C) 2012 Kris Kowal <kris.kowal@cixar.com>
  Copyright (C) 2012 Yusuke Suzuki <utatane.tea@gmail.com>
  Copyright (C) 2012 Arpad Borsos <arpad.borsos@googlemail.com>
  Copyright (C) 2011 Ariya Hidayat <ariya.hidayat@gmail.com>

  Redistribution and use in source and binary forms, with or without
  modification, are permitted provided that the following conditions are met:

    * Redistributions of source code must retain the above copyright
      notice, this list of conditions and the following disclaimer.
    * Redistributions in binary form must reproduce the above copyright
      notice, this list of conditions and the following disclaimer in the
      documentation and/or other materials provided with the distribution.

  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  ARE DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
  DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
  (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

/*******************************************************************************
 * @license
 * Copyright (c) 2010, 2014 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 * 
 * Contributors: IBM Corporation - initial API and implementation
 ******************************************************************************/

/*******************************************************************************
 * @license
 * Copyright (c) 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/

/*******************************************************************************
 * @license
 * Copyright (c) 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/

/*
  Copyright (C) 2012-2013 Yusuke Suzuki <utatane.tea@gmail.com>
  Copyright (C) 2012 Ariya Hidayat <ariya.hidayat@gmail.com>

  Redistribution and use in source and binary forms, with or without
  modification, are permitted provided that the following conditions are met:

    * Redistributions of source code must retain the above copyright
      notice, this list of conditions and the following disclaimer.
    * Redistributions in binary form must reproduce the above copyright
      notice, this list of conditions and the following disclaimer in the
      documentation and/or other materials provided with the distribution.

  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  ARE DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
  DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
  (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

/**
 * @fileoverview Defines environment settings and globals.
 * @author Elan Shanker
 * @copyright 2014 Elan Shanker. All rights reserved.
 */

/*******************************************************************************
 * @license
 * Copyright (c) 2013, 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/

/*******************************************************************************
 * @license
 * Copyright (c) 2012 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 * 
 * Contributors: IBM Corporation - initial API and implementation
 ******************************************************************************/

/*******************************************************************************
 * @license
 * Copyright (c) 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made
 * available under the terms of the Eclipse Public License v1.0
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html).
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/

/*******************************************************************************
 * @license
 * Copyright (c) 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 *
 * Contributors:
 *     IBM Corporation - Allow original requirejs plugin to find files in Orion workspace
 *******************************************************************************/

/**
 * @license RequireJS text 2.0.12 Copyright (c) 2010-2014, The Dojo Foundation All Rights Reserved.
 * Available via the MIT or new BSD license.
 * see: http://github.com/requirejs/text for details
 */

/*******************************************************************************
 * @license
 * Copyright (c) 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 * 
 * Contributors: IBM Corporation - initial API and implementation
 ******************************************************************************/

/**
 * @license RequireJS i18n 2.0.4 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved.
 * Available via the MIT or new BSD license.
 * see: http://github.com/requirejs/i18n for details
 */

/*******************************************************************************
 * @license
 * Copyright (c) 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 * 
 ******************************************************************************/

/*******************************************************************************
 * @license
 * Copyright (c) 2014, 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made
 * available under the terms of the Eclipse Public License v1.0
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html).
 *
 ******************************************************************************/

/*******************************************************************************
 * @license
 * Copyright (c) 2012, 2015 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials are made 
 * available under the terms of the Eclipse Public License v1.0 
 * (http://www.eclipse.org/legal/epl-v10.html), and the Eclipse Distribution 
 * License v1.0 (http://www.eclipse.org/org/documents/edl-v10.html). 
 *
 * Contributors: IBM Corporation - initial API and implementation
 *******************************************************************************/

!function(e,t){"use strict";"function"==typeof define&&define.amd?define("esprima/esprima",["exports"],t):t("undefined"!=typeof exports?exports:e.esprima={})}(this,function(e){"use strict";function t(e,t){if(!e)throw new Error("ASSERT: "+t)}function r(e){return e>=48&&57>=e}function n(e){return"0123456789abcdefABCDEF".indexOf(e)>=0}function o(e){return"01234567".indexOf(e)>=0}function s(e){return 32===e||9===e||11===e||12===e||160===e||e>=5760&&[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].indexOf(e)>=0}function a(e){return 10===e||13===e||8232===e||8233===e}function i(e){return 36===e||95===e||e>=65&&90>=e||e>=97&&122>=e||92===e||e>=128&&Dr.NonAsciiIdentifierStart.test(String.fromCharCode(e))}function l(e){return 36===e||95===e||e>=65&&90>=e||e>=97&&122>=e||e>=48&&57>=e||92===e||e>=128&&Dr.NonAsciiIdentifierPart.test(String.fromCharCode(e))}function c(e){switch(e){case"class":case"enum":case"export":case"extends":case"import":case"super":return!0;default:return!1}}function p(e){switch(e){case"implements":case"interface":case"package":case"private":case"protected":case"public":case"static":case"yield":case"let":return!0;default:return!1}}function d(e){return"eval"===e||"arguments"===e}function u(e){if(zr&&p(e))return!0;switch(e.length){case 2:return"if"===e||"in"===e||"do"===e;case 3:return"var"===e||"for"===e||"new"===e||"try"===e||"let"===e;case 4:return"this"===e||"else"===e||"case"===e||"void"===e||"with"===e||"enum"===e;case 5:return"while"===e||"break"===e||"catch"===e||"throw"===e||"const"===e||"yield"===e||"class"===e||"super"===e;case 6:return"return"===e||"typeof"===e||"delete"===e||"switch"===e||"export"===e||"import"===e;case 7:return"default"===e||"finally"===e||"extends"===e;case 8:return"function"===e||"continue"===e||"debugger"===e;case 10:return"instanceof"===e;default:return!1}}function h(e,r,n,o,s){var a;t("number"==typeof n,"Comment must have valid position"),Vr.lastCommentStart=n,a={type:e,value:r},$r.range&&(a.range=[n,o]),$r.loc&&(a.loc=s),$r.comments.push(a),$r.attachComment&&($r.leadingComments.push(a),$r.trailingComments.push(a))}function f(e){var t,r,n,o;for(t=Cr-e,r={start:{line:Pr,column:Cr-Ir-e}};Br>Cr;)if(n=Ar.charCodeAt(Cr),++Cr,a(n))return Nr=!0,$r.comments&&(o=Ar.slice(t+e,Cr-1),r.end={line:Pr,column:Cr-Ir-1},h("Line",o,t,Cr-1,r)),13===n&&10===Ar.charCodeAt(Cr)&&++Cr,++Pr,void(Ir=Cr);$r.comments&&(o=Ar.slice(t+e,Cr),r.end={line:Pr,column:Cr-Ir},h("Line",o,t,Cr,r))}function m(){var e,t,r,n;for($r.comments&&(e=Cr-2,t={start:{line:Pr,column:Cr-Ir-2}});Br>Cr;)if(r=Ar.charCodeAt(Cr),a(r))13===r&&10===Ar.charCodeAt(Cr+1)&&++Cr,Nr=!0,++Pr,++Cr,Ir=Cr;else if(42===r){if(47===Ar.charCodeAt(Cr+1))return++Cr,++Cr,void($r.comments&&(n=Ar.slice(e+2,Cr-2),t.end={line:Pr,column:Cr-Ir},h("Block",n,e,Cr,t)));++Cr}else++Cr;Cr>=Br&&$r.comments?(t.end={line:Pr,column:Cr-Ir},n=Ar.slice(e+2,Cr),h("Block",n,e,Cr,t),Z()):Q()}function g(){var e,t;for(Nr=!1,t=0===Cr;Br>Cr;)if(e=Ar.charCodeAt(Cr),s(e))++Cr;else if(a(e))Nr=!0,++Cr,13===e&&10===Ar.charCodeAt(Cr)&&++Cr,++Pr,Ir=Cr,t=!0;else if(47===e)if(e=Ar.charCodeAt(Cr+1),47===e)++Cr,++Cr,f(2),t=!0;else{if(42!==e)break;++Cr,++Cr,m()}else if(t&&45===e){if(45!==Ar.charCodeAt(Cr+1)||62!==Ar.charCodeAt(Cr+2))break;Cr+=3,f(3)}else{if(60!==e)break;if("!--"!==Ar.slice(Cr+1,Cr+4))break;++Cr,++Cr,++Cr,++Cr,f(4)}}function b(e){var t,r,o,s=0;for(r="u"===e?4:2,t=0;r>t;++t){if(!(Br>Cr&&n(Ar[Cr])))return"";o=Ar[Cr++],s=16*s+"0123456789abcdef".indexOf(o.toLowerCase())}return String.fromCharCode(s)}function y(){var e,t,r,o;for(e=Ar[Cr],t=0,"}"===e&&Q();Br>Cr&&(e=Ar[Cr++],n(e));)t=16*t+"0123456789abcdef".indexOf(e.toLowerCase());return(t>1114111||"}"!==e)&&Q(),65535>=t?String.fromCharCode(t):(r=(t-65536>>10)+55296,o=(t-65536&1023)+56320,String.fromCharCode(r,o))}function v(){var e,t;for(e=Ar.charCodeAt(Cr++),t=String.fromCharCode(e),92===e&&(117!==Ar.charCodeAt(Cr)&&Q(),++Cr,e=b("u"),e&&"\\"!==e&&i(e.charCodeAt(0))||Q(),t=e);Br>Cr&&(e=Ar.charCodeAt(Cr),l(e));)++Cr,t+=String.fromCharCode(e),92===e&&(t=t.substr(0,t.length-1),117!==Ar.charCodeAt(Cr)&&Q(),++Cr,e=b("u"),e&&"\\"!==e&&l(e.charCodeAt(0))||Q(),t+=e);return t}function w(){var e,t;for(e=Cr++;Br>Cr;){if(t=Ar.charCodeAt(Cr),92===t)return Cr=e,v();if(!l(t))break;++Cr}return Ar.slice(e,Cr)}function _(){var e,t,r;return e=Cr,t=92===Ar.charCodeAt(Cr)?v():w(),r=1===t.length?Er.Identifier:u(t)?Er.Keyword:"null"===t?Er.NullLiteral:"true"===t||"false"===t?Er.BooleanLiteral:Er.Identifier,{type:r,value:t,lineNumber:Pr,lineStart:Ir,start:e,end:Cr}}function S(){var e,t,r,n,o=Cr,s=Ar.charCodeAt(Cr),a=Ar[Cr];switch(s){case 46:case 40:case 41:case 59:case 44:case 123:case 125:case 91:case 93:case 58:case 63:case 126:return++Cr,$r.tokenize&&(40===s?$r.openParenToken=$r.tokens.length:123===s&&($r.openCurlyToken=$r.tokens.length)),{type:Er.Punctuator,value:String.fromCharCode(s),lineNumber:Pr,lineStart:Ir,start:o,end:Cr};default:if(e=Ar.charCodeAt(Cr+1),61===e)switch(s){case 43:case 45:case 47:case 60:case 62:case 94:case 124:case 37:case 38:case 42:return Cr+=2,{type:Er.Punctuator,value:String.fromCharCode(s)+String.fromCharCode(e),lineNumber:Pr,lineStart:Ir,start:o,end:Cr};case 33:case 61:return Cr+=2,61===Ar.charCodeAt(Cr)&&++Cr,{type:Er.Punctuator,value:Ar.slice(o,Cr),lineNumber:Pr,lineStart:Ir,start:o,end:Cr}}}if(n=Ar.substr(Cr,4),">>>="===n)return Cr+=4,{type:Er.Punctuator,value:n,lineNumber:Pr,lineStart:Ir,start:o,end:Cr};if(r=n.substr(0,3),">>>"===r||"<<="===r||">>="===r)return Cr+=3,{type:Er.Punctuator,value:r,lineNumber:Pr,lineStart:Ir,start:o,end:Cr};if(t=r.substr(0,2),a===t[1]&&"+-<>&|".indexOf(a)>=0||"=>"===t)return Cr+=2,{type:Er.Punctuator,value:t,lineNumber:Pr,lineStart:Ir,start:o,end:Cr};if("<>=!+-*%&|^/".indexOf(a)>=0)return++Cr,{type:Er.Punctuator,value:a,lineNumber:Pr,lineStart:Ir,start:o,end:Cr};++Cr;var i={type:Er.Punctuator,lineNumber:Pr,lineStart:Ir,start:o,end:Cr,value:Ar.slice(o,Cr)};Q(i)}function T(e){for(var t="";Br>Cr&&n(Ar[Cr]);)t+=Ar[Cr++];return 0===t.length&&Q(),i(Ar.charCodeAt(Cr))&&Q(),{type:Er.NumericLiteral,value:parseInt("0x"+t,16),lineNumber:Pr,lineStart:Ir,start:e,end:Cr}}function E(e){var t,n;for(n="";Br>Cr&&(t=Ar[Cr],"0"===t||"1"===t);)n+=Ar[Cr++];return 0===n.length&&Q(),Br>Cr&&(t=Ar.charCodeAt(Cr),(i(t)||r(t))&&Q()),{type:Er.NumericLiteral,value:parseInt(n,2),lineNumber:Pr,lineStart:Ir,start:e,end:Cr}}function x(e,t){var n,s;for(o(e)?(s=!0,n="0"+Ar[Cr++]):(s=!1,++Cr,n="");Br>Cr&&o(Ar[Cr]);)n+=Ar[Cr++];return s||0!==n.length||Q(),(i(Ar.charCodeAt(Cr))||r(Ar.charCodeAt(Cr)))&&Q(),{type:Er.NumericLiteral,value:parseInt(n,8),octal:s,lineNumber:Pr,lineStart:Ir,start:t,end:Cr}}function j(){var e,t;for(e=Cr+1;Br>e;++e){if(t=Ar[e],"8"===t||"9"===t)return!1;if(!o(t))return!0}return!0}function O(){var e,n,s;if(s=Ar[Cr],t(r(s.charCodeAt(0))||"."===s,"Numeric literal must start with a decimal digit or a decimal point"),n=Cr,e="","."!==s){if(e=Ar[Cr++],s=Ar[Cr],"0"===e){if("x"===s||"X"===s)return++Cr,T(n);if("b"===s||"B"===s)return++Cr,E(n);if("o"===s||"O"===s)return x(s,n);if(o(s)&&j())return x(s,n)}for(;r(Ar.charCodeAt(Cr));)e+=Ar[Cr++];s=Ar[Cr]}if("."===s){for(e+=Ar[Cr++];r(Ar.charCodeAt(Cr));)e+=Ar[Cr++];s=Ar[Cr]}if("e"===s||"E"===s)if(e+=Ar[Cr++],s=Ar[Cr],("+"===s||"-"===s)&&(e+=Ar[Cr++]),r(Ar.charCodeAt(Cr)))for(;r(Ar.charCodeAt(Cr));)e+=Ar[Cr++];else Q();return i(Ar.charCodeAt(Cr))&&Q(),{type:Er.NumericLiteral,value:parseFloat(e),lineNumber:Pr,lineStart:Ir,start:n,end:Cr}}function k(){var e,r,n,s,i,l,c="",p=!1;for(e=Ar[Cr],t("'"===e||'"'===e,"String literal must starts with a quote"),r=Cr,++Cr;Br>Cr;){if(n=Ar[Cr++],n===e){e="";break}if("\\"===n)if(n=Ar[Cr++],n&&a(n.charCodeAt(0)))++Pr,"\r"===n&&"\n"===Ar[Cr]&&++Cr,Ir=Cr;else switch(n){case"u":case"x":"{"===Ar[Cr]?(++Cr,c+=y()):(l=Cr,i=b(n),i?c+=i:(Cr=l,c+=n));break;case"n":c+="\n";break;case"r":c+="\r";break;case"t":c+="	";break;case"b":c+="\b";break;case"f":c+="\f";break;case"v":c+="";break;default:o(n)?(s="01234567".indexOf(n),0!==s&&(p=!0),Br>Cr&&o(Ar[Cr])&&(p=!0,s=8*s+"01234567".indexOf(Ar[Cr++]),"0123".indexOf(n)>=0&&Br>Cr&&o(Ar[Cr])&&(s=8*s+"01234567".indexOf(Ar[Cr++]))),c+=String.fromCharCode(s)):c+=n}else{if(a(n.charCodeAt(0)))break;c+=n}}var d={type:Er.StringLiteral,value:c,octal:p,lineNumber:Gr,lineStart:Wr,start:r,end:Cr};return""!==e&&Z(d),d}function R(e,t){var r=e;t.indexOf("u")>=0&&(r=r.replace(/\\u\{([0-9a-fA-F]+)\}/g,function(e,t){return parseInt(t,16)<=1114111?"x":void Q(null,Mr.InvalidRegExp)}).replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,"x"));try{RegExp(r)}catch(n){Q(null,Mr.InvalidRegExp)}try{return new RegExp(e,t)}catch(o){return null}}function M(){var e,r,n,o,s;for(e=Ar[Cr],t("/"===e,"Regular expression literal must start with a slash"),r=Ar[Cr++],n=!1,o=!1;Br>Cr;)if(e=Ar[Cr++],r+=e,"\\"===e)e=Ar[Cr++],a(e.charCodeAt(0))&&Q(null,Mr.UnterminatedRegExp),r+=e;else if(a(e.charCodeAt(0)))Q(null,Mr.UnterminatedRegExp);else if(n)"]"===e&&(n=!1);else{if("/"===e){o=!0;break}"["===e&&(n=!0)}return o||Q(Jr,Mr.UnterminatedRegExp),s=r.substr(1,r.length-2),{value:s,literal:r}}function D(){var e,t,r,n;for(t="",r="";Br>Cr&&(e=Ar[Cr],l(e.charCodeAt(0)));)if(++Cr,"\\"===e&&Br>Cr)if(e=Ar[Cr],"u"===e){if(++Cr,n=Cr,e=b("u"))for(r+=e,t+="\\u";Cr>n;++n)t+=Ar[n];else Cr=n,r+="u",t+="\\u";Z()}else t+="\\",Z();else r+=e,t+=e;return{value:r,literal:t}}function A(){Hr=!0;var e,t,r,n;return g(),e=Cr,t=M(),r=D(),n=R(t.value,r.value),Hr=!1,$r.tokenize?{type:Er.RegularExpression,value:n,regex:{pattern:t.value,flags:r.value},lineNumber:Pr,lineStart:Ir,start:e,end:Cr}:{literal:t.literal+r.literal,value:n,regex:{pattern:t.value,flags:r.value},start:e,end:Cr}}function z(){var e,t,r,n;return g(),e=Cr,t={start:{line:Pr,column:Cr-Ir}},r=A(),t.end={line:Pr,column:Cr-Ir},$r.tokenize||($r.tokens.length>0&&(n=$r.tokens[$r.tokens.length-1],n.range[0]===e&&"Punctuator"===n.type&&("/"===n.value||"/="===n.value)&&$r.tokens.pop()),$r.tokens.push({type:"RegularExpression",value:r.literal,regex:r.regex,range:[e,Cr],loc:t})),r}function C(e){return e.type===Er.Identifier||e.type===Er.Keyword||e.type===Er.BooleanLiteral||e.type===Er.NullLiteral}function P(){var e,t;if(e=$r.tokens[$r.tokens.length-1],!e)return z();if("Punctuator"===e.type){if("]"===e.value)return S();if(")"===e.value)return t=$r.tokens[$r.openParenToken-1],!t||"Keyword"!==t.type||"if"!==t.value&&"while"!==t.value&&"for"!==t.value&&"with"!==t.value?S():z();if("}"===e.value){if($r.tokens[$r.openCurlyToken-3]&&"Keyword"===$r.tokens[$r.openCurlyToken-3].type){if(t=$r.tokens[$r.openCurlyToken-4],!t)return S()}else{if(!$r.tokens[$r.openCurlyToken-4]||"Keyword"!==$r.tokens[$r.openCurlyToken-4].type)return S();if(t=$r.tokens[$r.openCurlyToken-5],!t)return z()}return jr.indexOf(t.value)>=0?S():z()}return z()}return"Keyword"===e.type&&"this"!==e.value?z():S()}function I(){var e;return Cr>=Br?{type:Er.EOF,lineNumber:Pr,lineStart:Ir,start:Cr,end:Cr,range:[Cr,Cr]}:(e=Ar.charCodeAt(Cr),i(e)?_():40===e||41===e||59===e?S():39===e||34===e?k():46===e?r(Ar.charCodeAt(Cr+1))?O():S():r(e)?O():$r.tokenize&&47===e?P():S())}function N(){var e,t,r,n;return e={start:{line:Pr,column:Cr-Ir}},t=I(),e.end={line:Pr,column:Cr-Ir},t.type!==Er.EOF&&(r=Ar.slice(t.start,t.end),n={type:xr[t.type],value:r,range:[t.start,t.end],loc:e},t.regex&&(n.regex={pattern:t.regex.pattern,flags:t.regex.flags}),$r.tokens.push(n)),t}function U(){var e;return Hr=!0,Ur=Cr,Lr=Pr,qr=Ir,g(),e=Jr,Fr=Cr,Gr=Pr,Wr=Ir,Jr="undefined"!=typeof $r.tokens?N():I(),Hr=!1,e}function L(){Hr=!0,g(),Ur=Cr,Lr=Pr,qr=Ir,Fr=Cr,Gr=Pr,Wr=Ir,Jr="undefined"!=typeof $r.tokens?N():I(),Hr=!1}function q(e){if($r.deps)for(var t=e.length,r=0;t>r;r++)F(e[r])}function F(e){if($r.deps&&e.type===Or.Literal){for(var t=0;t<$r.deps.length;t++)if($r.deps[t].value===e.value)return;$r.deps.push(e)}}function G(e,t){if($r.deps){var r=t.length;if("importScripts"===e.name)q(t);else if("Worker"===e.name)F(t[0]);else if("require"===e.name){var n=t[0];n.type===Or.ArrayExpression?($r.envs.node=!0,q(n.elements)):n.type===Or.Literal&&($r.envs.node=!0,F(n)),r>1&&(n=t[1],n.type===Or.ArrayExpression&&($r.envs.node=!0,q(n.elements)))}else"requirejs"===e.name?(n=t[0],n.type===Or.ArrayExpression&&($r.envs.amd=!0,q(n.elements))):"define"===e.name&&r>1&&(n=t[0],n.type===Or.Literal&&(n=t[1]),n.type===Or.ArrayExpression&&($r.envs.amd=!0,q(n.elements)))}}function W(){this.line=Gr,this.column=Fr-Wr}function H(){this.start=new W,this.end=null}function B(e){this.start={line:e.lineNumber,column:e.start-e.lineStart},this.end=null}function J(){$r.loc&&(this.loc=new H),$r.range&&(this.range=[Fr,0]),$r.directSourceFile&&(this.sourceFile=$r.directSourceFile)}function V(e){$r.loc&&(this.loc=new B(e)),$r.range&&(this.range=[e.start,0]),$r.directSourceFile&&(this.sourceFile=$r.directSourceFile)}function $(e,t,r,n){var o=new Error("Line "+e+": "+r);if(o.index=t,o.lineNumber=e,o.column=t-(Hr?Ir:qr)+1,o.description=r,n){var s=n;2===n.type&&$r&&Array.isArray($r.tokens)&&$r.tokens.length>0&&(s=$r.tokens[$r.tokens.length-1]),o.index="number"==typeof s.start?s.start:s.range[0],o.token=s.value,o.end="number"==typeof s.end?s.end:s.range[1]}return o}function X(e){var r,n;throw r=Array.prototype.slice.call(arguments,1),n=e.replace(/%(\d)/g,function(e,n){return t(n<r.length,"Message reference must be in range"),r[n]}),$(Lr,Ur,n)}function Y(e){var r,n,o;if(r=Array.prototype.slice.call(arguments,1),n=e.replace(/%(\d)/g,function(e,n){return t(n<r.length,"Message reference must be in range"),r[n]}),o=$(Pr,Ur,n),!$r.errors)throw o;$r.errors.push(o)}function K(e,t,r){var n=t||Mr.UnexpectedToken;e&&!t&&(n=e.type===Er.EOF?Mr.UnexpectedEOS:e.type===Er.Identifier?Mr.UnexpectedIdentifier:e.type===Er.NumericLiteral?Mr.UnexpectedNumber:e.type===Er.StringLiteral?Mr.UnexpectedString:Mr.UnexpectedToken,e.type===Er.Keyword&&(c(e.value)?n=Mr.UnexpectedReserved:zr&&p(e.value)&&(n=Mr.StrictReservedWord)));var o=null!=r?r:e?e.value:"ILLEGAL";return n=n.replace("%0",o),e&&"number"==typeof e.lineNumber?$(e.lineNumber,e.start,n,e):$(Hr?Pr:Lr,Hr?Cr:Ur,n,e)}function Q(e,t){throw K(e,t)}function Z(e,t,r){var n=K(e,t,r);if(!$r.errors)throw n;$r.errors.push(n)}function et(e){var t=U();(t.type!==Er.Punctuator||t.value!==e)&&Q(t)}function tt(e){var t;if($r.errors)if(t=Jr,t.type===Er.Punctuator&&","===t.value)U();else if(t.type===Er.Punctuator&&";"===t.value)if(U(),Jr.value===e)Z(t,Mr.UnexpectedToken,";");else{var r=e&&e!==t.value?e:";";$r.tokens&&$r.tokens.length>0&&(t=$r.tokens[$r.tokens.length-2]),Z(t,Mr.MissingToken,r)}else t.type!==Er.EOF&&($r.tokens&&$r.tokens.length>0&&(t=$r.tokens[$r.tokens.length-2]),Z(t,Mr.MissingToken,","));else et(",")}function rt(e){var t=U();(t.type!==Er.Keyword||t.value!==e)&&Q(t)}function nt(e){return Jr.type===Er.Punctuator&&Jr.value===e}function ot(e){return Jr.type===Er.Keyword&&Jr.value===e}function st(){var e;return Jr.type!==Er.Punctuator?!1:(e=Jr.value,"="===e||"*="===e||"/="===e||"%="===e||"+="===e||"-="===e||"<<="===e||">>="===e||">>>="===e||"&="===e||"^="===e||"|="===e)}function at(){try{if(59===Ar.charCodeAt(Fr)||nt(";"))return void U();if(Nr)return;if(Ur=Fr,Lr=Gr,qr=Wr,Jr.type!==Er.EOF&&!nt("}")){var e=Jr;$r.errors&&vr(Wr),Q(e)}}catch(t){if($r.errors)return void gr(t);throw t}}function it(e){return e.type===Or.Identifier||e.type===Or.MemberExpression}function lt(){var e=[],t=new J;for(et("[");!nt("]");)nt(",")?(U(),e.push(null)):(e.push(Mt()),nt("]")||et(","));return U(),t.finishArrayExpression(e)}function ct(e,t){var r,n,o=new J;return r=zr,n=nr(),t&&zr&&d(e[0].name)&&Z(t,Mr.StrictParamName),zr=r,o.finishFunctionExpression(null,e,[],n)}function pt(){var e,t=new J;return e=U(),e.type===Er.StringLiteral||e.type===Er.NumericLiteral?(zr&&e.octal&&Z(e,Mr.StrictOctalLiteral),t.finishLiteral(e)):t.finishIdentifier(e.value)}function dt(){var e,t,r,n,o,s=new J;return e=Jr,e.type===Er.Identifier?(r=pt(),"get"!==e.value||nt(":")||nt("(")?"set"!==e.value||nt(":")||nt("(")?Tr(e,r,s):(t=pt(),et("("),e=Jr,e.type!==Er.Identifier?(et(")"),Z(e),n=ct([])):(o=[Ct()],et(")"),n=ct(o,e)),s.finishProperty("set",t,n,!1,!1)):(t=pt(),et("("),et(")"),n=ct([]),s.finishProperty("get",t,n,!1,!1))):e.type!==Er.EOF&&e.type!==Er.Punctuator?Tr(e,pt(),s):void Q(e)}function ut(){var e,t,r,n,o=[],s={},a=String,i=new J;for(et("{");!nt("}");)e=dt(),null!=e&&"undefined"!=typeof e&&(t=e.key.type===Or.Identifier?e.key.name:a(e.key.value),n="init"===e.kind?Rr.Data:"get"===e.kind?Rr.Get:Rr.Set,r="$"+t,Object.prototype.hasOwnProperty.call(s,r)?(s[r]===Rr.Data?zr&&n===Rr.Data?Y(Mr.StrictDuplicateProperty):n!==Rr.Data&&Y(Mr.AccessorDataProperty):n===Rr.Data?Y(Mr.AccessorDataProperty):s[r]&n&&Y(Mr.AccessorGetSet),s[r]|=n):s[r]=n,o.push(e),nt("}")||tt("}"));return et("}"),i.finishObjectExpression(o)}function ht(){var e;return et("("),nt(")")?(U(),kr.ArrowParameterPlaceHolder):(++Vr.parenthesisCount,e=Dt(),et(")"),e)}function ft(){var e,t,r,n;if(nt("("))return ht();if(nt("["))return lt();if(nt("{"))return ut();if(e=Jr.type,n=new J,e===Er.Identifier)r=n.finishIdentifier(U().value);else if(e===Er.StringLiteral||e===Er.NumericLiteral)zr&&Jr.octal&&Z(Jr,Mr.StrictOctalLiteral),r=n.finishLiteral(U());else if(e===Er.Keyword){if(ot("function"))return lr();ot("this")?(U(),r=n.finishThisExpression()):Q(U())}else e===Er.BooleanLiteral?(t=U(),t.value="true"===t.value,r=n.finishLiteral(t)):e===Er.NullLiteral?(t=U(),t.value=null,r=n.finishLiteral(t)):nt("/")||nt("/=")?(Cr=Fr,t="undefined"!=typeof $r.tokens?z():A(),U(),r=n.finishLiteral(t)):Q(U());return r}function mt(){var e=[];if(et("("),!nt(")"))for(;Br>Fr&&(e.push(Mt()),!nt(")"));)tt(")");return mr(")"),e}function gt(){var e,t=new J;try{e=U(),C(e)||($r.errors&&_r(e),Q(e))}catch(r){if($r.errors)return gr(r),Sr(t,Or.Identifier);throw r}return t.finishIdentifier(e.value)}function bt(){return et("."),gt()}function yt(){var e;return et("["),e=Dt(),et("]"),e}function vt(){var e,t,r=new J;return rt("new"),e=_t(),t=nt("(")?mt():[],r.finishNewExpression(e,t)}function wt(){var e,t,r,n,o=Vr.allowIn;for(n=Jr,Vr.allowIn=!0,e=ot("new")?vt():ft();;)if(nt("."))r=bt(),e=new V(n).finishMemberExpression(".",e,r);else if(nt("("))t=mt(),e=new V(n).finishCallExpression(e,t);else{if(!nt("["))break;r=yt(),e=new V(n).finishMemberExpression("[",e,r)}return Vr.allowIn=o,e}function _t(){var e,r,n;for(t(Vr.allowIn,"callee of new expression always allow in keyword."),n=Jr,e=ot("new")?vt():ft();;)if(nt("["))r=yt(),e=new V(n).finishMemberExpression("[",e,r);else{if(!nt("."))break;r=bt(),e=new V(n).finishMemberExpression(".",e,r)}return e}function St(){var e,t,r=Jr;return e=wt(),Nr||Jr.type!==Er.Punctuator||(nt("++")||nt("--"))&&(zr&&e.type===Or.Identifier&&d(e.name)&&Y(Mr.StrictLHSPostfix),it(e)||Y(Mr.InvalidLHSInAssignment),t=U(),e=new V(r).finishPostfixExpression(t.value,e)),e}function Tt(){var e,t,r;return Jr.type!==Er.Punctuator&&Jr.type!==Er.Keyword?t=St():nt("++")||nt("--")?(r=Jr,e=U(),t=Tt(),zr&&t.type===Or.Identifier&&d(t.name)&&Y(Mr.StrictLHSPrefix),it(t)||Y(Mr.InvalidLHSInAssignment),t=new V(r).finishUnaryExpression(e.value,t)):nt("+")||nt("-")||nt("~")||nt("!")?(r=Jr,e=U(),t=Tt(),t=new V(r).finishUnaryExpression(e.value,t)):ot("delete")||ot("void")||ot("typeof")?(r=Jr,e=U(),t=Tt(),t=new V(r).finishUnaryExpression(e.value,t),zr&&"delete"===t.operator&&t.argument.type===Or.Identifier&&Y(Mr.StrictDelete)):t=St(),t}function Et(e,t){var r=0;if(e.type!==Er.Punctuator&&e.type!==Er.Keyword)return 0;switch(e.value){case"||":r=1;break;case"&&":r=2;break;case"|":r=3;break;case"^":r=4;break;case"&":r=5;break;case"==":case"!=":case"===":case"!==":r=6;break;case"<":case">":case"<=":case">=":case"instanceof":r=7;break;case"in":r=t?7:0;break;case"<<":case">>":case">>>":r=8;break;case"+":case"-":r=9;break;case"*":case"/":case"%":r=11}return r}function xt(){var e,t,r,n,o,s,a,i,l,c;if(e=Jr,l=Tt(),l===kr.ArrowParameterPlaceHolder)return l;if(n=Jr,o=Et(n,Vr.allowIn),0===o)return l;for(n.prec=o,U(),t=[e,Jr],a=Tt(),s=[l,n,a];(o=Et(Jr,Vr.allowIn))>0;){for(;s.length>2&&o<=s[s.length-2].prec;)a=s.pop(),i=s.pop().value,l=s.pop(),t.pop(),r=new V(t[t.length-1]).finishBinaryExpression(i,l,a),s.push(r);n=U(),n.prec=o,s.push(n),t.push(Jr),r=Tt(),s.push(r)}for(c=s.length-1,r=s[c],t.pop();c>1;)r=new V(t.pop()).finishBinaryExpression(s[c-1].value,s[c-2],r),c-=2;return r}function jt(){var e,t,r,n,o;return o=Jr,e=xt(),e===kr.ArrowParameterPlaceHolder?e:(nt("?")&&(U(),t=Vr.allowIn,Vr.allowIn=!0,r=Mt(),Vr.allowIn=t,et(":"),n=Mt(),e=new V(o).finishConditionalExpression(e,r,n)),e)}function Ot(){return nt("{")?nr():Mt()}function kt(e){var t,r,n,o,s,a,i,l,c;for(o=[],s=[],a=0,l=null,i={paramSet:{}},t=0,r=e.length;r>t;t+=1)if(n=e[t],n.type===Or.Identifier)o.push(n),s.push(null),or(i,n,n.name);else{if(n.type!==Or.AssignmentExpression)return null;o.push(n.left),s.push(n.right),++a,or(i,n.left,n.left.name)}return i.message===Mr.StrictParamDupe&&(c=zr?i.stricted:i.firstRestricted,Q(c,i.message)),0===a&&(s=[]),{params:o,defaults:s,rest:l,stricted:i.stricted,firstRestricted:i.firstRestricted,message:i.message}}function Rt(e,t){var r,n;return et("=>"),r=zr,n=Ot(),zr&&e.firstRestricted&&Q(e.firstRestricted,e.message),zr&&e.stricted&&Z(e.stricted,e.message),zr=r,t.finishArrowFunctionExpression(e.params,e.defaults,n,n.type!==Or.BlockStatement)}function Mt(){var e,t,r,n,o,s;return e=Vr.parenthesisCount,s=Jr,t=Jr,r=jt(),r!==kr.ArrowParameterPlaceHolder&&!nt("=>")||Vr.parenthesisCount!==e&&Vr.parenthesisCount!==e+1||(r.type===Or.Identifier?o=kt([r]):r.type===Or.AssignmentExpression?o=kt([r]):r.type===Or.SequenceExpression?o=kt(r.expressions):r===kr.ArrowParameterPlaceHolder&&(o=kt([])),!o)?(st()&&(it(r)||Y(Mr.InvalidLHSInAssignment),zr&&r.type===Or.Identifier&&d(r.name)&&Z(t,Mr.StrictLHSAssignment),t=U(),n=Mt(),r=new V(s).finishAssignmentExpression(t.value,r,n)),r):Rt(o,new V(s))}function Dt(){var e,t,r=Jr;if(e=Mt(),nt(",")){for(t=[e];Br>Fr&&nt(",");)U(),t.push(Mt());e=new V(r).finishSequenceExpression(t)}return e}function At(){for(var e,t=[],r=Cr;Br>Fr&&!nt("}")&&(e=cr(),"undefined"!=typeof e&&r!==Cr);)t.push(e),r=Cr;return t}function zt(){var e,t=new J;return et("{"),e=At(),mr("}"),t.finishBlockStatement(e)}function Ct(){var e,t=new J;return e=U(),e.type!==Er.Identifier&&(zr&&e.type===Er.Keyword&&p(e.value)?Z(e,Mr.StrictReservedWord):Q(e)),t.finishIdentifier(e.value)}function Pt(e){var t,r=null,n=new J;return t=Ct(),zr&&d(t.name)&&Y(Mr.StrictVarName),"const"===e?(et("="),r=Mt()):nt("=")&&(U(),r=Mt()),n.finishVariableDeclarator(t,r)}function It(e){var t=[];do{if(t.push(Pt(e)),!nt(","))break;U()}while(Br>Fr);return t}function Nt(e){var t;return rt("var"),t=It(),at(),e.finishVariableDeclaration(t,"var")}function Ut(e){var t,r=new J;return rt(e),t=It(e),at(),r.finishVariableDeclaration(t,e)}function Lt(){var e=new J;return et(";"),e.finishEmptyStatement()}function qt(e){var t=Dt();return at(),t||(t=Sr(e)),e.finishExpressionStatement(t)}function Ft(e){var t,r,n;return rt("if"),et("("),t=Dt(),mr(")","{"),r=rr(),ot("else")?(U(),n=rr()):n=null,e.finishIfStatement(t,r,n)}function Gt(e){var t,r,n;return rt("do"),n=Vr.inIteration,Vr.inIteration=!0,t=rr(),Vr.inIteration=n,rt("while"),et("("),r=Dt(),mr(")","{"),nt(";")&&U(),e.finishDoWhileStatement(t,r)}function Wt(e){var t,r,n;return rt("while"),et("("),t=Dt(),mr(")","{"),n=Vr.inIteration,Vr.inIteration=!0,r=rr(),Vr.inIteration=n,e.finishWhileStatement(t,r)}function Ht(){var e,t,r=new J;return e=U(),t=It(),r.finishVariableDeclaration(t,e.value)}function Bt(e){var t,r,n,o,s,a,i,l=Vr.allowIn;return t=r=n=null,rt("for"),et("("),nt(";")?U():(ot("var")||ot("let")?(Vr.allowIn=!1,t=Ht(),Vr.allowIn=l,1===t.declarations.length&&ot("in")&&(U(),o=t,s=Dt(),t=null)):(Vr.allowIn=!1,t=Dt(),Vr.allowIn=l,ot("in")&&(it(t)||Y(Mr.InvalidLHSInForIn),U(),o=t,s=Dt(),t=null)),"undefined"==typeof o&&et(";")),"undefined"==typeof o&&(nt(";")||(r=Dt()),et(";"),nt(")")||(n=Dt())),mr(")","{"),i=Vr.inIteration,Vr.inIteration=!0,a=rr(),Vr.inIteration=i,"undefined"==typeof o?e.finishForStatement(t,r,n,a):e.finishForInStatement(o,s,a)}function Jt(e){var t,r=null;if(rt("continue"),59===Ar.charCodeAt(Fr))return U(),Vr.inIteration||X(Mr.IllegalContinue),e.finishContinueStatement(null);if(Nr)return Vr.inIteration||X(Mr.IllegalContinue),e.finishContinueStatement(null);if(Jr.type===Er.Identifier){var n=Jr;r=Ct(),t="$"+r.name,Object.prototype.hasOwnProperty.call(Vr.labelSet,t)||Z(n,Mr.UnknownLabel,r.name)}return at(),null!==r||Vr.inIteration||X(Mr.IllegalContinue),e.finishContinueStatement(r)}function Vt(e){var t,r=null;return rt("break"),59===Ar.charCodeAt(Ur)?(U(),Vr.inIteration||Vr.inSwitch||X(Mr.IllegalBreak),e.finishBreakStatement(null)):Nr?(Vr.inIteration||Vr.inSwitch||X(Mr.IllegalBreak),e.finishBreakStatement(null)):(Jr.type===Er.Identifier&&(r=Ct(),t="$"+r.name,Object.prototype.hasOwnProperty.call(Vr.labelSet,t)||X(Mr.UnknownLabel,r.name)),at(),null!==r||Vr.inIteration||Vr.inSwitch||X(Mr.IllegalBreak),e.finishBreakStatement(r))}function $t(e){var t=null,r=Jr;return rt("return"),Vr.inFunctionBody||Z(r,Mr.IllegalReturn,r.value),32===Ar.charCodeAt(Ur)&&i(Ar.charCodeAt(Ur+1))?(t=Dt(),at(),e.finishReturnStatement(t)):Nr?e.finishReturnStatement(null):(nt(";")||nt("}")||Jr.type===Er.EOF||(t=Dt()),at(),e.finishReturnStatement(t))}function Xt(e){var t,r;return zr&&Y(Mr.StrictModeWith),rt("with"),et("("),t=Dt(),mr(")","{"),r=rr(),e.finishWithStatement(t,r)}function Yt(){var e,t,r=[],n=new J;ot("default")?(U(),e=null):(rt("case"),e=Dt()),nt(":")&&U();for(var o=Cr;Br>Fr&&!(nt("}")||ot("default")||ot("case"))&&(t=rr(),"undefined"!=typeof t&&null!==t)&&(r.push(t),o!==Cr);)o=Cr;return n.finishSwitchCase(e,r)}function Kt(e){var t,r,n,o,s;if(rt("switch"),et("("),t=Dt(),et(")"),et("{"),r=[],nt("}"))return U(),e.finishSwitchStatement(t,r);for(o=Vr.inSwitch,Vr.inSwitch=!0,s=!1;Br>Fr&&!nt("}");)n=Yt(),null===n.test&&(s&&X(Mr.MultipleDefaultsInSwitch),s=!0),r.push(n);return Vr.inSwitch=o,et("}"),e.finishSwitchStatement(t,r)}function Qt(e){var t;return rt("throw"),Nr&&X(Mr.NewlineAfterThrow),t=Dt(),at(),e.finishThrowStatement(t)}function Zt(){var e,t,r=new J;return rt("catch"),et("("),nt(")")&&Q(Jr),e=Ct(),zr&&d(e.name)&&Y(Mr.StrictCatchVariable),et(")"),t=zt(),r.finishCatchClause(e,t)}function er(e){var t,r=[],n=null;return rt("try"),t=zt(),ot("catch")&&r.push(Zt()),ot("finally")&&(U(),n=zt()),0!==r.length||n||X(Mr.NoCatchOrFinally),e.finishTryStatement(t,[],r,n)}function tr(e){return rt("debugger"),at(),e.finishDebuggerStatement()}function rr(){var e,t,r,n,o=Jr.type;if(o===Er.EOF&&Q(Jr),o===Er.Punctuator&&"{"===Jr.value)return zt();if(n=new J,o===Er.Punctuator)switch(Jr.value){case";":return Lt(n);case"(":return qt(n)}else if(o===Er.Keyword)switch(Jr.value){case"break":return Vt(n);case"continue":return Jt(n);case"debugger":return tr(n);case"do":return Gt(n);case"for":return Bt(n);case"function":return ir(n);case"if":return Ft(n);case"return":return $t(n);case"switch":return Kt(n);case"throw":return Qt(n);case"try":return er(n);case"var":return Nt(n);case"while":return Wt(n);case"with":return Xt(n)}return e=Dt(),e&&e.type===Or.Identifier&&nt(":")?(U(),r="$"+e.name,Object.prototype.hasOwnProperty.call(Vr.labelSet,r)&&X(Mr.Redeclaration,"Label",e.name),Vr.labelSet[r]=!0,t=rr(),delete Vr.labelSet[r],n.finishLabeledStatement(e,t)):(at(),e||(e=Sr(n)),n.finishExpressionStatement(e))}function nr(){var e,t,r,n,o,s,a,i,l,c=[],p=new J;for(et("{");Br>Fr&&Jr.type===Er.StringLiteral&&(t=Jr,e=cr(),c.push(e),e.expression.type===Or.Literal);)r=Ar.slice(t.start+1,t.end-1),"use strict"===r?(zr=!0,n&&Z(n,Mr.StrictOctalLiteral)):!n&&t.octal&&(n=t);o=Vr.labelSet,s=Vr.inIteration,a=Vr.inSwitch,i=Vr.inFunctionBody,l=Vr.parenthesizedCount,Vr.labelSet={},Vr.inIteration=!1,Vr.inSwitch=!1,Vr.inFunctionBody=!0,Vr.parenthesizedCount=0;for(var d=Cr;Br>Cr&&!nt("}")&&(e=cr(),"undefined"!=typeof e&&null!=e)&&(c.push(e),d!==Cr);)d=Cr;return mr("}"),Vr.labelSet=o,Vr.inIteration=s,Vr.inSwitch=a,Vr.inFunctionBody=i,Vr.parenthesizedCount=l,p.finishBlockStatement(c)}function or(e,t,r){var n="$"+r;zr?(d(r)&&(e.stricted=t,e.message=Mr.StrictParamName),Object.prototype.hasOwnProperty.call(e.paramSet,n)&&(e.stricted=t,e.message=Mr.StrictParamDupe)):e.firstRestricted||(d(r)?(e.firstRestricted=t,e.message=Mr.StrictParamName):p(r)?(e.firstRestricted=t,e.message=Mr.StrictReservedWord):Object.prototype.hasOwnProperty.call(e.paramSet,n)&&(e.firstRestricted=t,e.message=Mr.StrictParamDupe)),e.paramSet[n]=!0}function sr(e){var t,r,n;return t=Jr,r=Ct(),or(e,t,t.value),nt("=")&&(U(),n=Mt(),++e.defaultCount),e.params.push(r),e.defaults.push(n),!nt(")")}function ar(e){var t;if(t={params:[],defaultCount:0,defaults:[],firstRestricted:e},et("("),!nt(")"))for(t.paramSet={};Br>Fr&&sr(t);)et(",");return et(")"),0===t.defaultCount&&(t.defaults=[]),{params:t.params,defaults:t.defaults,stricted:t.stricted,firstRestricted:t.firstRestricted,message:t.message}}function ir(){var e,t,r,n,o,s,a,i,l=[],c=[],u=new J;return rt("function"),r=Jr,e=Ct(),zr?d(r.value)&&Z(r,Mr.StrictFunctionName):d(r.value)?(s=r,a=Mr.StrictFunctionName):p(r.value)&&(s=r,a=Mr.StrictReservedWord),o=ar(s),l=o.params,c=o.defaults,n=o.stricted,s=o.firstRestricted,o.message&&(a=o.message),i=zr,t=nr(),zr&&s&&Q(s,a),zr&&n&&Z(n,a),zr=i,u.finishFunctionDeclaration(e,l,c,t)}function lr(){var e,t,r,n,o,s,a,i=null,l=[],c=[],u=new J;return rt("function"),nt("(")||(e=Jr,i=Ct(),zr?d(e.value)&&Z(e,Mr.StrictFunctionName):d(e.value)?(r=e,n=Mr.StrictFunctionName):p(e.value)&&(r=e,n=Mr.StrictReservedWord)),o=ar(r),l=o.params,c=o.defaults,t=o.stricted,r=o.firstRestricted,o.message&&(n=o.message),a=zr,s=nr(),zr&&r&&Q(r,n),zr&&t&&Z(t,n),zr=a,u.finishFunctionExpression(i,l,c,s)}function cr(){if(Jr.type===Er.Keyword)switch(Jr.value){case"const":case"let":return Ut(Jr.value);case"function":return ir();default:return rr()}return Jr.type!==Er.EOF?rr():void 0}function pr(){for(var e,t,r,n,o=[];Br>Fr&&(t=Jr,t.type===Er.StringLiteral)&&(e=cr(),o.push(e),e.expression.type===Or.Literal);)r=Ar.slice(t.start+1,t.end-1),"use strict"===r?(zr=!0,n&&Z(n,Mr.StrictOctalLiteral)):!n&&t.octal&&(n=t);for(var s=Cr;Br>Fr&&(e=cr(),"undefined"!=typeof e&&null!==e)&&(o.push(e),s!==Cr);)s=Cr;return o}function dr(){var e,t;return L(),t=new J,zr=!1,e=pr(),t.finishProgram(e)}function ur(){var e,t,r,n=[];for(e=0;e<$r.tokens.length;++e)t=$r.tokens[e],r={type:t.type,value:t.value},t.regex&&(r.regex={pattern:t.regex.pattern,flags:t.regex.flags}),$r.range&&(r.range=t.range),$r.loc&&(r.loc=t.loc),n.push(r);$r.tokens=n}function hr(e,t){var r,n;r=String,"string"==typeof e||e instanceof String||(e=r(e)),Ar=e,Cr=0,Pr=Ar.length>0?1:0,Ir=0,Fr=Cr,Gr=Pr,Wr=Ir,Br=Ar.length,Jr=null,Vr={allowIn:!0,labelSet:{},inFunctionBody:!1,inIteration:!1,inSwitch:!1,lastCommentStart:-1},$r={},t=t||{},t.tokens=!0,$r.tokens=[],$r.tokenize=!0,$r.openParenToken=-1,$r.openCurlyToken=-1,$r.range="boolean"==typeof t.range&&t.range,$r.loc="boolean"==typeof t.loc&&t.loc,"boolean"==typeof t.comment&&t.comment&&($r.comments=[]),"boolean"==typeof t.tolerant&&t.tolerant&&($r.errors=[]);try{if(L(),Jr.type===Er.EOF)return $r.tokens;for(U();Jr.type!==Er.EOF;)try{U()}catch(o){if($r.errors){$r.errors.push(o);break}throw o}ur(),n=$r.tokens,"undefined"!=typeof $r.comments&&(n.comments=$r.comments),"undefined"!=typeof $r.errors&&(n.errors=$r.errors)}catch(s){throw s}finally{$r={}}return n}function fr(e,t){var r,n;n=String,"string"==typeof e||e instanceof String||(e=n(e)),Ar=e,Cr=0,Pr=Ar.length>0?1:0,Ir=0,Fr=Cr,Gr=Pr,Wr=Ir,Br=Ar.length,Jr=null,Vr={allowIn:!0,labelSet:{},parenthesisCount:0,inFunctionBody:!1,inIteration:!1,inSwitch:!1,lastCommentStart:-1},$r={},"undefined"!=typeof t&&("boolean"==typeof t.deps&&t.deps&&($r.deps=[],$r.envs=Object.create(null)),$r.range="boolean"==typeof t.range&&t.range,$r.loc="boolean"==typeof t.loc&&t.loc,$r.attachComment="boolean"==typeof t.attachComment&&t.attachComment,$r.loc&&null!==t.source&&void 0!==t.source&&($r.source=n(t.source)),"boolean"==typeof t.tokens&&t.tokens&&($r.tokens=[]),"boolean"==typeof t.comment&&t.comment&&($r.comments=[]),"boolean"==typeof t.tolerant&&t.tolerant&&($r.errors=[],$r.parseStatement=rr,$r.parseExpression=Dt,rr=yr(rr),Dt=br(Dt)),$r.attachComment&&($r.range=!0,$r.comments=[],$r.bottomRightStack=[],$r.trailingComments=[],$r.leadingComments=[]),$r.directSourceFile=t.directSourceFile);
try{r=dr(),"undefined"!=typeof $r.comments&&(r.comments=$r.comments),"undefined"!=typeof $r.tokens&&(ur(),r.tokens=$r.tokens),"undefined"!=typeof $r.errors&&(r.errors=$r.errors),"undefined"!=typeof $r.deps&&(r.dependencies=$r.deps,r.environments=$r.envs)}catch(o){throw o}finally{"undefined"!=typeof $r.errors&&(rr=$r.parseStatement,Dt=$r.parseExpression),$r={}}return r}function mr(e,t){try{et(e)}catch(r){if(!$r.errors)throw r;gr(r),t&&Ar[r.index]===t&&(Cr=r.index,L())}}function gr(e){for(var t=$r.errors.length,r=0;t>r;r++){var n=$r.errors[r];if(n.index===e.index&&n.message===e.message)return}$r.errors.push(e)}function br(e){return function(){try{return e.apply(null,arguments)}catch(t){gr(t)}}}function yr(e){return function(){$r.statementStart=Cr;try{return e.apply(null,arguments)}catch(t){gr(t)}}}function vr(e){for(var t=e;t>-1&&";"!==Ar[t]&&"\n"!==Ar[t];)t--;if(!(t<=$r.statementStart)){var r=!1;$r.lastRewindLocation?r=!0:$r.lastRewindLocation!==t&&(r=!0),r&&(Cr=t,wr(e),L(),$r.lastRewindLocation=Cr)}}function wr(e,t){for(var r=$r.tokens.length-1;r>-1;){var n=$r.tokens[r];if(n.range[0]<e){t&&$r.tokens.pop();break}r--,$r.tokens.pop()}return r}function _r(e){if(e.value&&e.type===Er.Punctuator){var t=e.range?e.range[0]:e.start,r=wr(t),n=$r.tokens[r];n.type===xr[Er.Punctuator]&&"."===n.value&&(Cr=n.range[0]+1,L())}}function Sr(e,t,r){var n={type:"RecoveredNode",name:"",recovered:!0,expectedValue:r,expectedType:t};return $r.range&&(n.range=e.range,n.range[1]=Cr,n.start=e.range,n.end=Cr),$r.loc&&(n.loc=e.loc,n.loc.end=new W),n}function Tr(e,t,r){if($r.errors){var n=Jr;if(":"===n.value)try{return n=U(),r.finishProperty("init",t,Mt(),!1,!0)}catch(o){return n=$r.tokens[$r.tokens.length-1],Z(n,Mr.UnexpectedToken,n.value),r.finishProperty("init",t,null,!1,!0),null}else{if(n.type===Er.Punctuator&&"}"===n.value)return Z(e,Mr.UnexpectedToken,e.value),r.finishProperty("init",t,!1,!0,!0),null;if(Z(e,Mr.UnexpectedToken,e.value),n.type===Er.Identifier||n.type===Er.StringLiteral)return r.finishProperty("init",t,!1,!0),null;for(;n.type!==Er.EOF;){if(n.type===Er.Punctuator&&(","===n.value||"}"===n.value))return r.finishProperty("init",t,!1,!0),null;n=U(),n=I()}}return r.finishProperty("init",t,!1,!0),null}return et(":"),r.finishProperty("init",t,Mt(),!1,!0)}var Er,xr,jr,Or,kr,Rr,Mr,Dr,Ar,zr,Cr,Pr,Ir,Nr,Ur,Lr,qr,Fr,Gr,Wr,Hr,Br,Jr,Vr,$r;Er={BooleanLiteral:1,EOF:2,Identifier:3,Keyword:4,NullLiteral:5,NumericLiteral:6,Punctuator:7,StringLiteral:8,RegularExpression:9},xr={},xr[Er.BooleanLiteral]="Boolean",xr[Er.EOF]="<end>",xr[Er.Identifier]="Identifier",xr[Er.Keyword]="Keyword",xr[Er.NullLiteral]="Null",xr[Er.NumericLiteral]="Numeric",xr[Er.Punctuator]="Punctuator",xr[Er.StringLiteral]="String",xr[Er.RegularExpression]="RegularExpression",jr=["(","{","[","in","typeof","instanceof","new","return","case","delete","throw","void","=","+=","-=","*=","/=","%=","<<=",">>=",">>>=","&=","|=","^=",",","+","-","*","/","%","++","--","<<",">>",">>>","&","|","^","!","~","&&","||","?",":","===","==",">=","<=","<",">","!=","!=="],Or={AssignmentExpression:"AssignmentExpression",ArrayExpression:"ArrayExpression",ArrowFunctionExpression:"ArrowFunctionExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DoWhileStatement:"DoWhileStatement",DebuggerStatement:"DebuggerStatement",EmptyStatement:"EmptyStatement",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForInStatement:"ForInStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",Identifier:"Identifier",IfStatement:"IfStatement",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",Program:"Program",Property:"Property",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SwitchStatement:"SwitchStatement",SwitchCase:"SwitchCase",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement"},kr={ArrowParameterPlaceHolder:{type:"ArrowParameterPlaceHolder"}},Rr={Data:1,Get:2,Set:4},Mr={UnexpectedToken:"Unexpected token %0",UnexpectedNumber:"Unexpected number",UnexpectedString:"Unexpected string",UnexpectedIdentifier:"Unexpected identifier",UnexpectedReserved:"Unexpected reserved word",UnexpectedEOS:"Unexpected end of input",NewlineAfterThrow:"Illegal newline after throw",InvalidRegExp:"Invalid regular expression",UnterminatedRegExp:"Invalid regular expression: missing /",InvalidLHSInAssignment:"Invalid left-hand side in assignment",InvalidLHSInForIn:"Invalid left-hand side in for-in",MultipleDefaultsInSwitch:"More than one default clause in switch statement",NoCatchOrFinally:"Missing catch or finally after try",UnknownLabel:"Undefined label '%0'",Redeclaration:"%0 '%1' has already been declared",IllegalContinue:"Illegal continue statement",IllegalBreak:"Illegal break statement",IllegalReturn:"Illegal return statement",StrictModeWith:"Strict mode code may not include a with statement",StrictCatchVariable:"Catch variable may not be eval or arguments in strict mode",StrictVarName:"Variable name may not be eval or arguments in strict mode",StrictParamName:"Parameter name eval or arguments is not allowed in strict mode",StrictParamDupe:"Strict mode function may not have duplicate parameter names",StrictFunctionName:"Function name may not be eval or arguments in strict mode",StrictOctalLiteral:"Octal literals are not allowed in strict mode.",StrictDelete:"Delete of an unqualified identifier in strict mode.",StrictDuplicateProperty:"Duplicate data property in object literal not allowed in strict mode",AccessorDataProperty:"Object literal may not have data and accessor property with the same name",AccessorGetSet:"Object literal may not have multiple get/set accessors with the same name",StrictLHSAssignment:"Assignment to eval or arguments is not allowed in strict mode",StrictLHSPostfix:"Postfix increment/decrement may not have eval or arguments operand in strict mode",StrictLHSPrefix:"Prefix increment/decrement may not have eval or arguments operand in strict mode",StrictReservedWord:"Use of future reserved word in strict mode",MissingToken:"Missing expected '%0'"},Dr={NonAsciiIdentifierStart:new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙա-ևא-תװ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࢠ-ࢲऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘౙౠౡಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೞೠೡೱೲഅ-ഌഎ-ഐഒ-ഺഽൎൠൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜌᜎ-ᜑᜠ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᧁ-ᧇᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭋᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᳩ-ᳬᳮ-ᳱᳵᳶᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⸯ々-〇〡-〩〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞭꞰꞱꟷ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭟꭤꭥꯀ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ﬀ-ﬆﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼＡ-Ｚａ-ｚｦ-ﾾￂ-ￇￊ-ￏￒ-ￗￚ-ￜ]"),NonAsciiIdentifierPart:new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮ̀-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁ҃-҇Ҋ-ԯԱ-Ֆՙա-և֑-ׇֽֿׁׂׅׄא-תװ-ײؐ-ؚؠ-٩ٮ-ۓە-ۜ۟-۪ۨ-ۼۿܐ-݊ݍ-ޱ߀-ߵߺࠀ-࠭ࡀ-࡛ࢠ-ࢲࣤ-ॣ०-९ॱ-ঃঅ-ঌএঐও-নপ-রলশ-হ়-ৄেৈো-ৎৗড়ঢ়য়-ৣ০-ৱਁ-ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹ਼ਾ-ੂੇੈੋ-੍ੑਖ਼-ੜਫ਼੦-ੵઁ-ઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હ઼-ૅે-ૉો-્ૐૠ-ૣ૦-૯ଁ-ଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହ଼-ୄେୈୋ-୍ୖୗଡ଼ଢ଼ୟ-ୣ୦-୯ୱஂஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹா-ூெ-ைொ-்ௐௗ௦-௯ఀ-ఃఅ-ఌఎ-ఐఒ-నప-హఽ-ౄె-ైొ-్ౕౖౘౙౠ-ౣ౦-౯ಁ-ಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹ಼-ೄೆ-ೈೊ-್ೕೖೞೠ-ೣ೦-೯ೱೲഁ-ഃഅ-ഌഎ-ഐഒ-ഺഽ-ൄെ-ൈൊ-ൎൗൠ-ൣ൦-൯ൺ-ൿංඃඅ-ඖක-නඳ-රලව-ෆ්ා-ුූෘ-ෟ෦-෯ෲෳก-ฺเ-๎๐-๙ກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ູົ-ຽເ-ໄໆ່-ໍ໐-໙ໜ-ໟༀ༘༙༠-༩༹༵༷༾-ཇཉ-ཬཱ-྄྆-ྗྙ-ྼ࿆က-၉ၐ-ႝႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፝-፟ᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜌᜎ-᜔ᜠ-᜴ᝀ-ᝓᝠ-ᝬᝮ-ᝰᝲᝳក-៓ៗៜ៝០-៩᠋-᠍᠐-᠙ᠠ-ᡷᢀ-ᢪᢰ-ᣵᤀ-ᤞᤠ-ᤫᤰ-᤻᥆-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉ᧐-᧙ᨀ-ᨛᨠ-ᩞ᩠-᩿᩼-᪉᪐-᪙ᪧ᪰-᪽ᬀ-ᭋ᭐-᭙᭫-᭳ᮀ-᯳ᰀ-᰷᱀-᱉ᱍ-ᱽ᳐-᳔᳒-ᳶ᳸᳹ᴀ-᷵᷼-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‌‍‿⁀⁔ⁱⁿₐ-ₜ⃐-⃥⃜⃡-⃰ℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵿-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⷠ-ⷿⸯ々-〇〡-〯〱-〵〸-〼ぁ-ゖ゙゚ゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘫꙀ-꙯ꙴ-꙽ꙿ-ꚝꚟ-꛱ꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞭꞰꞱꟷ-ꠧꡀ-ꡳꢀ-꣄꣐-꣙꣠-ꣷꣻ꤀-꤭ꤰ-꥓ꥠ-ꥼꦀ-꧀ꧏ-꧙ꧠ-ꧾꨀ-ꨶꩀ-ꩍ꩐-꩙ꩠ-ꩶꩺ-ꫂꫛ-ꫝꫠ-ꫯꫲ-꫶ꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭟꭤꭥꯀ-ꯪ꯬꯭꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ﬀ-ﬆﬓ-ﬗיִ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻ︀-️︠-︭︳︴﹍-﹏ﹰ-ﹴﹶ-ﻼ０-９Ａ-Ｚ＿ａ-ｚｦ-ﾾￂ-ￇￊ-ￏￒ-ￗￚ-ￜ]")},V.prototype=J.prototype={processComment:function(){var e,t,r,n,o,s=$r.bottomRightStack,a=s[s.length-1];if(!(this.type===Or.Program&&this.body.length>0)){if($r.trailingComments.length>0){for(r=[],n=$r.trailingComments.length-1;n>=0;--n)o=$r.trailingComments[n],o.range[0]>=this.range[1]&&(r.unshift(o),$r.trailingComments.splice(n,1));$r.trailingComments=[]}else a&&a.trailingComments&&a.trailingComments[0].range[0]>=this.range[1]&&(r=a.trailingComments,delete a.trailingComments);if(a)for(;a&&a.range[0]>=this.range[0];)e=a,a=s.pop();if(e)e.leadingComments&&e.leadingComments[e.leadingComments.length-1].range[1]<=this.range[0]&&(this.leadingComments=e.leadingComments,e.leadingComments=void 0);else if($r.leadingComments.length>0)for(t=[],n=$r.leadingComments.length-1;n>=0;--n)o=$r.leadingComments[n],o.range[1]<=this.range[0]&&(t.unshift(o),$r.leadingComments.splice(n,1));t&&t.length>0&&(this.leadingComments=t),r&&r.length>0&&(this.trailingComments=r),s.push(this)}},finish:function(){$r.loc&&(this.loc.end={line:Lr,column:Ur-qr},$r.source&&(this.loc.source=$r.source)),$r.range&&(this.range[1]=Ur,this.start=this.range[0],this.end=Ur),$r.attachComment&&this.processComment()},finishArrayExpression:function(e){return this.type=Or.ArrayExpression,this.elements=e,this.finish(),this},finishArrowFunctionExpression:function(e,t,r,n){return this.type=Or.ArrowFunctionExpression,this.id=null,this.params=e,this.defaults=t,this.body=r,this.rest=null,this.generator=!1,this.expression=n,this.finish(),this},finishAssignmentExpression:function(e,t,r){return this.type=Or.AssignmentExpression,this.operator=e,this.left=t,this.right=r,this.finish(),this},finishBinaryExpression:function(e,t,r){return this.type="||"===e||"&&"===e?Or.LogicalExpression:Or.BinaryExpression,this.operator=e,this.left=t,this.right=r,this.finish(),this},finishBlockStatement:function(e){return this.type=Or.BlockStatement,this.body=e,this.finish(),this},finishBreakStatement:function(e){return this.type=Or.BreakStatement,this.label=e,this.finish(),this},finishCallExpression:function(e,t){return this.type=Or.CallExpression,this.callee=e,this.arguments=t,G(e,t),this.finish(),this},finishCatchClause:function(e,t){return this.type=Or.CatchClause,this.param=e,this.body=t,this.finish(),this},finishConditionalExpression:function(e,t,r){return this.type=Or.ConditionalExpression,this.test=e,this.consequent=t,this.alternate=r,this.finish(),this},finishContinueStatement:function(e){return this.type=Or.ContinueStatement,this.label=e,this.finish(),this},finishDebuggerStatement:function(){return this.type=Or.DebuggerStatement,this.finish(),this},finishDoWhileStatement:function(e,t){return this.type=Or.DoWhileStatement,this.body=e,this.test=t,this.finish(),this},finishEmptyStatement:function(){return this.type=Or.EmptyStatement,this.finish(),this},finishExpressionStatement:function(e){return this.type=Or.ExpressionStatement,this.expression=e,this.finish(),this},finishForStatement:function(e,t,r,n){return this.type=Or.ForStatement,this.init=e,this.test=t,this.update=r,this.body=n,this.finish(),this},finishForInStatement:function(e,t,r){return this.type=Or.ForInStatement,this.left=e,this.right=t,this.body=r?r:Sr(this,"Statement"),this.each=!1,this.finish(),this},finishFunctionDeclaration:function(e,t,r,n){return this.type=Or.FunctionDeclaration,this.id=e,this.params=t,this.defaults=r,this.body=n,this.rest=null,this.generator=!1,this.expression=!1,this.finish(),this},finishFunctionExpression:function(e,t,r,n){return this.type=Or.FunctionExpression,this.id=e,this.params=t,this.defaults=r,this.body=n,this.rest=null,this.generator=!1,this.expression=!1,this.finish(),this},finishIdentifier:function(e){return this.type=Or.Identifier,this.name=e,this.finish(),this},finishIfStatement:function(e,t,r){return this.type=Or.IfStatement,this.test=e,this.consequent=t?t:Sr(this,"Statement"),this.alternate=r,this.finish(),this},finishLabeledStatement:function(e,t){return this.type=Or.LabeledStatement,this.label=e,this.body=t,this.finish(),this},finishLiteral:function(e){return this.type=Or.Literal,this.value=e.value,this.raw=Ar.slice(e.start,e.end),e.regex&&(this.regex=e.regex),this.finish(),this},finishMemberExpression:function(e,t,r){return this.type=Or.MemberExpression,this.computed="["===e,this.object=t,this.property=r,this.finish(),this},finishNewExpression:function(e,t){return this.type=Or.NewExpression,this.callee=e,this.arguments=t,G(e,t),this.finish(),this},finishObjectExpression:function(e){return this.type=Or.ObjectExpression,this.properties=e,this.finish(),this},finishPostfixExpression:function(e,t){return this.type=Or.UpdateExpression,this.operator=e,this.argument=t,this.prefix=!1,this.finish(),this},finishProgram:function(e){return this.type=Or.Program,this.body=e,this.finish(),this},finishProperty:function(e,t,r,n,o){return this.type=Or.Property,this.key=t,this.value=r,this.kind=e,this.method=n,this.shorthand=o,this.finish(),this},finishReturnStatement:function(e){return this.type=Or.ReturnStatement,this.argument=e,this.finish(),this},finishSequenceExpression:function(e){return this.type=Or.SequenceExpression,this.expressions=e,this.finish(),this},finishSwitchCase:function(e,t){return this.type=Or.SwitchCase,this.test=e,this.consequent=t,this.finish(),this},finishSwitchStatement:function(e,t){return this.type=Or.SwitchStatement,this.discriminant=e,this.cases=t,this.finish(),this},finishThisExpression:function(){return this.type=Or.ThisExpression,this.finish(),this},finishThrowStatement:function(e){return this.type=Or.ThrowStatement,this.argument=e,this.finish(),this},finishTryStatement:function(e,t,r,n){return this.type=Or.TryStatement,this.block=e,this.guardedHandlers=t,this.handlers=r,this.finalizer=n,this.finish(),this},finishUnaryExpression:function(e,t){return this.type="++"===e||"--"===e?Or.UpdateExpression:Or.UnaryExpression,this.operator=e,this.argument=t,this.prefix=!0,this.finish(),this},finishVariableDeclaration:function(e,t){return this.type=Or.VariableDeclaration,this.declarations=e,this.kind=t,this.finish(),this},finishVariableDeclarator:function(e,t){return this.type=Or.VariableDeclarator,this.id=e,this.init=t,this.finish(),this},finishWhileStatement:function(e,t){return this.type=Or.WhileStatement,this.test=e,this.body=t?t:Sr(this,"Statement"),this.finish(),this},finishWithStatement:function(e,t){return this.type=Or.WithStatement,this.object=e,this.body=t?t:Sr(this,"Statement"),this.finish(),this}},e.version="2.0.0",e.tokenize=hr,e.parse=fr,e.isIdentifierPart=l,e.isIdentifierStart=i,e.isIdentifierChar=l,e.Syntax=function(){var e,t={};"function"==typeof Object.create&&(t=Object.create(null));for(e in Or)Or.hasOwnProperty(e)&&(t[e]=Or[e]);return"function"==typeof Object.freeze&&Object.freeze(t),t}()}),function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define("acorn/dist/walk",[],e);else{var t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,(t.acorn||(t.acorn={})).walk=e()}}(function(){return function e(t,r,n){function o(a,i){if(!r[a]){if(!t[a]){var l="function"==typeof require&&require;if(!i&&l)return l(a,!0);if(s)return s(a,!0);var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var p=r[a]={exports:{}};t[a][0].call(p.exports,function(e){var r=t[a][1][e];return o(r?r:e)},p,p.exports,e,t,r,n)}return r[a].exports}for(var s="function"==typeof require&&require,a=0;a<n.length;a++)o(n[a]);return o}({1:[function(e,t,r){function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t,n,o,s){n||(n=r.base),function a(e,r,o){var s=o||e.type,i=t[s];n[s](e,r,a),i&&i(e,r)}(e,o,s)}function s(e,t,n,o){n||(n=r.base),o||(o=[]),function s(e,r,o){var a=o||e.type,i=t[a];e!=r[r.length-1]&&(r=r.slice(),r.push(e)),n[a](e,r,s),i&&i(e,r)}(e,o)}function a(e,t,n,o,s){var a=n?r.make(n,o):o;!function i(e,t,r){a[r||e.type](e,t,i)}(e,t,s)}function i(e){return"string"==typeof e?function(t){return t==e}:e?e:function(){return!0}}function l(e,t,n,o,s,a){o=i(o),s||(s=r.base);try{!function c(e,r,a){var i=a||e.type;if((null==t||e.start<=t)&&(null==n||e.end>=n)&&s[i](e,r,c),o(i,e)&&(null==t||e.start==t)&&(null==n||e.end==n))throw new m(e,r)}(e,a)}catch(l){if(l instanceof m)return l;throw l}}function c(e,t,n,o,s){n=i(n),o||(o=r.base);try{!function l(e,r,s){var a=s||e.type;if(!(e.start>t||e.end<t)&&(o[a](e,r,l),n(a,e)))throw new m(e,r)}(e,s)}catch(a){if(a instanceof m)return a;throw a}}function p(e,t,n,o,s){n=i(n),o||(o=r.base);try{!function l(e,r,s){if(!(e.end<t)){var a=s||e.type;if(e.start>=t&&n(a,e))throw new m(e,r);o[a](e,r,l)}}(e,s)}catch(a){if(a instanceof m)return a;throw a}}function d(e,t,n,o,s){n=i(n),o||(o=r.base);var a=void 0;return function l(e,r,s){if(!(e.start>t)){var i=s||e.type;e.end<=t&&(!a||a.node.end<e.end)&&n(i,e)&&(a=new m(e,r)),o[i](e,r,l)}}(e,s),a}function u(e,t){t||(t=r.base);var n={};for(var o in t)n[o]=t[o];for(var o in e)n[o]=e[o];return n}function h(e,t,r){r(e,t)}function f(){}r.__esModule=!0,r.simple=o,r.ancestor=s,r.recursive=a,r.findNodeAt=l,r.findNodeAround=c,r.findNodeAfter=p,r.findNodeBefore=d,r.make=u;var m=function b(e,t){n(this,b),this.node=e,this.state=t},g={};r.base=g,g.Program=g.BlockStatement=function(e,t,r){for(var n=0;n<e.body.length;++n)r(e.body[n],t,"Statement")},g.Statement=h,g.EmptyStatement=f,g.ExpressionStatement=g.ParenthesizedExpression=function(e,t,r){return r(e.expression,t,"Expression")},g.IfStatement=function(e,t,r){r(e.test,t,"Expression"),r(e.consequent,t,"Statement"),e.alternate&&r(e.alternate,t,"Statement")},g.LabeledStatement=function(e,t,r){return r(e.body,t,"Statement")},g.BreakStatement=g.ContinueStatement=f,g.WithStatement=function(e,t,r){r(e.object,t,"Expression"),r(e.body,t,"Statement")},g.SwitchStatement=function(e,t,r){r(e.discriminant,t,"Expression");for(var n=0;n<e.cases.length;++n){var o=e.cases[n];o.test&&r(o.test,t,"Expression");for(var s=0;s<o.consequent.length;++s)r(o.consequent[s],t,"Statement")}},g.ReturnStatement=g.YieldExpression=function(e,t,r){e.argument&&r(e.argument,t,"Expression")},g.ThrowStatement=g.SpreadElement=function(e,t,r){return r(e.argument,t,"Expression")},g.TryStatement=function(e,t,r){r(e.block,t,"Statement"),e.handler&&(r(e.handler.param,t,"Pattern"),r(e.handler.body,t,"ScopeBody")),e.finalizer&&r(e.finalizer,t,"Statement")},g.WhileStatement=g.DoWhileStatement=function(e,t,r){r(e.test,t,"Expression"),r(e.body,t,"Statement")},g.ForStatement=function(e,t,r){e.init&&r(e.init,t,"ForInit"),e.test&&r(e.test,t,"Expression"),e.update&&r(e.update,t,"Expression"),r(e.body,t,"Statement")},g.ForInStatement=g.ForOfStatement=function(e,t,r){r(e.left,t,"ForInit"),r(e.right,t,"Expression"),r(e.body,t,"Statement")},g.ForInit=function(e,t,r){"VariableDeclaration"==e.type?r(e,t):r(e,t,"Expression")},g.DebuggerStatement=f,g.FunctionDeclaration=function(e,t,r){return r(e,t,"Function")},g.VariableDeclaration=function(e,t,r){for(var n=0;n<e.declarations.length;++n){var o=e.declarations[n];r(o.id,t,"Pattern"),o.init&&r(o.init,t,"Expression")}},g.Function=function(e,t,r){for(var n=0;n<e.params.length;n++)r(e.params[n],t,"Pattern");r(e.body,t,"ScopeBody")},g.ScopeBody=function(e,t,r){return r(e,t,"Statement")},g.Pattern=function(e,t,r){"Identifier"==e.type?r(e,t,"VariablePattern"):"MemberExpression"==e.type?r(e,t,"MemberPattern"):r(e,t)},g.VariablePattern=f,g.MemberPattern=h,g.RestElement=function(e,t,r){return r(e.argument,t,"Pattern")},g.ArrayPattern=function(e,t,r){for(var n=0;n<e.elements.length;++n){var o=e.elements[n];o&&r(o,t,"Pattern")}},g.ObjectPattern=function(e,t,r){for(var n=0;n<e.properties.length;++n)r(e.properties[n].value,t,"Pattern")},g.Expression=h,g.ThisExpression=g.Super=g.MetaProperty=f,g.ArrayExpression=function(e,t,r){for(var n=0;n<e.elements.length;++n){var o=e.elements[n];o&&r(o,t,"Expression")}},g.ObjectExpression=function(e,t,r){for(var n=0;n<e.properties.length;++n)r(e.properties[n],t)},g.FunctionExpression=g.ArrowFunctionExpression=g.FunctionDeclaration,g.SequenceExpression=g.TemplateLiteral=function(e,t,r){for(var n=0;n<e.expressions.length;++n)r(e.expressions[n],t,"Expression")},g.UnaryExpression=g.UpdateExpression=function(e,t,r){r(e.argument,t,"Expression")},g.BinaryExpression=g.LogicalExpression=function(e,t,r){r(e.left,t,"Expression"),r(e.right,t,"Expression")},g.AssignmentExpression=g.AssignmentPattern=function(e,t,r){r(e.left,t,"Pattern"),r(e.right,t,"Expression")},g.ConditionalExpression=function(e,t,r){r(e.test,t,"Expression"),r(e.consequent,t,"Expression"),r(e.alternate,t,"Expression")},g.NewExpression=g.CallExpression=function(e,t,r){if(r(e.callee,t,"Expression"),e.arguments)for(var n=0;n<e.arguments.length;++n)r(e.arguments[n],t,"Expression")},g.MemberExpression=function(e,t,r){r(e.object,t,"Expression"),e.computed&&r(e.property,t,"Expression")},g.ExportNamedDeclaration=g.ExportDefaultDeclaration=function(e,t,r){e.declaration&&r(e.declaration,t)},g.ImportDeclaration=function(e,t,r){for(var n=0;n<e.specifiers.length;n++)r(e.specifiers[n],t)},g.ImportSpecifier=g.ImportDefaultSpecifier=g.ImportNamespaceSpecifier=g.Identifier=g.Literal=f,g.TaggedTemplateExpression=function(e,t,r){r(e.tag,t,"Expression"),r(e.quasi,t)},g.ClassDeclaration=g.ClassExpression=function(e,t,r){return r(e,t,"Class")},g.Class=function(e,t,r){e.id&&r(e.id,t,"Pattern"),e.superClass&&r(e.superClass,t,"Expression");for(var n=0;n<e.body.body.length;n++)r(e.body.body[n],t)},g.MethodDefinition=g.Property=function(e,t,r){e.computed&&r(e.key,t,"Expression"),r(e.value,t,"Expression")},g.ComprehensionExpression=function(e,t,r){for(var n=0;n<e.blocks.length;n++)r(e.blocks[n].right,t,"Expression");r(e.body,t,"Expression")},g.RecoveredNode=f},{}]},{},[1])(1)}),function(e){return"object"==typeof exports&&"object"==typeof module?exports.init=e:"function"==typeof define&&define.amd?define("tern/lib/def",{init:e}):void(tern.def={init:e})}(function(e,t){"use strict";function r(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function n(e,t,r){return e.call?e(t,r):e}function o(e,r){if("!ret"==r){if(e.retval)return e.retval;var n=new t.AVal;return e.propagate(new t.IsCallee(t.ANull,[],null,n)),n}return e.getProp(r)}function s(e,r){return function(o,s){for(var a=[],i=0;i<e.length;i++)a.push(n(e[i],o,s));return new t.Fn(name,t.ANull,a,n(r,o,s))}}function a(e){return function(r,o){for(var s=new t.AVal,a=0;a<e.length;a++)n(e[a],r,o).propagate(s);return s.maxWeight=1e5,s}}function i(e){return function(r,n){return new t.Arr(e(r,n))}}function l(e,r,n,o){var s=new b(e,null,n,o).parseType(!1,r,!0);if(/^fn\(/.test(e))for(var a=0;a<s.args.length;++a)(function(e){var r=s.args[e];r instanceof t.Fn&&r.args&&r.args.length&&c(s,function(n,o){var s=o[e];s&&s.propagate(new t.IsCallee(t.cx().topScope,r.args,null,t.ANull))})})(a);return s}function c(e,t,r){var n=e.computeRet,o=e.retval;e.computeRet=function(e,s,a){var i=t(e,s,a),l=n?n(e,s,a):o;return r?i:l}}function p(e){var t=Object.create(e.prototype);return t.props=Object.create(null),t.isShell=!0,t}function d(e){if(!e["!type"]||/^(fn\(|\[)/.test(e["!type"]))return!1;for(var t in e)if("!type"!=t&&"!doc"!=t&&"!url"!=t&&"!span"!=t&&"!data"!=t)return!1;return!0}function u(e,n,o){if(!e){var s=n["!type"];if(s)if(/^fn\(/.test(s))e=p(t.Fn);else{if("["!=s.charAt(0))throw new Error("Invalid !type spec: "+s);e=p(t.Arr)}else e=n["!stdProto"]?t.cx().protos[n["!stdProto"]]:p(t.Obj);e.name=o}for(var a in n)if(r(n,a)&&33!=a.charCodeAt(0)){var i=n[a];if("string"==typeof i||d(i))continue;var l=e.defProp(a);u(l.getObjType(),i,o?o+"."+a:a).propagate(l)}return e}function h(e,n,o){if(e.isShell){delete e.isShell;var s=n["!type"];if(s)l(s,o,e);else{var a=n["!proto"]&&l(n["!proto"]);t.Obj.call(e,a instanceof t.Obj?a:!0,o)}}var i=n["!effects"];if(i&&e instanceof t.Fn)for(var c=0;c<i.length;++c)v(i[c],e);f(n,e);for(var p in n)if(r(n,p)&&33!=p.charCodeAt(0)){var u=n[p],m=e.defProp(p),g=o?o+"."+p:p;if("string"==typeof u)m.isEmpty()&&l(u,g).propagate(m);else{if(d(u)){if(!m.isEmpty())continue;l(u["!type"],g,null,!0).propagate(m)}else h(m.getObjType(),u,g);u["!doc"]&&(m.doc=u["!doc"]),u["!url"]&&(m.url=u["!url"]),u["!span"]&&(m.span=u["!span"])}}return e}function f(e,t){e["!doc"]&&(t.doc=e["!doc"]),e["!url"]&&(t.url=e["!url"]),e["!span"]&&(t.span=e["!span"]),e["!data"]&&(t.metaData=e["!data"])}function m(e,r){var n=t.cx().parent,o=n&&n.passes&&n.passes[e];if(o)for(var s=0;s<o.length;s++)o[s](r)}function g(e,r){var n=t.cx();t.addOrigin(n.curOrigin=e["!name"]||"env#"+n.origins.length),n.localDefs=n.definitions[n.curOrigin]=Object.create(null),m("preLoadDef",e),u(r,e);var o=e["!define"];if(o){for(var s in o){var a=o[s];n.localDefs[s]="string"==typeof a?w(a):u(null,a,s)}for(var s in o){var a=o[s];"string"!=typeof a&&h(n.localDefs[s],o[s],s)}}h(r,e),m("postLoadDef",e),n.curOrigin=n.localDefs=null}var b=e.TypeParser=function(e,t,r,n){this.pos=t||0,this.spec=e,this.base=r,this.forceNew=n};b.prototype={eat:function(e){return(1==e.length?this.spec.charAt(this.pos)==e:this.spec.indexOf(e,this.pos)==this.pos)?(this.pos+=e.length,!0):void 0},word:function(e){for(var t,r="",e=e||/[\w$]/;(t=this.spec.charAt(this.pos))&&e.test(t);)r+=t,++this.pos;return r},error:function(){throw new Error("Unrecognized type spec: "+this.spec+" (at "+this.pos+")")},parseFnType:function(e,r,n){var o=[],a=[],i=!1;if(!this.eat(")"))for(var l=0;;++l){var c,p=this.spec.indexOf(": ",this.pos);-1!=p&&(c=this.spec.slice(this.pos,p),/^[$\w?]+$/.test(c)?this.pos=p+2:c=null),a.push(c);var d=this.parseType(e);if(d.call&&(i=!0),o.push(d),!this.eat(", ")){this.eat(")")||this.error();break}}var u,h,f,m;if(this.eat(" -> ")){var g=this.pos;u=this.parseType(!0),u.call&&(n?(h=u,u=t.ANull,f=g):i=!0)}else u=t.ANull;return i?s(o,u):(n&&(m=this.base)?t.Fn.call(this.base,r,t.ANull,o,a,u):m=new t.Fn(r,t.ANull,o,a,u),h&&(m.computeRet=h),null!=f&&(m.computeRetSource=this.spec.slice(f,this.pos)),m)},parseType:function(e,r,n){var o=this.parseTypeMaybeProp(e,r,n);if(!this.eat("|"))return o;for(var s=[o],i=o.call;;){var l=this.parseTypeMaybeProp(e,r,n);if(s.push(l),l.call&&(i=!0),!this.eat("|"))break}if(i)return a(s);for(var c=new t.AVal,p=0;p<s.length;p++)s[p].propagate(c);return c.maxWeight=1e5,c},parseTypeMaybeProp:function(e,t,r){for(var n=this.parseTypeInner(e,t,r);e&&this.eat(".");)n=this.extendWithProp(n);return n},extendWithProp:function(e){var t=this.word(/[\w<>$!]/)||this.error();return e.apply?function(r,n){return o(e(r,n),t)}:o(e,t)},parseTypeInner:function(e,r,n){if(this.eat("fn("))return this.parseFnType(e,r,n);if(this.eat("[")){var o=this.parseType(e);return this.eat("]")||this.error(),o.call?i(o):n&&this.base?(t.Arr.call(this.base,o),this.base):new t.Arr(o)}if(this.eat("+")){var s=this.word(/[\w$<>\.!]/),a=w(s+".prototype");return a instanceof t.Obj||(a=w(s)),a instanceof t.Obj?e&&this.eat("[")?this.parsePoly(a):n&&this.forceNew?new t.Obj(a):t.getInstance(a):a}if(e&&this.eat("!")){var l=this.word(/\d/);if(l)return l=Number(l),function(e,r){return r[l]||t.ANull};if(this.eat("this"))return function(e){return e};if(this.eat("custom:")){var c=this.word(/[\w$]/);return _[c]||function(){return t.ANull}}return this.fromWord("!"+this.word(/[\w$<>\.!]/))}return this.eat("?")?t.ANull:this.fromWord(this.word(/[\w$<>\.!`]/))},fromWord:function(e){var r=t.cx();switch(e){case"number":return r.num;case"string":return r.str;case"bool":return r.bool;case"<top>":return r.topScope}return r.localDefs&&e in r.localDefs?r.localDefs[e]:w(e)},parsePoly:function(e){var r,n="<i>";(r=this.spec.slice(this.pos).match(/^\s*(\w+)\s*=\s*/))&&(n=r[1],this.pos+=r[0].length);var o=this.parseType(!0);if(this.eat("]")||this.error(),o.call)return function(r,s){var a=t.getInstance(e);return o(r,s).propagate(a.defProp(n)),a};var s=t.getInstance(e);return o.propagate(s.defProp(n)),s}};var y,v=e.parseEffect=function(e,r){var o;if(0==e.indexOf("propagate ")){var s=new b(e,10),a=s.parseType(!0);s.eat(" ")||s.error();var i=s.parseType(!0);c(r,function(e,t){n(a,e,t).propagate(n(i,e,t))})}else if(0==e.indexOf("call ")){var l=5==e.indexOf("and return ",5),s=new b(e,l?16:5),p=s.parseType(!0),d=null,u=[];for(s.eat(" this=")&&(d=s.parseType(!0));s.eat(" ");)u.push(s.parseType(!0));c(r,function(e,r){for(var o=n(p,e,r),s=d?n(d,e,r):t.ANull,a=[],i=0;i<u.length;++i)a.push(n(u[i],e,r));var c=l?new t.AVal:t.ANull;return o.propagate(new t.IsCallee(s,a,null,c)),c},l)}else if(o=e.match(/^custom (\S+)\s*(.*)/)){var h=_[o[1]];h&&c(r,o[2]?h(o[2]):h)}else{if(0!=e.indexOf("copy "))throw new Error("Unknown effect type: "+e);var s=new b(e,5),f=s.parseType(!0);s.eat(" ");var m=s.parseType(!0);c(r,function(e,r){var o=n(f,e,r),s=n(m,e,r);o.forAllProps(function(e,r,n){n&&"<i>"!=e&&s.propagate(new t.PropHasSubset(e,r))})})}},w=e.parsePath=function(e,r){var n=t.cx(),o=n.paths[e],s=e;if(null!=o)return o;n.paths[e]=t.ANull;var a=r||y||n.topScope;if(n.localDefs)for(var i in n.localDefs)if(0==e.indexOf(i)){if(e==i)return n.paths[e]=n.localDefs[e];if("."==e.charAt(i.length)){a=n.localDefs[i],e=e.slice(i.length+1);break}}for(var l=e.split("."),c=0;c<l.length&&a!=t.ANull;++c){var p=l[c];if("!"==p.charAt(0))if("!proto"==p)a=a instanceof t.Obj&&a.proto||t.ANull;else{var d=a.getFunctionType();if(d)if("!ret"==p)a=d.retval&&d.retval.getType(!1)||t.ANull;else{var u=d.args&&d.args[Number(p.slice(1))];a=u&&u.getType(!1)||t.ANull}else a=t.ANull}else if(a instanceof t.Obj){var h="prototype"==p&&a instanceof t.Fn?a.getProp(p):a.props[p];a=!h||h.isEmpty()?t.ANull:h.types[0]}}return n.paths[s]=a==t.ANull?null:a,a};e.load=function(e,r){r||(r=t.cx().topScope);var n=y;y=r;try{g(e,r)}finally{y=n}},e.parse=function(e,r,n){var o=t.cx();r&&(o.origin=r,o.localDefs=o.definitions[r]);try{return"string"==typeof e?l(e,n):h(u(null,e,n),e,n)}finally{r&&(o.origin=o.localDefs=null)}};var _=Object.create(null);t.registerFunction=function(e,t){_[e]=t};var S=t.constraint({construct:function(e,t,r){this.created=e,this.target=t,this.spec=r},addType:function(e){if(e instanceof t.Obj&&this.created++<5){var r=new t.Obj(e),n=this.spec;if(n instanceof t.AVal&&(n=n.getObjType(!1)),n instanceof t.Obj)for(var o in n.props){var s=n.props[o].types[0],a=r.defProp(o);if(s&&s instanceof t.Obj&&s.props.value){var i=s.props.value.getType(!1);i&&a.addType(i)}}this.target.addType(r)}}});t.registerFunction("Object_create",function(e,r,n){if(n&&n.length&&"Literal"==n[0].type&&null==n[0].value)return new t.Obj;var o=new t.AVal;return r[0]&&r[0].propagate(new S(0,o,r[1])),o});var T=t.constraint({construct:function(e){this.target=e},addType:function(e){e instanceof t.Obj&&(e.hasProp("value")?e.getProp("value").propagate(this.target):e.hasProp("get")&&e.getProp("get").propagate(new t.IsCallee(t.ANull,[],null,this.target)))}});t.registerFunction("Object_defineProperty",function(e,r,n){if(n&&n.length>=3&&"Literal"==n[1].type&&"string"==typeof n[1].value){var o=r[0],s=new t.AVal;o.propagate(new t.PropHasSubset(n[1].value,s,n[1])),r[2].propagate(new T(s))}return t.ANull}),t.registerFunction("Object_defineProperties",function(e,r,n){if(r.length>=2){var o=r[0];r[1].forAllProps(function(e,r,s){if(s){var a=new t.AVal;o.propagate(new t.PropHasSubset(e,a,n&&n[1])),r.propagate(new T(a))}})}return t.ANull});var E=t.constraint({construct:function(e,t,r){this.self=e,this.args=t,this.target=r
},addType:function(e){if(e instanceof t.Fn){this.target.addType(new t.Fn(e.name,t.ANull,e.args.slice(this.args.length),e.argNames.slice(this.args.length),e.retval)),this.self.propagate(e.self);for(var r=0;r<Math.min(e.args.length,this.args.length);++r)this.args[r].propagate(e.args[r])}}});return t.registerFunction("Function_bind",function(e,r){if(!r.length)return t.ANull;var n=new t.AVal;return e.propagate(new E(r[0],r.slice(1),n)),n}),t.registerFunction("Array_ctor",function(e,r){var n=new t.Arr;if(1!=r.length||!r[0].hasType(t.cx().num))for(var o=n.getProp("<i>"),s=0;s<r.length;++s)r[s].propagate(o);return n}),t.registerFunction("Promise_ctor",function(e,r,n){if(r.length<1)return t.ANull;var o=new t.Obj(t.cx().definitions.ecma6["Promise.prototype"]),s=o.defProp("value",n&&n[0]),a=new t.AVal;a.propagate(s);var i=new t.Fn("execute",t.ANull,[a],["value"],t.ANull),l=t.cx().definitions.ecma6.promiseReject;return r[0].propagate(new t.IsCallee(t.ANull,[i,l],null,t.ANull)),o}),e}),function(e,t){return"object"==typeof exports&&"object"==typeof module?t(exports):"function"==typeof define&&define.amd?define("tern/lib/signal",["exports"],t):void t((e.tern||(e.tern={})).signal={})}(this,function(e){function t(e,t){var r=this._handlers||(this._handlers=Object.create(null));(r[e]||(r[e]=[])).push(t)}function r(e,t){var r=this._handlers&&this._handlers[e];if(r)for(var n=0;n<r.length;++n)if(r[n]==t){r.splice(n,1);break}}function n(e,t,r,n,o){var s=this._handlers&&this._handlers[e];if(s)for(var a=0;a<s.length;++a)s[a].call(this,t,r,n,o)}e.mixin=function(e){return e.on=t,e.off=r,e.signal=n,e}}),function(e,t){return"object"==typeof exports&&"object"==typeof module?t(exports,require("acorn"),require("acorn/dist/acorn_loose"),require("acorn/dist/walk"),require("./def"),require("./signal")):"function"==typeof define&&define.amd?define("tern/lib/infer",["exports","esprima/esprima","acorn/dist/walk","./def","./signal"],t):void t(e.tern||(e.tern={}),acorn,acorn.walk,tern.def,tern.signal)}(this,function(e,t,r,n,o){"use strict";function s(e,t){var r=Object.create(e);if(t)for(var n in t)r[n]=t[n];return r}function a(e,t,r){var n=e.getType(!1),o=t.getType(!1);return n&&o?i(n,o,r):!0}function i(e,t,r){if(!e||r>=5)return t;if(!e||e==t)return e;if(!t)return e;if(e.constructor!=t.constructor)return!1;if(e.constructor!=it){if(e.constructor==st){var n=0,o=0,s=0;for(var l in e.props)n++,l in t.props&&a(e.props[l],t.props[l],r+1)&&s++;for(var l in t.props)o++;return n&&o&&s<Math.max(n,o)/2?!1:n>o?e:t}return e.constructor==at&&e.args.length==t.args.length&&e.args.every(function(e,n){return a(e,t.args[n],r+1)})&&a(e.retval,t.retval,r+1)&&a(e.self,t.self,r+1)?e:!1}var c=e.getProp("<i>").getType(!1);if(!c)return t;var p=t.getProp("<i>").getType(!1);return!p||i(c,p,r+1)?t:void 0}function l(e){for(var t=0,r=0,n=0,o=null,s=0;s<e.length;++s){var a=e[s];if(a instanceof it)++t;else if(a instanceof at)++r;else if(a instanceof st)++n;else if(a instanceof ot){if(o&&a.name!=o.name)return null;o=a}}var i=(t&&1)+(r&&1)+(n&&1)+(o&&1);if(i>1)return null;if(o)return o;for(var l=0,c=null,s=0;s<e.length;++s){var a=e[s],p=0;if(t)p=a.getProp("<i>").isEmpty()?1:2;else if(r){p=1;for(var d=0;d<a.args.length;++d)a.args[d].isEmpty()||++p;a.retval.isEmpty()||++p}else n&&(p=a.name?100:2);p>=l&&(l=p,c=a)}return c}function c(e,t){lt.disabledComputing={fn:e,prev:lt.disabledComputing};try{return t()}finally{lt.disabledComputing=lt.disabledComputing.prev}}function p(e,t){var r=lt.props[e]||(lt.props[e]=[]);r.push(t)}function d(e){return lt.props[e]}function u(t){if(lt.workList)return t(lt.workList);var r=[],n=0,o=lt.workList=function(e,t,o){n<pt-dt*r.length&&r.push(e,t,o,n)};try{for(var s=t(o),a=0;a<r.length;a+=4){if(ct&&+new Date>=ct)throw new e.TimedOut;n=r[a+3]+1,r[a+1].addType(r[a],r[a+2])}return s}finally{lt.workList=null}}function h(e,t){e.fnType&&(e.fnType.instantiateScore=(e.fnType.instantiateScore||0)+t)}function f(e,t){try{return r.simple(e,{Expression:function(){if(--t<=0)throw ht}}),!0}catch(n){if(n==ht)return!1;throw n}}function m(e,t){var r=t.fnType.instantiateScore;return!lt.disabledComputing&&r&&t.fnType.args.length&&f(e,5*r)?(h(t.prev,r/2),g(e,t),!0):void(t.fnType.instantiateScore=null)}function g(e,t){for(var n=t.fnType,o=0;o<n.args.length;++o)n.args[o]=new F;n.self=new F,n.computeRet=function(o,s){return c(n,function(){var a=lt.curOrigin;lt.curOrigin=n.origin;var i=new ut(t.prev);i.originNode=t.originNode;for(var l in t.props)for(var c=i.defProp(l,t.props[l].originNode),p=0;p<s.length;++p)n.argNames[p]==l&&p<s.length&&s[p].propagate(c);for(var d=n.argNames.length!=s.length?n.argNames.slice(0,s.length):n.argNames;d.length<s.length;)d.push("?");if(i.fnType=new at(n.name,o,s,d,z),i.fnType.originNode=n.originNode,n.arguments){var u=i.fnType.arguments=new F;i.defProp("arguments").addType(new it(u));for(var p=0;p<s.length;++p)s[p].propagate(u)}return e.body.scope=i,r.recursive(e.body,i,null,ft),r.recursive(e.body,i,null,gt),lt.curOrigin=a,i.fnType.retval})}}function b(e){function t(e,r,n){if(!(n>3)&&e.forward)for(var s=0;s<e.forward.length;++s){var a=e.forward[s].propagatesTo();if(a){var i,l=r;if(a instanceof F)i=a;else{if(!(a.target instanceof F))continue;l+=a.pathExt,i=a.target}if(i==o)return l;var c=t(i,l,n+1);if(c)return c}}}var r=e.fnType,o=r.retval;if(o!=z){var s,a;!o.isEmpty()&&(s=o.getType())instanceof it&&(o=a=s.getProp("<i>"));for(var i=t(r.self,"!this",0),l=0;!i&&l<r.args.length;++l)i=t(r.args[l],"!"+l,0);if(i){a&&(i="["+i+"]");var c=new n.TypeParser(i),p=c.parseType(!0);return r.computeRet=p.apply?p:function(){return p},r.computeRetSource=i,!0}}}function y(e,t){return e.defProp(t.name,t)}function v(e,t,r){var n=e.property;return e.computed?"Literal"==n.type&&"string"==typeof n.value?n.value:(r&&x(n,t,r,z),"<i>"):n.name}function w(e){switch(e){case"+":case"-":case"~":return lt.num;case"!":return lt.bool;case"typeof":return lt.str;case"void":case"delete":return z}}function _(e){switch(e){case"==":case"!=":case"===":case"!==":case"<":case">":case">=":case"<=":case"in":case"instanceof":return!0}}function S(e){if(e.regex)return Y(lt.protos.RegExp);switch(typeof e.value){case"boolean":return lt.bool;case"number":return lt.num;case"string":return lt.str;case"object":case"function":return e.value?Y(lt.protos.RegExp):z}}function T(e){return function(t,r,n,o,s){var a=e(t,r,n,s);return o&&a.propagate(o),a}}function E(e){return function(t,r,n,o,s){return o||(o=new F),e(t,r,n,o,s),o}}function x(e,t,r,n,o){var s=mt[e.type];return s?s(e,t,r,n,o):void 0}function j(e,t){var r=e&&e[t],n=Array.prototype.slice.call(arguments,2);if(r)for(var o=0;o<r.length;++o)r[o].apply(null,n)}function O(e){var t=e?JSON.parse(JSON.stringify(e)):e;return e instanceof Error&&(t.__isError=!0,t.lineNumber="number"==typeof t.lineNumber?t.lineNumber:e.lineNumber,t.message=t.message||e.message,t.name=t.name||e.name,t.stack=t.stack||e.stack),t}function k(e){e&&Array.isArray(e)&&e.forEach(function(e){var t=e.message;e.message=t=t.replace(/^Line \d+: /,""),/^Unexpected/.test(t)&&(e.type=1,/end of input$/.test(t)&&(e.type=2))})}function R(e,t,r){var n=Array.isArray(e);return n&&1==e.length&&(e=e[0],n=!1),n?null==r?function(t){return e.indexOf(t.origin)>-1}:function(n,o){return o&&o.start>=t&&o.end<=r&&e.indexOf(n.origin)>-1}:null==r?function(t){return t.origin==e}:function(n,o){return o&&o.start>=t&&o.end<=r&&n.origin==e}}function M(e){St=!0;var t=d(e);if(t)for(var r=0;r<t.length;++r){var n=t[r].getProp(e);if(!n.isEmpty())return n}return z}function D(e,t){var r=vt[e.type];return r?r(e,t):null}var A=e.toString=function(e,t,r){return!e||e==r||t&&-3>t?"?":e.toString(t,r)},z=e.ANull=o.mixin({addType:function(){},propagate:function(){},getProp:function(){return z},forAllProps:function(){},hasType:function(){return!1},isEmpty:function(){return!0},getFunctionType:function(){},getObjType:function(){},getType:function(){},gatherProperties:function(){},propagatesTo:function(){},typeHint:function(){},propHint:function(){},toString:function(){return"?"}}),C=100,P=90,I=10,N=5,U=5,L=90,q=2,F=e.AVal=function(){this.types=[],this.forward=null,this.maxWeight=0};F.prototype=s(z,{addType:function(e,t){if(t=t||C,this.maxWeight<t){if(this.maxWeight=t,1==this.types.length&&this.types[0]==e)return;this.types.length=0}else if(this.maxWeight>t||this.types.indexOf(e)>-1)return;this.signal("addType",e),this.types.push(e);var r=this.forward;r&&u(function(n){for(var o=0;o<r.length;++o)n(e,r[o],t)})},propagate:function(e,t){if(!(e==z||e instanceof nt&&this.forward&&this.forward.length>2)){t&&t!=C&&(e=new rt(e,t)),(this.forward||(this.forward=[])).push(e);var r=this.types;r.length&&u(function(n){for(var o=0;o<r.length;++o)n(r[o],e,t)})}},getProp:function(e){if("__proto__"==e||"✖"==e)return z;var t=(this.props||(this.props=Object.create(null)))[e];return t||(t=this.props[e]=new F,this.propagate(new H(e,t))),t},forAllProps:function(e){this.propagate(new J(e))},hasType:function(e){return this.types.indexOf(e)>-1},isEmpty:function(){return 0===this.types.length},getFunctionType:function(){for(var e=this.types.length-1;e>=0;--e)if(this.types[e]instanceof at)return this.types[e]},getObjType:function(){for(var e=null,t=this.types.length-1;t>=0;--t){var r=this.types[t];if(r instanceof st){if(r.name)return r;e||(e=r)}}return e},getType:function(e){return 0===this.types.length&&e!==!1?this.makeupType():1===this.types.length?this.types[0]:l(this.types)},toString:function(e,t){if(0==this.types.length)return A(this.makeupType(),e,t);if(1==this.types.length)return A(this.types[0],e,t);var r=G(this.types);return r.length>2?"?":r.map(function(r){return A(r,e,t)}).join("|")},computedPropType:function(){if(!this.propertyOf)return null;if(this.propertyOf.hasProp("<i>")){var e=this.propertyOf.getProp("<i>");return e==this?null:e.getType()}if(this.propertyOf.maybeProps&&this.propertyOf.maybeProps["<i>"]==this){for(var t in this.propertyOf.props){var r=this.propertyOf.props[t];if(!r.isEmpty())return r}return null}},makeupType:function(){var e=this.computedPropType();if(e)return e;if(!this.forward)return null;for(var t=this.forward.length-1;t>=0;--t){var r=this.forward[t].typeHint();if(r&&!r.isEmpty())return St=!0,r}for(var n=Object.create(null),o=null,t=0;t<this.forward.length;++t){var s=this.forward[t].propHint();s&&"length"!=s&&"<i>"!=s&&"✖"!=s&&s!=lt.completingProperty&&(n[s]=!0,o=s)}if(!o)return null;var a=d(o);if(a){var i=[];e:for(var t=0;t<a.length;++t){var c=a[t];for(var s in n)if(!c.hasProp(s))continue e;c.hasCtor&&(c=Y(c)),i.push(c)}var p=l(i);if(p)return St=!0,p}},typeHint:function(){return this.types.length?this.getType():null},propagatesTo:function(){return this},gatherProperties:function(e,t){for(var r=0;r<this.types.length;++r)this.types[r].gatherProperties(e,t)},guessProperties:function(e){if(this.forward)for(var t=0;t<this.forward.length;++t){var r=this.forward[t].propHint();r&&e(r,null,0)}var n=this.makeupType();n&&n.gatherProperties(e)}});var G=e.simplifyTypes=function(e){var t=[];e:for(var r=0;r<e.length;++r){for(var n=e[r],o=0;o<t.length;o++){var s=i(n,t[o],0);if(s){t[o]=s;continue e}}t.push(n)}return t},W=e.constraint=function(e){var t=function(){this.origin=lt.curOrigin,this.construct.apply(this,arguments)};t.prototype=Object.create(z);for(var r in e)e.hasOwnProperty(r)&&(t.prototype[r]=e[r]);return t},H=W({construct:function(e,t){this.prop=e,this.target=t},addType:function(e,t){e.getProp&&e.getProp(this.prop).propagate(this.target,t)},propHint:function(){return this.prop},propagatesTo:function(){return"<i>"!=this.prop&&/[^\w_]/.test(this.prop)?void 0:{target:this.target,pathExt:"."+this.prop}}}),B=e.PropHasSubset=W({construct:function(e,t,r){this.prop=e,this.type=t,this.originNode=r},addType:function(e,t){if(e instanceof st){var r=e.defProp(this.prop,this.originNode);r.origin||(r.origin=this.origin),this.type.propagate(r,t)}},propHint:function(){return this.prop}}),J=W({construct:function(e){this.c=e},addType:function(e){e instanceof st&&e.forAllProps(this.c)}}),V=e.IsCallee=W({construct:function(e,t,r,n){this.self=e,this.args=t,this.argNodes=r,this.retval=n,this.disabled=lt.disabledComputing},addType:function(e,t){if(e instanceof at){for(var r=0;r<this.args.length;++r)r<e.args.length&&this.args[r].propagate(e.args[r],t),e.arguments&&this.args[r].propagate(e.arguments,t);this.self.propagate(e.self,this.self==lt.topScope?L:t);var n=e.computeRet;if(n)for(var o=this.disabled;o;o=o.prev)(o.fn==e||e.originNode&&o.fn.originNode==e.originNode)&&(n=null);n?n(this.self,this.args,this.argNodes).propagate(this.retval,t):e.retval.propagate(this.retval,t)}},typeHint:function(){for(var e=[],t=0;t<this.args.length;++t)e.push("?");return new at(null,this.self,this.args,e,z)},propagatesTo:function(){return{target:this.retval,pathExt:".!ret"}}}),$=W({construct:function(e,t,r,n){this.propName=e,this.args=t,this.argNodes=r,this.retval=n,this.disabled=lt.disabledComputing},addType:function(e,t){var r=new V(e,this.args,this.argNodes,this.retval);r.disabled=this.disabled,e.getProp(this.propName).propagate(r,t)},propHint:function(){return this.propName}}),X=e.IsCtor=W({construct:function(e,t){this.target=e,this.noReuse=t},addType:function(e,t){e instanceof at&&(lt.parent&&!lt.parent.options.reuseInstances&&(this.noReuse=!0),e.getProp("prototype").propagate(new K(this.noReuse?!1:e,this.target),t))}}),Y=e.getInstance=function(e,t){if(t===!1)return new st(e);t||(t=e.hasCtor),e.instances||(e.instances=[]);for(var r=0;r<e.instances.length;++r){var n=e.instances[r];if(n.ctor==t)return n.instance}var o=new st(e,t&&t.name);return o.origin=e.origin,e.instances.push({ctor:t,instance:o}),o},K=e.IsProto=W({construct:function(e,t){this.ctor=e,this.target=t},addType:function(e){e instanceof st&&((this.count=(this.count||0)+1)>8||this.target.addType(e==lt.protos.Array?new it:Y(e,this.ctor)))}}),Q=W({construct:function(e){this.fn=e},addType:function(e){if(e instanceof st&&!e.hasCtor){e.hasCtor=this.fn;var t=new tt(e,this.fn);t.addType(this.fn),e.forAllProps(function(e,r,n){n&&r.propagate(t)})}}}),Z=W({construct:function(e,t){this.other=e,this.target=t},addType:function(e,t){e==lt.str?this.target.addType(lt.str,t):e==lt.num&&this.other.hasType(lt.num)&&this.target.addType(lt.num,t)},typeHint:function(){return this.other}}),et=e.IfObj=W({construct:function(e){this.target=e},addType:function(e,t){e instanceof st&&this.target.addType(e,t)},propagatesTo:function(){return this.target}}),tt=W({construct:function(e,t){this.obj=e,this.ctor=t},addType:function(e){e instanceof at&&e.self&&e.self.isEmpty()&&e.self.addType(Y(this.obj,this.ctor),q)}}),rt=W({construct:function(e,t){this.inner=e,this.weight=t},addType:function(e,t){this.inner.addType(e,Math.min(t,this.weight))},propagatesTo:function(){return this.inner.propagatesTo()},typeHint:function(){return this.inner.typeHint()},propHint:function(){return this.inner.propHint()}}),nt=e.Type=function(){};nt.prototype=s(z,{constructor:nt,propagate:function(e,t){e.addType(this,t)},hasType:function(e){return e==this},isEmpty:function(){return!1},typeHint:function(){return this},getType:function(){return this}});var ot=e.Prim=function(e,t){this.name=t,this.proto=e};ot.prototype=s(nt.prototype,{constructor:ot,toString:function(){return this.name},getProp:function(e){return this.proto.hasProp(e)||z},gatherProperties:function(e,t){this.proto&&this.proto.gatherProperties(e,t)}});var st=e.Obj=function(e,t){if(this.props||(this.props=Object.create(null)),this.proto=e===!0?lt.protos.Object:e,e&&!t&&e.name&&!(this instanceof at)){var r=/^(.*)\.prototype$/.exec(this.proto.name);r&&(t=r[1])}this.name=t,this.maybeProps=null,this.origin=lt.curOrigin};st.prototype=s(nt.prototype,{constructor:st,toString:function(e){if(null==e&&(e=0),0>=e&&this.name)return this.name;var t=[],r=!1;for(var n in this.props)if("<i>"!=n){if(t.length>5){r=!0;break}t.push(e?n+": "+A(this.props[n],e-1,this):n)}return t.sort(),r&&t.push("..."),"{"+t.join(", ")+"}"},hasProp:function(e,t){var r=this.props[e];if(t!==!1)for(var n=this.proto;n&&!r;n=n.proto)r=n.props[e];return r},defProp:function(e,t){var r=this.hasProp(e,!1);if(r)return t&&!r.originNode&&(r.originNode=t),r;if("__proto__"==e||"✖"==e)return z;var n=this.maybeProps&&this.maybeProps[e];return n?(delete this.maybeProps[e],this.maybeUnregProtoPropHandler()):(n=new F,n.propertyOf=this),this.props[e]=n,n.originNode=t,n.origin=lt.curOrigin,this.broadcastProp(e,n,!0),n},getProp:function(e){var t=this.hasProp(e,!0)||this.maybeProps&&this.maybeProps[e];if(t)return t;if("__proto__"==e||"✖"==e)return z;var r=this.ensureMaybeProps()[e]=new F;return r.propertyOf=this,r},broadcastProp:function(e,t,r){if(r&&(this.signal("addProp",e,t),this instanceof ut||p(e,this)),this.onNewProp)for(var n=0;n<this.onNewProp.length;++n){var o=this.onNewProp[n];o.onProtoProp?o.onProtoProp(e,t,r):o(e,t,r)}},onProtoProp:function(e,t){var r=this.maybeProps&&this.maybeProps[e];r&&(delete this.maybeProps[e],this.maybeUnregProtoPropHandler(),this.proto.getProp(e).propagate(r)),this.broadcastProp(e,t,!1)},ensureMaybeProps:function(){return this.maybeProps||(this.proto&&this.proto.forAllProps(this),this.maybeProps=Object.create(null)),this.maybeProps},removeProp:function(e){var t=this.props[e];delete this.props[e],this.ensureMaybeProps()[e]=t,t.types.length=0},forAllProps:function(e){this.onNewProp||(this.onNewProp=[],this.proto&&this.proto.forAllProps(this)),this.onNewProp.push(e);for(var t=this;t;t=t.proto)for(var r in t.props)e.onProtoProp?e.onProtoProp(r,t.props[r],t==this):e(r,t.props[r],t==this)},maybeUnregProtoPropHandler:function(){if(this.maybeProps){for(var e in this.maybeProps)return;this.maybeProps=null}!this.proto||this.onNewProp&&this.onNewProp.length||this.proto.unregPropHandler(this)},unregPropHandler:function(e){for(var t=0;t<this.onNewProp.length;++t)if(this.onNewProp[t]==e){this.onNewProp.splice(t,1);break}this.maybeUnregProtoPropHandler()},gatherProperties:function(e,t){for(var r in this.props)"<i>"!=r&&e(r,this,t);this.proto&&this.proto.gatherProperties(e,t+1)},getObjType:function(){return this}});var at=e.Fn=function(e,t,r,n,o){st.call(this,lt.protos.Function,e),this.self=t,this.args=r,this.argNames=n,this.retval=o};at.prototype=s(st.prototype,{constructor:at,toString:function(e){null==e&&(e=0);for(var t="fn(",r=0;r<this.args.length;++r){r&&(t+=", ");var n=this.argNames[r];n&&"?"!=n&&(t+=n+": "),t+=e>-3?A(this.args[r],e-1,this):"?"}return t+=")",this.retval.isEmpty()||(t+=" -> "+(e>-3?A(this.retval,e-1,this):"?")),t},getProp:function(e){if("prototype"==e){var t=this.hasProp(e,!1);if(!t){t=this.defProp(e);var r=new st(!0,this.name&&this.name+".prototype");r.origin=this.origin,t.addType(r,I)}return t}return st.prototype.getProp.call(this,e)},defProp:function(e,t){if("prototype"==e){var r=this.hasProp(e,!1);return r?r:(r=st.prototype.defProp.call(this,e,t),r.origin=this.origin,r.propagate(new Q(this)),r)}return st.prototype.defProp.call(this,e,t)},getFunctionType:function(){return this}});var it=e.Arr=function(e){st.call(this,lt.protos.Array);var t=this.defProp("<i>");e&&e.propagate(t)};it.prototype=s(st.prototype,{constructor:it,toString:function(e){return null==e&&(e=0),"["+(e>-3?A(this.getProp("<i>"),e-1,this):"?")+"]"}}),e.Context=function(t,r){this.parent=r,this.props=Object.create(null),this.protos=Object.create(null),this.origins=[],this.curOrigin="ecma5",this.paths=Object.create(null),this.definitions=Object.create(null),this.purgeGen=0,this.workList=null,this.disabledComputing=null,e.withContext(this,function(){if(lt.protos.Object=new st(null,"Object.prototype"),lt.topScope=new ut,lt.topScope.name="<top>",lt.protos.Array=new st(!0,"Array.prototype"),lt.protos.Function=new at("Function.prototype",z,[],[],z),lt.protos.Function.proto=lt.protos.Object,lt.protos.RegExp=new st(!0,"RegExp.prototype"),lt.protos.String=new st(!0,"String.prototype"),lt.protos.Number=new st(!0,"Number.prototype"),lt.protos.Boolean=new st(!0,"Boolean.prototype"),lt.str=new ot(lt.protos.String,"string"),lt.bool=new ot(lt.protos.Boolean,"bool"),lt.num=new ot(lt.protos.Number,"number"),lt.curOrigin=null,t)for(var e=0;e<t.length;++e)n.load(t[e])})};var lt=null;e.cx=function(){return lt},e.withContext=function(e,t){var r=lt;lt=e;try{return t()}finally{lt=r}},e.TimedOut=function(){this.message="Timed out",this.stack=(new Error).stack},e.TimedOut.prototype=Object.create(Error.prototype),e.TimedOut.prototype.name="infer.TimedOut";var ct;e.withTimeout=function(e,t){var r=+new Date+e,n=ct;if(n&&r>n)return t();ct=r;try{return t()}finally{ct=n}},e.addOrigin=function(e){lt.origins.indexOf(e)<0&&lt.origins.push(e)};var pt=20,dt=1e-4,ut=e.Scope=function(e){st.call(this,e||!0),this.prev=e};ut.prototype=s(st.prototype,{constructor:ut,defVar:function(e,t){for(var r=this;;r=r.proto){var n=r.props[e];if(n)return n;if(!r.prev)return r.defProp(e,t)}}});var ht={},ft=r.make({Function:function(e,t,r){var n=e.body.scope=new ut(t);n.originNode=e;for(var o=[],s=[],a=0;a<e.params.length;++a){var i=e.params[a];s.push(i.name),o.push(y(n,i))}if(n.fnType=new at(e.id&&e.id.name,new F,o,s,z),n.fnType.originNode=e,e.id){var l="FunctionDeclaration"==e.type;y(l?t:n,e.id)}r(e.body,n,"ScopeBody")},TryStatement:function(e,t,r){if(r(e.block,t,"Statement"),e.handler){var n=y(t,e.handler.param);r(e.handler.body,t,"ScopeBody");var o=lt.definitions.ecma5;o&&n.isEmpty()&&Y(o["Error.prototype"]).propagate(n,U)}e.finalizer&&r(e.finalizer,t,"Statement")},VariableDeclaration:function(e,t,r){for(var n=0;n<e.declarations.length;++n){var o=e.declarations[n];y(t,o.id),o.init&&r(o.init,t,"Expression")}}}),mt={RecoveredNode:T(function(){return new F}),ArrayExpression:T(function(e,t,r){for(var n=new F,o=0;o<e.elements.length;++o){var s=e.elements[o];s&&x(s,t,r,n)}return new it(n)}),ObjectExpression:T(function(e,t,r,n){var o=e.objType=new st(!0,n);o.originNode=e;for(var s=0;s<e.properties.length;++s){var n,a=e.properties[s],i=a.key;if("✖"!=a.value.name)if("Identifier"==i.type?n=i.name:"string"==typeof i.value&&(n=i.value),n&&"set"!=a.kind){var l=o.defProp(n,i),c=l;l.initializer=!0,"get"==a.kind&&(c=new V(o,[],null,l)),x(a.value,t,r,c,n)}else x(a.value,t,r,z)}return o}),FunctionExpression:T(function(e,t,r,n){var o=e.body.scope,s=o.fnType;return n&&!s.name&&(s.name=n),r(e.body,t,"ScopeBody"),m(e,o)||b(o),e.id&&o.getProp(e.id.name).addType(s),s}),SequenceExpression:T(function(e,t,r){for(var n=0,o=e.expressions.length-1;o>n;++n)x(e.expressions[n],t,r,z);return x(e.expressions[o],t,r)}),UnaryExpression:T(function(e,t,r){return x(e.argument,t,r,z),w(e.operator)}),UpdateExpression:T(function(e,t,r){return x(e.argument,t,r,z),lt.num}),BinaryExpression:T(function(e,t,r){if("+"==e.operator){var n=x(e.left,t,r),o=x(e.right,t,r);if(n.hasType(lt.str)||o.hasType(lt.str))return lt.str;if(n.hasType(lt.num)&&o.hasType(lt.num))return lt.num;var s=new F;return n.propagate(new Z(o,s)),o.propagate(new Z(n,s)),s}return x(e.left,t,r,z),x(e.right,t,r,z),_(e.operator)?lt.bool:lt.num}),AssignmentExpression:T(function(e,t,r){var n,o,s;if("MemberExpression"==e.left.type?(s=v(e.left,t,r),"Identifier"==e.left.object.type&&(o=e.left.object.name+"."+s)):o=e.left.name,"="!=e.operator&&"+="!=e.operator?(x(e.right,t,r,z),n=lt.num):n=x(e.right,t,r,null,o),"MemberExpression"==e.left.type){var a=x(e.left.object,t,r);if("prototype"==s&&h(t,20),"<i>"==s){var i=e.left.property.name,l=t.props[i],c=l&&l.iteratesOver;if(c){h(t,20);var p="MemberExpression"==e.right.type&&e.right.computed&&e.right.property.name==i;return c.forAllProps(function(e,t,r){r&&"prototype"!=e&&"<i>"!=e&&a.propagate(new B(e,p?t:z))}),n}}a.propagate(new B(s,n,e.left.property))}else n.propagate(t.defVar(e.left.name,e.left));return n}),LogicalExpression:E(function(e,t,r,n){x(e.left,t,r,n),x(e.right,t,r,n)}),ConditionalExpression:E(function(e,t,r,n){x(e.test,t,r,z),x(e.consequent,t,r,n),x(e.alternate,t,r,n)}),NewExpression:E(function(e,t,r,n,o){"Identifier"==e.callee.type&&e.callee.name in t.props&&h(t,20);for(var s=0,a=[];s<e.arguments.length;++s)a.push(x(e.arguments[s],t,r));var i=x(e.callee,t,r),l=new F;i.propagate(new X(l,o&&/\.prototype$/.test(o))),l.propagate(n,P),i.propagate(new V(l,a,e.arguments,new et(n)))}),CallExpression:E(function(e,t,r,n){for(var o=0,s=[];o<e.arguments.length;++o)s.push(x(e.arguments[o],t,r));if("MemberExpression"==e.callee.type){var a=x(e.callee.object,t,r),i=v(e.callee,t,r);("call"==i||"apply"==i)&&t.fnType&&t.fnType.args.indexOf(a)>-1&&h(t,30),a.propagate(new $(i,s,e.arguments,n))}else{var l=x(e.callee,t,r);t.fnType&&t.fnType.args.indexOf(l)>-1&&h(t,30);var c=l.getFunctionType();c&&c.instantiateScore&&t.fnType&&h(t,c.instantiateScore/5),l.propagate(new V(lt.topScope,s,e.arguments,n))}}),MemberExpression:E(function(e,t,r,n){var o=v(e,t),s=x(e.object,t,r),a=s.getProp(o);if("<i>"==o){var i=x(e.property,t,r);if(!i.hasType(lt.num))return a.propagate(n,N)}a.propagate(n)}),Identifier:T(function(e,t){return"arguments"!=e.name||!t.fnType||e.name in t.props||t.defProp(e.name,t.fnType.originNode).addType(new it(t.fnType.arguments=new F)),t.getProp(e.name)}),ThisExpression:T(function(e,t){return t.fnType?t.fnType.self:lt.topScope}),Literal:T(function(e){return S(e)})},gt=r.make({Expression:function(e,t,r){x(e,t,r,z)},FunctionDeclaration:function(e,t,r){var n=e.body.scope,o=n.fnType;r(e.body,t,"ScopeBody"),m(e,n)||b(n);var s=t.getProp(e.id.name);s.addType(o)},VariableDeclaration:function(e,t,r){for(var n=0;n<e.declarations.length;++n){var o=e.declarations[n],s=t.getProp(o.id.name);o.init&&x(o.init,t,r,s,o.id.name)}},ReturnStatement:function(e,t,r){if(e.argument){var n=z;t.fnType&&(t.fnType.retval==z&&(t.fnType.retval=new F),n=t.fnType.retval),x(e.argument,t,r,n)}},ForInStatement:function(e,t,r){var n=x(e.right,t,r);if("Identifier"==e.right.type&&e.right.name in t.props||"MemberExpression"==e.right.type&&"prototype"==e.right.property.name){h(t,5);var o;"Identifier"==e.left.type?o=e.left.name:"VariableDeclaration"==e.left.type&&(o=e.left.declarations[0].id.name),o&&o in t.props&&(t.getProp(o).iteratesOver=n)}r(e.body,t,"Statement")},ScopeBody:function(e,t,r){r(e,e.scope||t)}}),bt=Object.create(null);bt.type="Program",bt.body=[],bt.comments=[],bt.tokens=[],bt.range=[0,0];var yt=e.parse=function(e,r,n){var o;if(r.preParse)for(var s=0;s<r.preParse.length;s++){var a=r.preParse[s](e,n);"string"==typeof a&&(e=a)}var o;try{n.tolerant=!0,n.tokens=!0,n.comment=!0,n.range=!0,n.deps=!0,n.loc=!0,o=t.parse(e,n),"object"!=typeof o.sourceFile&&(o.sourceFile=Object.create(null),o.sourceFile.text=o.source,o.sourceFile.name=o.fileLocation)}catch(i){o=bt,o.range[1]="string"==typeof e?e.length:0,o.errors=[i],"object"!=typeof o.sourceFile&&(o.sourceFile=Object.create(null),o.sourceFile.text=n.directSourceFile.text,o.sourceFile.name=n.directSourceFile.name)}return Array.isArray(o.errors)&&o.errors.length>0&&(k(o.errors),o.errors=o.errors.map(O)),j(r,"postParse",o,e),o};e.analyze=function(t,n,o,s){"string"==typeof t&&(t=yt(t)),n||(n="file#"+lt.origins.length),e.addOrigin(lt.curOrigin=n),o||(o=lt.topScope),r.recursive(t,o,null,ft),j(s,"preInfer",t,o),r.recursive(t,o,null,gt),j(s,"postInfer",t,o),lt.curOrigin=null},e.purge=function(e,t,r){var n=R(e,t,r);++lt.purgeGen,lt.topScope.purge(n);for(var o in lt.props){for(var s=lt.props[o],a=0;a<s.length;++a){var i=s[a],l=i.props[o];(!l||n(l,l.originNode))&&s.splice(a--,1)}s.length||delete lt.props[o]}},F.prototype.purge=function(e){if(this.purgeGen!=lt.purgeGen){this.purgeGen=lt.purgeGen;for(var t=0;t<this.types.length;++t){var r=this.types[t];e(r,r.originNode)?this.types.splice(t--,1):r.purge(e)}if(this.forward)for(var t=0;t<this.forward.length;++t){var n=this.forward[t];e(n)?(this.forward.splice(t--,1),this.props&&(this.props=null)):n.purge&&n.purge(e)}}},z.purge=function(){},st.prototype.purge=function(e){if(this.purgeGen==lt.purgeGen)return!0;this.purgeGen=lt.purgeGen;for(var t in this.props){var r=this.props[t];e(r,r.originNode)&&this.removeProp(t),r.purge(e)}},at.prototype.purge=function(e){if(!st.prototype.purge.call(this,e)){this.self.purge(e),this.retval.purge(e);for(var t=0;t<this.args.length;++t)this.args[t].purge(e)}};var vt={ArrayExpression:function(e,t){for(var r=new F,n=0;n<e.elements.length;++n){var o=e.elements[n];o&&D(o,t).propagate(r)}return new it(r)},ObjectExpression:function(e){return e.objType},FunctionExpression:function(e){return e.body.scope.fnType},SequenceExpression:function(e,t){return D(e.expressions[e.expressions.length-1],t)},UnaryExpression:function(e){return w(e.operator)},UpdateExpression:function(){return lt.num},BinaryExpression:function(e,t){if(_(e.operator))return lt.bool;if("+"==e.operator){var r=D(e.left,t),n=D(e.right,t);if(r.hasType(lt.str)||n.hasType(lt.str))return lt.str}return lt.num},AssignmentExpression:function(e,t){return D(e.right,t)},LogicalExpression:function(e,t){var r=D(e.left,t);return r.isEmpty()?D(e.right,t):r},ConditionalExpression:function(e,t){var r=D(e.consequent,t);return r.isEmpty()?D(e.alternate,t):r},NewExpression:function(e,t){var r=D(e.callee,t).getFunctionType(),n=r&&r.getProp("prototype").getObjType();return n?Y(n,r):z},CallExpression:function(e,t){var r=D(e.callee,t).getFunctionType();if(!r)return z;if(r.computeRet){for(var n=0,o=[];n<e.arguments.length;++n)o.push(D(e.arguments[n],t));var s=z;return"MemberExpression"==e.callee.type&&(s=D(e.callee.object,t)),r.computeRet(s,o,e.arguments)}return r.retval},MemberExpression:function(e,t){var r=v(e,t),n=D(e.object,t).getType();return n?n.getProp(r):"<i>"==r?z:M(r)},Identifier:function(e,t){return t.hasProp(e.name)||z},ThisExpression:function(e,t){return t.fnType?t.fnType.self:lt.topScope},Literal:function(e){return S(e)}},wt=e.searchVisitor=r.make({Function:function(e,t,r){var n=e.body.scope;e.id&&r(e.id,n);for(var o=0;o<e.params.length;++o)r(e.params[o],n);r(e.body,n,"ScopeBody")},TryStatement:function(e,t,n){e.handler&&n(e.handler.param,t),r.base.TryStatement(e,t,n)},VariableDeclaration:function(e,t,r){for(var n=0;n<e.declarations.length;++n){var o=e.declarations[n];r(o.id,t),o.init&&r(o.init,t,"Expression")}}});e.fullVisitor=r.make({MemberExpression:function(e,t,r){r(e.object,t,"Expression"),r(e.property,t,e.computed?"Expression":null)},ObjectExpression:function(e,t,r){for(var n=0;n<e.properties.length;++n)r(e.properties[n].value,t,"Expression"),r(e.properties[n].key,t)}},wt),e.findExpressionAt=function(e,t,n,o,s){var a=s||function(e,t){return"Identifier"==t.type&&"✖"==t.name?!1:vt.hasOwnProperty(t.type)};return r.findNodeAt(e,t,n,a,wt,o||lt.topScope)},e.findExpressionAround=function(e,t,n,o,s){var a=s||function(e,r){return null!=t&&r.start>t?!1:"Identifier"==r.type&&"✖"==r.name?!1:vt.hasOwnProperty(r.type)};return r.findNodeAround(e,n,a,wt,o||lt.topScope)},e.expressionType=function(e){return D(e.node,e.state)},e.parentNode=function(e,t){function n(t,s,a){if(t.start<=e.start&&t.end>=e.end){var i=o[o.length-1];if(t==e)throw{found:i};i!=t&&o.push(t),r.base[a||t.type](t,s,n),i!=t&&o.pop()}}var o=[];try{n(t,null)}catch(s){if(s.found)return s.found;throw s}};var _t={ArrayExpression:function(e,t,r){return r(e,!0).getProp("<i>")},ObjectExpression:function(e,t,r){for(var n=0;n<e.properties.length;++n){var o=t.properties[n];if(o.value==t)return r(e,!0).getProp(o.key.name)}},UnaryExpression:function(e){return w(e.operator)},UpdateExpression:function(){return lt.num},BinaryExpression:function(e){return _(e.operator)?lt.bool:lt.num},AssignmentExpression:function(e,t,r){return r(e.left)},LogicalExpression:function(e,t,r){return r(e,!0)},ConditionalExpression:function(e,t,r){return e.consequent==t||e.alternate==t?r(e,!0):void 0},NewExpression:function(e,t,r){return this.CallExpression(e,t,r)},CallExpression:function(e,t,r){for(var n=0;n<e.arguments.length;n++){var o=e.arguments[n];if(o==t){var s=r(e.callee).getFunctionType();if(s instanceof at)return s.args[n];break}}},ReturnStatement:function(e,t,n){var o=r.findNodeAround(t.sourceFile.ast,t.start,"Function");if(o){var s="FunctionExpression"==o.node.type?n(o.node,!0).getFunctionType():o.node.body.scope.fnType;if(s)return s.retval.getType()}},VariableDeclaration:function(e,t,r){for(var n=0;n<e.declarations.length;n++){var o=e.declarations[n];
if(o.init==t)return r(o.id)}}};e.typeFromContext=function(t,r){var n=e.parentNode(r.node,t),o=null;return _t.hasOwnProperty(n.type)&&(o=_t[n.type](n,r.node,function(n,o){var s={node:n,state:r.state},a=o?e.typeFromContext(t,s):e.expressionType(s);return a||z})),o||e.expressionType(r)};var St=!1;e.resetGuessing=function(e){St=e},e.didGuess=function(){return St},e.forAllPropertiesOf=function(e,t){e.gatherProperties(t,0)};var Tt=r.make({},wt);e.findRefs=function(e,t,n,o,s){Tt.Identifier=function(e,t){if(e.name==n)for(var r=t;r;r=r.prev)if(r==o&&s(e,t),n in r.props)return},r.recursive(e,t,null,Tt)};var Et=r.make({Function:function(e,t,r){r(e.body,e.body.scope,"ScopeBody")}});e.findPropRefs=function(e,t,n,o,s){r.simple(e,{MemberExpression:function(e,t){e.computed||e.property.name!=o||D(e.object,t).getType()==n&&s(e.property)},ObjectExpression:function(e,t){if(D(e,t).getType()==n)for(var r=0;r<e.properties.length;++r)e.properties[r].key.name==o&&s(e.properties[r].key)}},Et,t)};var xt=e.scopeAt=function(e,t,n){var o=r.findNodeAround(e,t,function(e,t){return"ScopeBody"==e&&t.scope});return o?o.node.scope:n||lt.topScope};e.forAllLocalsAt=function(e,t,r,n){var o=xt(e,t,r);o.gatherProperties(n,0)},n=e.def=n.init({},e)}),function(e,t){return"object"==typeof exports&&"object"==typeof module?t(exports,require("./infer"),require("./signal"),require("acorn"),require("acorn/dist/walk")):"function"==typeof define&&define.amd?define("tern/lib/tern",["exports","./infer","./signal","esprima/esprima","acorn/dist/walk"],t):void t(e.tern||(e.tern={}),tern,tern.signal,acorn,acorn.walk)}(this,function(e,t,r,n,o){"use strict";function s(e,t){this.name=e,this.parent=t,this.scope=this.text=this.ast=this.lineOffsets=null}function a(e,r,n){e.text=n.options.stripCRs?r.replace(/\r\n/g,"\n"):r,t.withContext(n.cx,function(){e.ast=t.parse(e.text,n.passes,{directSourceFile:e,allowReturnOutsideFunction:!0})}),e.lineOffsets=null}function i(e,r,n){if(r.query&&!V.hasOwnProperty(r.query.type))return n("No query type '"+r.query.type+"' defined");var o=r.query;o||n(null,{});var s=r.files||[];s.length&&++e.uses;for(var a=0;a<s.length;++a){var i=s[a];"delete"==i.type?e.delFile(i.name):c(e,i.name,null,"full"==i.type?i.text:null)}var l="number"==typeof r.timeout?[r.timeout]:null;if(!o)return void d(e,l,function(){});var p=V[o.type];if(p.takesFile){if("string"!=typeof o.file)return n(".query.file must be a string");/^#/.test(o.file)||c(e,o.file,null)}d(e,l,function(r){function a(){var t;if(p.runAsync)p.runAsync(e,o,i,function(e,t){n(e,t)});else{try{t=p.run(e,o,i)}catch(r){return e.options.debug&&"TernError"!=r.name&&console.error(r.stack),n(r)}n(null,t)}}if(r)return n(r);var i=p.takesFile&&g(e,s,o.file);return p.fullFile&&"part"==i.type?n("Can't run a "+o.type+" query on a file fragment"):void t.withContext(e.cx,l?function(){t.withTimeout(l[0],a)}:a)})}function l(e,r){return t.withContext(e.cx,function(){r.scope=e.cx.topScope,e.signal("beforeLoad",r),t.analyze(r.ast,r.name,r.scope,e.passes),e.signal("afterLoad",r)}),r}function c(e,t,r,n){var o=e.findFile(t);if(o)return null!=n&&(o.scope&&(e.needsPurge.push(t),o.scope=null),a(o,n,e)),void(y(e,o.parent)>y(e,r)&&(o.parent=r,o.excluded&&(o.excluded=null)));var i=new s(t,r);e.files.push(i),e.fileMap[t]=i,null!=n?a(i,n,e):e.options.async?(e.startAsyncAction(),e.options.getFile(t,function(t,r){"object"==typeof r&&(r=r.contents),a(i,r||"",e),e.finishAsyncAction(t)})):a(i,e.options.getFile(t)||"",e)}function p(e,t,r){var n=function(){e.off("everythingFetched",n),clearTimeout(o),d(e,t,r)};e.on("everythingFetched",n);var o=setTimeout(n,e.options.fetchTimeout)}function d(e,r,n){if(e.pending)return p(e,r,n);var o=e.fetchError;if(o)return e.fetchError=null,n(o);e.needsPurge.length>0&&t.withContext(e.cx,function(){t.purge(e.needsPurge),e.needsPurge.length=0});for(var s=!0,a=0;a<e.files.length;){for(var i=[];a<e.files.length;++a){var c=e.files[a];null==c.text?s=!1:null!=c.scope||c.excluded||i.push(c)}i.sort(function(t,r){return y(e,t.parent)-y(e,r.parent)});for(var d=0;d<i.length;d++){var c=i[d];if(c.parent&&!w(e,c))c.excluded=!0;else if(r){var u=+new Date;t.withTimeout(r[0],function(){l(e,c)}),r[0]-=+new Date-u}else l(e,c)}}s?n():p(e,r,n)}function u(e){var t=e.indexOf("\n");return 0>t?e:e.slice(0,t)}function h(e,t,r){var n=Math.max(0,r-500),o=null;if(!/^\s*$/.test(e))for(;;){var s=t.indexOf(e,n);if(0>s||s>r+500)break;(null==o||Math.abs(o-r)>Math.abs(s-r))&&(o=s),n=s+e.length}return o}function f(e){for(var t=0;e;++t,e=e.prev);return t}function m(e){var t=new Error(e);return t.name="TernError",t}function g(e,r,n){var s=n.match(/^#(\d+)$/);if(!s)return e.findFile(n);var a=r[s[1]];if(!a||"delete"==a.type)throw m("Reference to unknown file "+n);if("full"==a.type)return e.findFile(a.name);var i=a.backing=e.findFile(a.name),l=a.offset;a.offsetLines&&(l={line:a.offsetLines,ch:0}),a.offset=l=Y(i,null==a.offsetLines?a.offset:{line:a.offsetLines,ch:0},!0);var c,p,d=u(a.text),g=h(d,i.text,l),b=null==g?Math.max(0,i.text.lastIndexOf("\n",l)):g;return t.withContext(e.cx,function(){t.purge(a.name,b,b+a.text.length);var r,n=a.text;if(r=n.match(/(?:"([^"]*)"|([\w$]+))\s*:\s*function\b/)){var s=o.findNodeAround(a.backing.ast,b,"ObjectExpression");s&&s.node.objType&&(c={type:s.node.objType,prop:r[2]||r[1]})}if(g&&(r=d.match(/^(.*?)\bfunction\b/))){for(var l=r[1].length,u="",h=0;l>h;++h)u+=" ";n=u+n.slice(l),p=!0}var m=t.scopeAt(i.ast,b,i.scope),y=t.scopeAt(i.ast,b+n.length,i.scope),v=a.scope=f(m)<f(y)?y:m;a.ast=t.parse(n,e.passes,{directSourceFile:a,allowReturnOutsideFunction:!0}),t.analyze(a.ast,a.name,v,e.passes);e:if(c||p){var w=t.scopeAt(a.ast,d.length,m);if(!w.fnType)break e;if(c){var _=c.type.getProp(c.prop);_.addType(w.fnType)}else if(p){var S=t.scopeAt(i.ast,b+d.length,i.scope);if(S==m||!S.fnType)break e;var T=S.fnType,E=w.fnType;if(!E||E.name!=T.name&&T.name)break e;for(var h=0,x=Math.min(T.args.length,E.args.length);x>h;++h)T.args[h].propagate(E.args[h]);T.self.propagate(E.self),E.retval.propagate(T.retval)}}}),a}function b(e){var t=0;return o.simple(e,{Expression:function(){++t}}),t}function y(e,t){for(var r=0;t;)t=e.findFile(t).parent,++r;return r}function v(e,t){for(;;){var r=e.findFile(t.parent);if(!r.parent)break;t=r}return t.name}function w(e,t){var r=v(e,t),n=b(t.ast),o=e.budgets[r];return null==o&&(o=e.budgets[r]=e.options.dependencyBudget),n>o?!1:(e.budgets[r]=o-n,!0)}function _(e){return"number"==typeof e||"object"==typeof e&&"number"==typeof e.line&&"number"==typeof e.ch}function S(e){if(e.query){if("string"!=typeof e.query.type)return".query.type must be a string";if(e.query.start&&!_(e.query.start))return".query.start must be a position";if(e.query.end&&!_(e.query.end))return".query.end must be a position"}if(e.files){if(!Array.isArray(e.files))return"Files property must be an array";for(var t=0;t<e.files.length;++t){var r=e.files[t];if("object"!=typeof r)return".files[n] must be objects";if("string"!=typeof r.name)return".files[n].name must be a string";if("delete"!=r.type){if("string"!=typeof r.text)return".files[n].text must be a string";if("part"==r.type){if(!_(r.offset)&&"number"!=typeof r.offsetLines)return".files[n].offset must be a position"}else if("full"!=r.type)return'.files[n].type must be "full" or "part"'}}}}function T(e,t){for(var r=e.text,n=e.lineOffsets||(e.lineOffsets=[0]),o=0,s=0,a=Math.min(Math.floor(t/X),n.length-1),o=n[a],s=a*X;t>s;){if(++s,o=r.indexOf("\n",o)+1,0===o)return null;s%X===0&&n.push(o)}return o}function E(e,t){if(!e)return{line:0,ch:0};for(var r,n,o=e.lineOffsets||(e.lineOffsets=[0]),s=e.text,a=o.length-1;a>=0;--a)o[a]<=t&&(r=a*X,n=o[a]);for(;;){var i=s.indexOf("\n",n);if(i>=t||0>i)break;n=i+1,++r}return{line:r,ch:t-n}}function x(e){for(var t in e)null==e[t]&&delete e[t];return e}function j(e,t,r){null!=r&&(e[t]=r)}function O(e,t){"string"!=typeof e&&(e=e.name,t=t.name);var r=/^[A-Z]/.test(e),n=/^[A-Z]/.test(t);return r==n?t>e?-1:e==t?0:1:r?1:-1}function k(e,t,r){return"Literal"==e.type&&"string"==typeof e.value&&e.start==t-1&&e.end<=r+1}function R(e,t){for(var r=0;r<e.properties.length;r++){var n=e.properties[r];if(n.key.start<=t&&n.key.end>=t)return n}}function M(e,r,o){function s(n,o,s,a){if((!w&&r.omitObjectPrototype===!1||o!=e.cx.protos.Object||u)&&!(r.filter!==!1&&u&&0!==(r.caseInsensitive?n.toLowerCase():n).indexOf(u)||d&&d.props[n])){for(var i=0;i<h.length;++i){var l=h[i];if((_?l.name:l)==n)return}var c=_?{name:n}:n;if(h.push(c),o&&(r.types||r.docs||r.urls||r.origins)){var p=o.props[n];t.resetGuessing();var f=p.getType();c.guess=t.didGuess(),r.types&&(c.type=t.toString(p)),r.docs&&j(c,"doc",I(r,p.doc||f&&f.doc)),r.urls&&j(c,"url",p.url||f&&f.url),r.origins&&j(c,"origin",p.origin||f&&f.origin)}r.depths&&(c.depth=s),_&&a&&a(c)}}if(null==r.end)throw m("missing .query.end field");if(e.passes.completion)for(var a=0;a<e.passes.completion.length;a++){var i=e.passes.completion[a](o,r);if(i)return i}for(var l=Y(o,r.end),c=l,p=o.text;l&&n.isIdentifierChar(p.charCodeAt(l-1));)--l;if(r.expandWordForward!==!1)for(;c<p.length&&n.isIdentifierChar(p.charCodeAt(c));)++c;var d,u=p.slice(l,c),h=[];r.caseInsensitive&&(u=u.toLowerCase());var f,g,b,y,v,w,_=r.types||r.depths||r.docs||r.urls||r.origins,S=t.findExpressionAround(o.ast,null,l,o.scope);if(S)if("MemberExpression"==S.node.type&&S.node.object.end<l)v=S;else if(k(S.node,l,c)){var T=t.parentNode(S.node,o.ast);"MemberExpression"==T.type&&T.property==S.node&&(v={node:T,state:S.state})}else if("ObjectExpression"==S.node.type){var E=R(S.node,c);E?(w=S,g=y=E.key.name):u||/:\s*$/.test(o.text.slice(0,l))||(w=S,g=y=!0)}if(w)b=t.typeFromContext(o.ast,w),d=w.node.objType;else if(v)g=v.node.property,g="Literal"==g.type?g.value.slice(1):g.name,v.node=v.node.object,b=t.expressionType(v);else if("."==p.charAt(l-1)){for(var x=l-1;x&&("."==p.charAt(x-1)||n.isIdentifierChar(p.charCodeAt(x-1)));)x--;var M=p.slice(x,l-1);M&&(b=t.def.parsePath(M,o.scope).getObjType(),g=u)}if(null!=g){if(e.cx.completingProperty=g,b&&t.forAllPropertiesOf(b,s),!h.length&&r.guess!==!1&&b&&b.guessProperties&&b.guessProperties(function(e,t,r){e!=g&&"✖"!=e&&s(e,t,r)}),!h.length&&u.length>=2&&r.guess!==!1)for(var g in e.cx.props)s(g,e.cx.props[g][0],0);f="memberCompletion"}else t.forAllLocalsAt(o.ast,l,o.scope,s),r.includeKeywords&&Q.forEach(function(e){s(e,null,0,function(e){e.isKeyword=!0})}),f="variableCompletion";return e.passes[f]&&e.passes[f].forEach(function(e){e(o,l,c,h)}),r.sort!==!1&&h.sort(O),e.cx.completingProperty=null,{start:K(r,o,l),end:K(r,o,c),isProperty:!!g,isObjectKey:!!y,completions:h}}function D(e,t){var r=t.prefix,n=[];for(var o in e.cx.props)"<i>"==o||r&&0!==o.indexOf(r)||n.push(o);return t.sort!==!1&&n.sort(O),{completions:n}}function A(e,t,r){var n=Z(e,t,r);if(n)return n;throw m("No expression at the given position.")}function z(e){return e&&(e=e.getType())&&e instanceof t.Obj?e:null}function C(e,r,n,o){var s;if(o&&(t.resetGuessing(),s=t.expressionType(o)),e.passes.typeAt){var a=Y(n,r.end);e.passes.typeAt.forEach(function(e){s=e(n,a,o,s)})}if(!s)throw m("No type found at the given position.");var i;if("ObjectExpression"==o.node.type&&null!=r.end&&(i=R(o.node,Y(n,r.end)))){var l=i.key.name,c=z(t.typeFromContext(n.ast,o));if(c&&c.hasProp(l))s=c.hasProp(l);else{var p=z(s);p&&p.hasProp(l)&&(s=p.hasProp(l))}}return s}function P(e,r,n){var o,s=Z(n,r),a=C(e,r,n,s),i=a;if(a=r.preferFunction?a.getFunctionType()||a.getType():a.getType(),s&&("Identifier"==s.node.type?o=s.node.name:"MemberExpression"!=s.node.type||s.node.computed||(o=s.node.property.name)),null!=r.depth&&"number"!=typeof r.depth)throw m(".query.depth must be a number");var l={guess:t.didGuess(),type:t.toString(i,r.depth),name:a&&a.name,exprName:o};return a&&U(r,a,l),!l.doc&&i.doc&&(l.doc=I(r,i.doc)),x(l)}function I(e,t){if(!t)return null;if("full"==e.docFormat)return t;var r=/.\n[\s@\n]/.exec(t);if(r&&(t=t.slice(0,r.index+1)),t=t.replace(/\n\s*/g," "),t.length<100)return t;var n=/[\.!?] [A-Z]/g;n.lastIndex=80;var o=n.exec(t);return o&&(t=t.slice(0,o.index+1)),t}function N(e,r,n){var o=Z(n,r),s=C(e,r,n,o),a={url:s.url,doc:I(r,s.doc),type:t.toString(s)},i=s.getType();return i&&U(r,i,a),x(a)}function U(e,r,n){n.url||(n.url=r.url),n.doc||(n.doc=I(e,r.doc)),n.origin||(n.origin=r.origin);var o,s=t.cx().protos;!n.url&&!n.doc&&r.proto&&(o=r.proto.hasCtor)&&r.proto!=s.Object&&r.proto!=s.Function&&r.proto!=s.Array&&(n.url=o.url,n.doc=I(e,o.doc))}function L(e,t,r){var n=Z(r,t),o=C(e,t,r,n),s=et(o),a={url:o.url,doc:I(t,o.doc),origin:o.origin};if(o.types)for(var i=o.types.length-1;i>=0;--i){var l=o.types[i];U(t,l,a),s||(s=et(l))}if(s&&s.node){var c=s.node.sourceFile||e.findFile(s.origin),p=K(t,c,s.node.start),d=K(t,c,s.node.end);a.start=p,a.end=d,a.file=s.origin;var u=Math.max(0,s.node.start-50);a.contextOffset=s.node.start-u,a.context=c.text.slice(u,u+50)}else s&&(a.file=s.origin,tt(e,t,s,a));return x(a)}function q(e,r,n,o,s){function a(e){return function(t,n){if(s)for(var o=n;o!=l;o=o.prev){var a=o.hasProp(s);if(a)throw m("Renaming `"+i+"` to `"+s+"` would make a variable at line "+(E(e,t.start).line+1)+" point to the definition at line "+(E(e,a.name.start).line+1))}p.push({file:e.name,start:K(r,e,t.start),end:K(r,e,t.end)})}}for(var i=o.node.name,l=o.state;l&&!(i in l.props);l=l.prev);if(!l)throw m("Could not find a definition for "+i+" "+!!e.cx.topScope.props.x);var c,p=[];if(l.originNode){if(c="local",s){for(var d=l.prev;d&&!(s in d.props);d=d.prev);d&&t.findRefs(l.originNode,l,s,d,function(e){throw m("Renaming `"+i+"` to `"+s+"` would shadow the definition used at line "+(E(n,e.start).line+1))})}t.findRefs(l.originNode,l,i,l,a(n))}else{c="global";for(var u=0;u<e.files.length;++u){var h=e.files[u];t.findRefs(h.ast,h.scope,i,l,a(h))}}return{refs:p,type:c,name:i}}function F(e,r,n,o){function s(e){return function(t){i.push({file:e.name,start:K(r,e,t.start),end:K(r,e,t.end)})}}var a=t.expressionType(n).getObjType();if(!a)throw m("Couldn't determine type of base object.");for(var i=[],l=0;l<e.files.length;++l){var c=e.files[l];t.findPropRefs(c.ast,c.scope,a,o.name,s(c))}return{refs:i,name:o.name}}function G(e,t,r){var n=A(r,t,!0);if(n&&"Identifier"==n.node.type)return q(e,t,r,n);if(n&&"MemberExpression"==n.node.type&&!n.node.computed){var o=n.node.property;return n.node=n.node.object,F(e,t,n,o)}if(n&&"ObjectExpression"==n.node.type)for(var s=Y(r,t.end),a=0;a<n.node.properties.length;++a){var i=n.node.properties[a].key;if(i.start<=s&&i.end>=s)return F(e,t,n,i)}throw m("Not at a variable or property name.")}function W(e,t,r){if("string"!=typeof t.newName)throw m(".query.newName should be a string");var n=A(r,t);if(!n)throw m("Could not find an expression to rename.");if("Identifier"!=n.node.type)switch(n.node.type){case"MemberExpression":throw m("Rename is not supported on member expressions.");case"ThisExpression":throw m("Rename is not supported on this expressions.");case"ObjectExpression":throw m("Rename is not supported on object properties.");default:throw m("Rename is only supported on variables.")}var o=q(e,t,r,n,t.newName),s=o.refs;delete o.refs,o.files=e.files.map(function(e){return e.name});for(var a=o.changes=[],i=0;i<s.length;++i){var l=s[i];l.text=t.newName,a.push(l)}return o}function H(e){return{files:e.files.map(function(e){return e.name})}}var B=Object.create(null);e.registerPlugin=function(e,t){B[e]=t};var J=e.defaultOptions={debug:!1,async:!1,getFile:function(e,t){this.async&&t(null,null)},defs:[],plugins:{},fetchTimeout:1e3,dependencyBudget:2e4,reuseInstances:!0,stripCRs:!1},V={completions:{takesFile:!0,run:M},properties:{run:D},type:{takesFile:!0,run:P},documentation:{takesFile:!0,run:N},definition:{takesFile:!0,run:L},refs:{takesFile:!0,fullFile:!0,run:G},rename:{takesFile:!0,fullFile:!0,run:W},files:{run:H}};e.defineQueryType=function(e,t){V[e]=t},s.prototype.asLineChar=function(e){return E(this,e)};var $=e.Server=function(e){this.cx=null,this.options=e||{};for(var t in J)e.hasOwnProperty(t)||(e[t]=J[t]);this.handlers=Object.create(null),this.files=[],this.fileMap=Object.create(null),this.needsPurge=[],this.budgets=Object.create(null),this.uses=0,this.pending=0,this.asyncError=null,this.passes=Object.create(null),this.defs=e.defs.slice(0);for(var r in e.plugins)if(e.plugins.hasOwnProperty(r)&&r in B){var n=B[r](this,e.plugins[r]);if(n&&n.defs&&(n.loadFirst?this.defs.unshift(n.defs):this.defs.push(n.defs)),n&&n.passes)for(var o in n.passes)n.passes.hasOwnProperty(o)&&(this.passes[o]||(this.passes[o]=[])).push(n.passes[o])}this.reset()};$.prototype=r.mixin({addFile:function(e,t,r){!r||r in this.fileMap||(r=null),c(this,e,r,t)},delFile:function(e){var t=this.findFile(e);t&&(this.needsPurge.push(t.name),this.files.splice(this.files.indexOf(t),1),delete this.fileMap[e])},reset:function(){this.signal("reset"),this.cx=new t.Context(this.defs,this),this.uses=0,this.budgets=Object.create(null);for(var e=0;e<this.files.length;++e){var r=this.files[e];r.scope=null}},request:function(e,t){var r=S(e);if(r)return t(r);var n=this;i(this,e,function(e,r){t(e,r),n.uses>4e4&&(n.reset(),d(n,null,function(){}))})},findFile:function(e){return this.fileMap[e]},flush:function(e){var r=this.cx;d(this,null,function(n){return n?e(n):void t.withContext(r,e)})},startAsyncAction:function(){++this.pending},finishAsyncAction:function(e){e&&(this.asyncError=e),0===--this.pending&&this.signal("everythingFetched")}});var X=25,Y=e.resolvePos=function(e,t,r){if("number"!=typeof t){var n=T(e,t.line);if(null==n){if(!r)throw m("File doesn't contain a line "+t.line);t=e.text.length}else t=n+t.ch}if(t>e.text.length){if(!r)throw m("Position "+t+" is outside of file.");t=e.text.length}return t},K=e.outputPos=function(e,t,r){if(e.lineCharPositions){var n=E(t,r);return"part"==t.type&&(n.line+=null!=t.offsetLines?t.offsetLines:E(t.backing,t.offset).line),n}return r+("part"==t.type?t.offset:0)},Q="break do instanceof typeof case else new var catch finally return void continue for switch while debugger function this with default if throw delete in try".split(" "),Z=e.findQueryExpr=function(e,r,n){if(null==r.end)throw m("missing .query.end field");if(r.variable){var o=t.scopeAt(e.ast,Y(e,r.end),e.scope);return{node:{type:"Identifier",name:r.variable,start:r.end,end:r.end+1},state:o}}var s=r.start&&Y(e,r.start),a=Y(e,r.end),i=t.findExpressionAt(e.ast,s,a,e.scope);return i?i:(i=t.findExpressionAround(e.ast,s,a,e.scope),i&&("ObjectExpression"==i.node.type||n||(null==s?a:s)-i.node.start<20||i.node.end-a<20)?i:null)},et=e.getSpan=function(e){if(e.origin){if(e.originNode){var t=e.originNode;return/^Function/.test(t.type)&&t.id&&(t=t.id),{origin:e.origin,node:t}}return e.span?{origin:e.origin,span:e.span}:void 0}},tt=e.storeSpan=function(e,t,r,n){if(n.origin=r.origin,r.span){var o=/^(\d+)\[(\d+):(\d+)\]-(\d+)\[(\d+):(\d+)\]$/.exec(r.span);n.start=t.lineCharPositions?{line:Number(o[2]),ch:Number(o[3])}:Number(o[1]),n.end=t.lineCharPositions?{line:Number(o[5]),ch:Number(o[6])}:Number(o[4])}else{var s=e.findFile(r.origin);n.start=K(t,s,r.node.start),n.end=K(t,s,r.node.end)}};e.version="0.12.0",e.findDef=L,e.findExpr=Z,e.findExprType=C,e.resolveFile=g,e.storeTypeDocs=U,e.parseDoc=I,e.resolvePos=Y}),function(e){return"object"==typeof exports&&"object"==typeof module?e(exports):"function"==typeof define&&define.amd?define("tern/lib/comment",["exports"],e):void e(tern.comment||(tern.comment={}))}(function(e){function t(e){return 14>e&&e>8||32===e||160===e}function r(e,r){for(;r>0;--r){var n=e.charCodeAt(r-1);if(10==n)break;if(!t(n))return!1}return!0}e.commentsBefore=function(e,n){var o,s=null,a=0;e:for(;n>0;){var i=e.charCodeAt(n-1);if(10==i)for(var l=--n,c=!1;l>0;--l){if(i=e.charCodeAt(l-1),47==i&&47==e.charCodeAt(l-2)){if(!r(e,l-2))break e;var p=e.slice(l,n);!a&&o?s[0]=p+"\n"+s[0]:(s||(s=[])).unshift(p),o=!0,a=0,n=l-2;break}if(10==i){if(!c&&++a>1)break e;break}c||t(i)||(c=!0)}else if(47==i&&42==e.charCodeAt(n-2)){for(var l=n-2;l>1;--l)if(42==e.charCodeAt(l-1)&&47==e.charCodeAt(l-2)){if(!r(e,l-2))break e;(s||(s=[])).unshift(e.slice(l,n-2)),o=!1,a=0;break}n=l-2}else{if(!t(i))break;--n}}return s},e.commentAfter=function(e,r){for(;r<e.length;){var n=e.charCodeAt(r);if(47==n){var o,s=e.charCodeAt(r+1);if(47==s)o=e.indexOf("\n",r+2);else{if(42!=s)return;o=e.indexOf("*/",r+2)}return e.slice(r+2,0>o?e.length:o)}t(n)&&++r}},e.ensureCommentsBefore=function(t,r){return r.hasOwnProperty("commentsBefore")?r.commentsBefore:r.commentsBefore=e.commentsBefore(t,r.start)}}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require("../lib/comment"),require("acorn"),require("acorn/dist/walk")):"function"==typeof define&&define.amd?define("tern/plugin/doc_comment",["../lib/infer","../lib/tern","../lib/comment","esprima/esprima","acorn/dist/walk"],e):void e(tern,tern,tern.comment,acorn,acorn.walk)}(function(e,t,r,n,o){"use strict";function s(e,t){function n(e){r.ensureCommentsBefore(t,e)}o.simple(e,{VariableDeclaration:n,FunctionDeclaration:n,AssignmentExpression:function(e){"="==e.operator&&n(e)},ObjectExpression:function(e){for(var t=0;t<e.properties.length;++t)n(e.properties[t])},CallExpression:function(e){a(e)&&n(e)}})}function a(e){return"MemberExpression"==e.callee.type&&"Object"==e.callee.object.name&&"defineProperty"==e.callee.property.name&&e.arguments.length>=3&&"string"==typeof e.arguments[1].value}function i(t,r){v(t.sourceFile.text,r),o.simple(t,{VariableDeclaration:function(e,t){e.commentsBefore&&p(e,e.commentsBefore,t,t.getProp(e.declarations[0].id.name))},FunctionDeclaration:function(e,t){e.commentsBefore&&p(e,e.commentsBefore,t,t.getProp(e.id.name),e.body.scope.fnType)},AssignmentExpression:function(t,r){t.commentsBefore&&p(t,t.commentsBefore,r,e.expressionType({node:t.left,state:r}))},ObjectExpression:function(e,t){for(var r=0;r<e.properties.length;++r){var n=e.properties[r];n.commentsBefore&&p(n,n.commentsBefore,t,e.objType.getProp(n.key.name))}},CallExpression:function(t,r){if(t.commentsBefore&&a(t)){var n=e.expressionType({node:t.arguments[0],state:r}).getObjType();if(n&&n instanceof e.Obj){var o=n.props[t.arguments[1].value];o&&p(t,t.commentsBefore,r,o)}}}},e.searchVisitor,r)}function l(t){var r=t["!typedef"],n=e.cx(),o=t["!name"];if(r)for(var s in r)n.parent.jsdocTypedefs[s]=g(e.def.parse(r[s],o,s),s)}function c(e){for(var t,r=1;r<e.length;r++){var n=e[r],o=n.match(/^[\s\*]*/)[0];if(o!=n)if(null==t)t=o;else{for(var s=0;s<t.length&&t.charCodeAt(s)==o.charCodeAt(s);)++s;s<t.length&&(t=t.slice(0,s))}}for(e=e.map(function(e,r){if(e=e.replace(/\s+$/,""),0==r&&null!=t)for(var n=0;n<t.length;n++){var o=e.indexOf(t.slice(n));if(0==o)return e.slice(t.length-n)}return null==t||0==r?e.replace(/^[\s\*]*/,""):e.length<t.length?"":e.slice(t.length)});e.length&&!e[e.length-1];)e.pop();for(;e.length&&!e[0];)e.shift();return e}function p(t,r,n,o,s){y(t,n,o,r);var a=e.cx();!s&&o instanceof e.AVal&&o.types.length&&(s=o.types[o.types.length-1],s instanceof e.Obj&&s.origin==a.curOrigin&&!s.doc||(s=null));for(var i=r.length-1;i>=0;i--){var l=c(r[i].split(/\r\n?|\n/)).join("\n");if(l){o instanceof e.AVal&&(o.doc=l),s&&(s.doc=l);break}}}function d(e,t){for(;/\s/.test(e.charAt(t));)++t;return t}function u(e){if(!n.isIdentifierStart(e.charCodeAt(0)))return!1;for(var t=1;t<e.length;t++)if(!n.isIdentifierChar(e.charCodeAt(t)))return!1;return!0}function h(e,t,r,n){for(var o=[],s=[],a=!1,i=!0;r=d(t,r),!i||t.charAt(r)!=n;i=!1){var l=t.indexOf(":",r);if(0>l)return null;var c=t.slice(r,l);if(!u(c))return null;o.push(c),r=l+1;var p=f(e,t,r);if(!p)return null;r=p.end,a=a||p.madeUp,s.push(p.type),r=d(t,r);var h=t.charAt(r);if(++r,h==n)break;if(","!=h)return null}return{labels:o,types:s,end:r,madeUp:a}}function f(t,r,n){for(var o,s=!1,a=!1;;){var i=m(t,r,n);if(!i)return null;if(a=a||i.madeUp,s?i.type.propagate(s):o=i.type,n=d(r,i.end),"|"!=r.charAt(n))break;n++,s||(s=new e.AVal,o.propagate(s),o=s)}var l=!1;return"="==r.charAt(n)&&(++n,l=!0),{type:o,end:n,isOptional:l,madeUp:a}}function m(t,r,o){o=d(r,o);var s,a=!1;if(r.indexOf("function(",o)==o){var i=h(t,r,o+9,")"),l=e.ANull;if(!i)return null;if(o=d(r,i.end),":"==r.charAt(o)){++o;var c=f(t,r,o+1);if(!c)return null;o=c.end,l=c.type,a=c.madeUp}s=new e.Fn(null,e.ANull,i.types,i.labels,l)}else if("["==r.charAt(o)){var p=f(t,r,o+1);if(!p)return null;if(o=d(r,p.end),a=p.madeUp,"]"!=r.charAt(o))return null;++o,s=new e.Arr(p.type)}else if("{"==r.charAt(o)){var u=h(t,r,o+1,"}");if(!u)return null;s=new e.Obj(!0);for(var m=0;m<u.types.length;++m){var b=s.defProp(u.labels[m]);b.initializer=!0,u.types[m].propagate(b)}o=u.end,a=u.madeUp}else if("("==r.charAt(o)){var p=f(t,r,o+1);if(!p)return null;if(o=d(r,p.end),")"!=r.charAt(o))return null;++o,s=p.type}else{var y=o;if(!n.isIdentifierStart(r.charCodeAt(o)))return null;for(;n.isIdentifierChar(r.charCodeAt(o));)++o;if(y==o)return null;var v=r.slice(y,o);if(/^(number|integer)$/i.test(v))s=e.cx().num;else if(/^bool(ean)?$/i.test(v))s=e.cx().bool;else if(/^string$/i.test(v))s=e.cx().str;else if(/^(null|undefined)$/i.test(v))s=e.ANull;else if(/^array$/i.test(v)){var p=null;if("."==r.charAt(o)&&"<"==r.charAt(o+1)){var w=f(t,r,o+2);if(!w)return null;if(o=d(r,w.end),a=w.madeUp,">"!=r.charAt(o++))return null;p=w.type}s=new e.Arr(p)}else if(/^object$/i.test(v)){if(s=new e.Obj(!0),"."==r.charAt(o)&&"<"==r.charAt(o+1)){var _=f(t,r,o+2);if(!_)return null;if(o=d(r,_.end),a=a||_.madeUp,","!=r.charAt(o++))return null;var S=f(t,r,o);if(!S)return null;if(o=d(r,S.end),a=_.madeUp||S.madeUp,">"!=r.charAt(o++))return null;S.type.propagate(s.defProp("<i>"))}}else{for(;46==r.charCodeAt(o)||n.isIdentifierChar(r.charCodeAt(o));)++o;var T,E=r.slice(y,o),x=e.cx(),j=x.parent&&x.parent.jsdocTypedefs;j&&E in j?s=j[E]:(T=e.def.parsePath(E,t).getObjType())?s=g(T,E):(x.jsdocPlaceholders||(x.jsdocPlaceholders=Object.create(null)),s=E in x.jsdocPlaceholders?x.jsdocPlaceholders[E]:x.jsdocPlaceholders[E]=new e.Obj(null,E),a=!0)}}return{type:s,end:o,madeUp:a}}function g(t,r){if(t instanceof e.Fn&&/^[A-Z]/.test(r)){var n=t.getProp("prototype").getObjType();if(n instanceof e.Obj)return e.getInstance(n)}return t}function b(e,t,r){if(r=d(t,r||0),"{"!=t.charAt(r))return null;var n=f(e,t,r+1);if(!n)return null;var o=d(t,n.end);return"}"!=t.charAt(o)?null:(n.end=o+1,n)}function y(e,t,r,n){for(var o,s,a,i,l,c,p=n.length-1;p>=0;p--)for(var d,u=n[p],h=/(?:\n|$|\*)\s*@(type|param|arg(?:ument)?|returns?|this)\s+(.*)/g;d=h.exec(u);)if("this"==d[1]&&(c=f(t,d[2],0)))l=c,i=!0;else if(c=b(t,d[2]))switch(i=!0,d[1]){case"returns":case"return":a=c;break;case"type":o=c;break;case"param":case"arg":case"argument":var m=d[2].slice(c.end).match(/^\s*(\[?)\s*([^\]\s=]+)\s*(?:=[^\]]+\s*)?(\]?).*/);if(!m)continue;var g=m[2]+(c.isOptional||"["===m[1]&&"]"===m[3]?"?":"");(s||(s=Object.create(null)))[g]=c}i&&_(o,l,s,a,e,r)}function v(t,r){for(var n,o=e.cx(),s=/\s@typedef\s+(.*)/g;n=s.exec(t);){var a=b(r,n[1]),i=a&&n[1].slice(a.end).match(/^\s*(\S+)/);i&&(o.parent.jsdocTypedefs[i[1]]=a.type)}}function w(t,r){var n=e.cx().parent._docComment.weight;t.type.propagate(r,n||(t.madeUp?S:void 0))}function _(t,r,n,o,s,a){var i;if("VariableDeclaration"==s.type){var l=s.declarations[0];l.init&&"FunctionExpression"==l.init.type&&(i=l.init.body.scope.fnType)}else"FunctionDeclaration"==s.type?i=s.body.scope.fnType:"AssignmentExpression"==s.type?"FunctionExpression"==s.right.type&&(i=s.right.body.scope.fnType):"CallExpression"==s.type||"FunctionExpression"==s.value.type&&(i=s.value.body.scope.fnType);if(i&&(n||o||r)){if(n)for(var c=0;c<i.argNames.length;++c){var p=i.argNames[c],d=n[p];!d&&(d=n[p+"?"])&&(i.argNames[c]+="?"),d&&w(d,i.args[c])}o&&(i.retval==e.ANull&&(i.retval=new e.AVal),w(o,i.retval)),r&&w(r,i.self)}else t&&w(t,a)}var S=1,T=101;t.registerPlugin("doc_comment",function(e,t){return e.jsdocTypedefs=Object.create(null),e.on("reset",function(){e.jsdocTypedefs=Object.create(null)}),e._docComment={weight:t&&t.strong?T:void 0,fullDocs:t&&t.fullDocs},{passes:{postParse:s,postInfer:i,postLoadDef:l}}})}),define("orion/editor/templates",[],function(){function e(e,t){return t.substring(e.length)}function t(e,t,r,n){this.prefix=e,this.description=t,this.template=r,this.name=n,this._parse()}function r(e,t){this._keywords=e||[],this._templates=[],this.addTemplates(t||[])}var n="${tab}",o="${delimiter}",s="${cursor}";return t.prototype={getProposal:function(e,t,r){var a,i=t-e.length,l={},c=void 0!==r.delimiter?r.delimiter:"\n";r.indentation&&(c+=r.indentation);for(var p=void 0!==r.tab?r.tab:"	",d=0,u=this.variables,h=this.segments,f=[],m=0;m<h.length;m++){var g=h[m],b=u[g];if(void 0!==b)switch(g){case n:g=p;break;case o:g=c;break;case s:g="",a=d;break;default:var y=l[g];y||(y=l[g]={data:b.data,positions:[]}),g=b.substitution,y.data&&y.data.values&&(g=y.data.values[0]),y.positions.push({offset:i+d,length:g.length})}f.push(g),d+=g.length}var v=[];for(var w in l)l.hasOwnProperty(w)&&v.push(l[w]);return f=f.join(""),void 0===a&&(a=f.length),{proposal:f,name:this.name,description:this.description,groups:v,escapePosition:i+a,style:"noemphasis"}},match:function(e){return 0===this.prefix.indexOf(e)},_parse:function(){var e,t=this.template,r=[],s={},a=0;t=t.replace(/\n/g,o),t=t.replace(/\t/g,n),t.replace(/\$\{((?:[^\\}]+|\\.))*\}/g,function(n,o,i){var l=n.substring(2,n.length-1),c=n,p=l,d=null,u=p.indexOf(":");-1!==u&&(p=p.substring(0,u),c="${"+p+"}",d=JSON.parse(l.substring(u+1).replace("\\}","}").trim()));var h=s[c];return h||(h=s[c]={}),h.substitution=p,d&&(h.data=d),e=t.substring(a,i),e&&r.push(e),r.push(c),a=i+n.length,p}),e=t.substring(a,t.length),e&&r.push(e),this.segments=r,this.variables=s}},r.prototype={addTemplates:function(e){for(var r=this.getTemplates(),n=0;n<e.length;n++)r.push(new t(e[n].prefix,e[n].description,e[n].template,e[n].name))},initialize:function(){},computeProposals:function(e,t,r){var n=this.getPrefix(e,t,r),o=[];return this.isValid(n,e,t,r)&&(o=o.concat(this.getTemplateProposals(n,t,r)),o=o.concat(this.getKeywordProposals(n))),o},getKeywords:function(){return this._keywords},getKeywordProposals:function(t){var r=[],n=this.getKeywords();if(n){for(var o=0;o<n.length;o++)0===n[o].indexOf(t)&&r.push({proposal:e(t,n[o]),description:n[o],style:"noemphasis_keyword"});0<r.length&&r.splice(0,0,{proposal:"",description:"Keywords",style:"noemphasis_title_keywords",unselectable:!0})}return r},getPrefix:function(e,t,r){return r.prefix},getTemplates:function(){return this._templates},getTemplateProposals:function(e,t,r){for(var n=[],o=this.getTemplates(),s=0;s<o.length;s++){var a=o[s];if(a.match(e)){var i=a.getProposal(e,t,r);this.removePrefix(e,i),n.push(i)}}return 0<n.length&&(n.sort(function(e,t){return e.name<t.name?-1:e.name>t.name?1:0}),n.splice(0,0,{proposal:"",description:"Templates",style:"noemphasis_title",unselectable:!0})),n},removePrefix:function(t,r){var n=r.overwrite=r.proposal.substring(0,t.length)!==t;n||(r.proposal=e(t,r.proposal))},isValid:function(){return!0}},{Template:t,TemplateContentAssist:r}}),define("tern/plugin/resolver",["orion/editor/templates"],function(e){function t(e,t){for(var n=Object.keys(d),o=0;o<n.length;o++){var s=n[o],a=d[s];a&&(a.pending||a.file)||r(e,s,t)}}function r(e,t,r){d[t].pending||(e.startAsyncAction(),d[t].pending=!0,e.options.getFile({logical:t,file:r},function(r,n){d[t].file=n.file,d[t].contents=n.contents,d[t].logical=n.logical,d[t].err=r,delete d[t].pending,e.finishAsyncAction(r)}))}function n(e){var t=function(){clearTimeout(r),o(e)},r=setTimeout(t,e.options.fetchTimeout)}function o(e){if(e.pending)return n(e);for(var t=!0,r=Object.keys(d),o=0;o<r.length;o++)if(!d[r[o]]){t=!1;break}return t?void 0:n(e)}function s(e,r,n){if(Array.isArray(r.dependencies)&&r.dependencies.length>0){for(var o=0;o<r.dependencies.length;o++){var s=a(r.dependencies[o]);if(s){if("object"==typeof d[s])continue;if("object"==typeof n){if(n[s])continue;if("object"==typeof n.node&&n.node[s])continue;if("object"==typeof n.requirejs&&n.requirejs[s])continue}d[s]=Object.create(null)}}t(e,r.sourceFile?r.sourceFile.name:null)}}function a(e){return"string"==typeof e?e:null!=e&&"object"==typeof e?e.value:null
}function i(e){return d[e]}function l(t){if(t.t)return t.t;var r=new e.Template(t.prefix,t.description,t.template,t.name);return t.t=r,r}function c(e){if(e&&e.parents&&e.parents.length>0){var t=e.parents.pop();switch(t.type){case"MemberExpression":return{kind:"member"};case"VariableDeclarator":return null;case"FunctionDelcaration":case"FunctionExpression":if(offset<t.body.range[0])return null;break;case"Property":return offset-1>=t.value.range[0]&&offset-1<=t.value.range[1]?{kind:"prop"}:null;case"SwitchStatement":return{kind:"swtch"}}}return{kind:"top"}}function p(e,t){var r=c(t);if(r&&r.kind){for(var n=[],o=e.length,s=0;o>s;s++){var a=e[s];a.nodes&&a.nodes[r.kind]&&n.push(a)}return n.map(l,this)}}var d=Object.create(null);return{doPostParse:s,doPreInfer:o,getResolved:i,getTemplatesForNode:p}}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require):"function"==typeof define&&define.amd?define("tern/plugin/orionAmqp",["../lib/infer","../lib/tern","./resolver"],e):void e(infer,tern,resolver)}(function(e,t,r){function n(n,s,a,i){var l=t.resolvePos(n,a),c=e.findExpressionAround(n.ast,null,l,n.scope),p=r.getTemplatesForNode(o,c);if(p&&p.length>0)for(var d=0;d<p.length;d++){var u=p[d];u.origin="amqp",u.type="template",i.push(u)}}var o=[{prefix:"amqp",name:"amqp",nodes:{top:!0,member:!1,prop:!1},description:" - Node.js require statement for AMQP framework",template:"var amqp = require('amqp');\n"},{prefix:"amqp",name:"amqp connection",nodes:{top:!0,member:!1,prop:!1},description:" - create a new AMQP connection ",template:"var amqp = require('amqp');\nvar ${connection} = amqp.createConnection({\n	host: ${host},\n	port: ${port},\n	login: ${login},\n	password: ${password}\n});\n"},{prefix:"amqp",name:"amqp on",nodes:{top:!0,member:!1,prop:!1},description:" - create a new AMQP connection on statement",template:"${connection}.on(${event}, function() {\n	${cursor}\n});\n"},{prefix:"amqp",name:"amqp queue",nodes:{top:!0,member:!1,prop:!1},description:" - create a new AMQP connection queue statement",template:"${connection}.queue(${id}, function(queue) {\n	queue.bind('#'); //catch all messages\n	queue.subscribe(function (message, headers, deliveryInfo) {\n		// Receive messages\n	});\n	${cursor}\n});\n"},{prefix:"amqp",name:"amqp exchange",nodes:{top:!0,member:!1,prop:!1},description:" - create a new AMQP connection exchange",template:"var exchange = ${connection}.exchange(${id}, {type: 'topic'}, function(exchange) {\n	${cursor}\n});\n"}];t.registerPlugin("orionAmqp",function(){return{defs:s,passes:{variableCompletion:n}}});var s={"!name":"amqp","!define":{"!node":{amqp:{Connection:"Connection",createConnection:"fn(options: Object, implOptions: Object, readyCallback: fn()) -> +Connection"}},"Exchange.!3":{type:"string"},"createExchangeErrorHandlerFor.!ret":"fn(err: ?)","Connection.prototype._bodyToBuffer.!ret":"[Connection.prototype._bodyToBuffer.!ret.<i>]","Connection.prototype._bodyToBuffer.!ret.<i>":{contentType:"string"},"Connection.prototype._parseURLOptions.!ret":{ssl:{enabled:"bool"}},"Connection.prototype._sendHeader.!2":{reserved1:"number",routingKey:"string",noWait:"bool"},"serializer.serializeFields.!2":{reserved1:"number",routingKey:"string",noWait:"bool"},"Queue.prototype.subscribeRaw.!0":{state:"string"},"Message.!1":{parseError:"+Error",rawData:"string"},"parseTable.!ret":{"!doc":"XXX check if bitIndex greater than 7?"},"parseFields.!1":"[?]","parseFields.!ret":{}},methods:{"<i>":{"!doc":"debug(name);"},"!doc":"methods keyed on their name"},Channel:{prototype:{closeOK:"fn()",reconnect:"fn()",_taskPush:"fn(reply: ?, cb: ?)",_tasksFlush:"fn()",_handleTaskReply:"fn(channel: ?, method: ?, args: ?) -> bool",_onChannelMethod:"fn(channel: ?, method: ?, args: ?)",close:"fn(reason: ?)"},"!type":"fn(connection: +Connection, channel: number)","!doc":"This class is not exposed to the user."},Exchange:{prototype:{_onMethod:"fn(channel: ?, method: ?, args: ?) -> bool",publish:{"!type":"fn(routingKey: ?, data: ?, options: ?, callback: ?)","!doc":"exchange.publish('routing.key', 'body'); the third argument can specify additional options - mandatory (boolean, default false) - immediate (boolean, default false) - contentType (default 'application/octet-stream') - contentEncoding - headers - deliveryMode - priority (0-9) - correlationId - replyTo - expiration - messageId - timestamp - userId - appId - clusterId the callback is optional and is only used when confirm is turned on for the exchange"},_awaitConfirm:{"!type":"fn(task: ?, callback: ?)","!doc":"registers tasks for confirms"},cleanup:{"!type":"fn()","!doc":"do any necessary cleanups eg."},destroy:"fn(ifUnused: ?)",unbind:"fn()",bind:"fn()",bind_headers:"fn()"},"!type":"fn(connection: +Connection, channel: number, name: ?, options: Exchange.!3, openCallback: ?)",binds:"number",exchangeBinds:"number",sourceExchanges:{"<i>":"+Exchange"},_sequence:"number",_unAcked:{},_addedExchangeErrorHandler:"bool",state:"string",channel:"number",connection:"+Connection",_tasks:"[?]"},createExchangeErrorHandlerFor:{"!type":"fn(exchange: +Exchange) -> fn(err: ?)","!doc":"creates an error handler scoped to the given `exchange`"},Connection:{prototype:{setOptions:"fn(options: ?)",setImplOptions:"fn(options: ?)",connect:"fn()",reconnect:"fn()",disconnect:"fn()",addAllListeners:"fn()",heartbeat:"fn()",exchange:{"!type":"fn(name: ?, options: Exchange.!3, openCallback: ?) -> +Exchange","!doc":"connection.exchange('my-exchange', { type: 'topic' }); Options - type 'fanout', 'direct', or 'topic' (default) - passive (boolean) - durable (boolean) - autoDelete (boolean, default true)"},exchangeClosed:{"!type":"fn(name: ?)","!doc":"remove an exchange when it's closed (called from Exchange)"},queue:{"!type":"fn(name: ?) -> +Queue","!doc":"Options - passive (boolean) - durable (boolean) - exclusive (boolean) - autoDelete (boolean, default true)"},queueClosed:{"!type":"fn(name: ?)","!doc":"remove a queue when it's closed (called from Queue)"},publish:{"!type":"fn(routingKey: ?, body: ?, options: ?, callback: ?)","!doc":"Publishes a message to the default exchange."},_bodyToBuffer:"fn(body: ?) -> [?]",_inboundHeartbeatTimerReset:"fn()",_outboundHeartbeatTimerReset:"fn()",_saslResponse:"fn() -> ?|string",_onMethod:"fn(channel: number, method: methods.<i>, args: parseFields.!ret)",_parseURLOptions:{"!type":"fn(connectionString: ?) -> Connection.prototype._parseURLOptions.!ret","!doc":"Generate connection options from URI string formatted with amqp scheme."},_chooseHost:{"!type":"fn() -> !this.options.host","!doc":"If you pass a array of hosts, lets choose a random host or the preferred host number, or then next one."},_createSocket:"fn()",end:"fn()",_getSSLOptions:"fn() -> !this.sslConnectionOptions",_startHandshake:{"!type":"fn()","!doc":"Time to start the AMQP 7-way connection initialization handshake! 1."},_sendBody:{"!type":"fn(channel: number, body: ?, properties: ?)","!doc":"Parse helpers "},_sendHeader:{"!type":"fn(channel: number, size: ?, properties: ?)","!doc":"connection: the connection channel: the channel to send this on size: size in bytes of the following message properties: an object containing any of the following: - contentType (default 'application/octet-stream') - contentEncoding - headers - deliveryMode - priority (0-9) - correlationId - replyTo - expiration - messageId - timestamp - userId - appId - clusterId"},_sendMethod:"fn(channel: number, method: ?, args: ?)",generateChannelId:{"!type":"fn() -> !this.channelCounter","!doc":"tries to find the next available id slot for a channel"}},"!type":"fn(connectionArgs: ?, options: ?, readyCallback: ?)",connectionAttemptScheduled:{"!type":"bool","!doc":"Set to false, so that if we fail in the reconnect attempt, we can schedule another one."},_defaultExchange:"+Exchange",channelCounter:"number",_blocked:"bool",channels:{"!doc":"In the case where this is a reconnection, do not trample on the existing channels.","<i>":"+Queue"},exchanges:{"<i>":"+Exchange"},parser:{"!type":"+AMQPParser","!doc":"Reset parser state"},readyEmitted:{"!type":"bool","!doc":"Set 'ready' flag for auth failure detection."},hosti:{"!type":"number","!doc":"If this is already set, it looks like we want to choose another one."},"<i>":"fn()",sslConnectionOptions:{}},serializer:{serializeFloat:"fn(b: ?, size: number, value: ?, bigEndian: ?)",serializeInt:"fn(b: ?, size: number, int: number)",serializeShortString:"fn(b: ?, string: ?)",serializeLongString:"fn(b: ?, string: ?)",serializeDate:"fn(b: ?, date: ?)",serializeBuffer:"fn(b: ?, buffer: ?)",serializeBase64:"fn(b: ?, buffer: ?)",isBigInt:"fn(value: ?) -> bool",getCode:"fn(dec: ?) -> string",isFloat:"fn(value: ?) -> bool",serializeValue:"fn(b: ?, value: ?)",serializeTable:"fn(b: ?, object: ?)",serializeArray:"fn(b: ?, arr: ?)",serializeFields:"fn(buffer: ?, fields: ?, args: ?, strict: bool)"},methodTable:{"<i>":{"<i>":"methods.<i>"},"!doc":"a look up table for methods recieved indexed on class id, method id"},classes:{"!doc":"classes keyed on their index"},Queue:{prototype:{subscribeRaw:"fn(options: Queue.consumerTagListeners.<i>, messageListener: Queue.consumerTagListeners.<i>)",unsubscribe:"fn(consumerTag: ?)",subscribe:"fn(options: ?, messageListener: ?)",shift:{"!type":"fn(reject: ?, requeue: ?)","!doc":"Acknowledges the last message"},bind:"fn(exchange: string, routingKey: string, callback: string)",unbind:"fn(exchange: string, routingKey: string)",bind_headers:"fn()",unbind_headers:"fn()",destroy:"fn(options: ?)",purge:"fn()",_onMethod:"fn(channel: ?, method: ?, args: ?)",_onContentHeader:"fn(channel: number, classInfo: ?, weight: number, properties: parseFields.!ret, size: number)",_onContent:"fn(channel: number, data: ?)",flow:"fn(active: ?)",subscribeJSON:"Queue.prototype.subscribe"},"!type":"fn(connection: +Connection, channel: number, name: ?, options: ?, callback: ?)",name:"string",_bindings:{"<i>":{"<i>":"number"}},consumerTagListeners:{"<i>":{state:"string"}},consumerTagOptions:{"<i>":"Queue.consumerTagListeners.<i>"},options:{autoDelete:"bool",closeChannelOnUnsubscribe:"bool"},state:"string",_bindCallback:"string",_sequence:"number",confirm:"bool",currentMessage:"+Message"},AMQPParser:{prototype:{throwError:{"!type":"fn(error: string)","!doc":"If there's an error in the parser, call the onError handler or throw"},execute:{"!type":"fn(data: ?)","!doc":"Everytime data is recieved on the socket, pass it to this function for parsing."},_parseMethodFrame:"fn(channel: number, buffer: ?)",_parseHeaderFrame:"fn(channel: number, buffer: ?)"},"!type":"fn(version: string, type: string)","!doc":"An interruptible AMQP parser.",isClient:"bool",state:"string",parse:"fn(data: ?) -> AMQPParser.parse",onMethod:"fn(channel: number, method: methods.<i>, args: parseFields.!ret)",onContent:"fn(channel: number, data: ?)",onContentHeader:"fn(channel: number, classInfo: ?, weight: number, properties: parseFields.!ret, size: number)",onHeartBeat:"fn()",onError:"fn(e: string)"},maxFrameBuffer:{"!type":"number","!doc":"parser"},channelMax:{"!type":"number","!doc":"copying qpid)"},defaultPorts:{amqp:"number",amqps:"number"},defaultOptions:{host:"string",port:"number",login:"string",password:"string",authMechanism:"string",vhost:"string",connectionTimeout:"number",ssl:{enabled:"bool"}},defaultSslOptions:{port:"number",ssl:{rejectUnauthorized:"bool"}},defaultImplOptions:{defaultExchangeName:"string",reconnect:"bool",reconnectBackoffStrategy:"string",reconnectExponentialLimit:"number",reconnectBackoffTime:"number"},defaultClientProperties:{platform:"string",product:"string"},Message:{prototype:{acknowledge:{"!type":"fn(all: ?)","!doc":"Acknowledge receipt of message."},reject:{"!type":"fn(requeue: ?)","!doc":"Reject an incoming message."}},"!type":"fn(queue: +Queue, args: ?)","!doc":"Properties: - routingKey - size - deliveryTag - contentType (default 'application/octet-stream') - contentEncoding - headers - deliveryMode - priority (0-9) - correlationId - replyTo - experation - messageId - timestamp - userId - appId - clusterId",queue:"+Queue",read:"number",size:"number"},parseShortString:"fn(buffer: ?)",parseLongString:"fn(buffer: ?)",parseSignedInteger:"fn(buffer: ?) -> !0.<i>",parseValue:"fn(buffer: ?) -> !0.<i>",parseTable:"fn(buffer: ?) -> parseTable.!ret",parseFields:"fn(buffer: ?, fields: [?]) -> parseFields.!ret",Error:{name:"string"},createConnection:"fn(options: Object, implOptions: Object, readyCallback: fn()) -> +Connection"}}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require("../lib/comment"),require("acorn/dist/walk")):"function"==typeof define&&define.amd?define("tern/plugin/angular",["../lib/infer","../lib/tern","../lib/comment","acorn/dist/walk"],e):void e(tern,tern,tern.comment,acorn.walk)}(function(e,t,r,n){"use strict";function o(){this.fields=Object.create(null),this.forward=[]}function s(t){var r=e.cx().definitions.angular.service;return r.hasProp(t)?r.getProp(t):void 0}function a(t,r){var n=s(r);return n?n:t.injector&&t.injector?t.injector.get(r):e.ANull}function i(t,r,n,o){var s=[];if("FunctionExpression"==n.type)for(var i=0;i<n.params.length;++i)s.push(a(t,n.params[i].name));else if("ArrayExpression"==n.type){for(var i=0;i<n.elements.length-1;++i){var l=n.elements[i];s.push("Literal"==l.type&&"string"==typeof l.value?a(t,l.value):e.ANull)}var c=n.elements[n.elements.length-1];c&&"FunctionExpression"==c.type&&(r=c.body.scope.fnType)}var p=new e.AVal;if(o){var d=new e.AVal;r.propagate(new e.IsCtor(d)),d.propagate(p,90),r.propagate(new e.IsCallee(d,s,null,new e.IfObj(p)))}else r.propagate(new e.IsCallee(e.cx().topScope,s,null,p));return p}function l(e){var t=[];if(e&&"ArrayExpression"==e.type)for(var r=0;r<e.elements.length;++r){var n=e.elements[r];"Literal"==n.type&&"string"==typeof n.value&&t.push(n.value)}return t}function c(e){var t=e.definitions.angular;return t&&t.Module.getProp("prototype").getType()}function p(t,r){var n=e.cx(),s=n.parent._angular,a=c(n),i=new e.Obj(a||!0);a||s.nakedModules.push(i),i.origin=n.curOrigin,i.injector=new o,i.metaData={includes:r};for(var l=0;l<r.length;++l){var p=s.modules[r[l]];p?p.injector&&p.injector.forwardTo(i.injector):(s.pendingImports[r[l]]||(s.pendingImports[r[l]]=[])).push(i.injector)}if("string"==typeof t){s.modules[t]=i;var d=s.pendingImports[t];if(d){delete s.pendingImports[t];for(var l=0;l<d.length;++l)i.injector.forwardTo(d[l])}}return i}function d(e,t){n.simple(e,{CallExpression:function(e){if("MemberExpression"==e.callee.type&&!e.callee.computed&&e.arguments.length&&/^(value|constant|controller|factory|provider)$/.test(e.callee.property.name)){var n=r.commentsBefore(t,e.callee.property.start-1);if(n){var o=n[0],s=o.search(/\.\s/);s>5&&(o=o.slice(0,s+1)),o=o.trim().replace(/\s*\n\s*\*\s*|\s{1,}/g," "),e.arguments[0].angularDoc=o}}}})}function u(t){var r=e.cx(),n=t["!name"],o=r.definitions[n];if("angular"!=n){var s=o&&o["!ng"];if(s)for(var a in s.props){var i=s.props[a].getType(),l=p(a.replace(/`/g,"."),i.metaData&&i.metaData.includes||[]);l.origin=n;for(var d in i.props){var u=i.props[d],h=u.getType();h&&(/^_inject_/.test(d)?(h.name||(h.name=d.slice(8)),l.injector.set(d.slice(8),h,u.doc,u.span)):i.props[d].propagate(l.defProp(d)))}}}else{var f=c(r),m=r.parent._angular.nakedModules;if(f)for(var g=0;g<m.length;++g)m[g].proto=f}}function h(t){var r=e.cx().parent._angular.modules,n=new e.Obj(null),o=0;for(var s in r){var a=r[s];if(t.origins.indexOf(a.origin)>-1){var i=s.replace(/\./g,"`");if(n.defProp(i).addType(a),a.condenseForceInclude=!0,++o,a.injector)for(var l in a.injector.fields){var c=a.injector.fields[l];c.local&&(t.roots["!ng."+i+"._inject_"+l]=c)}}}o&&(t.roots["!ng"]=n)}function f(t){var r=e.cx().parent._angular.modules;for(var n in t.types){var o;if(o=n.match(/^!ng\.([^\.]+)\._inject_([^\.]+)^/)){var s=r[o[1].replace(/`/g,".")],a=s.injector.fields[o[2]],i=t.types[n];a.span&&(i.span=a.span),a.doc&&(i.doc=a.doc)}}}function m(e){e._angular={modules:Object.create(null),pendingImports:Object.create(null),nakedModules:[]}}var g=e.constraint({construct:function(e){this.doc=e},addType:function(e){e.doc||(e.doc=this.doc)}});o.prototype.get=function(t){if("$scope"==t)return new e.Obj(s("$rootScope").getType(),"$scope");if(t in this.fields)return this.fields[t];var r=this.fields[t]=new e.AVal;return r},o.prototype.set=function(t,r,n,o,s){if(!("$scope"==t||s&&s>10)){var a=this.fields[t]||(this.fields[t]=new e.AVal);s||(a.local=!0),a.origin||(a.origin=e.cx().curOrigin),"string"!=typeof o||a.span?o&&"object"==typeof o&&!a.originNode&&(a.originNode=o):a.span=o,n&&(a.doc=n,a.propagate(new g(n))),r.propagate(a);for(var i=0;i<this.forward.length;++i)this.forward[i].set(t,r,n,o,(s||0)+1)}},o.prototype.forwardTo=function(e){this.forward.push(e);for(var t in this.fields){var r=this.fields[t];e.set(t,r,r.doc,r.span||r.originNode,1)}},e.registerFunction("angular_callInject",function(e){return function(t,r,n){var o=t.getType();o&&n&&n[e]&&i(o,r[e],n[e])}}),e.registerFunction("angular_regFieldCall",function(e,t,r){var n=e.getType();if(n&&r&&r.length>1){var o=i(n,t[1],r[1]);n.injector&&"Literal"==r[0].type&&n.injector.set(r[0].value,o,r[0].angularDoc,r[0])}}),e.registerFunction("angular_regFieldNew",function(e,t,r){var n=e.getType();if(n&&r&&r.length>1){var o=i(n,t[1],r[1],!0);n.injector&&"Literal"==r[0].type&&n.injector.set(r[0].value,o,r[0].angularDoc,r[0])}}),e.registerFunction("angular_regField",function(e,t,r){var n=e.getType();n&&n.injector&&r&&r[0]&&"Literal"==r[0].type&&t[1]&&n.injector.set(r[0].value,t[1],r[0].angularDoc,r[0])}),e.registerFunction("angular_module",function(t,r,n){var o,s=n&&n[0]&&"Literal"==n[0].type&&n[0].value;return"string"==typeof s&&(o=e.cx().parent._angular.modules[s]),o||(o=p(s,l(n&&n[1]))),o});var b=e.constraint({construct:function(e,t,r){this.self=e,this.args=t,this.target=r},addType:function(t){if(t instanceof e.Fn){this.target.addType(new e.Fn(t.name,t.self,t.args.slice(this.args.length),t.argNames.slice(this.args.length),t.retval)),this.self.propagate(t.self);for(var r=0;r<Math.min(t.args.length,this.args.length);++r)this.args[r].propagate(t.args[r])}}});e.registerFunction("angular_bind",function(t,r){if(r.length<2)return e.ANull;var n=new e.AVal;return r[1].propagate(new b(r[0],r.slice(2),n)),n}),t.registerPlugin("angular",function(e){return m(e),e.on("reset",function(){m(e)}),{defs:y,passes:{postParse:d,postLoadDef:u,preCondenseReach:h,postCondenseReach:f},loadFirst:!0}});var y={"!name":"angular","!define":{cacheObj:{info:"fn() -> ?",put:"fn(key: string, value: ?) -> !1",get:"fn(key: string) -> ?",remove:"fn(key: string)",removeAll:"fn()",destroy:"fn()"},eventObj:{targetScope:"service.$rootScope",currentScope:"service.$rootScope",name:"string",stopPropagation:"fn()",preventDefault:"fn()",defaultPrevented:"bool"},directiveObj:{multiElement:{"!type":"bool","!url":"https://docs.angularjs.org/api/ng/service/$compile#-multielement-","!doc":"When this property is set to true, the HTML compiler will collect DOM nodes between nodes with the attributes directive-name-start and directive-name-end, and group them together as the directive elements. It is recommended that this feature be used on directives which are not strictly behavioural (such as ngClick), and which do not manipulate or replace child nodes (such as ngInclude)."},priority:{"!type":"number","!url":"https://docs.angularjs.org/api/ng/service/$compile#-priority-","!doc":"When there are multiple directives defined on a single DOM element, sometimes it is necessary to specify the order in which the directives are applied. The priority is used to sort the directives before their compile functions get called. Priority is defined as a number. Directives with greater numerical priority are compiled first. Pre-link functions are also run in priority order, but post-link functions are run in reverse order. The order of directives with the same priority is undefined. The default priority is 0."},terminal:{"!type":"bool","!url":"https://docs.angularjs.org/api/ng/service/$compile#-terminal-","!doc":"If set to true then the current priority will be the last set of directives which will execute (any directives at the current priority will still execute as the order of execution on same priority is undefined). Note that expressions and other directives used in the directive's template will also be excluded from execution."},scope:{"!type":"?","!url":"https://docs.angularjs.org/api/ng/service/$compile#-scope-","!doc":"If set to true, then a new scope will be created for this directive. If multiple directives on the same element request a new scope, only one new scope is created. The new scope rule does not apply for the root of the template since the root of the template always gets a new scope. If set to {} (object hash), then a new 'isolate' scope is created. The 'isolate' scope differs from normal scope in that it does not prototypically inherit from the parent scope. This is useful when creating reusable components, which should not accidentally read or modify data in the parent scope."},bindToController:{"!type":"bool","!url":"https://docs.angularjs.org/api/ng/service/$compile#-bindtocontroller-","!doc":"When an isolate scope is used for a component (see above), and controllerAs is used, bindToController: true will allow a component to have its properties bound to the controller, rather than to scope. When the controller is instantiated, the initial values of the isolate scope bindings are already available."},controller:{"!type":"fn()","!url":"https://docs.angularjs.org/api/ng/service/$compile#-require-","!doc":"Controller constructor function. The controller is instantiated before the pre-linking phase and it is shared with other directives (see require attribute). This allows the directives to communicate with each other and augment each other's behavior."},require:{"!type":"string","!url":"https://docs.angularjs.org/api/ng/service/$compile#-controller-","!doc":"Require another directive and inject its controller as the fourth argument to the linking function. The require takes a string name (or array of strings) of the directive(s) to pass in. If an array is used, the injected argument will be an array in corresponding order. If no such directive can be found, or if the directive does not have a controller, then an error is raised."},controllerAs:{"!type":"string","!url":"https://docs.angularjs.org/api/ng/service/$compile#-controlleras-","!doc":"Controller alias at the directive scope. An alias for the controller so it can be referenced at the directive template. The directive needs to define a scope for this configuration to be used. Useful in the case when directive is used as component."},restrict:{"!type":"string","!url":"https://docs.angularjs.org/api/ng/service/$compile#-restrict-","!doc":"String of subset of EACM which restricts the directive to a specific directive declaration style. If omitted, the defaults (elements and attributes) are used. E - Element name (default): <my-directive></my-directive>. A - Attribute (default): <div my-directive='exp'></div>. C - Class: <div class='my-directive: exp;'></div>. M - Comment: <!-- directive: my-directive exp --> "},templateNamespace:{"!type":"string","!url":"https://docs.angularjs.org/api/ng/service/$compile#-templatenamespace-","!doc":"String representing the document type used by the markup in the template. AngularJS needs this information as those elements need to be created and cloned in a special way when they are defined outside their usual containers like <svg> and <math>."},template:{"!type":"string","!url":"https://docs.angularjs.org/api/ng/service/$compile#-template-","!doc":"HTML markup that may: Replace the contents of the directive's element (default). Replace the directive's element itself (if replace is true - DEPRECATED). Wrap the contents of the directive's element (if transclude is true)."},templateUrl:{"!type":"string","!url":"https://docs.angularjs.org/api/ng/service/$compile#-templateurl-","!doc":"This is similar to template but the template is loaded from the specified URL, asynchronously."},transclude:{"!type":"bool","!url":"https://docs.angularjs.org/api/ng/service/$compile#-transclude-","!doc":"Extract the contents of the element where the directive appears and make it available to the directive. The contents are compiled and provided to the directive as a transclusion function."},compile:{"!type":"fn(tElement: +Element, tAttrs: +Attr)","!url":"https://docs.angularjs.org/api/ng/service/$compile#-transclude-","!doc":"The compile function deals with transforming the template DOM. Since most directives do not do template transformation, it is not used often."},link:{"!type":"fn(scope: ?, iElement: +Element, iAttrs: +Attr, controller: ?, transcludeFn: fn())","!url":"https://docs.angularjs.org/api/ng/service/$compile#-link-","!doc":"The link function is responsible for registering DOM listeners as well as updating the DOM. It is executed after the template has been cloned. This is where most of the directive logic will be put."}},Module:{"!url":"http://docs.angularjs.org/api/angular.Module","!doc":"Interface for configuring angular modules.",prototype:{animation:{"!type":"fn(name: string, animationFactory: fn()) -> !this","!url":"http://docs.angularjs.org/api/angular.Module#animation","!doc":"Defines an animation hook that can be later used with $animate service and directives that use this service."},config:{"!type":"fn(configFn: fn()) -> !this","!effects":["custom angular_callInject 0"],"!url":"http://docs.angularjs.org/api/angular.Module#config","!doc":"Use this method to register work which needs to be performed on module loading."},constant:"service.$provide.constant",controller:{"!type":"fn(name: string, constructor: fn()) -> !this","!effects":["custom angular_regFieldCall"],"!url":"http://docs.angularjs.org/api/ng.$controllerProvider","!doc":"Register a controller."},directive:{"!type":"fn(name: string, directiveFactory: fn() -> directiveObj) -> !this","!effects":["custom angular_regFieldCall"],"!url":"http://docs.angularjs.org/api/ng.$compileProvider#directive","!doc":"Register a new directive with the compiler."},factory:"service.$provide.factory",filter:{"!type":"fn(name: string, filterFactory: fn()) -> !this","!effects":["custom angular_callInject 1"],"!url":"http://docs.angularjs.org/api/ng.$filterProvider","!doc":"Register filter factory function."},provider:"service.$provide.provider",run:{"!type":"fn(initializationFn: fn()) -> !this","!effects":["custom angular_callInject 0"],"!url":"http://docs.angularjs.org/api/angular.Module#run","!doc":"Register work which should be performed when the injector is done loading all modules."},service:"service.$provide.service",value:"service.$provide.value",name:{"!type":"string","!url":"http://docs.angularjs.org/api/angular.Module#name","!doc":"Name of the module."},requires:{"!type":"[string]","!url":"http://docs.angularjs.org/api/angular.Module#requires","!doc":"List of module names which must be loaded before this module."}}},Promise:{"!url":"http://docs.angularjs.org/api/ng.$q","!doc":"Allow for interested parties to get access to the result of the deferred task when it completes.",prototype:{then:"fn(successCallback: fn(value: ?), errorCallback: fn(reason: ?), notifyCallback: fn(value: ?)) -> +Promise","catch":"fn(errorCallback: fn(reason: ?))","finally":"fn(callback: fn()) -> +Promise",success:"fn(callback: fn(data: ?, status: number, headers: ?, config: ?)) -> +Promise",error:"fn(callback: fn(data: ?, status: number, headers: ?, config: ?)) -> +Promise"}},Deferred:{"!url":"http://docs.angularjs.org/api/ng.$q",prototype:{resolve:"fn(value: ?)",reject:"fn(reason: ?)",notify:"fn(value: ?)",promise:"+Promise"}},ResourceClass:{"!url":"http://docs.angularjs.org/api/ngResource.$resource",prototype:{$promise:"+Promise",$save:"fn()"}},Resource:{"!url":"http://docs.angularjs.org/api/ngResource.$resource",prototype:{get:"fn(params: ?, callback: fn()) -> +ResourceClass",save:"fn(params: ?, callback: fn()) -> +ResourceClass",query:"fn(params: ?, callback: fn()) -> +ResourceClass",remove:"fn(params: ?, callback: fn()) -> +ResourceClass","delete":"fn(params: ?, callback: fn()) -> +ResourceClass"}},service:{$anchorScroll:{"!type":"fn()","!url":"http://docs.angularjs.org/api/ng.$anchorScroll","!doc":"Checks current value of $location.hash() and scroll to related element."},$animate:{"!url":"http://docs.angularjs.org/api/ng.$animate","!doc":"Rudimentary DOM manipulation functions to insert, remove, move elements within the DOM.",addClass:{"!type":"fn(element: +Element, className: string, done?: fn()) -> !this","!url":"http://docs.angularjs.org/api/ng.$animate#addClass","!doc":"Adds the provided className CSS class value to the provided element."},enter:{"!type":"fn(element: +Element, parent: +Element, after: +Element, done?: fn()) -> !this","!url":"http://docs.angularjs.org/api/ng.$animate#enter","!doc":"Inserts the element into the DOM either after the after element or within the parent element."},leave:{"!type":"fn(element: +Element, done?: fn()) -> !this","!url":"http://docs.angularjs.org/api/ng.$animate#leave","!doc":"Removes the element from the DOM."},move:{"!type":"fn(element: +Element, parent: +Element, after: +Element, done?: fn()) -> !this","!url":"http://docs.angularjs.org/api/ng.$animate#move","!doc":"Moves element to be placed either after the after element or inside of the parent element."},removeClass:{"!type":"fn(element: +Element, className: string, done?: fn()) -> !this","!url":"http://docs.angularjs.org/api/ng.$animate#removeClass","!doc":"Removes the provided className CSS class value from the provided element."}},$cacheFactory:{"!type":"fn(cacheId: string, options?: ?) -> cacheObj","!url":"http://docs.angularjs.org/api/ng.$cacheFactory","!doc":"Factory that constructs cache objects and gives access to them."},$compile:{"!type":"fn(element: +Element, transclude: fn(scope: ?), maxPriority: number)","!url":"http://docs.angularjs.org/api/ng.$compile","!doc":"Compiles a piece of HTML string or DOM into a template and produces a template function."},$controller:{"!type":"fn(controller: fn(), locals: ?) -> ?","!url":"http://docs.angularjs.org/api/ng.$controller","!doc":"Instantiates controllers."},$document:{"!type":"jQuery.fn","!url":"http://docs.angularjs.org/api/ng.$document","!doc":"A jQuery (lite)-wrapped reference to the browser's window.document element."},$exceptionHandler:{"!type":"fn(exception: +Error, cause?: string)","!url":"http://docs.angularjs.org/api/ng.$exceptionHandler","!doc":"Any uncaught exception in angular expressions is delegated to this service."},$filter:{"!type":"fn(name: string) -> fn(input: string) -> string","!url":"http://docs.angularjs.org/api/ng.$filter","!doc":"Retrieve a filter function."},$http:{"!type":"fn(config: ?) -> service.$q","!url":"http://docs.angularjs.org/api/ng.$http","!doc":"Facilitates communication with remote HTTP servers.","delete":"fn(url: string, config?: ?) -> +Promise",get:"fn(url: string, config?: ?) -> +Promise",head:"fn(url: string, config?: ?) -> +Promise",jsonp:"fn(url: string, config?: ?) -> +Promise",post:"fn(url: string, data: ?, config?: ?) -> +Promise",put:"fn(url: string, data: ?, config?: ?) -> +Promise"},$interpolate:{"!type":"fn(text: string, mustHaveExpression?: bool, trustedContext?: string) -> fn(context: ?) -> string","!url":"http://docs.angularjs.org/api/ng.$interpolate","!doc":"Compiles a string with markup into an interpolation function."},$locale:{"!url":"http://docs.angularjs.org/api/ng.$locale",id:"string"},$location:{"!url":"http://docs.angularjs.org/api/ng.$location","!doc":"Parses the URL in the browser address bar.",absUrl:{"!type":"fn() -> string","!url":"http://docs.angularjs.org/api/ng.$location#absUrl","!doc":"Return full url representation."},hash:{"!type":"fn(value?: string) -> string","!url":"http://docs.angularjs.org/api/ng.$location#hash","!doc":"Get or set the hash fragment."},host:{"!type":"fn() -> string","!url":"http://docs.angularjs.org/api/ng.$location#host","!doc":"Return host of current url."},path:{"!type":"fn(value?: string) -> string","!url":"http://docs.angularjs.org/api/ng.$location#path","!doc":"Get or set the URL path."},port:{"!type":"fn() -> number","!url":"http://docs.angularjs.org/api/ng.$location#port","!doc":"Returns the port of the current url."},protocol:{"!type":"fn() -> string","!url":"http://docs.angularjs.org/api/ng.$location#protocol","!doc":"Return protocol of current url."},replace:{"!type":"fn()","!url":"http://docs.angularjs.org/api/ng.$location#replace","!doc":"Changes to $location during current $digest will be replacing current history record, instead of adding new one."},search:{"!type":"fn(search: string, paramValue?: string) -> string","!url":"http://docs.angularjs.org/api/ng.$location#search","!doc":"Get or set the URL query."},url:{"!type":"fn(url: string, replace?: string) -> string","!url":"http://docs.angularjs.org/api/ng.$location#url","!doc":"Get or set the current url."}},$log:{"!url":"http://docs.angularjs.org/api/ng.$log","!doc":"Simple service for logging.",debug:{"!type":"fn(message: string)","!url":"http://docs.angularjs.org/api/ng.$log#debug","!doc":"Write a debug message."},error:{"!type":"fn(message: string)","!url":"http://docs.angularjs.org/api/ng.$log#error","!doc":"Write an error message."},info:{"!type":"fn(message: string)","!url":"http://docs.angularjs.org/api/ng.$log#info","!doc":"Write an info message."},log:{"!type":"fn(message: string)","!url":"http://docs.angularjs.org/api/ng.$log#log","!doc":"Write a log message."},warn:{"!type":"fn(message: string)","!url":"http://docs.angularjs.org/api/ng.$log#warn","!doc":"Write a warning message."}},$parse:{"!type":"fn(expression: string) -> fn(context: ?, locals: ?) -> ?","!url":"http://docs.angularjs.org/api/ng.$parse","!doc":"Converts Angular expression into a function."},$q:{"!type":"fn(executor: fn(resolve: fn(value: ?) -> +Promise, reject: fn(value: ?) -> +Promise)) -> +Promise","!url":"http://docs.angularjs.org/api/ng.$q","!doc":"A promise/deferred implementation.",all:{"!type":"fn(promises: [+Promise]) -> +Promise","!url":"http://docs.angularjs.org/api/ng.$q#all","!doc":"Combines multiple promises into a single promise."},defer:{"!type":"fn() -> +Deferred","!url":"http://docs.angularjs.org/api/ng.$q#defer","!doc":"Creates a Deferred object which represents a task which will finish in the future."},reject:{"!type":"fn(reason: ?) -> +Promise","!url":"http://docs.angularjs.org/api/ng.$q#reject","!doc":"Creates a promise that is resolved as rejected with the specified reason."},when:{"!type":"fn(value: ?) -> +Promise","!url":"http://docs.angularjs.org/api/ng.$q#when","!doc":"Wraps an object that might be a value or a (3rd party) then-able promise into a $q promise."}},$rootElement:{"!type":"+Element","!url":"http://docs.angularjs.org/api/ng.$rootElement","!doc":"The root element of Angular application."},$rootScope:{"!url":"http://docs.angularjs.org/api/ng.$rootScope",$apply:{"!type":"fn(expression: string)","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$apply","!doc":"Execute an expression in angular from outside of the angular framework."},$broadcast:{"!type":"fn(name: string, args?: ?) -> eventObj","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$broadcast","!doc":"Dispatches an event name downwards to all child scopes."},$destroy:{"!type":"fn()","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$destroy","!doc":"Removes the current scope (and all of its children) from the parent scope."},$digest:{"!type":"fn()","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$digest","!doc":"Processes all of the watchers of the current scope and its children."},$emit:{"!type":"fn(name: string, args?: ?) -> eventObj","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$emit","!doc":"Dispatches an event name upwards through the scope hierarchy."},$eval:{"!type":"fn(expression: string) -> ?","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$eval","!doc":"Executes the expression on the current scope and returns the result."},$evalAsync:{"!type":"fn(expression: string)","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$evalAsync","!doc":"Executes the expression on the current scope at a later point in time."},$new:{"!type":"fn(isolate: bool) -> service.$rootScope","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$new","!doc":"Creates a new child scope."},$on:{"!type":"fn(name: string, listener: fn(event: ?)) -> fn()","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$on","!doc":"Listens on events of a given type."},$watch:{"!type":"fn(watchExpression: string, listener?: fn(), objectEquality?: bool) -> fn()","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$watch","!doc":"Registers a listener callback to be executed whenever the watchExpression changes."},$watchCollection:{"!type":"fn(obj: string, listener: fn()) -> fn()","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$watchCollection","!doc":"Shallow watches the properties of an object and fires whenever any of the properties."},$id:{"!type":"number","!url":"http://docs.angularjs.org/api/ng.$rootScope.Scope#$id","!doc":"Unique scope ID."}},$sce:{HTML:"string",CSS:"string",URL:"string",RESOURCE_URL:"string",JS:"string",getTrusted:"fn(type: string, maybeTrusted: ?) -> !1",getTrustedCss:"fn(maybeTrusted: ?) -> !0",getTrustedHtml:"fn(maybeTrusted: ?) -> !0",getTrustedJs:"fn(maybeTrusted: ?) -> !0",getTrustedResourceUrl:"fn(maybeTrusted: ?) -> !0",getTrustedUrl:"fn(maybeTrusted: ?) -> !0",parse:"fn(type: string, expression: string) -> fn(context: ?, locals: ?) -> ?",parseAsCss:"fn(expression: string) -> fn(context: ?, locals: ?) -> ?",parseAsHtml:"fn(expression: string) -> fn(context: ?, locals: ?) -> ?",parseAsJs:"fn(expression: string) -> fn(context: ?, locals: ?) -> ?",parseAsResourceUrl:"fn(expression: string) -> fn(context: ?, locals: ?) -> ?",parseAsUrl:"fn(expression: string) -> fn(context: ?, locals: ?) -> ?",trustAs:"fn(type: string, value: ?) -> !1",trustAsHtml:"fn(value: ?) -> !0",trustAsJs:"fn(value: ?) -> !0",trustAsResourceUrl:"fn(value: ?) -> !0",trustAsUrl:"fn(value: ?) -> !0",isEnabled:"fn() -> bool"},$templateCache:{"!url":"http://docs.angularjs.org/api/ng.$templateCache","!proto":"cacheObj"},$timeout:{"!type":"fn(fn: fn(), delay?: number, invokeApply?: bool) -> +Promise","!url":"http://docs.angularjs.org/api/ng.$timeout","!doc":"Angular's wrapper for window.setTimeout.",cancel:"fn(promise: +Promise)"},$window:"<top>",$injector:{"!url":"http://docs.angularjs.org/api/AUTO.$injector","!doc":"Retrieve object instances as defined by provider.",annotate:{"!type":"fn(f: fn()) -> [string]","!url":"http://docs.angularjs.org/api/AUTO.$injector#annotate","!doc":"Returns an array of service names which the function is requesting for injection."},get:{"!type":"fn(name: string) -> ?","!url":"http://docs.angularjs.org/api/AUTO.$injector#get","!doc":"Return an instance of a service."},has:{"!type":"fn(name: string) -> bool","!url":"http://docs.angularjs.org/api/AUTO.$injector#has","!doc":"Allows the user to query if the particular service exist."},instantiate:{"!type":"fn(type: fn(), locals?: ?) -> +!0","!url":"http://docs.angularjs.org/api/AUTO.$injector#instantiate","!doc":"Create a new instance of JS type."},invoke:{"!type":"fn(type: fn(), self?: ?, locals?: ?) -> !0.!ret","!url":"http://docs.angularjs.org/api/AUTO.$injector#invoke","!doc":"Invoke the method and supply the method arguments from the $injector."}},$provide:{"!url":"http://docs.angularjs.org/api/AUTO.$provide","!doc":"Use $provide to register new providers with the $injector.",constant:{"!type":"fn(name: string, value: ?) -> !this","!effects":["custom angular_regField"],"!url":"http://docs.angularjs.org/api/AUTO.$provide#constant","!doc":"A constant value."},decorator:{"!type":"fn(name: string, decorator: fn())","!effects":["custom angular_regFieldCall"],"!url":"http://docs.angularjs.org/api/AUTO.$provide#decorator","!doc":"Decoration of service, allows the decorator to intercept the service instance creation."},factory:{"!type":"fn(name: string, providerFunction: fn()) -> !this","!effects":["custom angular_regFieldCall"],"!url":"http://docs.angularjs.org/api/AUTO.$provide#factory","!doc":"A short hand for configuring services if only $get method is required."},provider:{"!type":"fn(name: string, providerType: fn()) -> !this","!effects":["custom angular_regFieldCall"],"!url":"http://docs.angularjs.org/api/AUTO.$provide#provider","!doc":"Register a provider for a service."},service:{"!type":"fn(name: string, constructor: fn()) -> !this","!effects":["custom angular_regFieldNew"],"!url":"http://docs.angularjs.org/api/AUTO.$provide#provider","!doc":"Register a provider for a service."},value:{"!type":"fn(name: string, object: ?) -> !this","!effects":["custom angular_regField"],"!url":"http://docs.angularjs.org/api/AUTO.$providevalue","!doc":"A short hand for configuring services if the $get method is a constant."}},$cookies:{"!url":"http://docs.angularjs.org/api/ngCookies.$cookies","!doc":"Provides read/write access to browser's cookies.",text:"string"},$resource:{"!type":"fn(url: string, paramDefaults?: ?, actions?: ?) -> +Resource","!url":"http://docs.angularjs.org/api/ngResource.$resource","!doc":"Creates a resource object that lets you interact with RESTful server-side data sources."},$route:{"!url":"http://docs.angularjs.org/api/ngRoute.$route","!doc":"Deep-link URLs to controllers and views.",reload:{"!type":"fn()","!url":"http://docs.angularjs.org/api/ngRoute.$route#reload","!doc":"Reload the current route even if $location hasn't changed."},current:{"!url":"http://docs.angularjs.org/api/ngRoute.$route#current","!doc":"Reference to the current route definition.",controller:"?",locals:"?"},routes:"[?]"},$sanitize:{"!type":"fn(string) -> string","!url":"http://docs.angularjs.org/api/ngSanitize.$sanitize","!doc":"Sanitize HTML input."},$swipe:{"!url":"http://docs.angularjs.org/api/ngTouch.$swipe","!doc":"A service that abstracts the messier details of hold-and-drag swipe behavior.",bind:{"!type":"fn(element: +Element, handlers: ?)","!url":"http://docs.angularjs.org/api/ngTouch.$swipe#bind","!doc":"Abstracts the messier details of hold-and-drag swipe behavior."}}}},angular:{bind:{"!type":"fn(self: ?, fn: fn(), args?: ?) -> !custom:angular_bind","!url":"http://docs.angularjs.org/api/angular.bind","!doc":"Returns a function which calls function fn bound to self."},bootstrap:{"!type":"fn(element: +Element, modules?: [string]) -> service.$injector","!url":"http://docs.angularjs.org/api/angular.bootstrap","!doc":"Use this function to manually start up angular application."},copy:{"!type":"fn(source: ?, target?: ?) -> !0","!url":"http://docs.angularjs.org/api/angular.copy","!doc":"Creates a deep copy of source, which should be an object or an array."},element:{"!type":"fn(element: +Element) -> jQuery.fn","!url":"http://docs.angularjs.org/api/angular.element","!doc":"Wraps a raw DOM element or HTML string as a jQuery element."},equals:{"!type":"fn(o1: ?, o2: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.equals","!doc":"Determines if two objects or two values are equivalent."},extend:{"!type":"fn(dst: ?, src: ?) -> !0","!url":"http://docs.angularjs.org/api/angular.extend","!doc":"Extends the destination object dst by copying all of the properties from the src object(s) to dst."},forEach:{"!type":"fn(obj: ?, iterator: fn(value: ?, key: ?), context?: ?) -> !0","!effects":["call !1 this=!2 !0.<i> number"],"!url":"http://docs.angularjs.org/api/angular.forEach","!doc":"Invokes the iterator function once for each item in obj collection, which can be either an object or an array."},fromJson:{"!type":"fn(json: string) -> ?","!url":"http://docs.angularjs.org/api/angular.fromJson","!doc":"Deserializes a JSON string."},identity:{"!type":"fn(val: ?) -> !0","!url":"http://docs.angularjs.org/api/angular.identity","!doc":"A function that returns its first argument."},injector:{"!type":"fn(modules: [string]) -> service.$injector","!url":"http://docs.angularjs.org/api/angular.injector","!doc":"Creates an injector function"},isArray:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isArray","!doc":"Determines if a reference is an Array."},isDate:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isDate","!doc":"Determines if a reference is a date."},isDefined:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isDefined","!doc":"Determines if a reference is defined."},isElement:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isElement","!doc":"Determines if a reference is a DOM element."},isFunction:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isFunction","!doc":"Determines if a reference is a function."},isNumber:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isNumber","!doc":"Determines if a reference is a number."},isObject:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isObject","!doc":"Determines if a reference is an object."},isString:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isString","!doc":"Determines if a reference is a string."},isUndefined:{"!type":"fn(val: ?) -> bool","!url":"http://docs.angularjs.org/api/angular.isUndefined","!doc":"Determines if a reference is undefined."},lowercase:{"!type":"fn(val: string) -> string","!url":"http://docs.angularjs.org/api/angular.lowercase","!doc":"Converts the specified string to lowercase."},module:{"!type":"fn(name: string, deps: [string]) -> !custom:angular_module","!url":"http://docs.angularjs.org/api/angular.module","!doc":"A global place for creating, registering and retrieving Angular modules."},Module:"Module",noop:{"!type":"fn()","!url":"http://docs.angularjs.org/api/angular.noop","!doc":"A function that performs no operations."},toJson:{"!type":"fn(val: ?) -> string","!url":"http://docs.angularjs.org/api/angular.toJson","!doc":"Serializes input into a JSON-formatted string."},uppercase:{"!type":"fn(string) -> string","!url":"http://docs.angularjs.org/api/angular.uppercase","!doc":"Converts the specified string to uppercase."},version:{"!url":"http://docs.angularjs.org/api/angular.version",full:"string",major:"number",minor:"number",dot:"number",codename:"string"}}}
}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require):"function"==typeof define&&define.amd?define("tern/plugin/orionExpress",["../lib/infer","../lib/tern","./resolver"],e):void e(infer,tern,resolver)}(function(e,t,r){function n(n,s,a,i){var l=t.resolvePos(n,a),c=e.findExpressionAround(n.ast,null,l,n.scope),p=r.getTemplatesForNode(o,c);if(p&&p.length>0)for(var d=0;d<p.length;d++){var u=p[d];u.origin="express",u.type="template",i.push(u)}}var o=[{prefix:"express",name:"express",nodes:{top:!0,member:!1,prop:!1},description:" - Node.js require statement for Express",template:"var ${name} = require('express');"},{prefix:"express",name:"express app",description:" - create a new Express app",template:"var express = require('express');\nvar ${app} = express();\n${cursor}\napp.listen(${timeout});\n"},{prefix:"express",name:"express configure",nodes:{top:!0,member:!1,prop:!1},description:" - create an Express app configure statement",template:"app.configure(function() {\n	app.set(${id}, ${value});\n});"},{prefix:"express",name:"express specific configure",nodes:{top:!0,member:!1,prop:!1},description:" - create a specific Express app configure statement",template:"app.configure(${name}, function() {\n	app.set(${id}, ${value});\n});"},{prefix:"express",name:"express app get",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Express app.get call",template:"var value = app.get(${id}, function(request, result){\n	${cursor}\n});\n"},{prefix:"express",name:"express app set",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Express app set call",template:"app.set(${id}, ${value});\n"},{prefix:"express",name:"express app use",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Express app use statement",template:"app.use(${fnOrObject});\n"},{prefix:"express",name:"express app engine",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Express app engine statement",template:"app.engine(${fnOrObject});\n"},{prefix:"express",name:"express app param",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Express app param statement",template:"app.param(${id}, ${value});\n"},{prefix:"express",name:"express app error use",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Express app error handling use statement",template:"app.use(function(error, request, result, next) {\n	result.send(${code}, ${message});\n});\n"}];t.registerPlugin("orionExpress",function(){return{defs:s,passes:{variableCompletion:n}}});var s={express:{IRoute:{path:"string",stack:"?",all:"fn(handler: [RequestHandler]) -> IRoute",get:"fn(handler: [RequestHandler]) -> IRoute",post:"fn(handler: [RequestHandler]) -> IRoute",put:"fn(handler: [RequestHandler]) -> IRoute","delete":"fn(handler: [RequestHandler]) -> IRoute",patch:"fn(handler: [RequestHandler]) -> IRoute",options:"fn(handler: [RequestHandler]) -> IRoute"},Router:{"!type":"fn(options?: ?) -> Router",prototype:{param:"fn(name: string, handler: RequestParamHandler) -> T",all:"?",get:"?",post:"?",put:"?","delete":"?",patch:"?",options:"?",route:"fn(path: string) -> IRoute",use:"fn(handler: [RequestHandler]) -> T"}},CookieOptions:{maxAge:"number",signed:"bool",expires:"Date",httpOnly:"bool",path:"string",domain:"string",secure:"bool"},Errback:{},Request:{get:"fn(name: string) -> string",header:"fn(name: string) -> string",headers:{},accepts:"fn(type: string) -> string",acceptsCharset:"fn(charset: string) -> bool",acceptsLanguage:"fn(lang: string) -> bool",range:"fn(size: number) -> [?]",accepted:"[MediaType]",acceptedLanguages:"[?]",acceptedCharsets:"[?]",param:"fn(name: string, defaultValue?: ?) -> string",is:"fn(type: string) -> bool",protocol:"string",secure:"bool",ip:"string",ips:"[string]",subdomains:"[string]",path:"string",hostname:"string",host:"string",fresh:"bool",stale:"bool",xhr:"bool",body:"?",cookies:"?",method:"string",params:"?",user:"?",authenticatedUser:"?",files:"?",clearCookie:"fn(name: string, options?: ?) -> Response",query:"?",route:"?",signedCookies:"?",originalUrl:"string",url:"string"},MediaType:{value:"string",quality:"number",type:"string",subtype:"string"},Send:{},Response:{status:"fn(code: number) -> Response",sendStatus:"fn(code: number) -> Response",links:"fn(links: ?) -> Response",send:"Send",json:"Send",jsonp:"Send",sendFile:"fn(path: string)",sendfile:"fn(path: string)",download:"fn(path: string)",contentType:"fn(type: string) -> Response",type:"fn(type: string) -> Response",format:"fn(obj: ?) -> Response",attachment:"fn(filename?: string) -> Response",set:"fn(field: ?) -> Response",header:"fn(field: ?) -> Response",headersSent:"bool",get:"fn(field: string) -> string",clearCookie:"fn(name: string, options?: ?) -> Response",cookie:"fn(name: string, val: string, options: CookieOptions) -> Response",location:"fn(url: string) -> Response",redirect:"fn(url: string)",render:"fn(view: string, options?: Object, callback?: fn(err: Error, html: string))",locals:"?",charset:"string"},ErrorRequestHandler:{},RequestHandler:{},Handler:{},RequestParamHandler:{},Application:{init:"fn()",defaultConfiguration:"fn()",engine:"fn(ext: string, fn: Function) -> Application",set:"fn(setting: string, val: ?) -> Application",get:{},path:"fn() -> string",enabled:"fn(setting: string) -> bool",disabled:"fn(setting: string) -> bool",enable:"fn(setting: string) -> Application",disable:"fn(setting: string) -> Application",configure:"fn(fn: Function) -> Application",render:"fn(name: string, options?: Object, callback?: fn(err: Error, html: string))",listen:"fn(port: number, hostname: string, backlog: number, callback?: Function) -> http.Server",route:"fn(path: string) -> IRoute",router:"string",settings:"?",resource:"?",map:"?",locals:"?",routes:"?"},Express:{version:"string",mime:"string",createApplication:"fn() -> Application",createServer:"fn() -> Application",application:"?",request:"Request",response:"Response"},"static":"fn(root: string, options?: ?) -> RequestHandler"},"!name":"express","!define":{"!node":{express:{"!type":"fn() -> express.Application","!url":"http://expressjs.com","!doc":"Creates an express application.",Router:{"!type":"fn(options?: express.RouterOptions) -> +express.Router"}}}}}}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require):"function"==typeof define&&define.amd?define("tern/plugin/orionMongoDB",["../lib/infer","../lib/tern","./resolver"],e):void e(infer,tern,resolver)}(function(e,t,r){function n(n,s,a,i){var l=t.resolvePos(n,a),c=e.findExpressionAround(n.ast,null,l,n.scope),p=r.getTemplatesForNode(o,c);if(p&&p.length>0)for(var d=0;d<p.length;d++){var u=p[d];u.origin="mongodb",u.type="template",i.push(u)}}var o=[{prefix:"mongodb",name:"mongodb",nodes:{top:!0,member:!1,prop:!1},description:" - Node.js require statement for MongoDB",template:"var ${name} = require('mongodb');\n"},{prefix:"mongodb",name:"mongodb client",nodes:{top:!0,member:!1,prop:!1},description:" - create a new MongoDB client",template:"var MongoClient = require('mongodb').MongoClient;\nvar Server = require('mongodb').Server;\n${cursor}"},{prefix:"mongodb",name:"mongodb open",nodes:{top:!0,member:!1,prop:!1},description:" - create a new MongoDB client and open a connection",template:"var MongoClient = require('mongodb').MongoClient;\nvar Server = require('mongodb').Server;\nvar ${client} = new MongoClient(new Server(${host}, ${port}));\ntry {\n	${client}.open(function(error, ${client}) {\n		var ${db} = ${client}.db(${name});\n		${cursor}\n	});\n} finally {\n	${client}.close();\n};"},{prefix:"mongodb",name:"mongodb connect",nodes:{top:!0,member:!1,prop:!1},description:" - connect to an existing MongoDB database",template:"var MongoClient = require('mongodb').MongoClient;\nMongoClient.connect(${url}, function(error, db) {\n	${cursor}\n});\n"},{prefix:"mongodb",name:"mongodb connect (Cloud Foundry)",nodes:{top:!0,member:!1,prop:!1},description:" - connect to an existing MongoDB database using Cloud Foundry",template:"if (${process}.env.VCAP_SERVICES) {\n	var env = JSON.parse(${process}.env.VCAP_SERVICES);\n	var mongo = env['${mongo-version}'][0].credentials;\n} else {\n	var mongo = {\n		username : 'username',\n		password : 'password',\n		url : 'mongodb://username:password@localhost:27017/database'\n	};\n}\nvar MongoClient = require('mongodb').MongoClient;\nMongoClient.connect(mongo.url, function(error, db) {\n	${cursor}\n});\n"},{prefix:"mongodb",name:"mongodb collection",nodes:{top:!0,member:!1,prop:!1},description:" - create a MongoDB database collection",template:"${db}.collection(${id}, function(${error}, collection) {\n	${cursor}\n});"},{prefix:"mongodb",name:"mongodb strict collection",nodes:{top:!0,member:!1,prop:!1},description:" - create a MongoDB database strict collection",template:"${db}.collection(${id}, {strict:true}, function(${error}, collection) {\n	${cursor}\n});"}];t.registerPlugin("orionMongoDB",function(){return{defs:s,passes:{variableCompletion:n}}});var s={mongodb:{MongoClient:{"!type":"fn(serverConfig: ?, options: ?)",connect:"fn(uri: string, options: ?, callback: fn(err: Error, db: Db))",prototype:{}},Server:{"!type":"fn(host: string, port: number, opts?: ServerOptions)",prototype:{connect:"fn() -> ?"}},Db:{"!type":"fn(databaseName: string, serverConfig: Server, dbOptions?: DbCreateOptions)",prototype:{db:"fn(dbName: string) -> Db",open:"fn(callback: fn(err: Error, db: Db))",close:"fn(forceClose?: bool, callback?: fn(err: Error, result: ?))",admin:"fn(callback: fn(err: Error, result: ?)) -> ?",collectionsInfo:"fn(collectionName: string, callback?: fn(err: Error, result: ?))",collectionNames:"fn(collectionName: string, options: ?, callback?: fn(err: Error, result: ?))",collection:"fn(collectionName: string) -> Collection",collections:"fn(callback: fn(err: Error, collections: [Collection]))",eval:"fn(code: ?, parameters: [?], options?: ?, callback?: fn(err: Error, result: ?))",logout:"fn(options: ?, callback?: fn(err: Error, result: ?))",authenticate:"fn(userName: string, password: string, callback?: fn(err: Error, result: ?))",addUser:"fn(username: string, password: string, callback?: fn(err: Error, result: ?))",removeUser:"fn(username: string, callback?: fn(err: Error, result: ?))",createCollection:"fn(collectionName: string, callback?: fn(err: Error, result: Collection))",command:"fn(selector: Object, callback?: fn(err: Error, result: ?))",dropCollection:"fn(collectionName: string, callback?: fn(err: Error, result: ?))",renameCollection:"fn(fromCollection: string, toCollection: string, callback?: fn(err: Error, result: ?))",lastError:"fn(options: Object, connectionOptions: ?, callback: fn(err: Error, result: ?))",previousError:"fn(options: Object, callback: fn(err: Error, result: ?))",executeDbCommand:"fn(command_hash: ?, callback?: fn(err: Error, result: ?))",executeDbAdminCommand:"fn(command_hash: ?, callback?: fn(err: Error, result: ?))",resetErrorHistory:"fn(callback?: fn(err: Error, result: ?))",createIndex:"fn(collectionName: ?, fieldOrSpec: ?, options: IndexOptions, callback: Function)",ensureIndex:"fn(collectionName: ?, fieldOrSpec: ?, options: IndexOptions, callback: Function)",cursorInfo:"fn(options: ?, callback: Function)",dropIndex:"fn(collectionName: string, indexName: string, callback: Function)",reIndex:"fn(collectionName: string, callback: Function)",indexInformation:"fn(collectionName: string, options: ?, callback: Function)",dropDatabase:"fn(callback: fn(err: Error, result: ?))",stats:"fn(options: ?, callback: Function)",_registerHandler:"fn(db_command: ?, raw: ?, connection: ?, exhaust: ?, callback: Function)",_reRegisterHandler:"fn(newId: ?, object: ?, callback: Function)",_callHandler:"fn(id: ?, document: ?, err: ?) -> ?",_hasHandler:"fn(id: ?) -> ?",_removeHandler:"fn(id: ?) -> ?",_findHandler:"fn(id: ?) -> ret",__executeQueryCommand:"fn(self: ?, db_command: ?, options: ?, callback: ?)",DEFAULT_URL:"string",connect:"fn(url: string, options: Object, callback: fn(err: Error, result: ?))",addListener:"fn(event: string, handler: fn(param: ?)) -> ?"}},SocketOptions:{timeout:"number",noDelay:"bool",keepAlive:"number",encoding:"string"},ServerOptions:{auto_reconnect:"bool",poolSize:"number",socketOptions:"?"},PKFactory:{counter:"number",createPk:"fn()"},DbCreateOptions:{w:"?",wtimeout:"number",fsync:"bool",journal:"bool",readPreference:"string",native_parser:"bool",forceServerObjectId:"bool",pkFactory:"PKFactory",serializeFunctions:"bool",raw:"bool",recordQueryStats:"bool",retryMiliSeconds:"number",numberOfRetries:"number",logger:"Object",slaveOk:"number",promoteLongs:"bool"},ReadPreference:{PRIMARY:"string",PRIMARY_PREFERRED:"string",SECONDARY:"string",SECONDARY_PREFERRED:"string",NEAREST:"string",prototype:{}},CollectionCreateOptions:{readPreference:"string",slaveOk:"bool",serializeFunctions:"bool",raw:"bool",pkFactory:"PKFactory"},CollStats:{ns:"string",count:"number",size:"number",avgObjSize:"number",storageSize:"number",numExtents:"number",nindexes:"number",lastExtentSize:"number",paddingFactor:"number",flags:"number",totalIndexSize:"number",indexSizes:{_id_:"number",username:"number"}},Collection:{insert:"fn(query: ?, callback: fn(err: Error, result: ?))",remove:"fn(selector: Object, callback?: fn(err: Error, result: ?))",rename:"fn(newName: String, callback?: fn(err: Error, result: ?))",save:"fn(doc: ?, callback: fn(err: Error, result: ?))",update:"fn(selector: Object, document: ?, callback?: fn(err: Error, result: ?))",distinct:"fn(key: string, query: Object, callback: fn(err: Error, result: ?))",count:"fn(callback: fn(err: Error, result: ?))",drop:"fn(callback?: fn(err: Error, result: ?))",findAndModify:"fn(query: Object, sort: [?], doc: Object, callback: fn(err: Error, result: ?))",findAndRemove:"fn(query: Object, sort?: [?], callback?: fn(err: Error, result: ?))",find:"fn(callback?: fn(err: Error, result: Cursor)) -> Cursor",findOne:"fn(callback?: fn(err: Error, result: ?)) -> Cursor",createIndex:"fn(fieldOrSpec: ?, callback: fn(err: Error, indexName: string))",ensureIndex:"fn(fieldOrSpec: ?, callback: fn(err: Error, indexName: string))",indexInformation:"fn(options: ?, callback: Function)",dropIndex:"fn(name: string, callback: Function)",dropAllIndexes:"fn(callback: Function)",reIndex:"fn(callback: Function)",mapReduce:"fn(map: Function, reduce: Function, options: MapReduceOptions, callback: Function)",group:"fn(keys: Object, condition: Object, initial: Object, reduce: Function, finalize: Function, command: bool, options: Object, callback: Function)",options:"fn(callback: Function)",isCapped:"fn(callback: Function)",indexExists:"fn(indexes: string, callback: Function)",geoNear:"fn(x: number, y: number, callback: Function)",geoHaystackSearch:"fn(x: number, y: number, callback: Function)",indexes:"fn(callback: Function)",aggregate:"fn(pipeline: [?], callback: fn(err: Error, results: ?))",stats:"fn(options: Object, callback: fn(err: Error, results: CollStats))",hint:"?"},MapReduceOptions:{out:"Object",query:"Object",sort:"Object",limit:"number",keeptemp:"bool",finalize:"?",scope:"Object",jsMode:"bool",verbose:"bool",readPreference:"string"},IndexOptions:{w:"?",wtimeout:"number",fsync:"bool",journal:"bool",unique:"bool",sparse:"bool",background:"bool",dropDups:"bool",min:"number",max:"number",v:"number",expireAfterSeconds:"number",name:"string"},Cursor:{INIT:"number",OPEN:"number",CLOSED:"number",GET_MORE:"number",prototype:{rewind:"fn() -> Cursor",toArray:"fn(callback: fn(err: Error, results: [?]))",each:"fn(callback: fn(err: Error, item: ?))",count:"fn(applySkipLimit: bool, callback: fn(err: Error, count: number))",sort:"fn(keyOrList: ?, callback?: fn(err: Error, result: ?)) -> Cursor",limit:"fn(limit: number, callback?: fn(err: Error, result: ?)) -> Cursor",setReadPreference:"fn(preference: string, callback?: Function) -> Cursor",skip:"fn(skip: number, callback?: fn(err: Error, result: ?)) -> Cursor",batchSize:"fn(batchSize: number, callback?: fn(err: Error, result: ?)) -> Cursor",nextObject:"fn(callback: fn(err: Error, doc: ?))",explain:"fn(callback: fn(err: Error, result: ?))",stream:"fn() -> CursorStream",close:"fn(callback: fn(err: Error, result: ?))",isClosed:"fn() -> bool"}},CursorStream:{"!type":"fn(cursor: Cursor)",prototype:{pause:"fn() -> ?",resume:"fn() -> ?",destroy:"fn() -> ?"}},CollectionFindOptions:{limit:"number",sort:"?",fields:"Object",skip:"number",hint:"Object",explain:"bool",snapshot:"bool",timeout:"bool",tailtable:"bool",tailableRetryInterval:"number",numberOfRetries:"number",awaitdata:"bool",oplogReplay:"bool",exhaust:"bool",batchSize:"number",returnKey:"bool",maxScan:"number",min:"number",max:"number",showDiskLoc:"bool",comment:"String",raw:"bool",readPreference:"String",partial:"bool"},MongoCollectionOptions:{safe:"?",serializeFunctions:"?",raw:"bool",pkFactory:"?",readPreference:"string"}},"!name":"mongodb","!define":{"!node":{mongodb:{"!doc":"MongoDB","!url":"https://www.mongodb.org/",MongoClient:"mongodb.MongoClient",Db:"mongodb.Db",Server:"mongodb.Server",SocketOptions:"mongodb.SocketOptions",ServerOptions:"mongodb.ServerOptions",CollectionFindOptions:"mongodb.CollectionFindOptions",MongoCollectionOptions:"mongodb.MongoCollectionOptions",IndexOptions:"mongodb.IndexOptions",CollectionCreateOptions:"mongodb.CollectionCreateOptions",DbCreateOptions:"mongodb.DbCreateOptions",MapReduceOptions:"mongodb.MapReduceOptions",CollStats:"mongodb.CollStats",ReadPreference:"mongodb.ReadPreference",Collection:"mongodb.Collection",Cursor:"mongodb.Cursor",PKFactory:"mongodb.PKFactory"}}}}}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require):"function"==typeof define&&define.amd?define("tern/plugin/orionMySQL",["../lib/infer","../lib/tern","./resolver"],e):void e(infer,tern,resolver)}(function(e,t,r){function n(n,s,a,i){var l=t.resolvePos(n,a),c=e.findExpressionAround(n.ast,null,l,n.scope),p=r.getTemplatesForNode(o,c);if(p&&p.length>0)for(var d=0;d<p.length;d++){var u=p[d];u.origin="mysql",u.type="template",i.push(u)}}var o=[{prefix:"mysql",name:"mysql",nodes:{top:!0,member:!1,prop:!1},description:" - Node.js require statement for MySQL DB",template:"var mysql = require('mysql');\n"},{prefix:"mysql",name:"mysql connection",nodes:{top:!0,member:!1,prop:!1},description:" - create a new MySQL DB connection",template:"var mysql = require('mysql');\nvar ${connection} = mysql.createConnection({\n	host : ${host},\n	user : ${username},\n	password : ${password}\n});\ntry {\n	${connection}.connect();\n	${cursor}\n} finally {\n	${connection}.end();\n}"},{prefix:"mysql",name:"mysql query",nodes:{top:!0,member:!1,prop:!1},description:" - create a new MySQL DB query statement",template:"${connection}.query(${sql}, function(error, rows, fields) {\n	${cursor}\n});\n"}];t.registerPlugin("orionMySQL",function(){return{defs:s,passes:{variableCompletion:n}}});var s={mysql:{createConnection:"fn(connectionUri: string) -> Connection",createPool:"fn(config: PoolConfig) -> Pool",createPoolCluster:"fn(config?: PoolClusterConfig) -> PoolCluster",escape:"fn(value: ?) -> string",format:"fn(sql: string) -> string",MySql:{createConnection:"fn(connectionUri: string) -> Connection",createPool:"fn(config: PoolConfig) -> Pool",createPoolCluster:"fn(config?: PoolClusterConfig) -> PoolCluster",escape:"fn(value: ?) -> string",format:"fn(sql: string) -> string"},ConnectionStatic:{createQuery:"fn(sql: string) -> Query"},Connection:{config:"ConnectionConfig",threadId:"number",beginTransaction:"fn(callback: fn(err: Error))",connect:"fn()",commit:"fn(callback: fn(err: Error))",changeUser:"fn(options: ConnectionOptions)",query:"QueryFunction",end:"fn()",destroy:"fn()",pause:"fn()",release:"fn()",resume:"fn()",escape:"fn(value: ?) -> string",escapeId:"fn(value: string) -> string",format:"fn(sql: string) -> string",on:"fn(ev: string, callback: fn(args: [?])) -> Connection",rollback:"fn(callback: fn())"},Pool:{config:"PoolConfig",getConnection:"fn(callback: fn(err: Error, connection: Connection))",query:"QueryFunction",end:"fn()",on:"fn(ev: string, callback: fn(args: [?])) -> Pool"},PoolCluster:{config:"PoolClusterConfig",add:"fn(config: PoolConfig)",end:"fn()",getConnection:"fn(callback: fn(err: Error, connection: Connection))",of:"fn(pattern: string) -> Pool",on:"fn(ev: string, callback: fn(args: [?])) -> PoolCluster"},Query:{sql:"string",start:"fn()",determinePacket:"fn(firstByte: number, parser: ?) -> ?",stream:"fn(options: StreamOptions) -> stream.Readable",pipe:"fn(callback: fn(args: [?])) -> Query",on:"fn(ev: string, callback: fn(args: [?])) -> Query"},QueryFunction:{},QueryOptions:{sql:"string",timeout:"number",nestTables:"?",typeCast:"?"},StreamOptions:{highWaterMark:"number",objectMode:"?"},ConnectionOptions:{user:"string",password:"string",database:"string",charset:"string"},ConnectionConfig:{host:"string",port:"number",localAddress:"string",socketPath:"string",timezone:"string",connectTimeout:"number",stringifyObjects:"bool",insecureAuth:"bool",typeCast:"?",queryFormat:"fn(query: string, values: ?)",supportBigNumbers:"bool",bigNumberStrings:"bool",dateStrings:"bool",debug:"?",trace:"bool",multipleStatements:"bool",flags:"?",ssl:"?"},PoolConfig:{acquireTimeout:"number",waitForConnections:"bool",connectionLimit:"number",queueLimit:"number"},PoolClusterConfig:{canRetry:"bool",removeNodeErrorCount:"number",defaultSelector:"string"},SslCredentials:{pfx:"string",key:"string",passphrase:"string",cert:"string",ca:"?",crl:"?",ciphers:"string"},Error:{code:"string",errno:"number",sqlStateMarker:"string",sqlState:"string",fieldCount:"number",stack:"string",fatal:"bool"}},"!name":"mysql","!define":{"!node":{mysql:{createConnection:"fn(connectionUri: string) -> mysql.Connection",createPool:"fn(config: mysql.PoolConfig) -> mysql.Pool",createPoolCluster:"fn(config?: mysql.PoolClusterConfig) -> mysql.PoolCluster",escape:"fn(value: ?) -> string",format:"fn(sql: string) -> string"}}}}}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require):"function"==typeof define&&define.amd?define("tern/plugin/node",["../lib/infer","../lib/tern","./resolver"],e):void e(tern,tern)}(function(e,t,r,n){"use strict";function o(e,t){if("/"==t[0])return t;var r,n=e.lastIndexOf("/");for(n>=0&&(t=e.slice(0,n+1)+t);r=/[^\/]*[^\/\.][^\/]*\/\.\.\//.exec(t);)t=t.slice(0,r.index)+t.slice(r.index+r[0].length);return t.replace(/(^|[^\.])\.\//g,"$1")}function s(e,t){return"/"!=e[e.length-1]&&(e+="/"),0==t.indexOf(e)?t.slice(e.length):t}function a(t,r){return t.modules[r]||(t.modules[r]=new e.AVal)}function i(t,r,n){var o=new e.Scope(t);o.originNode=n,e.cx().definitions.node.require.propagate(o.defProp("require"));var s=new e.Obj(e.cx().definitions.node.Module.getProp("prototype").getType());s.propagate(o.defProp("module"));var a=new e.Obj(!0,"exports");s.origin=a.origin=r,s.originNode=a.originNode=o.originNode,a.propagate(o.defProp("exports"));var i=o.exports=s.defProp("exports");return a.propagate(i,y),o}function l(e,t){return e.addFile(t,null,e._node.currentOrigin),a(e._node,t)}function c(e){return e.replace(/\\/g,"/")}function p(e,t){return o(c(e.options.projectDir||"")+"/",c(t))}function d(t){var r=e.cx().parent._node.modules,n=t.roots["!node"]=new e.Obj(null);for(var o in r){var s=r[o],a=s.origin||o,i=n.defProp(a.replace(/\./g,"`"));s.propagate(i),i.origin=s.origin}}function u(t){var r=e.cx(),n=r.definitions[t["!name"]]["!node"],t=r.parent._node;if(n)for(var o in n.props){var s=o.replace(/`/g,"."),i=a(t,s);i.origin=s,n.props[o].propagate(i)}}function h(e,t,r,n){if(!r)return n;var o="Literal"===r.node.type&&"string"==typeof r.node.value,s=!!r.node.required;if(o&&s){n=Object.create(n);var a;r.node.required&&(a=r.node.required.getType())&&(n.origin=a.origin,n.originNode=a.originNode)}return n}function f(r,n){var o=t.resolvePos(r,n.end),s=e.findExpressionAround(r.ast,null,o,r.scope,"CallExpression");if(s){var a=s.node;if(!("Identifier"!=a.callee.type||"require"!=a.callee.name||a.arguments.length<1)){var i=a.arguments[0];if(!("Literal"!=i.type||"string"!=typeof i.value||i.start>o||i.end<o)){var l=i.raw.slice(1,o-i.start),c=i.raw.charAt(0);l&&l.charAt(l.length-1)==c&&(l=l.slice(0,l.length-1));var p=m(n,r,l);return i.end==o+1&&r.text.charAt(o)==c&&++o,{start:t.outputPos(n,r,i.start),end:t.outputPos(n,r,o),isProperty:!1,completions:p.map(function(e){var t="string"==typeof e?e:e.name,r=JSON.stringify(t);return"'"==c&&(r=c+r.slice(1,r.length-1).replace(/'/g,"\\'")+c),"string"==typeof e?r:(e.displayName=t,e.name=r,e)})}}}}}function m(t,r,n){function o(r){for(var o in r)if(o!=c){var a=g(o,c);if(a&&(t.filter===!1||!n||0===(t.caseInsensitive?a.toLowerCase():a).indexOf(n))){var i=d?{name:a}:a;if(s.push(i),t.types||t.docs||t.urls||t.origins){var l=r[o];e.resetGuessing();var p=l.getType();i.guess=e.didGuess(),t.types&&(i.type=e.toString(l)),t.docs&&b(i,"doc",l.doc||p&&p.doc),t.urls&&b(i,"url",l.url||p&&p.url),t.origins&&b(i,"origin",l.origin||p&&p.origin)}}}}var s=[],a=e.cx(),i=a.parent,l=i._node,c=l.currentFile||p(i,r.name),d=t.types||t.depths||t.docs||t.urls||t.origins;return t.caseInsensitive&&(n=n.toLowerCase()),o(a.definitions.node),o(l.modules),s}function g(e,t){function r(e,t){return e.slice(0,t.length)==t}function n(e,t){return e.slice(-t.length)==t}if(-1==e.indexOf("/"))return e;var o=c(s(t+"/..",e));return r(o,"node_modules")?(o=o.substring("node_modules".length+1,o.length),n(o,"index.js")&&(o=o.substring(0,o.length-"index.js".length-1))):r(o,"../")||(o="./"+o),n(o,".js")&&(o=o.substring(0,o.length-".js".length)),o}function b(e,t,r){null!=r&&(e[t]=r)}var y=95;n&&function(){var t=n("fs"),r=n("module"),o=n("path");s=o.relative,l=function(n,a,i){var l=n._node;if(1==l.options.dontLoad||l.options.dontLoad&&new RegExp(l.options.dontLoad).test(a)||l.options.load&&!new RegExp(l.options.load).test(a))return e.ANull;if(l.modules[a])return l.modules[a];var p={id:i,paths:r._nodeModulePaths(o.dirname(i))};try{var d=r._resolveFilename(a,p)}catch(u){return e.ANull}var h=c(d);return l.modules[h]?l.modules[h]:(t.existsSync(d)&&/^(\.js)?$/.test(o.extname(d))&&n.addFile(s(n.options.projectDir,d),null,l.currentOrigin),l.modules[h]=new e.AVal)}}(),e.registerFunction("nodeRequire",function(t,n,s){if(!s||!s.length||"Literal"!=s[0].type||"string"!=typeof s[0].value)return e.ANull;var a,c=e.cx(),d=c.parent,u=d._node,h=s[0].value,f=c.definitions.node;if(f[h]&&/^[a-z_]*$/.test(h))a=f[h];else if(h in u.modules)a=u.modules[h];else if(u.options.modules&&u.options.modules.hasOwnProperty(h)){var m=u.options.modules[h];if("string"==typeof m&&"="==m.charAt(0))a=e.def.parsePath(m.slice(1));else{var g=i(c.topScope,h);e.def.load(u.options.modules[h],g),a=u.modules[h]=g.exports}}else{var b=r.getResolved(h);b&&void 0!==b.file&&(h=b.file);var y=u.currentFile||p(d,s[0].sourceFile.name),v=/^\.{0,2}\//.test(h);if(v){if(!y)return s[0].required||e.ANull;h=o(y,h)}a=l(d,h,y)}return s[0].required=a}),t.registerPlugin("node",function(t,n){function o(e){return/\.js$/g.test(e.name)&&e.ast&&e.ast.environments?e.ast.environments.node:!1}return t._node={modules:Object.create(null),options:n||{},currentFile:null,currentRequires:[],currentOrigin:null,server:t},t.on("beforeLoad",function(e){o(e)&&(this._node.currentFile=p(t,e.name),this._node.currentOrigin=e.name,this._node.currentRequires=[],e.scope=i(e.scope,this._node.currentOrigin,e.ast))}),t.on("afterLoad",function(e){if(o(e)){var t=a(this._node,this._node.currentFile);t.origin=this._node.currentOrigin,e.scope.exports.propagate(t),this._node.currentFile=null,this._node.currentOrigin=null}}),t.on("reset",function(){this._node.modules=Object.create(null)}),{defs:v,passes:{preCondenseReach:d,postLoadDef:u,completion:f,typeAt:h,postParse:function(n){r.doPostParse(t,n,e.cx().definitions)},preInfer:function(){r.doPreInfer(t)}}}}),t.defineQueryType("node_exports",{takesFile:!0,run:function(r,n,o){function s(o){var s={},a=o.getType(!1);s.type=e.toString(o,3);var i=o.doc||a&&a.doc,l=o.url||a&&a.url;i&&(s.doc=i),l&&(s.url=l);var c=t.getSpan(o)||a&&t.getSpan(a);return c&&t.storeSpan(r,n,c,s),s}var a=r._node.modules[p(r,o.name)];if(!a)return{};var i=a.getObjType(!1),l=s(a);if(i instanceof e.Obj){var c=l.props={};for(var d in i.props)c[d]=s(i.props[d])}return l}});var v={"!name":"node","!define":{require:{"!type":"fn(id: string) -> !custom:nodeRequire",resolve:{"!type":"fn() -> string","!url":"http://nodejs.org/api/globals.html#globals_require_resolve","!doc":"Use the internal require() machinery to look up the location of a module, but rather than loading the module, just return the resolved filename."},cache:{"!url":"http://nodejs.org/api/globals.html#globals_require_cache","!doc":"Modules are cached in this object when they are required. By deleting a key value from this object, the next require will reload the module."},extensions:{"!url":"http://nodejs.org/api/globals.html#globals_require_extensions","!doc":"Instruct require on how to handle certain file extensions."},"!url":"http://nodejs.org/api/globals.html#globals_require","!doc":"To require modules."},Module:{"!type":"fn()",prototype:{exports:{"!type":"?","!url":"http://nodejs.org/api/modules.html#modules_module_exports","!doc":"The exports object is created by the Module system. Sometimes this is not acceptable, many want their module to be an instance of some class. To do this assign the desired export object to module.exports. For example suppose we were making a module called a.js"},require:{"!type":"require","!url":"http://nodejs.org/api/modules.html#modules_module_require_id","!doc":"The module.require method provides a way to load a module as if require() was called from the original module."},id:{"!type":"string","!url":"http://nodejs.org/api/modules.html#modules_module_id","!doc":"The identifier for the module. Typically this is the fully resolved filename."},filename:{"!type":"string","!url":"http://nodejs.org/api/modules.html#modules_module_filename","!doc":"The fully resolved filename to the module."},loaded:{"!type":"bool","!url":"http://nodejs.org/api/modules.html#modules_module_loaded","!doc":"Whether or not the module is done loading, or is in the process of loading."},parent:{"!type":"+Module","!url":"http://nodejs.org/api/modules.html#modules_module_parent","!doc":"The module that required this one."},children:{"!type":"[+Module]","!url":"http://nodejs.org/api/modules.html#modules_module_children","!doc":"The module objects required by this one."}}},events:{EventEmitter:{prototype:{addListener:{"!type":"fn(event: string, listener: fn())","!url":"http://nodejs.org/api/events.html#events_emitter_addlistener_event_listener","!doc":"Adds a listener to the end of the listeners array for the specified event."},on:{"!type":"fn(event: string, listener: fn())","!url":"http://nodejs.org/api/events.html#events_emitter_on_event_listener","!doc":"Adds a listener to the end of the listeners array for the specified event."},once:{"!type":"fn(event: string, listener: fn())","!url":"http://nodejs.org/api/events.html#events_emitter_once_event_listener","!doc":"Adds a one time listener for the event. This listener is invoked only the next time the event is fired, after which it is removed."},removeListener:{"!type":"fn(event: string, listener: fn())","!url":"http://nodejs.org/api/events.html#events_emitter_removelistener_event_listener","!doc":"Remove a listener from the listener array for the specified event. Caution: changes array indices in the listener array behind the listener."},removeAllListeners:{"!type":"fn(event: string)","!url":"http://nodejs.org/api/events.html#events_emitter_removealllisteners_event","!doc":"Removes all listeners, or those of the specified event."},setMaxListeners:{"!type":"fn(n: number)","!url":"http://nodejs.org/api/events.html#events_emitter_setmaxlisteners_n","!doc":"By default EventEmitters will print a warning if more than 10 listeners are added for a particular event. This is a useful default which helps finding memory leaks. Obviously not all Emitters should be limited to 10. This function allows that to be increased. Set to zero for unlimited."},listeners:{"!type":"fn(event: string) -> [fn()]","!url":"http://nodejs.org/api/events.html#events_emitter_listeners_event","!doc":"Returns an array of listeners for the specified event."},emit:{"!type":"fn(event: string)","!url":"http://nodejs.org/api/events.html#events_emitter_emit_event_arg1_arg2","!doc":"Execute each of the listeners in order with the supplied arguments."}},"!url":"http://nodejs.org/api/events.html#events_class_events_eventemitter","!doc":"To access the EventEmitter class, require('events').EventEmitter."}},stream:{"!type":"fn()",prototype:{"!proto":"events.EventEmitter.prototype",pipe:{"!type":"fn(destination: +stream.Writable, options?: ?)","!url":"http://nodejs.org/api/stream.html#stream_readable_pipe_destination_options","!doc":"Connects this readable stream to destination WriteStream. Incoming data on this stream gets written to destination. Properly manages back-pressure so that a slow destination will not be overwhelmed by a fast readable stream."}},Writable:{"!type":"fn(options?: ?)",prototype:{"!proto":"stream.prototype",write:{"!type":"fn(chunk: +Buffer, encoding?: string, callback?: fn()) -> bool","!url":"http://nodejs.org/api/stream.html#stream_writable_write_chunk_encoding_callback_1","!doc":"Writes chunk to the stream. Returns true if the data has been flushed to the underlying resource. Returns false to indicate that the buffer is full, and the data will be sent out in the future. The 'drain' event will indicate when the buffer is empty again."},end:{"!type":"fn(chunk: +Buffer, encoding?: string, callback?: fn()) -> bool","!url":"http://nodejs.org/api/stream.html#stream_writable_end_chunk_encoding_callback","!doc":"Call this method to signal the end of the data being written to the stream."}},"!url":"http://nodejs.org/api/stream.html#stream_class_stream_writable","!doc":"A Writable Stream has the following methods, members, and events."},Readable:{"!type":"fn(options?: ?)",prototype:{"!proto":"stream.prototype",setEncoding:{"!type":"fn(encoding: string)","!url":"http://nodejs.org/api/stream.html#stream_readable_setencoding_encoding","!doc":"Makes the 'data' event emit a string instead of a Buffer. encoding can be 'utf8', 'utf16le' ('ucs2'), 'ascii', or 'hex'."},pause:{"!type":"fn()","!url":"http://nodejs.org/api/stream.html#stream_readable_pause","!doc":"Switches the readable stream into \"old mode\", where data is emitted using a 'data' event rather than being buffered for consumption via the read() method."},resume:{"!type":"fn()","!url":"http://nodejs.org/api/stream.html#stream_readable_resume","!doc":"Switches the readable stream into \"old mode\", where data is emitted using a 'data' event rather than being buffered for consumption via the read() method."},destroy:"fn()",unpipe:{"!type":"fn(dest?: +stream.Writable)","!url":"http://nodejs.org/api/stream.html#stream_readable_unpipe_destination","!doc":"Undo a previously established pipe(). If no destination is provided, then all previously established pipes are removed."},push:{"!type":"fn(chunk: +Buffer) -> bool","!url":"http://nodejs.org/api/stream.html#stream_readable_push_chunk","!doc":"Explicitly insert some data into the read queue. If called with null, will signal the end of the data."},unshift:{"!type":"fn(chunk: +Buffer) -> bool","!url":"http://nodejs.org/api/stream.html#stream_readable_unshift_chunk","!doc":"This is the corollary of readable.push(chunk). Rather than putting the data at the end of the read queue, it puts it at the front of the read queue."},wrap:{"!type":"fn(stream: ?) -> +stream.Readable","!url":"http://nodejs.org/api/stream.html#stream_readable_wrap_stream","!doc":"If you are using an older Node library that emits 'data' events and has a pause() method that is advisory only, then you can use the wrap() method to create a Readable stream that uses the old stream as its data source."},read:{"!type":"fn(size?: number) -> +Buffer","!url":"http://nodejs.org/api/stream.html#stream_readable_read_size_1","!doc":"Call this method to consume data once the 'readable' event is emitted."}},"!url":"http://nodejs.org/api/stream.html#stream_class_stream_readable","!doc":"A Readable Stream has the following methods, members, and events."},Duplex:{"!type":"fn(options?: ?)",prototype:{"!proto":"stream.Readable.prototype",write:"fn(chunk: +Buffer, encoding?: string, callback?: fn()) -> bool",end:"fn(chunk: +Buffer, encoding?: string, callback?: fn()) -> bool"},"!url":"http://nodejs.org/api/stream.html#stream_class_stream_duplex","!doc":'A "duplex" stream is one that is both Readable and Writable, such as a TCP socket connection.'},Transform:{"!type":"fn(options?: ?)",prototype:{"!proto":"stream.Duplex.prototype"},"!url":"http://nodejs.org/api/stream.html#stream_class_stream_transform","!doc":'A "transform" stream is a duplex stream where the output is causally connected in some way to the input, such as a zlib stream or a crypto stream.'},PassThrough:"stream.Transform","!url":"http://nodejs.org/api/stream.html#stream_stream","!doc":"A stream is an abstract interface implemented by various objects in Node. For example a request to an HTTP server is a stream, as is stdout. Streams are readable, writable, or both. All streams are instances of EventEmitter"},querystring:{stringify:{"!type":"fn(obj: ?, sep?: string, eq?: string) -> string","!url":"http://nodejs.org/api/querystring.html#querystring_querystring_stringify_obj_sep_eq","!doc":"Serialize an object to a query string. Optionally override the default separator ('&') and assignment ('=') characters."},parse:{"!type":"fn(str: string, sep?: string, eq?: string, options?: ?) -> ?","!url":"http://nodejs.org/api/querystring.html#querystring_querystring_parse_str_sep_eq_options","!doc":"Deserialize a query string to an object. Optionally override the default separator ('&') and assignment ('=') characters."},escape:{"!type":"fn(string) -> string","!url":"http://nodejs.org/api/querystring.html#querystring_querystring_escape","!doc":"The escape function used by querystring.stringify, provided so that it could be overridden if necessary."},unescape:{"!type":"fn(string) -> string","!url":"http://nodejs.org/api/querystring.html#querystring_querystring_unescape","!doc":"The unescape function used by querystring.parse, provided so that it could be overridden if necessary."}},http:{STATUS_CODES:{},createServer:{"!type":"fn(listener?: fn(request: +http.IncomingMessage, response: +http.ServerResponse)) -> +http.Server","!url":"http://nodejs.org/api/http.html#http_http_createserver_requestlistener","!doc":"Returns a new web server object."},Server:{"!type":"fn()",prototype:{"!proto":"events.EventEmitter.prototype",listen:{"!type":"fn(port: number, hostname?: string, backlog?: number, callback?: fn())","!url":"http://nodejs.org/api/http.html#http_server_listen_port_hostname_backlog_callback","!doc":"Begin accepting connections on the specified port and hostname. If the hostname is omitted, the server will accept connections directed to any IPv4 address (INADDR_ANY)."},close:{"!type":"fn(callback?: ?)","!url":"http://nodejs.org/api/http.html#http_server_close_callback","!doc":"Stops the server from accepting new connections."},maxHeadersCount:{"!type":"number","!url":"http://nodejs.org/api/http.html#http_server_maxheaderscount","!doc":"Limits maximum incoming headers count, equal to 1000 by default. If set to 0 - no limit will be applied."},setTimeout:{"!type":"fn(timeout: number, callback?: fn())","!url":"http://nodejs.org/api/http.html#http_server_settimeout_msecs_callback","!doc":"Sets the timeout value for sockets, and emits a 'timeout' event on the Server object, passing the socket as an argument, if a timeout occurs."},timeout:{"!type":"number","!url":"http://nodejs.org/api/http.html#http_server_timeout","!doc":"The number of milliseconds of inactivity before a socket is presumed to have timed out."}},"!url":"http://nodejs.org/api/http.html#http_class_http_server","!doc":"Class for HTTP server objects."},ServerResponse:{"!type":"fn()",prototype:{"!proto":"stream.Writable.prototype",writeContinue:{"!type":"fn()","!url":"http://nodejs.org/api/http.html#http_response_writecontinue","!doc":"Sends a HTTP/1.1 100 Continue message to the client, indicating that the request body should be sent."},writeHead:{"!type":"fn(statusCode: number, headers?: ?)","!url":"http://nodejs.org/api/http.html#http_response_writehead_statuscode_reasonphrase_headers","!doc":"Sends a response header to the request. The status code is a 3-digit HTTP status code, like 404. The last argument, headers, are the response headers. Optionally one can give a human-readable reasonPhrase as the second argument."},setTimeout:{"!type":"fn(timeout: number, callback?: fn())","!url":"http://nodejs.org/api/http.html#http_response_settimeout_msecs_callback","!doc":"Sets the Socket's timeout value to msecs. If a callback is provided, then it is added as a listener on the 'timeout' event on the response object."},statusCode:{"!type":"number","!url":"http://nodejs.org/api/http.html#http_response_statuscode","!doc":"When using implicit headers (not calling response.writeHead() explicitly), this property controls the status code that will be sent to the client when the headers get flushed."},setHeader:{"!type":"fn(name: string, value: string)","!url":"http://nodejs.org/api/http.html#http_response_setheader_name_value","!doc":"Sets a single header value for implicit headers. If this header already exists in the to-be-sent headers, its value will be replaced. Use an array of strings here if you need to send multiple headers with the same name."},headersSent:{"!type":"bool","!url":"http://nodejs.org/api/http.html#http_response_headerssent","!doc":"Boolean (read-only). True if headers were sent, false otherwise."},sendDate:{"!type":"bool","!url":"http://nodejs.org/api/http.html#http_response_senddate","!doc":"When true, the Date header will be automatically generated and sent in the response if it is not already present in the headers. Defaults to true."},getHeader:{"!type":"fn(name: string) -> string","!url":"http://nodejs.org/api/http.html#http_response_getheader_name","!doc":"Reads out a header that's already been queued but not sent to the client. Note that the name is case insensitive. This can only be called before headers get implicitly flushed."},removeHeader:{"!type":"fn(name: string)","!url":"http://nodejs.org/api/http.html#http_response_removeheader_name","!doc":"Removes a header that's queued for implicit sending."},addTrailers:{"!type":"fn(headers: ?)","!url":"http://nodejs.org/api/http.html#http_response_addtrailers_headers","!doc":"This method adds HTTP trailing headers (a header but at the end of the message) to the response."}},"!url":"http://nodejs.org/api/http.html#http_class_http_serverresponse","!doc":"This object is created internally by a HTTP server--not by the user. It is passed as the second parameter to the 'request' event."},request:{"!type":"fn(options: ?, callback?: fn(res: +http.IncomingMessage)) -> +http.ClientRequest","!url":"http://nodejs.org/api/http.html#http_http_request_options_callback","!doc":"Node maintains several connections per server to make HTTP requests. This function allows one to transparently issue requests."},get:{"!type":"fn(options: ?, callback?: fn(res: +http.IncomingMessage)) -> +http.ClientRequest","!url":"http://nodejs.org/api/http.html#http_http_get_options_callback","!doc":"Since most requests are GET requests without bodies, Node provides this convenience method. The only difference between this method and http.request() is that it sets the method to GET and calls req.end() automatically."},globalAgent:{"!type":"+http.Agent","!url":"http://nodejs.org/api/http.html#http_http_globalagent","!doc":"Global instance of Agent which is used as the default for all http client requests."},Agent:{"!type":"fn()",prototype:{maxSockets:{"!type":"number","!url":"http://nodejs.org/api/http.html#http_agent_maxsockets","!doc":"By default set to 5. Determines how many concurrent sockets the agent can have open per host."},sockets:{"!type":"[+net.Socket]","!url":"http://nodejs.org/api/http.html#http_agent_sockets","!doc":"An object which contains arrays of sockets currently in use by the Agent. Do not modify."},requests:{"!type":"[+http.ClientRequest]","!url":"http://nodejs.org/api/http.html#http_agent_requests","!doc":"An object which contains queues of requests that have not yet been assigned to sockets. Do not modify."}},"!url":"http://nodejs.org/api/http.html#http_class_http_agent","!doc":"In node 0.5.3+ there is a new implementation of the HTTP Agent which is used for pooling sockets used in HTTP client requests."},ClientRequest:{"!type":"fn()",prototype:{"!proto":"stream.Writable.prototype",abort:{"!type":"fn()","!url":"http://nodejs.org/api/http.html#http_request_abort","!doc":"Aborts a request. (New since v0.3.8.)"},setTimeout:{"!type":"fn(timeout: number, callback?: fn())","!url":"http://nodejs.org/api/http.html#http_request_settimeout_timeout_callback","!doc":"Once a socket is assigned to this request and is connected socket.setTimeout() will be called."},setNoDelay:{"!type":"fn(noDelay?: fn())","!url":"http://nodejs.org/api/http.html#http_request_setnodelay_nodelay","!doc":"Once a socket is assigned to this request and is connected socket.setNoDelay() will be called."},setSocketKeepAlive:{"!type":"fn(enable?: bool, initialDelay?: number)","!url":"http://nodejs.org/api/http.html#http_request_setsocketkeepalive_enable_initialdelay","!doc":"Once a socket is assigned to this request and is connected socket.setKeepAlive() will be called."}},"!url":"http://nodejs.org/api/http.html#http_class_http_clientrequest","!doc":"This object is created internally and returned from http.request(). It represents an in-progress request whose header has already been queued. The header is still mutable using the setHeader(name, value), getHeader(name), removeHeader(name) API. The actual header will be sent along with the first data chunk or when closing the connection."},IncomingMessage:{"!type":"fn()",prototype:{"!proto":"stream.Readable.prototype",httpVersion:{"!type":"string","!url":"http://nodejs.org/api/http.html#http_message_httpversion","!doc":"In case of server request, the HTTP version sent by the client. In the case of client response, the HTTP version of the connected-to server. Probably either '1.1' or '1.0'."},headers:{"!type":"?","!url":"http://nodejs.org/api/http.html#http_message_headers","!doc":"The request/response headers object."},trailers:{"!type":"?","!url":"http://nodejs.org/api/http.html#http_message_trailers","!doc":"The request/response trailers object. Only populated after the 'end' event."},setTimeout:{"!type":"fn(timeout: number, callback?: fn())","!url":"http://nodejs.org/api/http.html#http_message_settimeout_msecs_callback","!doc":"Calls message.connection.setTimeout(msecs, callback)."},setEncoding:{"!type":"fn(encoding?: string)","!url":"http://nodejs.org/api/http.html#http_message_setencoding_encoding","!doc":"Set the encoding for data emitted by the 'data' event."},pause:{"!type":"fn()","!url":"http://nodejs.org/api/http.html#http_message_pause","!doc":"Pauses request/response from emitting events. Useful to throttle back a download."},resume:{"!type":"fn()","!url":"http://nodejs.org/api/http.html#http_message_resume","!doc":"Resumes a paused request/response."},method:{"!type":"string","!url":"http://nodejs.org/api/http.html#http_message_method","!doc":"Only valid for request obtained from http.Server."},url:{"!type":"string","!url":"http://nodejs.org/api/http.html#http_message_url","!doc":"Only valid for request obtained from http.Server."},statusCode:{"!type":"number","!url":"http://nodejs.org/api/http.html#http_message_statuscode","!doc":"Only valid for response obtained from http.ClientRequest."},socket:{"!type":"+net.Socket","!url":"http://nodejs.org/api/http.html#http_message_socket","!doc":"The net.Socket object associated with the connection."}},"!url":"http://nodejs.org/api/http.html#http_http_incomingmessage","!doc":"An IncomingMessage object is created by http.Server or http.ClientRequest and passed as the first argument to the 'request' and 'response' event respectively. It may be used to access response status, headers and data."}},https:{Server:"http.Server",createServer:{"!type":"fn(listener?: fn(request: +http.IncomingMessage, response: +http.ServerResponse)) -> +https.Server","!url":"http://nodejs.org/api/https.html#https_https_createserver_options_requestlistener","!doc":"Returns a new HTTPS web server object. The options is similar to tls.createServer(). The requestListener is a function which is automatically added to the 'request' event."},request:{"!type":"fn(options: ?, callback?: fn(res: +http.IncomingMessage)) -> +http.ClientRequest","!url":"http://nodejs.org/api/https.html#https_https_request_options_callback","!doc":"Makes a request to a secure web server."},get:{"!type":"fn(options: ?, callback?: fn(res: +http.IncomingMessage)) -> +http.ClientRequest","!url":"http://nodejs.org/api/https.html#https_https_get_options_callback","!doc":"Like http.get() but for HTTPS."},Agent:"http.Agent",globalAgent:"http.globalAgent"},cluster:{"!proto":"events.EventEmitter.prototype",settings:{exec:"string",args:"[string]",silent:"bool","!url":"http://nodejs.org/api/cluster.html#cluster_cluster_settings","!doc":"All settings set by the .setupMaster is stored in this settings object. This object is not supposed to be changed or set manually, by you."},Worker:{"!type":"fn()",prototype:{"!proto":"events.EventEmitter.prototype",id:{"!type":"string","!url":"http://nodejs.org/api/cluster.html#cluster_worker_id","!doc":"Each new worker is given its own unique id, this id is stored in the id."},process:{"!type":"+child_process.ChildProcess","!url":"http://nodejs.org/api/cluster.html#cluster_worker_process","!doc":"All workers are created using child_process.fork(), the returned object from this function is stored in process."},suicide:{"!type":"bool","!url":"http://nodejs.org/api/cluster.html#cluster_worker_suicide","!doc":"This property is a boolean. It is set when a worker dies after calling .kill() or immediately after calling the .disconnect() method. Until then it is undefined."},send:{"!type":"fn(message: ?, sendHandle?: ?)","!url":"http://nodejs.org/api/cluster.html#cluster_worker_send_message_sendhandle","!doc":"This function is equal to the send methods provided by child_process.fork(). In the master you should use this function to send a message to a specific worker. However in a worker you can also use process.send(message), since this is the same function."},destroy:"fn()",disconnect:{"!type":"fn()","!url":"http://nodejs.org/api/cluster.html#cluster_worker_disconnect","!doc":"When calling this function the worker will no longer accept new connections, but they will be handled by any other listening worker. Existing connection will be allowed to exit as usual. When no more connections exist, the IPC channel to the worker will close allowing it to die graceful. When the IPC channel is closed the disconnect event will emit, this is then followed by the exit event, there is emitted when the worker finally die."},kill:{"!type":"fn(signal?: string)","!url":"http://nodejs.org/api/cluster.html#cluster_worker_kill_signal_sigterm","!doc":"This function will kill the worker, and inform the master to not spawn a new worker. The boolean suicide lets you distinguish between voluntary and accidental exit."}},"!url":"http://nodejs.org/api/cluster.html#cluster_class_worker","!doc":"A Worker object contains all public information and method about a worker. In the master it can be obtained using cluster.workers. In a worker it can be obtained using cluster.worker."},isMaster:{"!type":"bool","!url":"http://nodejs.org/api/cluster.html#cluster_cluster_ismaster","!doc":"True if the process is a master. This is determined by the process.env.NODE_UNIQUE_ID. If process.env.NODE_UNIQUE_ID is undefined, then isMaster is true."},isWorker:{"!type":"bool","!url":"http://nodejs.org/api/cluster.html#cluster_cluster_isworker","!doc":"This boolean flag is true if the process is a worker forked from a master. If the process.env.NODE_UNIQUE_ID is set to a value, then isWorker is true."},setupMaster:{"!type":"fn(settings?: cluster.settings)","!url":"http://nodejs.org/api/cluster.html#cluster_cluster_setupmaster_settings","!doc":"setupMaster is used to change the default 'fork' behavior. The new settings are effective immediately and permanently, they cannot be changed later on."},fork:{"!type":"fn(env?: ?) -> +cluster.Worker","!url":"http://nodejs.org/api/cluster.html#cluster_cluster_fork_env","!doc":"Spawn a new worker process. This can only be called from the master process."},disconnect:{"!type":"fn(callback?: fn())","!url":"http://nodejs.org/api/cluster.html#cluster_cluster_disconnect_callback","!doc":"When calling this method, all workers will commit a graceful suicide. When they are disconnected all internal handlers will be closed, allowing the master process to die graceful if no other event is waiting."},worker:{"!type":"+cluster.Worker","!url":"http://nodejs.org/api/cluster.html#cluster_cluster_worker","!doc":"A reference to the current worker object. Not available in the master process."},workers:{"!type":"[+cluster.Worker]","!url":"http://nodejs.org/api/cluster.html#cluster_cluster_workers","!doc":"A hash that stores the active worker objects, keyed by id field. Makes it easy to loop through all the workers. It is only available in the master process."},"!url":"http://nodejs.org/api/cluster.html#cluster_cluster","!doc":"A single instance of Node runs in a single thread. To take advantage of multi-core systems the user will sometimes want to launch a cluster of Node processes to handle the load."},zlib:{Zlib:{"!type":"fn()",prototype:{"!proto":"stream.Duplex.prototype",flush:{"!type":"fn(callback: fn())","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_flush_callback","!doc":"Flush pending data. Don't call this frivolously, premature flushes negatively impact the effectiveness of the compression algorithm."},reset:{"!type":"fn()","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_reset","!doc":"Reset the compressor/decompressor to factory defaults. Only applicable to the inflate and deflate algorithms."}},"!url":"http://nodejs.org/api/zlib.html#zlib_class_zlib_zlib","!doc":"Not exported by the zlib module. It is documented here because it is the base class of the compressor/decompressor classes."},deflate:{"!type":"fn(buf: +Buffer, callback: fn())","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_deflate_buf_callback","!doc":"Compress a string with Deflate."},deflateRaw:{"!type":"fn(buf: +Buffer, callback: fn())","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_deflateraw_buf_callback","!doc":"Compress a string with DeflateRaw."},gzip:{"!type":"fn(buf: +Buffer, callback: fn())","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_gzip_buf_callback","!doc":"Compress a string with Gzip."},gunzip:{"!type":"fn(buf: +Buffer, callback: fn())","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_gunzip_buf_callback","!doc":"Decompress a raw Buffer with Gunzip."},inflate:{"!type":"fn(buf: +Buffer, callback: fn())","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_inflate_buf_callback","!doc":"Decompress a raw Buffer with Inflate."},inflateRaw:{"!type":"fn(buf: +Buffer, callback: fn())","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_inflateraw_buf_callback","!doc":"Decompress a raw Buffer with InflateRaw."},unzip:{"!type":"fn(buf: +Buffer, callback: fn())","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_unzip_buf_callback","!doc":"Decompress a raw Buffer with Unzip."},Gzip:{"!type":"fn()","!url":"http://nodejs.org/api/zlib.html#zlib_class_zlib_gzip","!doc":"Compress data using gzip.",prototype:{"!proto:":"zlib.Zlib.prototype"}},createGzip:{"!type":"fn(options: ?) -> +zlib.Zlib","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_creategzip_options","!doc":"Returns a new Gzip object with an options."},Gunzip:{"!type":"fn()","!url":"http://nodejs.org/api/zlib.html#zlib_class_zlib_gunzip","!doc":"Decompress a gzip stream.",prototype:{"!proto:":"zlib.Zlib.prototype"}},createGunzip:{"!type":"fn(options: ?) -> +zlib.Gunzip","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_creategunzip_options","!doc":"Returns a new Gunzip object with an options."},Deflate:{"!type":"fn()","!url":"http://nodejs.org/api/zlib.html#zlib_class_zlib_deflate","!doc":"Compress data using deflate.",prototype:{"!proto:":"zlib.Zlib.prototype"}},createDeflate:{"!type":"fn(options: ?) -> +zlib.Deflate","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_createdeflate_options","!doc":"Returns a new Deflate object with an options."},Inflate:{"!type":"fn()","!url":"http://nodejs.org/api/zlib.html#zlib_class_zlib_inflate","!doc":"Decompress a deflate stream.",prototype:{"!proto:":"zlib.Zlib.prototype"}},createInflate:{"!type":"fn(options: ?) -> +zlib.Inflate","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_createinflate_options","!doc":"Returns a new Inflate object with an options."},InflateRaw:{"!type":"fn()","!url":"http://nodejs.org/api/zlib.html#zlib_class_zlib_inflateraw","!doc":"Decompress a raw deflate stream.",prototype:{"!proto:":"zlib.Zlib.prototype"}},createInflateRaw:{"!type":"fn(options: ?) -> +zlib.InflateRaw","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_createinflateraw_options","!doc":"Returns a new InflateRaw object with an options."},DeflateRaw:{"!type":"fn()","!url":"http://nodejs.org/api/zlib.html#zlib_class_zlib_deflateraw","!doc":"Compress data using deflate, and do not append a zlib header.",prototype:{"!proto:":"zlib.Zlib.prototype"}},createDeflateRaw:{"!type":"fn(options: ?) -> +zlib.DeflateRaw","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_createdeflateraw_options","!doc":"Returns a new DeflateRaw object with an options."},Unzip:{"!type":"fn()","!url":"http://nodejs.org/api/zlib.html#zlib_class_zlib_unzip","!doc":"Decompress either a Gzip- or Deflate-compressed stream by auto-detecting the header.",prototype:{"!proto:":"zlib.Zlib.prototype"}},createUnzip:{"!type":"fn(options: ?) -> +zlib.Unzip","!url":"http://nodejs.org/api/zlib.html#zlib_zlib_createunzip_options","!doc":"Returns a new Unzip object with an options."},Z_NO_FLUSH:"number",Z_PARTIAL_FLUSH:"number",Z_SYNC_FLUSH:"number",Z_FULL_FLUSH:"number",Z_FINISH:"number",Z_BLOCK:"number",Z_TREES:"number",Z_OK:"number",Z_STREAM_END:"number",Z_NEED_DICT:"number",Z_ERRNO:"number",Z_STREAM_ERROR:"number",Z_DATA_ERROR:"number",Z_MEM_ERROR:"number",Z_BUF_ERROR:"number",Z_VERSION_ERROR:"number",Z_NO_COMPRESSION:"number",Z_BEST_SPEED:"number",Z_BEST_COMPRESSION:"number",Z_DEFAULT_COMPRESSION:"number",Z_FILTERED:"number",Z_HUFFMAN_ONLY:"number",Z_RLE:"number",Z_FIXED:"number",Z_DEFAULT_STRATEGY:"number",Z_BINARY:"number",Z_TEXT:"number",Z_ASCII:"number",Z_UNKNOWN:"number",Z_DEFLATED:"number",Z_NULL:"number"},os:{tmpdir:{"!type":"fn() -> string","!url":"http://nodejs.org/api/os.html#os_os_tmpdir","!doc":"Returns the operating system's default directory for temp files."},endianness:{"!type":"fn() -> string","!url":"http://nodejs.org/api/os.html#os_os_endianness","!doc":'Returns the endianness of the CPU. Possible values are "BE" or "LE".'},hostname:{"!type":"fn() -> string","!url":"http://nodejs.org/api/os.html#os_os_hostname","!doc":"Returns the hostname of the operating system."},type:{"!type":"fn() -> string","!url":"http://nodejs.org/api/os.html#os_os_type","!doc":"Returns the operating system name."},platform:{"!type":"fn() -> string","!url":"http://nodejs.org/api/os.html#os_os_platform","!doc":"Returns the operating system platform."},arch:{"!type":"fn() -> string","!url":"http://nodejs.org/api/os.html#os_os_arch","!doc":"Returns the operating system CPU architecture."},release:{"!type":"fn() -> string","!url":"http://nodejs.org/api/os.html#os_os_release","!doc":"Returns the operating system release."},uptime:{"!type":"fn() -> number","!url":"http://nodejs.org/api/os.html#os_os_uptime","!doc":"Returns the system uptime in seconds."},loadavg:{"!type":"fn() -> [number]","!url":"http://nodejs.org/api/os.html#os_os_loadavg","!doc":"Returns an array containing the 1, 5, and 15 minute load averages."},totalmem:{"!type":"fn() -> number","!url":"http://nodejs.org/api/os.html#os_os_totalmem","!doc":"Returns the total amount of system memory in bytes."},freemem:{"!type":"fn() -> number","!url":"http://nodejs.org/api/os.html#os_os_freemem","!doc":"Returns the amount of free system memory in bytes."},cpus:{"!type":"fn() -> [os.cpuSpec]","!url":"http://nodejs.org/api/os.html#os_os_cpus","!doc":"Returns an array of objects containing information about each CPU/core installed: model, speed (in MHz), and times (an object containing the number of milliseconds the CPU/core spent in: user, nice, sys, idle, and irq)."},networkInterfaces:{"!type":"fn() -> ?","!url":"http://nodejs.org/api/os.html#os_os_networkinterfaces","!doc":"Get a list of network interfaces."},EOL:{"!type":"string","!url":"http://nodejs.org/api/os.html#os_os_eol","!doc":"A constant defining the appropriate End-of-line marker for the operating system."}},punycode:{decode:{"!type":"fn(string: string) -> string","!url":"http://nodejs.org/api/punycode.html#punycode_punycode_decode_string","!doc":"Converts a Punycode string of ASCII code points to a string of Unicode code points."},encode:{"!type":"fn(string: string) -> string","!url":"http://nodejs.org/api/punycode.html#punycode_punycode_encode_string","!doc":"Converts a string of Unicode code points to a Punycode string of ASCII code points."},toUnicode:{"!type":"fn(domain: string) -> string","!url":"http://nodejs.org/api/punycode.html#punycode_punycode_tounicode_domain","!doc":"Converts a Punycode string representing a domain name to Unicode. Only the Punycoded parts of the domain name will be converted, i.e. it doesn't matter if you call it on a string that has already been converted to Unicode."},toASCII:{"!type":"fn(domain: string) -> string","!url":"http://nodejs.org/api/punycode.html#punycode_punycode_toascii_domain","!doc":"Converts a Unicode string representing a domain name to Punycode. Only the non-ASCII parts of the domain name will be converted, i.e. it doesn't matter if you call it with a domain that's already in ASCII."},ucs2:{decode:{"!type":"fn(string: string) -> string","!url":"http://nodejs.org/api/punycode.html#punycode_punycode_ucs2_decode_string","!doc":"Creates an array containing the decimal code points of each Unicode character in the string. While JavaScript uses UCS-2 internally, this function will convert a pair of surrogate halves (each of which UCS-2 exposes as separate characters) into a single code point, matching UTF-16."},encode:{"!type":"fn(codePoints: [number]) -> string","!url":"http://nodejs.org/api/punycode.html#punycode_punycode_ucs2_encode_codepoints","!doc":"Creates a string based on an array of decimal code points."}},version:{"!type":"?","!url":"http://nodejs.org/api/punycode.html#punycode_punycode_version","!doc":"A string representing the current Punycode.js version number."}},repl:{start:{"!type":"fn(options: ?) -> +events.EventEmitter","!url":"http://nodejs.org/api/repl.html#repl_repl_start_options","!doc":"Returns and starts a REPLServer instance."}},readline:{createInterface:{"!type":"fn(options: ?) -> +readline.Interface","!url":"http://nodejs.org/api/readline.html#readline_readline_createinterface_options","!doc":"Creates a readline Interface instance."},Interface:{"!type":"fn()",prototype:{"!proto":"events.EventEmitter.prototype",setPrompt:{"!type":"fn(prompt: string, length: number)","!url":"http://nodejs.org/api/readline.html#readline_rl_setprompt_prompt_length","!doc":"Sets the prompt, for example when you run node on the command line, you see > , which is node's prompt."},prompt:{"!type":"fn(preserveCursor?: bool)","!url":"http://nodejs.org/api/readline.html#readline_rl_prompt_preservecursor","!doc":"Readies readline for input from the user, putting the current setPrompt options on a new line, giving the user a new spot to write. Set preserveCursor to true to prevent the cursor placement being reset to 0."},question:{"!type":"fn(query: string, callback: fn())","!url":"http://nodejs.org/api/readline.html#readline_rl_question_query_callback","!doc":"Prepends the prompt with query and invokes callback with the user's response. Displays the query to the user, and then invokes callback with the user's response after it has been typed."},pause:{"!type":"fn()","!url":"http://nodejs.org/api/readline.html#readline_rl_pause","!doc":"Pauses the readline input stream, allowing it to be resumed later if needed."},resume:{"!type":"fn()","!url":"http://nodejs.org/api/readline.html#readline_rl_resume","!doc":"Resumes the readline input stream."},close:{"!type":"fn()","!url":"http://nodejs.org/api/readline.html#readline_rl_close","!doc":'Closes the Interface instance, relinquishing control on the input and output streams. The "close" event will also be emitted.'},write:{"!type":"fn(data: ?, key?: ?)","!url":"http://nodejs.org/api/readline.html#readline_rl_write_data_key","!doc":"Writes data to output stream. key is an object literal to represent a key sequence; available if the terminal is a TTY."}},"!url":"http://nodejs.org/api/readline.html#readline_class_interface","!doc":"The class that represents a readline interface with an input and output stream."}},vm:{createContext:{"!type":"fn(initSandbox?: ?) -> ?","!url":"http://nodejs.org/api/vm.html#vm_vm_createcontext_initsandbox","!doc":"vm.createContext creates a new context which is suitable for use as the 2nd argument of a subsequent call to vm.runInContext. A (V8) context comprises a global object together with a set of build-in objects and functions. The optional argument initSandbox will be shallow-copied to seed the initial contents of the global object used by the context."},Script:{"!type":"fn()",prototype:{runInThisContext:{"!type":"fn()","!url":"http://nodejs.org/api/vm.html#vm_script_runinthiscontext","!doc":"Similar to vm.runInThisContext but a method of a precompiled Script object. script.runInThisContext runs the code of script and returns the result. Running code does not have access to local scope, but does have access to the global object (v8: in actual context)."},runInNewContext:{"!type":"fn(sandbox?: ?)","!url":"http://nodejs.org/api/vm.html#vm_script_runinnewcontext_sandbox","!doc":"Similar to vm.runInNewContext a method of a precompiled Script object. script.runInNewContext runs the code of script with sandbox as the global object and returns the result. Running code does not have access to local scope. sandbox is optional."}},"!url":"http://nodejs.org/api/vm.html#vm_class_script","!doc":"A class for running scripts. Returned by vm.createScript."},runInThisContext:{"!type":"fn(code: string, filename?: string)","!url":"http://nodejs.org/api/vm.html#vm_vm_runinthiscontext_code_filename","!doc":"vm.runInThisContext() compiles code, runs it and returns the result. Running code does not have access to local scope. filename is optional, it's used only in stack traces."},runInNewContext:{"!type":"fn(code: string, sandbox?: ?, filename?: string)","!url":"http://nodejs.org/api/vm.html#vm_vm_runinnewcontext_code_sandbox_filename","!doc":"vm.runInNewContext compiles code, then runs it in sandbox and returns the result. Running code does not have access to local scope. The object sandbox will be used as the global object for code. sandbox and filename are optional, filename is only used in stack traces."},runInContext:{"!type":"fn(code: string, context: ?, filename?: string)","!url":"http://nodejs.org/api/vm.html#vm_vm_runincontext_code_context_filename","!doc":"vm.runInContext compiles code, then runs it in context and returns the result. A (V8) context comprises a global object, together with a set of built-in objects and functions. Running code does not have access to local scope and the global object held within context will be used as the global object for code. filename is optional, it's used only in stack traces."},createScript:{"!type":"fn(code: string, filename?: string) -> +vm.Script","!url":"http://nodejs.org/api/vm.html#vm_vm_createscript_code_filename","!doc":"createScript compiles code but does not run it. Instead, it returns a vm.Script object representing this compiled code. This script can be run later many times using methods below. The returned script is not bound to any global object. It is bound before each run, just for that run. filename is optional, it's only used in stack traces."}},child_process:{ChildProcess:{"!type":"fn()",prototype:{"!proto":"events.EventEmitter.prototype",stdin:{"!type":"+stream.Writable","!url":"http://nodejs.org/api/child_process.html#child_process_child_stdin","!doc":"A Writable Stream that represents the child process's stdin. Closing this stream via end() often causes the child process to terminate."},stdout:{"!type":"+stream.Readable","!url":"http://nodejs.org/api/child_process.html#child_process_child_stdout","!doc":"A Readable Stream that represents the child process's stdout."},stderr:{"!type":"+stream.Readable","!url":"http://nodejs.org/api/child_process.html#child_process_child_stderr","!doc":"A Readable Stream that represents the child process's stderr."},pid:{"!type":"number","!url":"http://nodejs.org/api/child_process.html#child_process_child_pid","!doc":"The PID of the child process."},kill:{"!type":"fn(signal?: string)","!url":"http://nodejs.org/api/child_process.html#child_process_child_kill_signal","!doc":"Send a signal to the child process. If no argument is given, the process will be sent 'SIGTERM'."},send:{"!type":"fn(message: ?, sendHandle?: ?)","!url":"http://nodejs.org/api/child_process.html#child_process_child_send_message_sendhandle","!doc":"When using child_process.fork() you can write to the child using child.send(message, [sendHandle]) and messages are received by a 'message' event on the child."},disconnect:{"!type":"fn()","!url":"http://nodejs.org/api/child_process.html#child_process_child_disconnect","!doc":"To close the IPC connection between parent and child use the child.disconnect() method. This allows the child to exit gracefully since there is no IPC channel keeping it alive. When calling this method the disconnect event will be emitted in both parent and child, and the connected flag will be set to false. Please note that you can also call process.disconnect() in the child process."}},"!url":"http://nodejs.org/api/child_process.html#child_process_class_childprocess","!doc":"ChildProcess is an EventEmitter."},spawn:{"!type":"fn(command: string, args?: [string], options?: ?) -> +child_process.ChildProcess","!url":"http://nodejs.org/api/child_process.html#child_process_child_process_spawn_command_args_options","!doc":"Launches a new process with the given command, with command line arguments in args. If omitted, args defaults to an empty Array."},exec:{"!type":"fn(command: string, callback: fn(error: ?, stdout: +Buffer, stderr: +Buffer)) -> +child_process.ChildProcess","!url":"http://nodejs.org/api/child_process.html#child_process_child_process_exec_command_options_callback","!doc":"Runs a command in a shell and buffers the output."},execFile:{"!type":"fn(file: string, args: [string], options: ?, callback: fn(error: ?, stdout: +Buffer, stderr: +Buffer)) -> +child_process.ChildProcess","!url":"http://nodejs.org/api/child_process.html#child_process_child_process_execfile_file_args_options_callback","!doc":"This is similar to child_process.exec() except it does not execute a subshell but rather the specified file directly. This makes it slightly leaner than child_process.exec. It has the same options."},fork:{"!type":"fn(modulePath: string, args?: [string], options?: ?) -> +child_process.ChildProcess","!url":"http://nodejs.org/api/child_process.html#child_process_child_process_fork_modulepath_args_options","!doc":"This is a special case of the spawn() functionality for spawning Node processes. In addition to having all the methods in a normal ChildProcess instance, the returned object has a communication channel built-in."}},url:{parse:{"!type":"fn(urlStr: string, parseQueryString?: bool, slashesDenoteHost?: bool) -> url.type","!url":"http://nodejs.org/api/url.html#url_url_parse_urlstr_parsequerystring_slashesdenotehost","!doc":"Take a URL string, and return an object."},format:{"!type":"fn(url: url.type) -> string","!url":"http://nodejs.org/api/url.html#url_url_format_urlobj","!doc":"Take a parsed URL object, and return a formatted URL string."},resolve:{"!type":"fn(from: string, to: string) -> string","!url":"http://nodejs.org/api/url.html#url_url_resolve_from_to","!doc":"Take a base URL, and a href URL, and resolve them as a browser would for an anchor tag."}},dns:{lookup:{"!type":"fn(domain: string, callback: fn(err: +Error, address: string, family: number)) -> string","!url":"http://nodejs.org/api/dns.html#dns_dns_lookup_domain_family_callback","!doc":"Resolves a domain (e.g. 'google.com') into the first found A (IPv4) or AAAA (IPv6) record. The family can be the integer 4 or 6. Defaults to null that indicates both Ip v4 and v6 address family."},resolve:{"!type":"fn(domain: string, callback: fn(err: +Error, addresses: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_resolve_domain_rrtype_callback","!doc":"Resolves a domain (e.g. 'google.com') into an array of the record types specified by rrtype. Valid rrtypes are 'A' (IPV4 addresses, default), 'AAAA' (IPV6 addresses), 'MX' (mail exchange records), 'TXT' (text records), 'SRV' (SRV records), 'PTR' (used for reverse IP lookups), 'NS' (name server records) and 'CNAME' (canonical name records)."},resolve4:{"!type":"fn(domain: string, callback: fn(err: +Error, addresses: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_resolve4_domain_callback","!doc":"The same as dns.resolve(), but only for IPv4 queries (A records). addresses is an array of IPv4 addresses (e.g. ['74.125.79.104', '74.125.79.105', '74.125.79.106'])."},resolve6:{"!type":"fn(domain: string, callback: fn(err: +Error, addresses: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_resolve6_domain_callback","!doc":"The same as dns.resolve4() except for IPv6 queries (an AAAA query)."},resolveMx:{"!type":"fn(domain: string, callback: fn(err: +Error, addresses: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_resolvemx_domain_callback","!doc":"The same as dns.resolve(), but only for mail exchange queries (MX records)."},resolveTxt:{"!type":"fn(domain: string, callback: fn(err: +Error, addresses: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_resolvetxt_domain_callback","!doc":"The same as dns.resolve(), but only for text queries (TXT records). addresses is an array of the text records available for domain (e.g., ['v=spf1 ip4:0.0.0.0 ~all'])."},resolveSrv:{"!type":"fn(domain: string, callback: fn(err: +Error, addresses: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_resolvesrv_domain_callback","!doc":"The same as dns.resolve(), but only for service records (SRV records). addresses is an array of the SRV records available for domain. Properties of SRV records are priority, weight, port, and name (e.g., [{'priority': 10, {'weight': 5, 'port': 21223, 'name': 'service.example.com'}, ...])."},resolveNs:{"!type":"fn(domain: string, callback: fn(err: +Error, addresses: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_resolvens_domain_callback","!doc":"The same as dns.resolve(), but only for name server records (NS records). addresses is an array of the name server records available for domain (e.g., ['ns1.example.com', 'ns2.example.com'])."},resolveCname:{"!type":"fn(domain: string, callback: fn(err: +Error, addresses: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_resolvecname_domain_callback","!doc":"The same as dns.resolve(), but only for canonical name records (CNAME records). addresses is an array of the canonical name records available for domain (e.g., ['bar.example.com'])."},reverse:{"!type":"fn(ip: string, callback: fn(err: +Error, domains: [string])) -> [string]","!url":"http://nodejs.org/api/dns.html#dns_dns_reverse_ip_callback","!doc":"Reverse resolves an ip address to an array of domain names."}},net:{createServer:{"!type":"fn(options?: ?, connectionListener?: fn(socket: +net.Socket)) -> +net.Server","!url":"http://nodejs.org/api/net.html#net_net_createserver_options_connectionlistener","!doc":"Creates a new TCP server. The connectionListener argument is automatically set as a listener for the 'connection' event."},Server:{"!type":"fn()",prototype:{"!proto":"net.Socket.prototype",listen:{"!type":"fn(port: number, hostname?: string, backlog?: number, callback?: fn())","!url":"http://nodejs.org/api/net.html#net_server_listen_port_host_backlog_callback","!doc":"Begin accepting connections on the specified port and host. If the host is omitted, the server will accept connections directed to any IPv4 address (INADDR_ANY). A port value of zero will assign a random port."},close:{"!type":"fn(callback?: fn())","!url":"http://nodejs.org/api/net.html#net_server_close_callback","!doc":"Stops the server from accepting new connections and keeps existing connections. This function is asynchronous, the server is finally closed when all connections are ended and the server emits a 'close' event. Optionally, you can pass a callback to listen for the 'close' event."},maxConnections:{"!type":"number","!url":"http://nodejs.org/api/net.html#net_server_maxconnections","!doc":"Set this property to reject connections when the server's connection count gets high."},getConnections:{"!type":"fn(callback: fn(err: +Error, count: number))","!url":"http://nodejs.org/api/net.html#net_server_getconnections_callback","!doc":"Asynchronously get the number of concurrent connections on the server. Works when sockets were sent to forks."}},"!url":"http://nodejs.org/api/net.html#net_class_net_server","!doc":"This class is used to create a TCP or UNIX server. A server is a net.Socket that can listen for new incoming connections."},Socket:{"!type":"fn(options: ?)",prototype:{"!proto":"events.EventEmitter.prototype",connect:{"!type":"fn(port: number, host?: string, connectionListener?: fn())","!url":"http://nodejs.org/api/net.html#net_socket_connect_port_host_connectlistener","!doc":"Opens the connection for a given socket. If port and host are given, then the socket will be opened as a TCP socket, if host is omitted, localhost will be assumed. If a path is given, the socket will be opened as a unix socket to that path."},bufferSize:{"!type":"number","!url":"http://nodejs.org/api/net.html#net_socket_buffersize","!doc":"net.Socket has the property that socket.write() always works. This is to help users get up and running quickly. The computer cannot always keep up with the amount of data that is written to a socket - the network connection simply might be too slow. Node will internally queue up the data written to a socket and send it out over the wire when it is possible. (Internally it is polling on the socket's file descriptor for being writable)."},setEncoding:{"!type":"fn(encoding?: string)","!url":"http://nodejs.org/api/net.html#net_socket_setencoding_encoding","!doc":"Set the encoding for the socket as a Readable Stream."},write:{"!type":"fn(data: +Buffer, encoding?: string, callback?: fn())","!url":"http://nodejs.org/api/net.html#net_socket_write_data_encoding_callback","!doc":"Sends data on the socket. The second parameter specifies the encoding in the case of a string--it defaults to UTF8 encoding."},end:{"!type":"fn(data?: +Buffer, encoding?: string)","!url":"http://nodejs.org/api/net.html#net_socket_end_data_encoding","!doc":"Half-closes the socket. i.e., it sends a FIN packet. It is possible the server will still send some data."},destroy:{"!type":"fn()","!url":"http://nodejs.org/api/net.html#net_socket_destroy","!doc":"Ensures that no more I/O activity happens on this socket. Only necessary in case of errors (parse error or so)."},pause:{"!type":"fn()","!url":"http://nodejs.org/api/net.html#net_socket_pause","!doc":"Pauses the reading of data. That is, 'data' events will not be emitted. Useful to throttle back an upload."},resume:{"!type":"fn()","!url":"http://nodejs.org/api/net.html#net_socket_resume","!doc":"Resumes reading after a call to pause()."},setTimeout:{"!type":"fn(timeout: number, callback?: fn())","!url":"http://nodejs.org/api/net.html#net_socket_settimeout_timeout_callback","!doc":"Sets the socket to timeout after timeout milliseconds of inactivity on the socket. By default net.Socket do not have a timeout."},setKeepAlive:{"!type":"fn(enable?: bool, initialDelay?: number)","!url":"http://nodejs.org/api/net.html#net_socket_setkeepalive_enable_initialdelay","!doc":"Enable/disable keep-alive functionality, and optionally set the initial delay before the first keepalive probe is sent on an idle socket. enable defaults to false."},address:{"!type":"fn() -> net.address","!url":"http://nodejs.org/api/net.html#net_socket_address","!doc":"Returns the bound address, the address family name and port of the socket as reported by the operating system. Returns an object with three properties, e.g. { port: 12346, family: 'IPv4', address: '127.0.0.1' }"},unref:{"!type":"fn()","!url":"http://nodejs.org/api/net.html#net_socket_unref","!doc":"Calling unref on a socket will allow the program to exit if this is the only active socket in the event system. If the socket is already unrefd calling unref again will have no effect."},ref:{"!type":"fn()","!url":"http://nodejs.org/api/net.html#net_socket_ref","!doc":"Opposite of unref, calling ref on a previously unrefd socket will not let the program exit if it's the only socket left (the default behavior). If the socket is refd calling ref again will have no effect."},remoteAddress:{"!type":"string","!url":"http://nodejs.org/api/net.html#net_socket_remoteaddress","!doc":"The string representation of the remote IP address. For example, '74.125.127.100' or '2001:4860:a005::68'."},remotePort:{"!type":"number","!url":"http://nodejs.org/api/net.html#net_socket_remoteport","!doc":"The numeric representation of the remote port. For example, 80 or 21."},localPort:{"!type":"number","!url":"http://nodejs.org/api/net.html#net_socket_localport","!doc":"The numeric representation of the local port. For example, 80 or 21."},bytesRead:{"!type":"number","!url":"http://nodejs.org/api/net.html#net_socket_bytesread","!doc":"The amount of received bytes."},bytesWritten:{"!type":"number","!url":"http://nodejs.org/api/net.html#net_socket_byteswritten","!doc":"The amount of bytes sent."},setNoDelay:{"!type":"fn(noDelay?: fn())","!url":"http://nodejs.org/api/net.html#net_socket_setnodelay_nodelay","!doc":"Disables the Nagle algorithm. By default TCP connections use the Nagle algorithm, they buffer data before sending it off. Setting true for noDelay will immediately fire off data each time socket.write() is called. noDelay defaults to true."},localAddress:{"!type":"string","!url":"http://nodejs.org/api/net.html#net_socket_localaddress","!doc":"The string representation of the local IP address the remote client is connecting on. For example, if you are listening on '0.0.0.0' and the client connects on '192.168.1.1', the value would be '192.168.1.1'."}},"!url":"http://nodejs.org/api/net.html#net_class_net_socket","!doc":"This object is an abstraction of a TCP or UNIX socket. net.Socket instances implement a duplex Stream interface. They can be created by the user and used as a client (with connect()) or they can be created by Node and passed to the user through the 'connection' event of a server."},connect:{"!type":"fn(options: ?, connectionListener?: fn()) -> +net.Socket","!url":"http://nodejs.org/api/net.html#net_net_connect_options_connectionlistener","!doc":"Constructs a new socket object and opens the socket to the given location. When the socket is established, the 'connect' event will be emitted."},createConnection:{"!type":"fn(options: ?, connectionListener?: fn()) -> +net.Socket","!url":"http://nodejs.org/api/net.html#net_net_createconnection_options_connectionlistener","!doc":"Constructs a new socket object and opens the socket to the given location. When the socket is established, the 'connect' event will be emitted."},isIP:{"!type":"fn(input: string) -> number","!url":"http://nodejs.org/api/net.html#net_net_isip_input","!doc":"Tests if input is an IP address. Returns 0 for invalid strings, returns 4 for IP version 4 addresses, and returns 6 for IP version 6 addresses."},isIPv4:{"!type":"fn(input: string) -> bool","!url":"http://nodejs.org/api/net.html#net_net_isipv4_input","!doc":"Returns true if input is a version 4 IP address, otherwise returns false."},isIPv6:{"!type":"fn(input: string) -> bool","!url":"http://nodejs.org/api/net.html#net_net_isipv6_input","!doc":"Returns true if input is a version 6 IP address, otherwise returns false."}},dgram:{createSocket:{"!type":"fn(type: string, callback?: fn()) -> +dgram.Socket","!url":"http://nodejs.org/api/dgram.html#dgram_dgram_createsocket_type_callback","!doc":"Creates a datagram Socket of the specified types. Valid types are udp4 and udp6."},Socket:{"!type":"fn()",prototype:{"!proto":"events.EventEmitter.prototype",send:{"!type":"fn(buf: +Buffer, offset: number, length: number, port: number, address: string, callback?: fn())","!url":"http://nodejs.org/api/dgram.html#dgram_socket_send_buf_offset_length_port_address_callback","!doc":"For UDP sockets, the destination port and IP address must be specified. A string may be supplied for the address parameter, and it will be resolved with DNS. An optional callback may be specified to detect any DNS errors and when buf may be re-used. Note that DNS lookups will delay the time that a send takes place, at least until the next tick. The only way to know for sure that a send has taken place is to use the callback."},bind:{"!type":"fn(port: number, address?: string)","!url":"http://nodejs.org/api/dgram.html#dgram_socket_bind_port_address_callback","!doc":"For UDP sockets, listen for datagrams on a named port and optional address. If address is not specified, the OS will try to listen on all addresses."},close:{"!type":"fn()","!url":"http://nodejs.org/api/dgram.html#dgram_socket_close","!doc":"Close the underlying socket and stop listening for data on it."},address:{address:"string",family:"string",port:"number","!url":"http://nodejs.org/api/dgram.html#dgram_socket_address","!doc":"Returns an object containing the address information for a socket. For UDP sockets, this object will contain address , family and port."},setBroadcast:{"!type":"fn(flag: bool)","!url":"http://nodejs.org/api/dgram.html#dgram_socket_setbroadcast_flag","!doc":"Sets or clears the SO_BROADCAST socket option. When this option is set, UDP packets may be sent to a local interface's broadcast address."},setTTL:{"!type":"fn(ttl: number)","!url":"http://nodejs.org/api/dgram.html#dgram_socket_setttl_ttl","!doc":'Sets the IP_TTL socket option. TTL stands for "Time to Live," but in this context it specifies the number of IP hops that a packet is allowed to go through. Each router or gateway that forwards a packet decrements the TTL. If the TTL is decremented to 0 by a router, it will not be forwarded. Changing TTL values is typically done for network probes or when multicasting.'},setMulticastTTL:{"!type":"fn(ttl: number)","!url":"http://nodejs.org/api/dgram.html#dgram_socket_setmulticastttl_ttl","!doc":'Sets the IP_MULTICAST_TTL socket option. TTL stands for "Time to Live," but in this context it specifies the number of IP hops that a packet is allowed to go through, specifically for multicast traffic. Each router or gateway that forwards a packet decrements the TTL. If the TTL is decremented to 0 by a router, it will not be forwarded.'},setMulticastLoopback:{"!type":"fn(flag: bool)","!url":"http://nodejs.org/api/dgram.html#dgram_socket_setmulticastloopback_flag","!doc":"Sets or clears the IP_MULTICAST_LOOP socket option. When this option is set, multicast packets will also be received on the local interface."},addMembership:{"!type":"fn(multicastAddress: string, multicastInterface?: string)","!url":"http://nodejs.org/api/dgram.html#dgram_socket_addmembership_multicastaddress_multicastinterface","!doc":"Tells the kernel to join a multicast group with IP_ADD_MEMBERSHIP socket option."},dropMembership:{"!type":"fn(multicastAddress: string, multicastInterface?: string)","!url":"http://nodejs.org/api/dgram.html#dgram_socket_dropmembership_multicastaddress_multicastinterface","!doc":"Opposite of addMembership - tells the kernel to leave a multicast group with IP_DROP_MEMBERSHIP socket option. This is automatically called by the kernel when the socket is closed or process terminates, so most apps will never need to call this."}},"!url":"http://nodejs.org/api/dgram.html#dgram_class_dgram_socket","!doc":"The dgram Socket class encapsulates the datagram functionality. It should be created via dgram.createSocket(type, [callback])."}},fs:{rename:{"!type":"fn(oldPath: string, newPath: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_rename_oldpath_newpath_callback","!doc":"Asynchronous rename(2). No arguments other than a possible exception are given to the completion callback."},renameSync:{"!type":"fn(oldPath: string, newPath: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_renamesync_oldpath_newpath","!doc":"Synchronous rename(2)."},ftruncate:{"!type":"fn(fd: number, len: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_ftruncate_fd_len_callback","!doc":"Asynchronous ftruncate(2). No arguments other than a possible exception are given to the completion callback."},ftruncateSync:{"!type":"fn(fd: number, len: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_ftruncatesync_fd_len","!doc":"Synchronous ftruncate(2)."},truncate:{"!type":"fn(path: string, len: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_truncate_path_len_callback","!doc":"Asynchronous truncate(2). No arguments other than a possible exception are given to the completion callback."},truncateSync:{"!type":"fn(path: string, len: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_truncatesync_path_len","!doc":"Synchronous truncate(2)."},chown:{"!type":"fn(path: string, uid: number, gid: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_chown_path_uid_gid_callback","!doc":"Asynchronous chown(2). No arguments other than a possible exception are given to the completion callback."},chownSync:{"!type":"fn(path: string, uid: number, gid: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_chownsync_path_uid_gid","!doc":"Synchronous chown(2)."},fchown:{"!type":"fn(fd: number, uid: number, gid: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_fchown_fd_uid_gid_callback","!doc":"Asynchronous fchown(2). No arguments other than a possible exception are given to the completion callback."},fchownSync:{"!type":"fn(fd: number, uid: number, gid: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_fchownsync_fd_uid_gid","!doc":"Synchronous fchown(2)."},lchown:{"!type":"fn(path: string, uid: number, gid: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_lchown_path_uid_gid_callback","!doc":"Asynchronous lchown(2). No arguments other than a possible exception are given to the completion callback."},lchownSync:{"!type":"fn(path: string, uid: number, gid: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_lchownsync_path_uid_gid","!doc":"Synchronous lchown(2)."},chmod:{"!type":"fn(path: string, mode: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_chmod_path_mode_callback","!doc":"Asynchronous chmod(2). No arguments other than a possible exception are given to the completion callback."},chmodSync:{"!type":"fn(path: string, mode: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_chmodsync_path_mode","!doc":"Synchronous chmod(2)."},fchmod:{"!type":"fn(fd: number, mode: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_fchmod_fd_mode_callback","!doc":"Asynchronous fchmod(2). No arguments other than a possible exception are given to the completion callback."},fchmodSync:{"!type":"fn(fd: number, mode: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_fchmodsync_fd_mode","!doc":"Synchronous fchmod(2)."},lchmod:{"!type":"fn(path: string, mode: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_lchmod_path_mode_callback","!doc":"Asynchronous lchmod(2). No arguments other than a possible exception are given to the completion callback."},lchmodSync:{"!type":"fn(path: string, mode: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_lchmodsync_path_mode","!doc":"Synchronous lchmod(2)."},stat:{"!type":"fn(path: string, callback?: fn(err: +Error, stats: +fs.Stats) -> ?) -> +fs.Stats","!url":"http://nodejs.org/api/fs.html#fs_fs_stat_path_callback","!doc":"Asynchronous stat(2). The callback gets two arguments (err, stats) where stats is a fs.Stats object."},lstat:{"!type":"fn(path: string, callback?: fn(err: +Error, stats: +fs.Stats) -> ?) -> +fs.Stats","!url":"http://nodejs.org/api/fs.html#fs_fs_lstat_path_callback","!doc":"Asynchronous lstat(2). The callback gets two arguments (err, stats) where stats is a fs.Stats object. lstat() is identical to stat(), except that if path is a symbolic link, then the link itself is stat-ed, not the file that it refers to."},fstat:{"!type":"fn(fd: number, callback?: fn(err: +Error, stats: +fs.Stats) -> ?) -> +fs.Stats","!url":"http://nodejs.org/api/fs.html#fs_fs_fstat_fd_callback","!doc":"Asynchronous fstat(2). The callback gets two arguments (err, stats) where stats is a fs.Stats object. fstat() is identical to stat(), except that the file to be stat-ed is specified by the file descriptor fd."},statSync:{"!type":"fn(path: string) -> +fs.Stats","!url":"http://nodejs.org/api/fs.html#fs_fs_statsync_path","!doc":"Synchronous stat(2). Returns an instance of fs.Stats."},lstatSync:{"!type":"fn(path: string) -> +fs.Stats","!url":"http://nodejs.org/api/fs.html#fs_fs_lstatsync_path","!doc":"Synchronous lstat(2). Returns an instance of fs.Stats."},fstatSync:{"!type":"fn(fd: number) -> +fs.Stats","!url":"http://nodejs.org/api/fs.html#fs_fs_fstatsync_fd","!doc":"Synchronous fstat(2). Returns an instance of fs.Stats."},link:{"!type":"fn(srcpath: string, dstpath: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_link_srcpath_dstpath_callback","!doc":"Asynchronous link(2). No arguments other than a possible exception are given to the completion callback."},linkSync:{"!type":"fn(srcpath: string, dstpath: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_linksync_srcpath_dstpath","!doc":"Synchronous link(2)."},symlink:{"!type":"fn(srcpath: string, dstpath: string, type?: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_symlink_srcpath_dstpath_type_callback","!doc":"Asynchronous symlink(2). No arguments other than a possible exception are given to the completion callback. type argument can be either 'dir', 'file', or 'junction' (default is 'file'). It is only used on Windows (ignored on other platforms). Note that Windows junction points require the destination path to be absolute. When using 'junction', the destination argument will automatically be normalized to absolute path."},symlinkSync:{"!type":"fn(srcpath: string, dstpath: string, type?: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_symlinksync_srcpath_dstpath_type","!doc":"Synchronous symlink(2)."},readlink:{"!type":"fn(path: string, callback?: fn(err: +Error, linkString: string))","!url":"http://nodejs.org/api/fs.html#fs_fs_readlink_path_callback","!doc":"Asynchronous readlink(2). The callback gets two arguments (err, linkString)."},readlinkSync:{"!type":"fn(path: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_readlinksync_path","!doc":"Synchronous readlink(2). Returns the symbolic link's string value."},realpath:{"!type":"fn(path: string, cache: string, callback: fn(err: +Error, resolvedPath: string))","!url":"http://nodejs.org/api/fs.html#fs_fs_realpath_path_cache_callback","!doc":"Asynchronous realpath(2). The callback gets two arguments (err, resolvedPath). May use process.cwd to resolve relative paths. cache is an object literal of mapped paths that can be used to force a specific path resolution or avoid additional fs.stat calls for known real paths."},realpathSync:{"!type":"fn(path: string, cache?: bool) -> string","!url":"http://nodejs.org/api/fs.html#fs_fs_realpathsync_path_cache","!doc":"Synchronous realpath(2). Returns the resolved path."},unlink:{"!type":"fn(path: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_unlink_path_callback","!doc":"Asynchronous unlink(2). No arguments other than a possible exception are given to the completion callback."},unlinkSync:{"!type":"fn(path: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_unlinksync_path","!doc":"Synchronous unlink(2)."},rmdir:{"!type":"fn(path: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_rmdir_path_callback","!doc":"Asynchronous rmdir(2). No arguments other than a possible exception are given to the completion callback."},rmdirSync:{"!type":"fn(path: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_rmdirsync_path","!doc":"Synchronous rmdir(2)."},mkdir:{"!type":"fn(path: string, mode?: ?, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_mkdir_path_mode_callback","!doc":"Asynchronous mkdir(2). No arguments other than a possible exception are given to the completion callback. mode defaults to 0777."},mkdirSync:{"!type":"fn(path: string, mode?: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_mkdirsync_path_mode","!doc":"Synchronous mkdir(2)."},readdir:{"!type":"fn(path: string, callback?: fn(err: +Error, files: [string]))","!url":"http://nodejs.org/api/fs.html#fs_fs_readdir_path_callback","!doc":"Asynchronous readdir(3). Reads the contents of a directory. The callback gets two arguments (err, files) where files is an array of the names of the files in the directory excluding '.' and '..'."},readdirSync:{"!type":"fn(path: string) -> [string]","!url":"http://nodejs.org/api/fs.html#fs_fs_readdirsync_path","!doc":"Synchronous readdir(3). Returns an array of filenames excluding '.' and '..'."},close:{"!type":"fn(fd: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_close_fd_callback","!doc":"Asynchronous close(2). No arguments other than a possible exception are given to the completion callback."},closeSync:{"!type":"fn(fd: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_closesync_fd","!doc":"Synchronous close(2)."},open:{"!type":"fn(path: string, flags: string, mode?: string, callback?: fn(err: +Error, fd: number))","!url":"http://nodejs.org/api/fs.html#fs_fs_open_path_flags_mode_callback","!doc":"Asynchronous file open."},openSync:{"!type":"fn(path: string, flags: string, mode?: string) -> number","!url":"http://nodejs.org/api/fs.html#fs_fs_opensync_path_flags_mode","!doc":"Synchronous open(2)."},utimes:{"!type":"fn(path: string, atime: number, mtime: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_utimes_path_atime_mtime_callback","!doc":"Change file timestamps of the file referenced by the supplied path."},utimesSync:{"!type":"fn(path: string, atime: number, mtime: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_utimessync_path_atime_mtime","!doc":"Change file timestamps of the file referenced by the supplied path."},futimes:{"!type":"fn(fd: number, atime: number, mtime: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_futimes_fd_atime_mtime_callback","!doc":"Change the file timestamps of a file referenced by the supplied file descriptor."},futimesSync:{"!type":"fn(fd: number, atime: number, mtime: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_futimessync_fd_atime_mtime","!doc":"Change the file timestamps of a file referenced by the supplied file descriptor."},fsync:{"!type":"fn(fd: number, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_fsync_fd_callback","!doc":"Asynchronous fsync(2). No arguments other than a possible exception are given to the completion callback."},fsyncSync:{"!type":"fn(fd: number)","!url":"http://nodejs.org/api/fs.html#fs_fs_fsyncsync_fd","!doc":"Synchronous fsync(2)."},write:{"!type":"fn(fd: number, buffer: +Buffer, offset: number, length: number, position: number, callback?: fn(err: +Error, written: number, buffer: +Buffer))","!url":"http://nodejs.org/api/fs.html#fs_fs_write_fd_buffer_offset_length_position_callback","!doc":"Write buffer to the file specified by fd."},writeSync:{"!type":"fn(fd: number, buffer: +Buffer, offset: number, length: number, position: number) -> number","!url":"http://nodejs.org/api/fs.html#fs_fs_writesync_fd_buffer_offset_length_position","!doc":"Synchronous version of fs.write(). Returns the number of bytes written."},read:{"!type":"fn(fd: number, buffer: +Buffer, offset: number, length: number, position: number, callback?: fn(err: +Error, bytesRead: number, buffer: +Buffer))","!url":"http://nodejs.org/api/fs.html#fs_fs_read_fd_buffer_offset_length_position_callback","!doc":"Read data from the file specified by fd."},readSync:{"!type":"fn(fd: number, buffer: +Buffer, offset: number, length: number, position: number) -> number","!url":"http://nodejs.org/api/fs.html#fs_fs_readsync_fd_buffer_offset_length_position","!doc":"Synchronous version of fs.read. Returns the number of bytesRead."},readFile:{"!type":"fn(filename: string, callback: fn(err: +Error, data: +Buffer))","!url":"http://nodejs.org/api/fs.html#fs_fs_readfile_filename_options_callback","!doc":"Asynchronously reads the entire contents of a file."},readFileSync:{"!type":"fn(filename: string, encoding: string) -> +Buffer","!url":"http://nodejs.org/api/fs.html#fs_fs_readfilesync_filename_options","!doc":"Synchronous version of fs.readFile. Returns the contents of the filename."},writeFile:{"!type":"fn(filename: string, data: +Buffer, encoding?: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_writefile_filename_data_options_callback","!doc":"Asynchronously writes data to a file, replacing the file if it already exists. data can be a string or a buffer."},writeFileSync:{"!type":"fn(filename: string, data: +Buffer, encoding?: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_writefilesync_filename_data_options","!doc":"The synchronous version of fs.writeFile."},appendFile:{"!type":"fn(filename: string, data: ?, encoding?: string, callback?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_appendfile_filename_data_options_callback","!doc":"Asynchronously append data to a file, creating the file if it not yet exists. data can be a string or a buffer."},appendFileSync:{"!type":"fn(filename: string, data: ?, encoding?: string)","!url":"http://nodejs.org/api/fs.html#fs_fs_appendfilesync_filename_data_options","!doc":"The synchronous version of fs.appendFile."},watchFile:{"!type":"fn(filename: string, options: ?, listener: fn(current: +fs.Stats, prev: +fs.Stats))","!url":"http://nodejs.org/api/fs.html#fs_fs_watchfile_filename_options_listener","!doc":"Watch for changes on filename. The callback listener will be called each time the file is accessed."},unwatchFile:{"!type":"fn(filename: string, listener?: fn())","!url":"http://nodejs.org/api/fs.html#fs_fs_unwatchfile_filename_listener","!doc":"Stop watching for changes on filename. If listener is specified, only that particular listener is removed. Otherwise, all listeners are removed and you have effectively stopped watching filename."},watch:{"!type":"fn(filename: string, options?: ?, listener?: fn(event: string, filename: string)) -> +fs.FSWatcher","!url":"http://nodejs.org/api/fs.html#fs_fs_watch_filename_options_listener","!doc":"Watch for changes on filename, where filename is either a file or a directory. The returned object is a fs.FSWatcher."},exists:{"!type":"fn(path: string, callback?: fn(exists: bool))","!url":"http://nodejs.org/api/fs.html#fs_fs_exists_path_callback","!doc":"Test whether or not the given path exists by checking with the file system. Then call the callback argument with either true or false."},existsSync:{"!type":"fn(path: string) -> bool","!url":"http://nodejs.org/api/fs.html#fs_fs_existssync_path","!doc":"Synchronous version of fs.exists."},Stats:{"!type":"fn()",prototype:{isFile:"fn() -> bool",isDirectory:"fn() -> bool",isBlockDevice:"fn() -> bool",isCharacterDevice:"fn() -> bool",isSymbolicLink:"fn() -> bool",isFIFO:"fn() -> bool",isSocket:"fn() -> bool",dev:"number",ino:"number",mode:"number",nlink:"number",uid:"number",gid:"number",rdev:"number",size:"number",blksize:"number",blocks:"number",atime:"+Date",mtime:"+Date",ctime:"+Date"},"!url":"http://nodejs.org/api/fs.html#fs_class_fs_stats","!doc":"Objects returned from fs.stat(), fs.lstat() and fs.fstat() and their synchronous counterparts are of this type."},createReadStream:{"!type":"fn(path: string, options?: ?) -> +stream.Readable","!url":"http://nodejs.org/api/fs.html#fs_fs_createreadstream_path_options","!doc":"Returns a new ReadStream object."},createWriteStream:{"!type":"fn(path: string, options?: ?) -> +stream.Writable","!url":"http://nodejs.org/api/fs.html#fs_fs_createwritestream_path_options","!doc":"Returns a new WriteStream object."},FSWatcher:{"!type":"fn()",prototype:{close:"fn()"},"!url":"http://nodejs.org/api/fs.html#fs_class_fs_fswatcher","!doc":"Objects returned from fs.watch() are of this type."}},path:{normalize:{"!type":"fn(p: string) -> string","!url":"http://nodejs.org/api/path.html#path_path_normalize_p","!doc":"Normalize a string path, taking care of '..' and '.' parts."},join:{"!type":"fn() -> string","!url":"http://nodejs.org/api/path.html#path_path_join_path1_path2","!doc":"Join all arguments together and normalize the resulting path."},resolve:{"!type":"fn(from: string, from2: string, from3: string, from4: string, from5: string, to: string) -> string","!url":"http://nodejs.org/api/path.html#path_path_resolve_from_to","!doc":"Resolves to to an absolute path."},relative:{"!type":"fn(from: string, to: string) -> string","!url":"http://nodejs.org/api/path.html#path_path_relative_from_to","!doc":"Solve the relative path from from to to."},dirname:{"!type":"fn(p: string) -> string","!url":"http://nodejs.org/api/path.html#path_path_dirname_p","!doc":"Return the directory name of a path. Similar to the Unix dirname command."},basename:{"!type":"fn(p: string, ext?: string) -> string","!url":"http://nodejs.org/api/path.html#path_path_basename_p_ext","!doc":"Return the last portion of a path. Similar to the Unix basename command."},extname:{"!type":"fn(p: string) -> string","!url":"http://nodejs.org/api/path.html#path_path_extname_p","!doc":"Return the extension of the path, from the last '.' to end of string in the last portion of the path. If there is no '.' in the last portion of the path or the first character of it is '.', then it returns an empty string."},sep:{"!type":"string","!url":"http://nodejs.org/api/path.html#path_path_sep","!doc":"The platform-specific file separator. '\\\\' or '/'."},delimiter:{"!type":"string","!url":"http://nodejs.org/api/path.html#path_path_delimiter","!doc":"The platform-specific path delimiter, ; or ':'."}},string_decoder:{StringDecoder:{"!type":"fn(encoding?: string)",prototype:{write:{"!type":"fn(buffer: +Buffer) -> string","!url":"http://nodejs.org/api/string_decoder.html#string_decoder_decoder_write_buffer","!doc":"Returns a decoded string."},end:{"!type":"fn()","!url":"http://nodejs.org/api/string_decoder.html#string_decoder_decoder_end","!doc":"Returns any trailing bytes that were left in the buffer."}},"!url":"http://nodejs.org/api/string_decoder.html#string_decoder_class_stringdecoder","!doc":"Accepts a single argument, encoding which defaults to utf8."}},tls:{CLIENT_RENEG_LIMIT:"number",CLIENT_RENEG_WINDOW:"number",SLAB_BUFFER_SIZE:"number",getCiphers:{"!type":"fn() -> [string]","!url":"http://nodejs.org/api/tls.html#tls_tls_getciphers","!doc":"Returns an array with the names of the supported SSL ciphers."},Server:{"!type":"fn()",prototype:{"!proto":"net.Server.prototype",listen:{"!type":"fn(port: number, host?: string, callback?: fn())","!url":"http://nodejs.org/api/tls.html#tls_server_listen_port_host_callback","!doc":"Begin accepting connections on the specified port and host. If the host is omitted, the server will accept connections directed to any IPv4 address (INADDR_ANY)."},close:{"!type":"fn()","!url":"http://nodejs.org/api/tls.html#tls_server_close","!doc":"Stops the server from accepting new connections. This function is asynchronous, the server is finally closed when the server emits a 'close' event."},addContext:{"!type":"fn(hostName: string, credentials: tls.Server.credentials)","!url":"http://nodejs.org/api/tls.html#tls_server_addcontext_hostname_credentials","!doc":"Add secure context that will be used if client request's SNI hostname is matching passed hostname (wildcards can be used). credentials can contain key, cert and ca."}},"!url":"http://nodejs.org/api/tls.html#tls_class_tls_server","!doc":"This class is a subclass of net.Server and has the same methods on it. Instead of accepting just raw TCP connections, this accepts encrypted connections using TLS or SSL."},createServer:{"!type":"fn(options?: ?, connectionListener?: fn(stream: +tls.CleartextStream)) -> +tls.Server","!url":"http://nodejs.org/api/tls.html#tls_tls_createserver_options_secureconnectionlistener","!doc":"Creates a new tls.Server. The connectionListener argument is automatically set as a listener for the secureConnection event."},CleartextStream:{"!type":"fn()",prototype:{"!proto":"stream.Duplex.prototype",authorized:{"!type":"bool","!url":"http://nodejs.org/api/tls.html#tls_cleartextstream_authorized","!doc":"A boolean that is true if the peer certificate was signed by one of the specified CAs, otherwise false"},authorizationError:{"!type":"+Error","!url":"http://nodejs.org/api/tls.html#tls_cleartextstream_authorizationerror","!doc":"The reason why the peer's certificate has not been verified. This property becomes available only when cleartextStream.authorized === false."},getPeerCertificate:{"!type":"fn() -> ?","!url":"http://nodejs.org/api/tls.html#tls_cleartextstream_getpeercertificate","!doc":"Returns an object representing the peer's certificate. The returned object has some properties corresponding to the field of the certificate."},getCipher:{"!type":"fn() -> tls.cipher","!url":"http://nodejs.org/api/tls.html#tls_cleartextstream_getcipher","!doc":"Returns an object representing the cipher name and the SSL/TLS protocol version of the current connection."},address:{"!type":"net.address","!url":"http://nodejs.org/api/tls.html#tls_cleartextstream_address","!doc":"Returns the bound address, the address family name and port of the underlying socket as reported by the operating system. Returns an object with three properties, e.g. { port: 12346, family: 'IPv4', address: '127.0.0.1' }"},remoteAddress:{"!type":"string","!url":"http://nodejs.org/api/tls.html#tls_cleartextstream_remoteaddress","!doc":"The string representation of the remote IP address. For example, '74.125.127.100' or '2001:4860:a005::68'."},remotePort:{"!type":"number","!url":"http://nodejs.org/api/tls.html#tls_cleartextstream_remoteport","!doc":"The numeric representation of the remote port. For example, 443."}},"!url":"http://nodejs.org/api/tls.html#tls_class_tls_cleartextstream","!doc":"This is a stream on top of the Encrypted stream that makes it possible to read/write an encrypted data as a cleartext data."},connect:{"!type":"fn(port: number, host?: string, options: ?, listener: fn()) -> +tls.CleartextStream","!url":"http://nodejs.org/api/tls.html#tls_tls_connect_options_callback","!doc":"Creates a new client connection to the given port and host (old API) or options.port and options.host. (If host is omitted, it defaults to localhost.)"},createSecurePair:{"!type":"fn(credentials?: crypto.credentials, isServer?: bool, requestCert?: bool, rejectUnauthorized?: bool) -> +tls.SecurePair","!url":"http://nodejs.org/api/tls.html#tls_tls_createsecurepair_credentials_isserver_requestcert_rejectunauthorized","!doc":"Creates a new secure pair object with two streams, one of which reads/writes encrypted data, and one reads/writes cleartext data. Generally the encrypted one is piped to/from an incoming encrypted data stream, and the cleartext one is used as a replacement for the initial encrypted stream."},SecurePair:{"!type":"fn()",prototype:{"!proto":"events.EventEmitter.prototype",cleartext:{"!type":"+tls.CleartextStream","!url":"http://nodejs.org/api/tls.html#tls_class_securepair","!doc":"Returned by tls.createSecurePair."},encrypted:{"!type":"+stream.Duplex","!url":"http://nodejs.org/api/tls.html#tls_class_securepair","!doc":"Returned by tls.createSecurePair."}},"!url":"http://nodejs.org/api/tls.html#tls_class_securepair","!doc":"Returned by tls.createSecurePair."}},crypto:{getCiphers:{"!type":"fn() -> [string]","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_getciphers","!doc":"Returns an array with the names of the supported ciphers."},getHashes:{"!type":"fn() -> [string]","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_gethashes","!doc":"Returns an array with the names of the supported hash algorithms."},createCredentials:{"!type":"fn(details?: ?) -> crypto.credentials","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createcredentials_details","!doc":"Creates a credentials object."},createHash:{"!type":"fn(algorithm: string) -> +crypto.Hash","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createhash_algorithm","!doc":"Creates and returns a hash object, a cryptographic hash with the given algorithm which can be used to generate hash digests."},Hash:{"!type":"fn()",prototype:{"!proto":"stream.Duplex.prototype",update:{"!type":"fn(data: +Buffer, encoding?: string)","!url":"http://nodejs.org/api/crypto.html#crypto_hash_update_data_input_encoding","!doc":"Updates the hash content with the given data, the encoding of which is given in input_encoding and can be 'utf8', 'ascii' or 'binary'. If no encoding is provided, then a buffer is expected."},digest:{"!type":"fn(encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_hash_digest_encoding","!doc":"Calculates the digest of all of the passed data to be hashed. The encoding can be 'hex', 'binary' or 'base64'. If no encoding is provided, then a buffer is returned."}},"!url":"http://nodejs.org/api/crypto.html#crypto_class_hash","!doc":"The class for creating hash digests of data."},createHmac:{"!type":"fn(algorithm: string, key: string) -> +crypto.Hmac","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createhmac_algorithm_key","!doc":"Creates and returns a hmac object, a cryptographic hmac with the given algorithm and key."},Hmac:{"!type":"fn()",prototype:{update:{"!type":"fn(data: +Buffer)","!url":"http://nodejs.org/api/crypto.html#crypto_hmac_update_data","!doc":"Update the hmac content with the given data. This can be called many times with new data as it is streamed."},digest:{"!type":"fn(encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_hmac_digest_encoding","!doc":"Calculates the digest of all of the passed data to the hmac. The encoding can be 'hex', 'binary' or 'base64'. If no encoding is provided, then a buffer is returned."}},"!url":"http://nodejs.org/api/crypto.html#crypto_class_hmac","!doc":"Class for creating cryptographic hmac content."},createCipher:{"!type":"fn(algorithm: string, password: string) -> +crypto.Cipher","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createcipher_algorithm_password","!doc":"Creates and returns a cipher object, with the given algorithm and password."},createCipheriv:{"!type":"fn(algorithm: string, password: string, iv: string) -> +crypto.Cipher","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createcipheriv_algorithm_key_iv","!doc":"Creates and returns a cipher object, with the given algorithm, key and iv."},Cipher:{"!type":"fn()",prototype:{"!proto":"stream.Duplex.prototype",update:{"!type":"fn(data: +Buffer, input_encoding?: string, output_encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_cipher_update_data_input_encoding_output_encoding","!doc":"Updates the cipher with data, the encoding of which is given in input_encoding and can be 'utf8', 'ascii' or 'binary'. If no encoding is provided, then a buffer is expected."},"final":{"!type":"fn(output_encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_cipher_final_output_encoding","!doc":"Returns any remaining enciphered contents, with output_encoding being one of: 'binary', 'base64' or 'hex'. If no encoding is provided, then a buffer is returned."},setAutoPadding:{"!type":"fn(auto_padding: bool)","!url":"http://nodejs.org/api/crypto.html#crypto_cipher_setautopadding_auto_padding_true","!doc":"You can disable automatic padding of the input data to block size. If auto_padding is false, the length of the entire input data must be a multiple of the cipher's block size or final will fail. Useful for non-standard padding, e.g. using 0x0 instead of PKCS padding. You must call this before cipher.final."}},"!url":"http://nodejs.org/api/crypto.html#crypto_class_cipher","!doc":"Class for encrypting data."},createDecipher:{"!type":"fn(algorithm: string, password: string) -> +crypto.Decipher","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createdecipher_algorithm_password","!doc":"Creates and returns a decipher object, with the given algorithm and key. This is the mirror of the createCipher() above."},createDecipheriv:{"!type":"fn(algorithm: string, key: string, iv: string) -> +crypto.Decipher","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createdecipheriv_algorithm_key_iv","!doc":"Creates and returns a decipher object, with the given algorithm, key and iv. This is the mirror of the createCipheriv() above."},Decipher:{"!type":"fn()",prototype:{"!proto":"stream.Duplex.prototype",update:{"!type":"fn(data: +Buffer, input_encoding?: string, output_encoding?: string)","!url":"http://nodejs.org/api/crypto.html#crypto_decipher_update_data_input_encoding_output_encoding","!doc":"Updates the decipher with data, which is encoded in 'binary', 'base64' or 'hex'. If no encoding is provided, then a buffer is expected."},"final":{"!type":"fn(output_encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_decipher_final_output_encoding","!doc":"Returns any remaining plaintext which is deciphered, with output_encoding being one of: 'binary', 'ascii' or 'utf8'. If no encoding is provided, then a buffer is returned."},setAutoPadding:{"!type":"fn(auto_padding: bool)","!url":"http://nodejs.org/api/crypto.html#crypto_decipher_setautopadding_auto_padding_true","!doc":"You can disable auto padding if the data has been encrypted without standard block padding to prevent decipher.final from checking and removing it. Can only work if the input data's length is a multiple of the ciphers block size. You must call this before streaming data to decipher.update."}},"!url":"http://nodejs.org/api/crypto.html#crypto_class_decipher","!doc":"Class for decrypting data."},createSign:{"!type":"fn(algorithm: string) -> +crypto.Sign","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createsign_algorithm","!doc":"Creates and returns a signing object, with the given algorithm. On recent OpenSSL releases, openssl list-public-key-algorithms will display the available signing algorithms. Examples are 'RSA-SHA256'."},Sign:{"!type":"fn()",prototype:{"!proto":"stream.Writable.prototype",update:{"!type":"fn(data: +Buffer)","!url":"http://nodejs.org/api/crypto.html#crypto_sign_update_data","!doc":"Updates the sign object with data. This can be called many times with new data as it is streamed."},sign:{"!type":"fn(private_key: string, output_format: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_sign_sign_private_key_output_format","!doc":"Calculates the signature on all the updated data passed through the sign. private_key is a string containing the PEM encoded private key for signing."}},"!url":"http://nodejs.org/api/crypto.html#crypto_class_sign","!doc":"Class for generating signatures."},createVerify:{"!type":"fn(algorith: string) -> +crypto.Verify","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_createverify_algorithm","!doc":"Creates and returns a verification object, with the given algorithm. This is the mirror of the signing object above."},Verify:{"!type":"fn()",prototype:{"!proto":"stream.Writable.prototype",update:{"!type":"fn(data: +Buffer)","!url":"http://nodejs.org/api/crypto.html#crypto_verifier_update_data","!doc":"Updates the verifier object with data. This can be called many times with new data as it is streamed."},verify:{"!type":"fn(object: string, signature: string, signature_format?: string) -> bool","!url":"http://nodejs.org/api/crypto.html#crypto_verifier_verify_object_signature_signature_format","!doc":"Verifies the signed data by using the object and signature. object is a string containing a PEM encoded object, which can be one of RSA public key, DSA public key, or X.509 certificate. signature is the previously calculated signature for the data, in the signature_format which can be 'binary', 'hex' or 'base64'. If no encoding is specified, then a buffer is expected."}},"!url":"http://nodejs.org/api/crypto.html#crypto_class_verify","!doc":"Class for verifying signatures."},createDiffieHellman:{"!type":"fn(prime: number, encoding?: string) -> +crypto.DiffieHellman","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_creatediffiehellman_prime_length","!doc":"Creates a Diffie-Hellman key exchange object and generates a prime of the given bit length. The generator used is 2."},DiffieHellman:{"!type":"fn()",prototype:{generateKeys:{"!type":"fn(encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_diffiehellman_generatekeys_encoding","!doc":"Generates private and public Diffie-Hellman key values, and returns the public key in the specified encoding. This key should be transferred to the other party. Encoding can be 'binary', 'hex', or 'base64'. If no encoding is provided, then a buffer is returned."},computeSecret:{"!type":"fn(other_public_key: +Buffer, input_encoding?: string, output_encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_diffiehellman_computesecret_other_public_key_input_encoding_output_encoding","!doc":"Computes the shared secret using other_public_key as the other party's public key and returns the computed shared secret. Supplied key is interpreted using specified input_encoding, and secret is encoded using specified output_encoding. Encodings can be 'binary', 'hex', or 'base64'. If the input encoding is not provided, then a buffer is expected."},getPrime:{"!type":"fn(encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_diffiehellman_getprime_encoding","!doc":"Returns the Diffie-Hellman prime in the specified encoding, which can be 'binary', 'hex', or 'base64'. If no encoding is provided, then a buffer is returned."},getGenerator:{"!type":"fn(encoding: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_diffiehellman_getgenerator_encoding","!doc":"Returns the Diffie-Hellman prime in the specified encoding, which can be 'binary', 'hex', or 'base64'. If no encoding is provided, then a buffer is returned."},getPublicKey:{"!type":"fn(encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_diffiehellman_getpublickey_encoding","!doc":"Returns the Diffie-Hellman public key in the specified encoding, which can be 'binary', 'hex', or 'base64'. If no encoding is provided, then a buffer is returned."},getPrivateKey:{"!type":"fn(encoding?: string) -> +Buffer","!url":"http://nodejs.org/api/crypto.html#crypto_diffiehellman_getprivatekey_encoding","!doc":"Returns the Diffie-Hellman private key in the specified encoding, which can be 'binary', 'hex', or 'base64'. If no encoding is provided, then a buffer is returned."},setPublicKey:{"!type":"fn(public_key: +Buffer, encoding?: string)","!url":"http://nodejs.org/api/crypto.html#crypto_diffiehellman_setpublickey_public_key_encoding","!doc":"Sets the Diffie-Hellman public key. Key encoding can be 'binary', 'hex' or 'base64'. If no encoding is provided, then a buffer is expected."},setPrivateKey:{"!type":"fn(public_key: +Buffer, encoding?: string)","!url":"http://nodejs.org/api/crypto.html#crypto_diffiehellman_setprivatekey_private_key_encoding","!doc":"Sets the Diffie-Hellman private key. Key encoding can be 'binary', 'hex' or 'base64'. If no encoding is provided, then a buffer is expected."}},"!url":"http://nodejs.org/api/crypto.html#crypto_class_diffiehellman","!doc":"The class for creating Diffie-Hellman key exchanges."},getDiffieHellman:{"!type":"fn(group_name: string) -> +crypto.DiffieHellman","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_getdiffiehellman_group_name","!doc":"Creates a predefined Diffie-Hellman key exchange object. The supported groups are: 'modp1', 'modp2', 'modp5' (defined in RFC 2412) and 'modp14', 'modp15', 'modp16', 'modp17', 'modp18' (defined in RFC 3526). The returned object mimics the interface of objects created by crypto.createDiffieHellman() above, but will not allow to change the keys (with diffieHellman.setPublicKey() for example). The advantage of using this routine is that the parties don't have to generate nor exchange group modulus beforehand, saving both processor and communication time."},pbkdf2:{"!type":"fn(password: string, salt: string, iterations: number, keylen: number, callback: fn(err: +Error, derivedKey: string))","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_pbkdf2_password_salt_iterations_keylen_callback","!doc":"Asynchronous PBKDF2 applies pseudorandom function HMAC-SHA1 to derive a key of given length from the given password, salt and iterations. The callback gets two arguments (err, derivedKey)."},pbkdf2Sync:{"!type":"fn(password: string, salt: string, iterations: number, keylen: number) -> string","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_pbkdf2sync_password_salt_iterations_keylen","!doc":"Synchronous PBKDF2 function. Returns derivedKey or throws error."},randomBytes:{"!type":"fn(size: number, callback?: fn(err: +Error, buf: +Buffer))","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_randombytes_size_callback","!doc":"Generates cryptographically strong pseudo-random data."},pseudoRandomBytes:{"!type":"fn(size: number, callback?: fn(err: +Error, buf: +Buffer))","!url":"http://nodejs.org/api/crypto.html#crypto_crypto_pseudorandombytes_size_callback","!doc":"Generates non-cryptographically strong pseudo-random data. The data returned will be unique if it is sufficiently long, but is not necessarily unpredictable. For this reason, the output of this function should never be used where unpredictability is important, such as in the generation of encryption keys."},DEFAULT_ENCODING:"string"},util:{format:{"!type":"fn(format: string) -> string","!url":"http://nodejs.org/api/util.html#util_util_format_format","!doc":"Returns a formatted string using the first argument as a printf-like format."},debug:{"!type":"fn(msg: string)","!url":"http://nodejs.org/api/util.html#util_util_debug_string","!doc":"A synchronous output function. Will block the process and output string immediately to stderr."},error:{"!type":"fn(msg: string)","!url":"http://nodejs.org/api/util.html#util_util_error","!doc":"Same as util.debug() except this will output all arguments immediately to stderr."},puts:{"!type":"fn(data: string)","!url":"http://nodejs.org/api/util.html#util_util_puts","!doc":"A synchronous output function. Will block the process and output all arguments to stdout with newlines after each argument."},print:{"!type":"fn(data: string)","!url":"http://nodejs.org/api/util.html#util_util_print","!doc":"A synchronous output function. Will block the process, cast each argument to a string then output to stdout. Does not place newlines after each argument."},log:{"!type":"fn(string: string)","!url":"http://nodejs.org/api/util.html#util_util_log_string","!doc":"Output with timestamp on stdout."},inspect:{"!type":"fn(object: ?, options: ?) -> string","!url":"http://nodejs.org/api/util.html#util_util_inspect_object_options","!doc":"Return a string representation of object, which is useful for debugging."},isArray:{"!type":"fn(object: ?) -> bool","!url":"http://nodejs.org/api/util.html#util_util_isarray_object","!doc":'Returns true if the given "object" is an Array. false otherwise.'},isRegExp:{"!type":"fn(object: ?) -> bool","!url":"http://nodejs.org/api/util.html#util_util_isregexp_object","!doc":'Returns true if the given "object" is a RegExp. false otherwise.'},isDate:{"!type":"fn(object: ?) -> bool","!url":"http://nodejs.org/api/util.html#util_util_isdate_object","!doc":'Returns true if the given "object" is a Date. false otherwise.'},isError:{"!type":"fn(object: ?) -> bool","!url":"http://nodejs.org/api/util.html#util_util_iserror_object","!doc":'Returns true if the given "object" is an Error. false otherwise.'},inherits:{"!type":"fn(constructor: ?, superConstructor: ?)","!url":"http://nodejs.org/api/util.html#util_util_inherits_constructor_superconstructor","!doc":"Inherit the prototype methods from one constructor into another. The prototype of constructor will be set to a new object created from superConstructor."}},assert:{"!type":"fn(value: ?, message?: string)",fail:{"!type":"fn(actual: ?, expected: ?, message: string, operator: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_fail_actual_expected_message_operator","!doc":"Throws an exception that displays the values for actual and expected separated by the provided operator."},ok:{"!type":"fn(value: ?, message?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert","!doc":"This module is used for writing unit tests for your applications, you can access it with require('assert')."},equal:{"!type":"fn(actual: ?, expected: ?, message?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_equal_actual_expected_message","!doc":"Tests shallow, coercive equality with the equal comparison operator ( == )."},notEqual:{"!type":"fn(actual: ?, expected: ?, message?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_notequal_actual_expected_message","!doc":"Tests shallow, coercive non-equality with the not equal comparison operator ( != )."},deepEqual:{"!type":"fn(actual: ?, expected: ?, message?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_deepequal_actual_expected_message","!doc":"Tests for deep equality."},notDeepEqual:{"!type":"fn(acutal: ?, expected: ?, message?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_notdeepequal_actual_expected_message","!doc":"Tests for any deep inequality."},strictEqual:{"!type":"fn(actual: ?, expected: ?, message?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_strictequal_actual_expected_message","!doc":"Tests strict equality, as determined by the strict equality operator ( === )"},notStrictEqual:{"!type":"fn(actual: ?, expected: ?, message?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_notstrictequal_actual_expected_message","!doc":"Tests strict non-equality, as determined by the strict not equal operator ( !== )"},"throws":{"!type":"fn(block: fn(), error?: ?, messsage?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_throws_block_error_message","!doc":"Expects block to throw an error. error can be constructor, regexp or validation function."},doesNotThrow:{"!type":"fn(block: fn(), error?: ?, messsage?: string)","!url":"http://nodejs.org/api/assert.html#assert_assert_doesnotthrow_block_message","!doc":"Expects block not to throw an error."},ifError:{"!type":"fn(value: ?)","!url":"http://nodejs.org/api/assert.html#assert_assert_iferror_value","!doc":"Tests if value is not a false value, throws if it is a true value. Useful when testing the first argument, error in callbacks."},"!url":"http://nodejs.org/api/assert.html#assert_assert","!doc":"This module is used for writing unit tests for your applications, you can access it with require('assert')."},tty:{isatty:{"!type":"fn(fd: number) -> bool","!url":"http://nodejs.org/api/tty.html#tty_tty_isatty_fd","!doc":"Returns true or false depending on if the fd is associated with a terminal."}},domain:{create:{"!type":"fn() -> +events.EventEmitter","!url":"http://nodejs.org/api/domain.html#domain_domain_create","!doc":"Returns a new Domain object."},Domain:{"!type":"fn()",prototype:{"!proto":"events.EventEmitter.prototype",run:{"!type":"fn(fn: fn())","!url":"http://nodejs.org/api/domain.html#domain_domain_run_fn","!doc":"Run the supplied function in the context of the domain, implicitly binding all event emitters, timers, and lowlevel requests that are created in that context."},members:{"!type":"[+events.EventEmitter]","!url":"http://nodejs.org/api/domain.html#domain_domain_members","!doc":"An array of timers and event emitters that have been explicitly added to the domain."},add:{"!type":"fn(emitter: +events.EventEmitter)","!url":"http://nodejs.org/api/domain.html#domain_domain_add_emitter","!doc":"Explicitly adds an emitter to the domain. If any event handlers called by the emitter throw an error, or if the emitter emits an error event, it will be routed to the domain's error event, just like with implicit binding."},remove:{"!type":"fn(emitter: +events.EventEmitter)","!url":"http://nodejs.org/api/domain.html#domain_domain_remove_emitter","!doc":"The opposite of domain.add(emitter). Removes domain handling from the specified emitter."},bind:{"!type":"fn(callback: fn(err: +Error, data: ?)) -> !0","!url":"http://nodejs.org/api/domain.html#domain_domain_bind_callback","!doc":"The returned function will be a wrapper around the supplied callback function. When the returned function is called, any errors that are thrown will be routed to the domain's error event."},intercept:{"!type":"fn(cb: fn(data: ?)) -> !0","!url":"http://nodejs.org/api/domain.html#domain_domain_intercept_callback","!doc":"This method is almost identical to domain.bind(callback). However, in addition to catching thrown errors, it will also intercept Error objects sent as the first argument to the function."},dispose:{"!type":"fn()","!url":"http://nodejs.org/api/domain.html#domain_domain_dispose","!doc":"The dispose method destroys a domain, and makes a best effort attempt to clean up any and all IO that is associated with the domain. Streams are aborted, ended, closed, and/or destroyed. Timers are cleared. Explicitly bound callbacks are no longer called. Any error events that are raised as a result of this are ignored."}},"!url":"http://nodejs.org/api/domain.html#domain_class_domain","!doc":"The Domain class encapsulates the functionality of routing errors and uncaught exceptions to the active Domain object."}},"os.cpuSpec":{model:"string",speed:"number",times:{user:"number",nice:"number",sys:"number",idle:"number",irq:"number"}},"process.memoryUsage.type":{rss:"number",heapTotal:"?",number:"?",heapUsed:"number"},"net.address":{port:"number",family:"string",address:"string"},"url.type":{href:"string",protocol:"string",auth:"string",hostname:"string",port:"string",host:"string",pathname:"string",search:"string",query:"string",slashes:"bool",hash:"string"},"tls.Server.credentials":{key:"string",cert:"string",ca:"string"},"tls.cipher":{name:"string",version:"string"},"crypto.credentials":{pfx:"string",key:"string",passphrase:"string",cert:"string",ca:"string",crl:"string",ciphers:"string"},buffer:{Buffer:"Buffer",INSPECT_MAX_BYTES:"number",SlowBuffer:"Buffer"},module:{},timers:{setTimeout:{"!type":"fn(callback: fn(), ms: number) -> timers.Timer","!url":"http://nodejs.org/api/globals.html#globals_settimeout_cb_ms","!doc":"Run callback cb after at least ms milliseconds. The actual delay depends on external factors like OS timer granularity and system load."},clearTimeout:{"!type":"fn(id: timers.Timer)","!url":"http://nodejs.org/api/globals.html#globals_cleartimeout_t","!doc":"Stop a timer that was previously created with setTimeout(). The callback will not execute."},setInterval:{"!type":"fn(callback: fn(), ms: number) -> timers.Timer","!url":"http://nodejs.org/api/globals.html#globals_setinterval_cb_ms","!doc":"Run callback cb repeatedly every ms milliseconds. Note that the actual interval may vary, depending on external factors like OS timer granularity and system load. It's never less than ms but it may be longer."},clearInterval:{"!type":"fn(id: timers.Timer)","!url":"http://nodejs.org/api/globals.html#globals_clearinterval_t","!doc":"Stop a timer that was previously created with setInterval(). The callback will not execute."},setImmediate:{"!type":"fn(callback: fn()) -> timers.Timer","!url":"http://nodejs.org/api/timers.html#timers_setimmediate_callback_arg","!doc":"Schedule the 'immediate' execution of callback after I/O events callbacks."},clearImmediate:{"!type":"fn(id: timers.Timer)","!url":"http://nodejs.org/api/timers.html#timers_clearimmediate_immediateid","!doc":"Stops an immediate from triggering."},Timer:{unref:{"!type":"fn()","!url":"http://nodejs.org/api/timers.html#timers_unref","!doc":"Create a timer that is active but if it is the only item left in the event loop won't keep the program running."},ref:{"!type":"fn()","!url":"http://nodejs.org/api/timers.html#timers_unref","!doc":"Explicitly request the timer hold the program open (cancel the effect of 'unref')."}}}},process:{stdout:{"!type":"+stream.Writable","!url":"http://nodejs.org/api/process.html#process_process_stdout","!doc":"A Writable Stream to stdout."},stderr:{"!type":"+stream.Writable","!url":"http://nodejs.org/api/process.html#process_process_stderr","!doc":"A writable stream to stderr."},stdin:{"!type":"+stream.Readable","!url":"http://nodejs.org/api/process.html#process_process_stdin","!doc":"A Readable Stream for stdin. The stdin stream is paused by default, so one must call process.stdin.resume() to read from it."},argv:{"!type":"[string]","!url":"http://nodejs.org/api/process.html#process_process_argv","!doc":"An array containing the command line arguments. The first element will be 'node', the second element will be the name of the JavaScript file. The next elements will be any additional command line arguments."},execPath:{"!type":"string","!url":"http://nodejs.org/api/process.html#process_process_execpath","!doc":"This is the absolute pathname of the executable that started the process."},abort:{"!type":"fn()","!url":"http://nodejs.org/api/process.html#process_process_abort","!doc":"This causes node to emit an abort. This will cause node to exit and generate a core file."},chdir:{"!type":"fn(directory: string)","!url":"http://nodejs.org/api/process.html#process_process_chdir_directory","!doc":"Changes the current working directory of the process or throws an exception if that fails."},cwd:{"!type":"fn()","!url":"http://nodejs.org/api/process.html#process_process_cwd","!doc":"Returns the current working directory of the process."},env:{"!url":"http://nodejs.org/api/process.html#process_process_env","!doc":"An object containing the user environment."},exit:{"!type":"fn(code?: number)","!url":"http://nodejs.org/api/process.html#process_process_exit_code","!doc":"Ends the process with the specified code. If omitted, exit uses the 'success' code 0."},getgid:{"!type":"fn() -> number","!url":"http://nodejs.org/api/process.html#process_process_getgid","!doc":"Gets the group identity of the process. This is the numerical group id, not the group name."},setgid:{"!type":"fn(id: number)","!url":"http://nodejs.org/api/process.html#process_process_setgid_id","!doc":"Sets the group identity of the process. This accepts either a numerical ID or a groupname string. If a groupname is specified, this method blocks while resolving it to a numerical ID."},getuid:{"!type":"fn() -> number","!url":"http://nodejs.org/api/process.html#process_process_getuid","!doc":"Gets the user identity of the process. This is the numerical userid, not the username."},setuid:{"!type":"fn(id: number)","!url":"http://nodejs.org/api/process.html#process_process_setuid_id","!doc":"Sets the user identity of the process. This accepts either a numerical ID or a username string. If a username is specified, this method blocks while resolving it to a numerical ID."},version:{"!type":"string","!url":"http://nodejs.org/api/process.html#process_process_version","!doc":"A compiled-in property that exposes NODE_VERSION."},versions:{http_parser:"string",node:"string",v8:"string",ares:"string",uv:"string",zlib:"string",openssl:"string","!url":"http://nodejs.org/api/process.html#process_process_versions","!doc":"A property exposing version strings of node and its dependencies."},config:{target_defaults:{cflags:"[?]",default_configuration:"string",defines:"[string]",include_dirs:"[string]",libraries:"[string]"},variables:{clang:"number",host_arch:"string",node_install_npm:"bool",node_install_waf:"bool",node_prefix:"string",node_shared_openssl:"bool",node_shared_v8:"bool",node_shared_zlib:"bool",node_use_dtrace:"bool",node_use_etw:"bool",node_use_openssl:"bool",target_arch:"string",v8_no_strict_aliasing:"number",v8_use_snapshot:"bool",visibility:"string"},"!url":"http://nodejs.org/api/process.html#process_process_config","!doc":'An Object containing the JavaScript representation of the configure options that were used to compile the current node executable. This is the same as the "config.gypi" file that was produced when running the ./configure script.'},kill:{"!type":"fn(pid: number, signal?: string)","!url":"http://nodejs.org/api/process.html#process_process_kill_pid_signal","!doc":"Send a signal to a process. pid is the process id and signal is the string describing the signal to send. Signal names are strings like 'SIGINT' or 'SIGUSR1'. If omitted, the signal will be 'SIGTERM'."},pid:{"!type":"number","!url":"http://nodejs.org/api/process.html#process_process_pid","!doc":"The PID of the process."},title:{"!type":"string","!url":"http://nodejs.org/api/process.html#process_process_title","!doc":"Getter/setter to set what is displayed in 'ps'."},arch:{"!type":"string","!url":"http://nodejs.org/api/process.html#process_process_arch","!doc":"What processor architecture you're running on: 'arm', 'ia32', or 'x64'."},platform:{"!type":"string","!url":"http://nodejs.org/api/process.html#process_process_platform","!doc":"What platform you're running on: 'darwin', 'freebsd', 'linux', 'sunos' or 'win32'"},memoryUsage:{"!type":"fn() -> process.memoryUsage.type","!url":"http://nodejs.org/api/process.html#process_process_memoryusage","!doc":"Returns an object describing the memory usage of the Node process measured in bytes."},nextTick:{"!type":"fn(callback: fn())","!url":"http://nodejs.org/api/process.html#process_process_nexttick_callback","!doc":"On the next loop around the event loop call this callback. This is not a simple alias to setTimeout(fn, 0), it's much more efficient. It typically runs before any other I/O events fire, but there are some exceptions."},maxTickDepth:{"!type":"number","!url":"http://nodejs.org/api/process.html#process_process_maxtickdepth","!doc":"The maximum depth of nextTick-calling nextTick-callbacks that will be evaluated before allowing other forms of I/O to occur."},umask:{"!type":"fn(mask?: number) -> number","!url":"http://nodejs.org/api/process.html#process_process_umask_mask","!doc":"Sets or reads the process's file mode creation mask. Child processes inherit the mask from the parent process. Returns the old mask if mask argument is given, otherwise returns the current mask."},uptime:{"!type":"fn() -> number","!url":"http://nodejs.org/api/process.html#process_process_uptime","!doc":"Number of seconds Node has been running."},hrtime:{"!type":"fn() -> [number]","!url":"http://nodejs.org/api/process.html#process_process_hrtime","!doc":"Returns the current high-resolution real time in a [seconds, nanoseconds] tuple Array. It is relative to an arbitrary time in the past. It is not related to the time of day and therefore not subject to clock drift. The primary use is for measuring performance between intervals."},"!url":"http://nodejs.org/api/globals.html#globals_process","!doc":"The process object."},global:{"!type":"<top>","!url":"http://nodejs.org/api/globals.html#globals_global","!doc":"In browsers, the top-level scope is the global scope. That means that in browsers if you're in the global scope var something will define a global variable. In Node this is different. The top-level scope is not the global scope; var something inside a Node module will be local to that module."},console:{log:{"!type":"fn(text: string)","!url":"http://nodejs.org/api/stdio.html#stdio_console_log_data","!doc":"Prints to stdout with newline. This function can take multiple arguments in a printf()-like way."},info:{"!type":"fn(text: string)","!url":"http://nodejs.org/api/stdio.html#stdio_console_info_data","!doc":"Same as console.log."},error:{"!type":"fn(text: string)","!url":"http://nodejs.org/api/stdio.html#stdio_console_error_data","!doc":"Same as console.log but prints to stderr."},warn:{"!type":"fn(text: string)","!url":"http://nodejs.org/api/stdio.html#stdio_console_warn_data","!doc":"Same as console.error."},dir:{"!type":"fn(obj: ?)","!url":"http://nodejs.org/api/stdio.html#stdio_console_dir_obj","!doc":"Uses util.inspect on obj and prints resulting string to stdout."},time:{"!type":"fn(label: string)","!url":"http://nodejs.org/api/stdio.html#stdio_console_time_label","!doc":"Mark a time."},timeEnd:{"!type":"fn(label: string)","!url":"http://nodejs.org/api/stdio.html#stdio_console_timeend_label","!doc":"Finish timer, record output."},trace:{"!type":"fn(label: string)","!url":"http://nodejs.org/api/stdio.html#stdio_console_trace_label","!doc":"Print a stack trace to stderr of the current position."},assert:{"!type":"fn(expression: bool)","!url":"http://nodejs.org/api/stdio.html#stdio_console_assert_expression_message","!doc":"Same as assert.ok() where if the expression evaluates as false throw an AssertionError with message."},"!url":"http://nodejs.org/api/globals.html#globals_console","!doc":"Used to print to stdout and stderr."},__filename:{"!type":"string","!url":"http://nodejs.org/api/globals.html#globals_filename","!doc":"The filename of the code being executed. This is the resolved absolute path of this code file. For a main program this is not necessarily the same filename used in the command line. The value inside a module is the path to that module file."},__dirname:{"!type":"string","!url":"http://nodejs.org/api/globals.html#globals_dirname","!doc":"The name of the directory that the currently executing script resides in."},setTimeout:"timers.setTimeout",clearTimeout:"timers.clearTimeout",setInterval:"timers.setInterval",clearInterval:"timers.clearInterval",module:{"!type":"+Module","!url":"http://nodejs.org/api/globals.html#globals_module","!doc":"A reference to the current module. In particular module.exports is the same as the exports object. module isn't actually a global but rather local to each module."},Buffer:{"!type":"fn(str: string, encoding?: string) -> +Buffer",prototype:{"!proto":"String.prototype",write:"fn(string: string, offset?: number, length?: number, encoding?: string) -> number",toString:"fn(encoding?: string, start?: number, end?: number) -> string",length:"number",copy:"fn(targetBuffer: +Buffer, targetStart?: number, sourceStart?: number, sourceEnd?: number)",slice:"fn(start?: number, end?: number) -> +Buffer",readUInt8:"fn(offset: number, noAssert?: bool) -> number",readUInt16LE:"fn(offset: number, noAssert?: bool) -> number",readUInt16BE:"fn(offset: number, noAssert?: bool) -> number",readUInt32LE:"fn(offset: number, noAssert?: bool) -> number",readUInt32BE:"fn(offset: number, noAssert?: bool) -> number",readInt8:"fn(offset: number, noAssert?: bool) -> number",readInt16LE:"fn(offset: number, noAssert?: bool) -> number",readInt16BE:"fn(offset: number, noAssert?: bool) -> number",readInt32LE:"fn(offset: number, noAssert?: bool) -> number",readInt32BE:"fn(offset: number, noAssert?: bool) -> number",readFloatLE:"fn(offset: number, noAssert?: bool) -> number",readFloatBE:"fn(offset: number, noAssert?: bool) -> number",readDoubleLE:"fn(offset: number, noAssert?: bool) -> number",readDoubleBE:"fn(offset: number, noAssert?: bool) -> number",writeUInt8:"fn(value: number, offset: number, noAssert?: bool)",writeUInt16LE:"fn(value: number, offset: number, noAssert?: bool)",writeUInt16BE:"fn(value: number, offset: number, noAssert?: bool)",writeUInt32LE:"fn(value: number, offset: number, noAssert?: bool)",writeUInt32BE:"fn(value: number, offset: number, noAssert?: bool)",writeInt8:"fn(value: number, offset: number, noAssert?: bool)",writeInt16LE:"fn(value: number, offset: number, noAssert?: bool)",writeInt16BE:"fn(value: number, offset: number, noAssert?: bool)",writeInt32LE:"fn(value: number, offset: number, noAssert?: bool)",writeInt32BE:"fn(value: number, offset: number, noAssert?: bool)",writeFloatLE:"fn(value: number, offset: number, noAssert?: bool)",writeFloatBE:"fn(value: number, offset: number, noAssert?: bool)",writeDoubleLE:"fn(value: number, offset: number, noAssert?: bool)",writeDoubleBE:"fn(value: number, offset: number, noAssert?: bool)",fill:"fn(value: ?, offset?: number, end?: number)"},isBuffer:"fn(obj: ?) -> bool",byteLength:"fn(string: string, encoding?: string) -> number",concat:"fn(list: [+Buffer], totalLength?: number) -> +Buffer","!url":"http://nodejs.org/api/globals.html#globals_class_buffer","!doc":"Used to handle binary data."}}
}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require):"function"==typeof define&&define.amd?define("tern/plugin/orionPostgres",["../lib/infer","../lib/tern","./resolver"],e):void e(infer,tern,resolver)}(function(e,t,r){function n(n,s,a,i){var l=t.resolvePos(n,a),c=e.findExpressionAround(n.ast,null,l,n.scope),p=r.getTemplatesForNode(o,c);if(p&&p.length>0)for(var d=0;d<p.length;d++){var u=p[d];u.origin="postgres",u.type="template",i.push(u)}}var o=[{prefix:"postgres",name:"postgres",nodes:{top:!0,member:!1,prop:!1},description:" - Node.js require statement for Postgres DB",template:"var pg = require('pg');\n"},{prefix:"postgres",name:"postgres client",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Postgres DB client",template:"var pg = require('pg');\nvar url = \"postgres://postgres:${port}@${host}/${database}\";\nvar ${client} = new pg.Client(url);\n"},{prefix:"postgres",name:"postgres connect",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Postgres DB client and connect",template:"var pg = require('pg');\nvar url = \"postgres://postgres:${port}@${host}/${database}\";\nvar ${client} = new pg.Client(url);\n${client}.connect(function(error) {\n	${cursor}\n});\n"},{prefix:"postgres",name:"postgres query",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Postgres DB query statement",template:"${client}.query(${sql}, function(error, result) {\n	${cursor}\n});\n"}];t.registerPlugin("orionPostgres",function(){return{defs:s,passes:{variableCompletion:n}}});var s={pg:{connect:"fn(connection: string, callback: fn(err: Error, client: Client, done: fn()))",end:"fn()",ConnectionConfig:{user:"string",database:"string",password:"string",port:"number",host:"string"},Defaults:{poolSize:"number",poolIdleTimeout:"number",reapIntervalMillis:"number",binary:"bool",parseInt8:"bool"},ClientConfig:{ssl:"bool"},QueryConfig:{name:"string",text:"string",values:"[?]"},QueryResult:{rows:"[?]"},ResultBuilder:{command:"string",rowCount:"number",oid:"number",addRow:"fn(row: ?)"},Client:{"!type":"fn(connection: string)",prototype:{connect:"fn(callback?: fn(err: Error))",end:"fn()",query:"fn(queryText: string, callback?: fn(err: Error, result: QueryResult)) -> Query",copyFrom:"fn(queryText: string) -> stream.Writable",copyTo:"fn(queryText: string) -> stream.Readable",pauseDrain:"fn()",resumeDrain:"fn()",on:"fn(event: string, listener: fn()) -> Client"}},Query:{prototype:{on:"fn(event: string, listener: fn(row: ?, result?: ResultBuilder)) -> Query"}},Events:{prototype:{on:"fn(event: string, listener: fn(err: Error, client: Client)) -> Events"}}},"!name":"pg","!define":{"!node":{pg:{connect:"fn(connection: string, callback: fn(err: Error, client: Client, done: fn()))",end:"fn()",Client:"pg.Client"}}}}}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require):"function"==typeof define&&define.amd?define("tern/plugin/orionRedis",["../lib/infer","../lib/tern","./resolver"],e):void e(infer,tern,resolver)}(function(e,t,r){function n(n,s,a,i){var l=t.resolvePos(n,a),c=e.findExpressionAround(n.ast,null,l,n.scope),p=r.getTemplatesForNode(o,c);if(p&&p.length>0)for(var d=0;d<p.length;d++){var u=p[d];u.origin="redis",u.type="template",i.push(u)}}var o=[{prefix:"redis",name:"redis",nodes:{top:!0,member:!1,prop:!1},description:" - Node.js require statement for Redis",template:"var ${name} = require('redis');\n"},{prefix:"redis",name:"redis client",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Redis client",template:"var ${name} = require('redis');\nvar ${client} = ${name}.createClient(${port}, ${host}, ${options});\n"},{prefix:"redis",name:"redis connect",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Redis client and connect",template:"var ${name} = require('redis');\nvar ${client} = ${name}.createClient(${port}, ${host}, ${options});\ntry {\n	${cursor}\n} finally {\n	${client}.close();\n}\n"},{prefix:"redis",name:"redis set",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Redis client set call",template:"client.set(${key}, ${value});\n"},{prefix:"redis",name:"redis get",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Redis client get call",template:"client.get(${key}, function(${error}, ${reply}) {\n	${cursor}\n});\n"},{prefix:"redis",name:"redis on",nodes:{top:!0,member:!1,prop:!1},description:" - create a new Redis client event handler",template:"client.on(${event}, function(${arg}) {\n	${cursor}});\n"}];t.registerPlugin("orionRedis",function(){return{defs:s,passes:{variableCompletion:n}}});var s={"!name":"redis","!define":{"!node":{redis:{createClient:"fn(port_arg: number, host_arg?: string, options?: ClientOpts) -> RedisClient",print:"fn(err: Error, reply: ?)",debug_mode:"bool",ClientOpts:"redis.ClientOpts"}}},ClientOpts:{parser:"string",return_buffers:"bool",detect_buffers:"bool",socket_nodelay:"bool",no_ready_check:"bool",enable_offline_queue:"bool",retry_max_delay:"number",connect_timeout:"number",max_attempts:"number",auth_pass:"string"},RedisClient:{connected:"bool",retry_delay:"number",retry_backoff:"number",command_queue:"[?]",offline_queue:"[?]",server_info:"ServerInfo",end:"fn()",auth:"fn(password: string, callback?: ?)",ping:"fn(callback?: ?)",append:"fn(key: string, value: string, callback?: ?)",bitcount:"fn(key: string, callback?: ?)",set:"fn(key: string, value: string, callback?: ?)",get:"fn(key: string, callback?: ?)",exists:"fn(key: string, value: string, callback?: ?)",publish:"fn(channel: string, value: ?)",subscribe:"fn(channel: string)",setnx:"fn(args: [?], callback?: ?)",setex:"fn(args: [?], callback?: ?)",strlen:"fn(args: [?], callback?: ?)",del:"fn(args: [?], callback?: ?)",setbit:"fn(args: [?], callback?: ?)",getbit:"fn(args: [?], callback?: ?)",setrange:"fn(args: [?], callback?: ?)",getrange:"fn(args: [?], callback?: ?)",substr:"fn(args: [?], callback?: ?)",incr:"fn(args: [?], callback?: ?)",decr:"fn(args: [?], callback?: ?)",mget:"fn(args: [?], callback?: ?)",rpush:"fn(args: [?])",lpush:"fn(args: [?], callback?: ?)",rpushx:"fn(args: [?], callback?: ?)",lpushx:"fn(args: [?], callback?: ?)",linsert:"fn(args: [?], callback?: ?)",rpop:"fn(args: [?], callback?: ?)",lpop:"fn(args: [?], callback?: ?)",brpop:"fn(args: [?], callback?: ?)",brpoplpush:"fn(args: [?], callback?: ?)",blpop:"fn(args: [?], callback?: ?)",llen:"fn(args: [?], callback?: ?)",lindex:"fn(args: [?], callback?: ?)",lset:"fn(args: [?], callback?: ?)",lrange:"fn(args: [?], callback?: ?)",ltrim:"fn(args: [?], callback?: ?)",lrem:"fn(args: [?], callback?: ?)",rpoplpush:"fn(args: [?], callback?: ?)",sadd:"fn(args: [?], callback?: ?)",srem:"fn(args: [?], callback?: ?)",smove:"fn(args: [?], callback?: ?)",sismember:"fn(args: [?], callback?: ?)",scard:"fn(args: [?], callback?: ?)",spop:"fn(args: [?], callback?: ?)",srandmember:"fn(args: [?], callback?: ?)",sinter:"fn(args: [?], callback?: ?)",sinterstore:"fn(args: [?], callback?: ?)",sunion:"fn(args: [?], callback?: ?)",sunionstore:"fn(args: [?], callback?: ?)",sdiff:"fn(args: [?], callback?: ?)",sdiffstore:"fn(args: [?], callback?: ?)",smembers:"fn(args: [?], callback?: ?)",zadd:"fn(args: [?], callback?: ?)",zincrby:"fn(args: [?], callback?: ?)",zrem:"fn(args: [?], callback?: ?)",zremrangebyscore:"fn(args: [?], callback?: ?)",zremrangebyrank:"fn(args: [?], callback?: ?)",zunionstore:"fn(args: [?], callback?: ?)",zinterstore:"fn(args: [?], callback?: ?)",zrange:"fn(args: [?], callback?: ?)",zrangebyscore:"fn(args: [?], callback?: ?)",zrevrangebyscore:"fn(args: [?], callback?: ?)",zcount:"fn(args: [?], callback?: ?)",zrevrange:"fn(args: [?], callback?: ?)",zcard:"fn(args: [?], callback?: ?)",zscore:"fn(args: [?], callback?: ?)",zrank:"fn(args: [?], callback?: ?)",zrevrank:"fn(args: [?], callback?: ?)",hset:"fn(args: [?], callback?: ?)",hsetnx:"fn(args: [?], callback?: ?)",hget:"fn(args: [?], callback?: ?)",hmset:"fn(args: [?], callback?: ?)",hmget:"fn(args: [?], callback?: ?)",hincrby:"fn(args: [?], callback?: ?)",hdel:"fn(args: [?], callback?: ?)",hlen:"fn(args: [?], callback?: ?)",hkeys:"fn(args: [?], callback?: ?)",hvals:"fn(args: [?], callback?: ?)",hgetall:"fn(args: [?], callback?: ?)",hexists:"fn(args: [?], callback?: ?)",incrby:"fn(args: [?], callback?: ?)",decrby:"fn(args: [?], callback?: ?)",getset:"fn(args: [?], callback?: ?)",mset:"fn(args: [?], callback?: ?)",msetnx:"fn(args: [?], callback?: ?)",randomkey:"fn(args: [?], callback?: ?)",select:"fn(args: [?], callback?: ?)",move:"fn(args: [?], callback?: ?)",rename:"fn(args: [?], callback?: ?)",renamenx:"fn(args: [?], callback?: ?)",expire:"fn(args: [?], callback?: ?)",expireat:"fn(args: [?], callback?: ?)",keys:"fn(args: [?], callback?: ?)",dbsize:"fn(args: [?], callback?: ?)",echo:"fn(args: [?], callback?: ?)",save:"fn(args: [?], callback?: ?)",bgsave:"fn(args: [?], callback?: ?)",bgrewriteaof:"fn(args: [?], callback?: ?)",shutdown:"fn(args: [?], callback?: ?)",lastsave:"fn(args: [?], callback?: ?)",type:"fn(args: [?], callback?: ?)",multi:"fn(args: [?], callback?: ?)",exec:"fn(args: [?], callback?: ?)",discard:"fn(args: [?], callback?: ?)",sync:"fn(args: [?], callback?: ?)",flushdb:"fn(args: [?], callback?: ?)",flushall:"fn(args: [?], callback?: ?)",sort:"fn(args: [?], callback?: ?)",info:"fn(args: [?], callback?: ?)",monitor:"fn(args: [?], callback?: ?)",ttl:"fn(args: [?], callback?: ?)",persist:"fn(args: [?], callback?: ?)",slaveof:"fn(args: [?], callback?: ?)",debug:"fn(args: [?], callback?: ?)",config:"fn(args: [?], callback?: ?)",unsubscribe:"fn(args: [?], callback?: ?)",psubscribe:"fn(args: [?], callback?: ?)",punsubscribe:"fn(args: [?], callback?: ?)",watch:"fn(args: [?], callback?: ?)",unwatch:"fn(args: [?], callback?: ?)",cluster:"fn(args: [?], callback?: ?)",restore:"fn(args: [?], callback?: ?)",migrate:"fn(args: [?], callback?: ?)",dump:"fn(args: [?], callback?: ?)",object:"fn(args: [?], callback?: ?)",client:"fn(args: [?], callback?: ?)",eval:"fn(args: [?], callback?: ?)",evalsha:"fn(args: [?], callback?: ?)",quit:"fn(args: [?], callback?: ?)"},createClient:"fn(port_arg: number, host_arg?: string, options?: ClientOpts) -> RedisClient",print:"fn(err: Error, reply: ?)",debug_mode:"bool",MessageHandler:{},ServerInfo:{redis_version:"string",versions:"[number]"}}}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern")):"function"==typeof define&&define.amd?define("tern/plugin/requirejs",["../lib/infer","../lib/tern","./resolver"],e):void e(tern,tern)}(function(e,t,r){"use strict";function n(t,r){r.push(t?t:e.ANull)}function o(t){return t.require||(t.require=new e.Fn("require",e.ANull,[e.cx().str],["module"],new e.AVal),t.require.computeRet=function(r,n,o){if(o.length&&"Literal"==o[0].type&&"string"==typeof o[0].value){var s=i(o[0].value,t);if(s)return s}return e.ANull}),t.require}function s(t,r){var n=new e.Obj(e.cx().definitions.requirejs.module,"module"),o=n.defProp("exports"),s=c(p(t.currentFile),t);return s&&o.propagate(s),r.propagate(o,m),n}function a(t){var r=new e.Obj(!0,"exports"),n=c(p(t.currentFile),t);return n&&n.addType(r,m),r}function i(t,r){if(r.options.override&&Object.prototype.hasOwnProperty.call(r.options.override,t)){var n=r.options.override[t];if("string"==typeof n&&"="==n.charAt(0))return e.def.parsePath(n.slice(1));if("object"==typeof n){var o=l(t,r);if(o)return o;var s=r.interfaces[p(t)]=new e.Obj(null,p(t));return e.def.load(n,s),s}t=n}return o=c(t,r),o&&r.server.addFile(o.origin,o.contents,r.currentFile),o}function l(e,t){var n=r.getResolved(e);return n&&n.file?t.interfaces[p(n.file)]:null}function c(t,n){var o=l(t,n);if(!o){var s=r.getResolved(t);s&&s.file&&(o=n.interfaces[p(s.file)]=new e.AVal,o.origin=s.file,o.contents=s.contents)}return o}function p(e){return e.replace(/\.js$/,"")}function d(e){switch(e.type){case"ArrayExpression":return e.elements.map(d);case"Literal":return e.value;case"ObjectExpression":var t={};return e.properties.forEach(function(e){var r=e.key.name||e.key.value;t[r]=d(e.value)}),t}}function u(t){var r=e.cx().parent._requireJS.interfaces,n=t.roots["!requirejs"]=new e.Obj(null);for(var o in r){var s=n.defProp(o.replace(/\./g,"`"));r[o].propagate(s),s.origin=r[o].origin}}function h(t){var r=e.cx(),n=r.definitions[t["!name"]]["!requirejs"],t=r.parent._requireJS;if(n)for(var o in n.props)n.props[o].propagate(i(o,t))}function f(e,t,r,n){if(!r||"Literal"!=r.node.type||"string"!=typeof r.node.value||!r.node.required)return n;n=Object.create(n);var o=r.node.required;return n.origin=o.origin,n.originNode=o.originNode,n}var m=50;e.registerFunction("requireJS",function(t,r,l){function c(e){return"require"==e?o(u):"exports"==e?g||(g=a(u)):"module"==e?b||(b=s(u,g||(g=a(u)))):i(e,u)}var d=e.cx().parent,u=d&&d._requireJS;if(!u||!r.length)return e.ANull;var h=u.currentFile,f=u.interfaces[p(h)]=new e.AVal;f.origin=h;var m,g,b,y=[];if(l&&r.length>1){var v=l[2==r.length?0:1];if("Literal"==v.type&&"string"==typeof v.value)n(c(v.value),y);else if("ArrayExpression"==v.type)for(var w=0;w<v.elements.length;++w){var _=v.elements[w];"Literal"==_.type&&"string"==typeof _.value&&n(c(_.value),y)}}else l&&1==r.length&&"FunctionExpression"==l[0].type&&l[0].params.length&&(n(c("require",u),y),n(c("exports",u),y),n(c("module",u),y),m=r[0]);return m||(m=r[Math.min(r.length-1,2)],m.isEmpty()||m.getFunctionType()||(m=null)),m?(m.propagate(new e.IsCallee(e.ANull,y,null,f)),f.originNode=m.originNode):r.length&&r[0].propagate(f),e.ANull}),e.registerFunction("requireJSConfig",function(t,r,n){var o=e.cx().parent,s=o&&o._requireJS;if(s&&n&&n.length&&"ObjectExpression"==n[0].type){var a=d(n[0]);for(var i in a)if(a.hasOwnProperty(i)){var l=a[i],c=s.options[i];if(c){if("paths"==i)for(var p in l)l.hasOwnProperty(p)&&!s.options.paths[p]&&(s.options.paths[p]=l[p])}else s.options[i]=l}}return e.ANull}),t.registerPlugin("requirejs",function(t,n){return t._requireJS={interfaces:Object.create(null),options:n||{},currentFile:null,server:t},t.on("beforeLoad",function(e){this._requireJS.currentFile=e.name}),t.on("reset",function(){this._requireJS.interfaces=Object.create(null),this._requireJS.require=null}),{defs:g,passes:{preCondenseReach:u,postLoadDef:h,typeAt:f,postParse:function(n){r.doPostParse(t,n,e.cx().definitions)},preInfer:function(){r.doPreInfer(t)}}}});var g={"!name":"requirejs","!define":{module:{id:"string",uri:"string",config:"fn() -> ?"},config:{"!url":"http://requirejs.org/docs/api.html#config",baseUrl:{"!type":"string","!doc":"the root path to use for all module lookups","!url":"http://requirejs.org/docs/api.html#config-baseUrl"},paths:{"!type":"?","!doc":"path mappings for module names not found directly under baseUrl. The path settings are assumed to be relative to baseUrl, unless the paths setting starts with a '/' or has a URL protocol in it ('like http:').","!url":"http://requirejs.org/docs/api.html#config-paths"},shim:{"!type":"?","!doc":"Configure the dependencies, exports, and custom initialization for older, traditional 'browser globals' scripts that do not use define() to declare the dependencies and set a module value.","!url":"http://requirejs.org/docs/api.html#config-shim"},map:{"!type":"?","!doc":"For the given module prefix, instead of loading the module with the given ID, substitute a different module ID.","!url":"http://requirejs.org/docs/api.html#config-map"},config:{"!type":"?","!doc":"There is a common need to pass configuration info to a module. That configuration info is usually known as part of the application, and there needs to be a way to pass that down to a module. In RequireJS, that is done with the config option for requirejs.config(). Modules can then read that info by asking for the special dependency 'module' and calling module.config().","!url":"http://requirejs.org/docs/api.html#config-moduleconfig"},packages:{"!type":"?","!doc":"configures loading modules from CommonJS packages. See the packages topic for more information.","!url":"http://requirejs.org/docs/api.html#config-packages"},nodeIdCompat:{"!type":"?","!doc":"Node treats module ID example.js and example the same. By default these are two different IDs in RequireJS. If you end up using modules installed from npm, then you may need to set this config value to true to avoid resolution issues.","!url":"http://requirejs.org/docs/api.html#config-nodeIdCompat"},waitSeconds:{"!type":"number","!doc":"The number of seconds to wait before giving up on loading a script. Setting it to 0 disables the timeout. The default is 7 seconds.","!url":"http://requirejs.org/docs/api.html#config-waitSeconds"},context:{"!type":"number","!doc":"A name to give to a loading context. This allows require.js to load multiple versions of modules in a page, as long as each top-level require call specifies a unique context string. To use it correctly, see the Multiversion Support section.","!url":"http://requirejs.org/docs/api.html#config-context"},deps:{"!type":"?","!doc":"An array of dependencies to load. Useful when require is defined as a config object before require.js is loaded, and you want to specify dependencies to load as soon as require() is defined. Using deps is just like doing a require([]) call, but done as soon as the loader has processed the configuration. It does not block any other require() calls from starting their requests for modules, it is just a way to specify some modules to load asynchronously as part of a config block.","!url":"http://requirejs.org/docs/api.html#config-deps"},callback:{"!type":"fn()","!doc":"A function to execute after deps have been loaded. Useful when require is defined as a config object before require.js is loaded, and you want to specify a function to require after the configuration's deps array has been loaded.","!url":"http://requirejs.org/docs/api.html#config-callback"},enforceDefine:{"!type":"bool","!doc":"If set to true, an error will be thrown if a script loads that does not call define() or have a shim exports string value that can be checked. See Catching load failures in IE for more information.","!url":"http://requirejs.org/docs/api.html#config-enforceDefine"},xhtml:{"!type":"bool","!doc":"If set to true, document.createElementNS() will be used to create script elements.","!url":"http://requirejs.org/docs/api.html#config-xhtml"},urlArgs:{"!type":"string","!doc":"Extra query string arguments appended to URLs that RequireJS uses to fetch resources. Most useful to cache bust when the browser or server is not configured correctly.","!url":"http://requirejs.org/docs/api.html#config-urlArgs"},scriptType:{"!type":"string","!doc":"Specify the value for the type='' attribute used for script tags inserted into the document by RequireJS. Default is 'text/javascript'. To use Firefox's JavaScript 1.8 features, use 'text/javascript;version=1.8'.","!url":"http://requirejs.org/docs/api.html#config-scriptType"},skipDataMain:{"!type":"bool","!doc":"Introduced in RequireJS 2.1.9: If set to true, skips the data-main attribute scanning done to start module loading. Useful if RequireJS is embedded in a utility library that may interact with other RequireJS library on the page, and the embedded version should not do data-main loading.","!url":"http://requirejs.org/docs/api.html#config-skipDataMain"}},RequireJSError:{prototype:{"!proto":"Error.prototype",requireType:{"!type":"string","!doc":"A string value with a general classification, like 'timeout', 'nodefine', 'scripterror'.","!url":"http://requirejs.org/docs/api.html#errors"},requireModules:{"!type":"[string]","!doc":"An array of module names/URLs that timed out.","!url":"http://requirejs.org/docs/api.html#errors"}}}},requirejs:{"!type":"fn(deps: [string], callback: fn(), errback?: fn(err: +RequireJSError)) -> !custom:requireJS",onError:{"!type":"fn(err: +RequireJSError)","!doc":"To detect errors that are not caught by local errbacks, you can override requirejs.onError()","!url":"http://requirejs.org/docs/api.html#requirejsonerror"},load:{"!type":"fn(context: ?, moduleName: string, url: string)"},config:"fn(config: config) -> !custom:requireJSConfig",version:"string",isBrowser:"bool"},require:"requirejs",define:{"!type":"fn(deps: [string], callback: fn()) -> !custom:requireJS",amd:{jQuery:"bool"}}}}),define("tern/plugin/ternPlugins",["../lib/infer","../lib/tern","acorn/dist/walk"],function(e,t){t.registerPlugin("ternPlugins",function(){return{}}),t.defineQueryType("installed_plugins",{run:function(e){return e.options&&"object"==typeof e.options.plugins?e.options.plugins:null}}),t.defineQueryType("environments",{run:function(e){if(e.options&&"object"==typeof e.options.plugins){for(var t=e.options.plugins,r=Object.keys(t),n=Object.create(null),o=0;o<r.length;o++){var s=r[o],a=t[s].env;a&&(n[a]=!0)}return n}return null}}),t.defineQueryType("install_plugins",{run:function(){}}),t.defineQueryType("remove_plugins",{run:function(){}}),t.defineQueryType("plugin_enablement",{run:function(){}})}),function(e,t){"use strict";"function"==typeof define&&define.amd?define("estraverse/estraverse",["exports"],t):t("undefined"!=typeof exports?exports:e.estraverse={})}(this,function(e){"use strict";function t(){}function r(e){var t,n,o={};for(t in e)e.hasOwnProperty(t)&&(n=e[t],o[t]="object"==typeof n&&null!==n?r(n):n);return o}function n(e){var t,r={};for(t in e)e.hasOwnProperty(t)&&(r[t]=e[t]);return r}function o(e,t){var r,n,o,s;for(n=e.length,o=0;n;)r=n>>>1,s=o+r,t(e[s])?n=r:(o=s+1,n-=r+1);return o}function s(e,t){var r,n,o,s;for(n=e.length,o=0;n;)r=n>>>1,s=o+r,t(e[s])?(o=s+1,n-=r+1):n=r;return o}function a(e,t){return _(t).forEach(function(r){e[r]=t[r]}),e}function i(e,t){this.parent=e,this.key=t}function l(e,t,r,n){this.node=e,this.path=t,this.wrap=r,this.ref=n}function c(){}function p(e){return null==e?!1:"object"==typeof e&&"string"==typeof e.type}function d(e,t){return(e===g.ObjectExpression||e===g.ObjectPattern)&&"properties"===t}function u(e,t){var r=new c;return r.traverse(e,t)}function h(e,t){var r=new c;return r.replace(e,t)}function f(e,t){var r;return r=o(t,function(t){return t.range[0]>e.range[0]}),e.extendedRange=[e.range[0],e.range[1]],r!==t.length&&(e.extendedRange[1]=t[r].range[0]),r-=1,r>=0&&(e.extendedRange[0]=t[r].range[1]),e}function m(e,t,n){var o,s,a,i,l=[];if(!e.range)throw new Error("attachComments needs range information");if(!n.length){if(t.length){for(a=0,s=t.length;s>a;a+=1)o=r(t[a]),o.extendedRange=[0,e.range[0]],l.push(o);e.leadingComments=l}return e}for(a=0,s=t.length;s>a;a+=1)l.push(f(r(t[a]),n));return i=0,u(e,{enter:function(e){for(var t;i<l.length&&(t=l[i],!(t.extendedRange[1]>e.range[0]));)t.extendedRange[1]===e.range[0]?(e.leadingComments||(e.leadingComments=[]),e.leadingComments.push(t),l.splice(i,1)):i+=1;return i===l.length?y.Break:l[i].extendedRange[0]>e.range[1]?y.Skip:void 0}}),i=0,u(e,{leave:function(e){for(var t;i<l.length&&(t=l[i],!(e.range[1]<t.extendedRange[0]));)e.range[1]===t.extendedRange[0]?(e.trailingComments||(e.trailingComments=[]),e.trailingComments.push(t),l.splice(i,1)):i+=1;return i===l.length?y.Break:l[i].extendedRange[0]>e.range[1]?y.Skip:void 0}}),e}var g,b,y,v,w,_,S,T,E;b=Array.isArray,b||(b=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),t(n),t(s),w=Object.create||function(){function e(){}return function(t){return e.prototype=t,new e}}(),_=Object.keys||function(e){var t,r=[];for(t in e)r.push(t);return r},g={AssignmentExpression:"AssignmentExpression",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",AwaitExpression:"AwaitExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ComprehensionBlock:"ComprehensionBlock",ComprehensionExpression:"ComprehensionExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DebuggerStatement:"DebuggerStatement",DirectiveStatement:"DirectiveStatement",DoWhileStatement:"DoWhileStatement",EmptyStatement:"EmptyStatement",ExportBatchSpecifier:"ExportBatchSpecifier",ExportDeclaration:"ExportDeclaration",ExportSpecifier:"ExportSpecifier",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForInStatement:"ForInStatement",ForOfStatement:"ForOfStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",GeneratorExpression:"GeneratorExpression",Identifier:"Identifier",IfStatement:"IfStatement",ImportDeclaration:"ImportDeclaration",ImportDefaultSpecifier:"ImportDefaultSpecifier",ImportNamespaceSpecifier:"ImportNamespaceSpecifier",ImportSpecifier:"ImportSpecifier",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MethodDefinition:"MethodDefinition",ModuleSpecifier:"ModuleSpecifier",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",Program:"Program",Property:"Property",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SpreadElement:"SpreadElement",SwitchStatement:"SwitchStatement",SwitchCase:"SwitchCase",TaggedTemplateExpression:"TaggedTemplateExpression",TemplateElement:"TemplateElement",TemplateLiteral:"TemplateLiteral",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"},v={AssignmentExpression:["left","right"],ArrayExpression:["elements"],ArrayPattern:["elements"],ArrowFunctionExpression:["params","defaults","rest","body"],AwaitExpression:["argument"],BlockStatement:["body"],BinaryExpression:["left","right"],BreakStatement:["label"],CallExpression:["callee","arguments"],CatchClause:["param","body"],ClassBody:["body"],ClassDeclaration:["id","body","superClass"],ClassExpression:["id","body","superClass"],ComprehensionBlock:["left","right"],ComprehensionExpression:["blocks","filter","body"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DirectiveStatement:[],DoWhileStatement:["body","test"],EmptyStatement:[],ExportBatchSpecifier:[],ExportDeclaration:["declaration","specifiers","source"],ExportSpecifier:["id","name"],ExpressionStatement:["expression"],ForStatement:["init","test","update","body"],ForInStatement:["left","right","body"],ForOfStatement:["left","right","body"],FunctionDeclaration:["id","params","defaults","rest","body"],FunctionExpression:["id","params","defaults","rest","body"],GeneratorExpression:["blocks","filter","body"],Identifier:[],IfStatement:["test","consequent","alternate"],ImportDeclaration:["specifiers","source"],ImportDefaultSpecifier:["id"],ImportNamespaceSpecifier:["id"],ImportSpecifier:["id","name"],Literal:[],LabeledStatement:["label","body"],LogicalExpression:["left","right"],MemberExpression:["object","property"],MethodDefinition:["key","value"],ModuleSpecifier:[],NewExpression:["callee","arguments"],ObjectExpression:["properties"],ObjectPattern:["properties"],Program:["body"],Property:["key","value"],ReturnStatement:["argument"],SequenceExpression:["expressions"],SpreadElement:["argument"],SwitchStatement:["discriminant","cases"],SwitchCase:["test","consequent"],TaggedTemplateExpression:["tag","quasi"],TemplateElement:[],TemplateLiteral:["quasis","expressions"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handlers","handler","guardedHandlers","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],WhileStatement:["test","body"],WithStatement:["object","body"],YieldExpression:["argument"]},S={},T={},E={},y={Break:S,Skip:T,Remove:E},i.prototype.replace=function(e){this.parent[this.key]=e},i.prototype.remove=function(){return b(this.parent)?(this.parent.splice(this.key,1),!0):(this.replace(null),!1)},c.prototype.path=function(){function e(e,t){if(b(t))for(n=0,o=t.length;o>n;++n)e.push(t[n]);else e.push(t)}var t,r,n,o,s,a;if(!this.__current.path)return null;for(s=[],t=2,r=this.__leavelist.length;r>t;++t)a=this.__leavelist[t],e(s,a.path);return e(s,this.__current.path),s},c.prototype.type=function(){var e=this.current();return e.type||this.__current.wrap},c.prototype.parents=function(){var e,t,r;for(r=[],e=1,t=this.__leavelist.length;t>e;++e)r.push(this.__leavelist[e].node);return r},c.prototype.current=function(){return this.__current.node},c.prototype.__execute=function(e,t){var r,n;return n=void 0,r=this.__current,this.__current=t,this.__state=null,e&&(n=e.call(this,t.node,this.__leavelist[this.__leavelist.length-1].node)),this.__current=r,n},c.prototype.notify=function(e){this.__state=e},c.prototype.skip=function(){this.notify(T)},c.prototype["break"]=function(){this.notify(S)},c.prototype.remove=function(){this.notify(E)},c.prototype.__initialize=function(e,t){this.visitor=t,this.root=e,this.__worklist=[],this.__leavelist=[],this.__current=null,this.__state=null,this.__fallback="iteration"===t.fallback,this.__keys=v,t.keys&&(this.__keys=a(w(this.__keys),t.keys))},c.prototype.traverse=function(e,t){var r,n,o,s,a,i,c,u,h,f,m,g;for(this.__initialize(e,t),g={},r=this.__worklist,n=this.__leavelist,r.push(new l(e,null,null,null)),n.push(new l(null,null,null,null));r.length;)if(o=r.pop(),o!==g){if(o.node){if(i=this.__execute(t.enter,o),this.__state===S||i===S)return;if(r.push(g),n.push(o),this.__state===T||i===T)continue;if(s=o.node,a=o.wrap||s.type,f=this.__keys[a],!f){if(!this.__fallback)throw new Error("Unknown node type "+a+".");f=_(s)}for(u=f.length;(u-=1)>=0;)if(c=f[u],m=s[c])if(b(m)){for(h=m.length;(h-=1)>=0;)if(m[h]){if(d(a,f[u]))o=new l(m[h],[c,h],"Property",null);else{if(!p(m[h]))continue;o=new l(m[h],[c,h],null,null)}r.push(o)}}else p(m)&&r.push(new l(m,c,null,null))}}else if(o=n.pop(),i=this.__execute(t.leave,o),this.__state===S||i===S)return},c.prototype.replace=function(e,t){function r(e){var t,r,o,s;if(e.ref.remove())for(r=e.ref.key,s=e.ref.parent,t=n.length;t--;)if(o=n[t],o.ref&&o.ref.parent===s){if(o.ref.key<r)break;--o.ref.key}}var n,o,s,a,c,u,h,f,m,g,y,v,w;for(this.__initialize(e,t),y={},n=this.__worklist,o=this.__leavelist,v={root:e},u=new l(e,null,null,new i(v,"root")),n.push(u),o.push(u);n.length;)if(u=n.pop(),u!==y){if(c=this.__execute(t.enter,u),void 0!==c&&c!==S&&c!==T&&c!==E&&(u.ref.replace(c),u.node=c),(this.__state===E||c===E)&&(r(u),u.node=null),this.__state===S||c===S)return v.root;if(s=u.node,s&&(n.push(y),o.push(u),this.__state!==T&&c!==T)){if(a=u.wrap||s.type,m=this.__keys[a],!m){if(!this.__fallback)throw new Error("Unknown node type "+a+".");m=_(s)}for(h=m.length;(h-=1)>=0;)if(w=m[h],g=s[w])if(b(g)){for(f=g.length;(f-=1)>=0;)if(g[f]){if(d(a,m[h]))u=new l(g[f],[w,f],"Property",new i(g,f));else{if(!p(g[f]))continue;u=new l(g[f],[w,f],null,new i(g,f))}n.push(u)}}else p(g)&&n.push(new l(g,w,null,new i(s,w)))}}else if(u=o.pop(),c=this.__execute(t.leave,u),void 0!==c&&c!==S&&c!==T&&c!==E&&u.ref.replace(c),(this.__state===E||c===E)&&r(u),this.__state===S||c===S)return v.root;return v.root},e.version="1.8.1-dev",e.Syntax=g,e.traverse=u,e.replace=h,e.attachComments=m,e.VisitorKeys=v,e.VisitorOption=y,e.Controller=c}),define("eslint/conf/globals",[],function(){return{builtin:{Array:!1,ArrayBuffer:!1,Boolean:!1,constructor:!1,Date:!1,DataView:!1,decodeURI:!1,decodeURIComponent:!1,encodeURI:!1,encodeURIComponent:!1,Error:!1,eval:!1,EvalError:!1,Float32Array:!1,Float64Array:!1,Function:!1,hasOwnProperty:!1,Infinity:!1,Int16Array:!1,Int32Array:!1,Int8Array:!1,isFinite:!1,isNaN:!1,isPrototypeOf:!1,JSON:!1,Map:!1,Math:!1,NaN:!1,Number:!1,Object:!1,parseFloat:!1,parseInt:!1,Promise:!1,propertyIsEnumerable:!1,Proxy:!1,RangeError:!1,ReferenceError:!1,Reflect:!1,RegExp:!1,Set:!1,String:!1,Symbol:!1,SyntaxError:!1,System:!1,toLocaleString:!1,toString:!1,TypeError:!1,Uint16Array:!1,Uint32Array:!1,Uint8Array:!1,Uint8ClampedArray:!1,undefined:!1,URIError:!1,valueOf:!1,WeakMap:!1,WeakSet:!1},nonstandard:{escape:!1,unescape:!1},browser:{addEventListener:!1,alert:!1,applicationCache:!1,atob:!1,Audio:!1,AudioProcessingEvent:!1,BeforeUnloadEvent:!1,Blob:!1,blur:!1,btoa:!1,cancelAnimationFrame:!1,CanvasGradient:!1,CanvasPattern:!1,CanvasRenderingContext2D:!1,clearInterval:!1,clearTimeout:!1,close:!1,closed:!1,CloseEvent:!1,Comment:!1,CompositionEvent:!1,confirm:!1,console:!1,crypto:!1,CSS:!1,CustomEvent:!1,DataView:!1,Debug:!1,defaultStatus:!1,devicePixelRatio:!1,dispatchEvent:!1,document:!1,Document:!1,DocumentFragment:!1,DOMParser:!1,DragEvent:!1,Element:!1,ElementTimeControl:!1,ErrorEvent:!1,event:!1,Event:!1,FileReader:!1,find:!1,focus:!1,FocusEvent:!1,FormData:!1,frameElement:!1,frames:!1,GamepadEvent:!1,getComputedStyle:!1,getSelection:!1,HashChangeEvent:!1,history:!1,HTMLAnchorElement:!1,HTMLBaseElement:!1,HTMLBlockquoteElement:!1,HTMLBodyElement:!1,HTMLBRElement:!1,HTMLButtonElement:!1,HTMLCanvasElement:!1,HTMLDirectoryElement:!1,HTMLDivElement:!1,HTMLDListElement:!1,HTMLElement:!1,HTMLFieldSetElement:!1,HTMLFontElement:!1,HTMLFormElement:!1,HTMLFrameElement:!1,HTMLFrameSetElement:!1,HTMLHeadElement:!1,HTMLHeadingElement:!1,HTMLHRElement:!1,HTMLHtmlElement:!1,HTMLIFrameElement:!1,HTMLImageElement:!1,HTMLInputElement:!1,HTMLIsIndexElement:!1,HTMLLabelElement:!1,HTMLLayerElement:!1,HTMLLegendElement:!1,HTMLLIElement:!1,HTMLLinkElement:!1,HTMLMapElement:!1,HTMLMenuElement:!1,HTMLMetaElement:!1,HTMLModElement:!1,HTMLObjectElement:!1,HTMLOListElement:!1,HTMLOptGroupElement:!1,HTMLOptionElement:!1,HTMLParagraphElement:!1,HTMLParamElement:!1,HTMLPreElement:!1,HTMLQuoteElement:!1,HTMLScriptElement:!1,HTMLSelectElement:!1,HTMLStyleElement:!1,HTMLTableCaptionElement:!1,HTMLTableCellElement:!1,HTMLTableColElement:!1,HTMLTableElement:!1,HTMLTableRowElement:!1,HTMLTableSectionElement:!1,HTMLTextAreaElement:!1,HTMLTitleElement:!1,HTMLUListElement:!1,HTMLVideoElement:!1,IDBCursor:!1,IDBCursorWithValue:!1,IDBDatabase:!1,IDBEnvironment:!1,IDBFactory:!1,IDBIndex:!1,IDBKeyRange:!1,IDBObjectStore:!1,IDBOpenDBRequest:!1,IDBRequest:!1,IDBTransaction:!1,IDBVersionChangeEvent:!1,Image:!1,indexedDB:!1,innerHeight:!1,innerWidth:!1,InputEvent:!1,Intl:!1,KeyboardEvent:!1,length:!1,localStorage:!1,location:!1,matchMedia:!1,MessageChannel:!1,MessageEvent:!1,MessagePort:!1,MouseEvent:!1,moveBy:!1,moveTo:!1,MutationObserver:!1,name:!1,navigator:!1,Node:!1,NodeFilter:!1,NodeList:!1,Notification:!1,OfflineAudioCompletionEvent:!1,onbeforeunload:!0,onblur:!0,onerror:!0,onfocus:!0,onload:!0,onresize:!0,onunload:!0,open:!1,openDatabase:!1,opener:!1,opera:!1,Option:!1,outerHeight:!1,outerWidth:!1,PageTransitionEvent:!1,pageXOffset:!1,pageYOffset:!1,parent:!1,PopStateEvent:!1,postMessage:!1,print:!1,ProgressEvent:!1,prompt:!1,Range:!1,removeEventListener:!1,requestAnimationFrame:!1,resizeBy:!1,resizeTo:!1,screen:!1,screenX:!1,screenY:!1,scroll:!1,scrollbars:!1,scrollBy:!1,scrollTo:!1,scrollX:!1,scrollY:!1,self:!1,sessionStorage:!1,setInterval:!1,setTimeout:!1,SharedWorker:!1,showModalDialog:!1,status:!1,stop:!1,StorageEvent:!1,SVGAElement:!1,SVGAltGlyphDefElement:!1,SVGAltGlyphElement:!1,SVGAltGlyphItemElement:!1,SVGAngle:!1,SVGAnimateColorElement:!1,SVGAnimatedAngle:!1,SVGAnimatedBoolean:!1,SVGAnimatedEnumeration:!1,SVGAnimatedInteger:!1,SVGAnimatedLength:!1,SVGAnimatedLengthList:!1,SVGAnimatedNumber:!1,SVGAnimatedNumberList:!1,SVGAnimatedPathData:!1,SVGAnimatedPoints:!1,SVGAnimatedPreserveAspectRatio:!1,SVGAnimatedRect:!1,SVGAnimatedString:!1,SVGAnimatedTransformList:!1,SVGAnimateElement:!1,SVGAnimateMotionElement:!1,SVGAnimateTransformElement:!1,SVGAnimationElement:!1,SVGCircleElement:!1,SVGClipPathElement:!1,SVGColor:!1,SVGColorProfileElement:!1,SVGColorProfileRule:!1,SVGComponentTransferFunctionElement:!1,SVGCSSRule:!1,SVGCursorElement:!1,SVGDefsElement:!1,SVGDescElement:!1,SVGDocument:!1,SVGElement:!1,SVGElementInstance:!1,SVGElementInstanceList:!1,SVGEllipseElement:!1,SVGEvent:!1,SVGExternalResourcesRequired:!1,SVGFEBlendElement:!1,SVGFEColorMatrixElement:!1,SVGFEComponentTransferElement:!1,SVGFECompositeElement:!1,SVGFEConvolveMatrixElement:!1,SVGFEDiffuseLightingElement:!1,SVGFEDisplacementMapElement:!1,SVGFEDistantLightElement:!1,SVGFEFloodElement:!1,SVGFEFuncAElement:!1,SVGFEFuncBElement:!1,SVGFEFuncGElement:!1,SVGFEFuncRElement:!1,SVGFEGaussianBlurElement:!1,SVGFEImageElement:!1,SVGFEMergeElement:!1,SVGFEMergeNodeElement:!1,SVGFEMorphologyElement:!1,SVGFEOffsetElement:!1,SVGFEPointLightElement:!1,SVGFESpecularLightingElement:!1,SVGFESpotLightElement:!1,SVGFETileElement:!1,SVGFETurbulenceElement:!1,SVGFilterElement:!1,SVGFilterPrimitiveStandardAttributes:!1,SVGFitToViewBox:!1,SVGFontElement:!1,SVGFontFaceElement:!1,SVGFontFaceFormatElement:!1,SVGFontFaceNameElement:!1,SVGFontFaceSrcElement:!1,SVGFontFaceUriElement:!1,SVGForeignObjectElement:!1,SVGGElement:!1,SVGGlyphElement:!1,SVGGlyphRefElement:!1,SVGGradientElement:!1,SVGHKernElement:!1,SVGICCColor:!1,SVGImageElement:!1,SVGLangSpace:!1,SVGLength:!1,SVGLengthList:!1,SVGLinearGradientElement:!1,SVGLineElement:!1,SVGLocatable:!1,SVGMarkerElement:!1,SVGMaskElement:!1,SVGMatrix:!1,SVGMetadataElement:!1,SVGMissingGlyphElement:!1,SVGMPathElement:!1,SVGNumber:!1,SVGNumberList:!1,SVGPaint:!1,SVGPathElement:!1,SVGPathSeg:!1,SVGPathSegArcAbs:!1,SVGPathSegArcRel:!1,SVGPathSegClosePath:!1,SVGPathSegCurvetoCubicAbs:!1,SVGPathSegCurvetoCubicRel:!1,SVGPathSegCurvetoCubicSmoothAbs:!1,SVGPathSegCurvetoCubicSmoothRel:!1,SVGPathSegCurvetoQuadraticAbs:!1,SVGPathSegCurvetoQuadraticRel:!1,SVGPathSegCurvetoQuadraticSmoothAbs:!1,SVGPathSegCurvetoQuadraticSmoothRel:!1,SVGPathSegLinetoAbs:!1,SVGPathSegLinetoHorizontalAbs:!1,SVGPathSegLinetoHorizontalRel:!1,SVGPathSegLinetoRel:!1,SVGPathSegLinetoVerticalAbs:!1,SVGPathSegLinetoVerticalRel:!1,SVGPathSegList:!1,SVGPathSegMovetoAbs:!1,SVGPathSegMovetoRel:!1,SVGPatternElement:!1,SVGPoint:!1,SVGPointList:!1,SVGPolygonElement:!1,SVGPolylineElement:!1,SVGPreserveAspectRatio:!1,SVGRadialGradientElement:!1,SVGRect:!1,SVGRectElement:!1,SVGRenderingIntent:!1,SVGScriptElement:!1,SVGSetElement:!1,SVGStopElement:!1,SVGStringList:!1,SVGStylable:!1,SVGStyleElement:!1,SVGSVGElement:!1,SVGSwitchElement:!1,SVGSymbolElement:!1,SVGTests:!1,SVGTextContentElement:!1,SVGTextElement:!1,SVGTextPathElement:!1,SVGTextPositioningElement:!1,SVGTitleElement:!1,SVGTransform:!1,SVGTransformable:!1,SVGTransformList:!1,SVGTRefElement:!1,SVGTSpanElement:!1,SVGUnitTypes:!1,SVGURIReference:!1,SVGUseElement:!1,SVGViewElement:!1,SVGViewSpec:!1,SVGVKernElement:!1,SVGZoomAndPan:!1,Text:!1,TextDecoder:!1,TextEncoder:!1,TimeEvent:!1,top:!1,TouchEvent:!1,UIEvent:!1,URL:!1,WebGLActiveInfo:!1,WebGLBuffer:!1,WebGLContextEvent:!1,WebGLFramebuffer:!1,WebGLProgram:!1,WebGLRenderbuffer:!1,WebGLRenderingContext:!1,WebGLShader:!1,WebGLShaderPrecisionFormat:!1,WebGLTexture:!1,WebGLUniformLocation:!1,WebSocket:!1,WheelEvent:!1,window:!1,Window:!1,Worker:!1,XDomainRequest:!1,XMLHttpRequest:!1,XMLSerializer:!1,XPathEvaluator:!1,XPathException:!1,XPathExpression:!1,XPathNamespace:!1,XPathNSResolver:!1,XPathResult:!1},worker:{importScripts:!0,postMessage:!0,self:!0},node:{__dirname:!1,__filename:!1,arguments:!1,Buffer:!1,clearImmediate:!1,clearInterval:!1,clearTimeout:!1,console:!1,DataView:!1,exports:!0,GLOBAL:!1,global:!1,module:!1,process:!1,require:!1,setImmediate:!1,setInterval:!1,setTimeout:!1},amd:{define:!1,require:!1},mocha:{after:!1,afterEach:!1,before:!1,beforeEach:!1,context:!1,describe:!1,it:!1,setup:!1,specify:!1,suite:!1,suiteSetup:!1,suiteTeardown:!1,teardown:!1,test:!1,xcontext:!1,xdescribe:!1,xit:!1,xspecify:!1},jasmine:{afterAll:!1,afterEach:!1,beforeAll:!1,beforeEach:!1,describe:!1,expect:!1,fail:!1,fdescribe:!1,fit:!1,it:!1,jasmine:!1,pending:!1,runs:!1,spyOn:!1,waits:!1,waitsFor:!1,xdescribe:!1,xit:!1},qunit:{asyncTest:!1,deepEqual:!1,equal:!1,expect:!1,module:!1,notDeepEqual:!1,notEqual:!1,notPropEqual:!1,notStrictEqual:!1,ok:!1,propEqual:!1,QUnit:!1,raises:!1,start:!1,stop:!1,strictEqual:!1,test:!1,"throws":!1},phantomjs:{console:!0,exports:!0,phantom:!0,require:!0,WebPage:!0},couch:{emit:!1,exports:!1,getRow:!1,log:!1,module:!1,provides:!1,require:!1,respond:!1,send:!1,start:!1,sum:!1},rhino:{defineClass:!1,deserialize:!1,gc:!1,help:!1,importClass:!1,importPackage:!1,java:!1,load:!1,loadClass:!1,Packages:!1,print:!1,quit:!1,readFile:!1,readUrl:!1,runCommand:!1,seal:!1,serialize:!1,spawn:!1,sync:!1,toint32:!1,version:!1},wsh:{ActiveXObject:!0,Enumerator:!0,GetObject:!0,ScriptEngine:!0,ScriptEngineBuildVersion:!0,ScriptEngineMajorVersion:!0,ScriptEngineMinorVersion:!0,VBArray:!0,WScript:!0,WSH:!0,XDomainRequest:!0},jquery:{$:!1,jQuery:!1},yui:{Y:!1,YUI:!1,YUI_config:!1},shelljs:{cat:!1,cd:!1,chmod:!1,config:!1,cp:!1,dirs:!1,echo:!1,env:!1,error:!1,exec:!1,exit:!1,find:!1,grep:!1,ls:!1,mkdir:!1,mv:!1,popd:!1,pushd:!1,pwd:!1,rm:!1,sed:!1,target:!1,tempdir:!1,test:!1,which:!1},prototypejs:{$:!1,$$:!1,$A:!1,$break:!1,$continue:!1,$F:!1,$H:!1,$R:!1,$w:!1,Abstract:!1,Ajax:!1,Autocompleter:!1,Builder:!1,Class:!1,Control:!1,Draggable:!1,Draggables:!1,Droppables:!1,Effect:!1,Element:!1,Enumerable:!1,Event:!1,Field:!1,Form:!1,Hash:!1,Insertion:!1,ObjectRange:!1,PeriodicalExecuter:!1,Position:!1,Prototype:!1,Scriptaculous:!1,Selector:!1,Sortable:!1,SortableObserver:!1,Sound:!1,Template:!1,Toggle:!1,Try:!1},meteor:{$:!1,_:!1,Accounts:!1,App:!1,Assets:!1,Blaze:!1,check:!1,Cordova:!1,DDP:!1,DDPServer:!1,Deps:!1,EJSON:!1,Email:!1,HTTP:!1,Log:!1,Match:!1,Meteor:!1,Mongo:!1,MongoInternals:!1,Npm:!1,Package:!1,Plugin:!1,process:!1,Random:!1,ReactiveDict:!1,ReactiveVar:!1,Router:!1,Session:!1,share:!1,Spacebars:!1,Template:!1,Tinytest:!1,Tracker:!1,UI:!1,Utils:!1,WebApp:!1,WebAppInternals:!1},mongo:{_isWindows:!1,_rand:!1,BulkWriteResult:!1,cat:!1,cd:!1,connect:!1,db:!1,getHostName:!1,getMemInfo:!1,hostname:!1,listFiles:!1,load:!1,ls:!1,md5sumFile:!1,mkdir:!1,Mongo:!1,ObjectId:!1,PlanCache:!1,pwd:!1,quit:!1,removeFile:!1,rs:!1,sh:!1,UUID:!1,version:!1,WriteResult:!1}}
}),define("eslint/conf/environments",["./globals"],function(e){var t={builtin:e.builtin,browser:{globals:e.browser},node:{globals:e.node,ecmaFeatures:{globalReturn:!0}},amd:{globals:e.amd},mocha:{globals:e.mocha},jasmine:{globals:e.jasmine},phantomjs:{globals:e.phantom},jquery:{globals:e.jquery},prototypejs:{globals:e.prototypejs},shelljs:{globals:e.shelljs},meteor:{globals:e.meteor}};return t}),define("javascript/finder",["estraverse/estraverse","eslint/conf/environments"],function(e,t){e.VisitorKeys.RecoveredNode||(e.VisitorKeys.RecoveredNode=[]);var r={visitor:null,punc:"\n	\r (){}[]:;,.+=-*^&@!%~`'\"/\\",findWord:function(e,t){if(e&&t>-1){for(var r=this.punc.indexOf(e.charAt(t))>-1,n=r&&t>0?t-1:t;n>=0&&!(this.punc.indexOf(e.charAt(n))>-1);)n--;var o=n;for(n=t;n<=e.length&&!(this.punc.indexOf(e.charAt(n))>-1);)n++;return(o===t||r&&o===t-1)&&n===t?null:o===t?e.substring(o,n):e.substring(o+1,n)}return null},findNode:function(t,r,n){var o=null,s=n&&n.parents?[]:null,a=n&&n.next?n.next:!1;if(null!=t&&t>-1&&r&&e.traverse(r,{enter:function(r){if(r.type&&r.range){if(!a&&r.type===e.Syntax.Program&&t<r.range[0])return e.VisitorOption.Break;if(r.range[0]<=t)o=r,s&&s.push(r);else if(a&&(o=r,s&&s.push(r)),o.type!==e.Syntax.Program)return e.VisitorOption.Break}},leave:function(e){s&&t>e.range[1]&&s.pop()}}),o&&s&&s.length>0){var i=s[s.length-1];"Program"!==i.type&&i.range[0]===o.range[0]&&i.range[1]===o.range[1]&&s.pop(),o.parents=s}return o},findNodeAfterComment:function(t,r){var n=null,o=[];if(Array.isArray(t.range)&&r){var s=t.range[1];e.traverse(r,{enter:function(t,r){if(t.type&&t.range)if(r&&o.push(r),s>t.range[0])n=t;else if(n=t,t.type!==e.Syntax.Program)return e.VisitorOption.Break}})}return n&&(n.parents=o),n},findToken:function(e,t){if(null!=e&&e>-1&&t&&t.length>0){var r,n=0,o=t.length-1,s=0;if(r=t[0],e>=r.range[0]&&e<r.range[1])return r.index=0,r;if(r=t[o],e>=r.range[0])return r.index=o,r;for(r=null;o>=n;){if(s=Math.floor((n+o)/2),r=t[s],e<r.range[0])o=s-1;else if(e>r.range[1])n=s+1;else if(e===r.range[1]){var a=t[s+1];if(a.range[0]!==r.range[1])return r.index=s,r;n=s+1}else if(e>=r.range[0]&&e<r.range[1])return r.index=s,r;if(n===o)return r=t[n],e>=r.range[0]&&e<=r.range[1]?(r.index=n,r):null}}return null},findComment:function(e,t){if(t.comments){for(var r=t.comments,n=r.length,o=0;n>o;o++){var s=r[o];if(s.range[0]<e&&s.range[1]>=e)return s;if(e===t.range[1]&&e===s.range[1])return s;if(e>t.range[1]&&e<=s.range[1])return s;if(s.range[0]>e)return null}return null}},findScriptBlocks:function(e,t){var r=[],n=null,o=/<\s*script([^>]*)(?:\/>|>((?:.|\r?\n)*?)<\s*\/script[^<>]*>)/gi,s=/(type|language)\s*=\s*"([^"]*)"/i,a=/src\s*=\s*"([^"]*)"/i,i=this.findHtmlCommentBlocks(e,t);e:for(;null!=(n=o.exec(e));){var l=n[1],c=n[2],p=null;if(l){var d=s.exec(l);if(d&&d[2]){var u=d[2];if("language"===d[1]&&(u="text/"+u),!/^(application|text)\/(ecmascript|javascript(\d.\d)?|livescript|jscript|x\-ecmascript|x\-javascript)$/gi.test(u))continue}var h=a.exec(l);h&&(p=h[1])}if(c||!p){var f=n.index+n[0].indexOf(">")+1;if(null==t||t>=f&&f+c.length>=t){for(var m=0;m<i.length;m++)if(i[m].start<=f&&i[m].end>=f)continue e;r.push({text:c,offset:f,dependencies:p})}}else r.push({text:"",offset:0,dependencies:p})}var g={blur:!0,change:!0,click:!0,dblclick:!0,focus:!0,keydown:!0,keypress:!0,keyup:!0,load:!0,mousedown:!0,mousemove:!0,mouseout:!0,mouseover:!0,mouseup:!0,reset:!0,select:!0,submit:!0,unload:!0},b=/\s+on(\w*)(\s*=\s*")([^"]*)"/gi,y=0;e:for(;null!=(n=b.exec(e));){y++;var v=n[1],w=n[2];if(c=n[3],v&&v in g){if(!c||!w)continue;if(f=n.index+2+v.length+w.length,null==t||t>=f&&f+c.length>=t){for(var _=0;_<i.length;_++)if(i[_].start<=f&&i[_].end>=f)continue e;r.push({text:c,offset:f,isWrappedFunctionCall:!0})}}}return r},findHtmlCommentBlocks:function(e,t){for(var r=[],n=null,o=/<!--((?:.|\r?\n)*?)-->/gi;null!=(n=o.exec(e));){var s=n[1];s.length<1||(null==t||n.index<=t&&n.index+s.length>=n.index)&&r.push({text:s,start:n.index,end:n.index+s.length})}return r},findESLintEnvForMember:function(e){var r=Object.keys(t);if(r)for(var n=r.length,o=0;n>o;o++){var s=t[r[o]];if("undefined"!=typeof s[e])return r[o];var a=s.globals;if(a&&"undefined"!=typeof a[e])return r[o]}return null},findDirective:function(e,t){if(e&&"undefined"!=typeof t)for(var r=e.comments.length,n=0;r>n;n++){var o=/^\s*(eslint-\w+|eslint|globals?)(\s|$)/.exec(e.comments[n].value);if(null!=o&&"undefined"!=typeof o&&o[1]===t)return e.comments[n]}return null},findCommentForNode:function n(e){var t=e.leadingComments,r=null;if(t&&t.length>0){if(r=t[t.length-1],"Block"===r.type)return r.node=e,r}else if("Property"===e.type){if(r=n(e.key))return r.node=e,r}else if("FunctionDeclaration"===e.type&&(r=n(e.id)))return r.node=e,r;return r=Object.create(null),r.node=e,r.value="",r},findParentFunction:function(e){if(e)if(e.parents)for(var t=e.parents,r=t.pop();r;){if("FunctionDeclaration"===r.type||"FunctionExpression"===r.type)return r;r=t.pop()}else if(e.parent)for(var r=e.parent;r;){if("FunctionDeclaration"===r.type||"FunctionExpression"===r.type)return r;r=r.parent}return null}};return r}),define("tern/plugin/refs",["../lib/infer","../lib/tern","acorn/dist/walk","javascript/finder"],function(e,t,r,n){function o(r,o,a,l){try{var c,p=n.findComment(r.end,o.ast);if(p)c={guess:!1,type:void 0,name:void 0,category:"Block"===p.type?"blockcomments":"linecomments"};else{var d,u,h,f=t.findExpr(o,r);try{u=t.findExprType(a,r,o,f),h=u,u=r.preferFunction?u.getFunctionType()||u.getType():u.getType(),f&&("Identifier"===f.node.type?d=f.node.name:"MemberExpression"!==f.node.type||f.node.computed||(d=f.node.property.name))}catch(m){}c={guess:e.didGuess(),type:e.toString(h),name:u&&u.name,exprName:d},s(r,o,c),u?t.storeTypeDocs(r,u,c):i(r,o,c),!c.doc&&h&&h.doc&&(c.doc=t.parseDoc(r,h.doc))}l(null,c)}catch(g){a.options.debug&&"TernError"!==g.name&&console.error(g.stack),l(g)}}function s(e,t,r){if(Array.isArray(t.ast.errors)&&t.ast.errors.length>0)return void(r.category="parseerrors");var o=n.findNode(e.end-1,t.ast,{parents:!0});if(o){if("Identifier"===o.type){var s=o.parents.pop();s.parents=o.parents,o=s}if("RecoveredNode"!==o.type)switch(o.type){case"Program":r.category="uncategorized";break;case"FunctionDeclaration":case"FunctionExpression":for(var i=0,l=o.params.length;l>i;i++)if(a(e.end,o.params[i])){r.category="vardecls";break}r.category||(r.category="funcdecls");break;case"Property":a(e.end,o.key)?r.category=o.value&&"FunctionExpression"===o.value.type?"funcdecl":"propwrite":a(e.end,o.value)&&(r.category="FunctionExpression"===o.value.type?"funcdecls":"Identifier"===o.value.type?"varaccess":"propwrite");break;case"CallExpression":if(a(e.end,o.callee)&&(r.category="funccalls"),o.arguments.length>0)for(i=0,l=o.arguments.length;l>i;i++){var c=o.arguments[i];a(e.end,c)&&("Identifier"===c.type?r.category="varaccess":"MemberExpression"===c.type&&(r.category="propaccess"))}break;case"AssignmentExpression":a(e.end,o.left)?r.category="Identifier"===o.left.type?"varwrite":"propwrite":a(e.end,o.right)&&("Identifier"===o.right.type?r.category="varaccess":"MemberExpression"===o.right.type&&(r.category="propaccess"));break;case"VariableDeclarator":a(e.end,o.id)?r.category="vardecls":a(e.end,o.init)&&(r.category="varaccess");break;case"Literal":o.regex?r.category="regex":"string"==typeof o.value&&(r.category="strings");break;case"NewExpression":o.callee&&a(e.end,o.callee)&&(r.category="funccalls");break;case"MemberExpression":if(o.object&&"Identifier"===o.object.type&&a(e.end,o.object)){r.category="varaccess";break}for(var p;"MemberExpression"===o.type;)p=o.property,s=o.parents.pop(),s.parents=o.parents,o=s;if(o&&("CallExpression"===o.type||"NewExpression"===o.type)&&a(e.end,p)){if(o.callee&&a(e.end,o.callee))r.category="funccalls";else if(o.arguments&&o.arguments.length>0)for(i=0,l=o.arguments.length;l>i;i++)a(e.end,o.arguments[i])&&(r.category="propaccess")}else r.category=o&&"AssignmentExpression"===o.type&&a(e.end,o.left)?o.right&&"FunctionExpression"===o.right.type?"funcdecls":a(e.end,p)?"propwrite":"propaccess":"propaccess";break;case"UpdateExpression":"Identifier"===o.argument.type?r.category="varaccess":"MemberExpression"===o.argument.type&&(r.category="propaccess");break;case"BinaryExpression":"Identifier"===o.left.type&&a(e.end,o.left)?r.category="varaccess":"Identifier"===o.right.type&&a(e.end,o.right)&&(r.category="varaccess");break;case"BreakStatement":case"ConditionalExpression":case"ContinueStatement":case"IfStatement":case"DoWhileStatement":case"ForInStatement":case"ForStatement":case"LogicalExpression":case"SwitchStatement":case"SwitchCase":case"WithStatement":case"WhileStatement":r.category="varaccess";break;case"LetStatement":case"LabeledStatement":r.category="varwrite";break;case"Block":r.category="blockcomments";break;case"Line":r.category="linecomments";break;case"UnaryExpression":o.argument&&a(e.end,o.argument)&&(r.category="varaccess")}}r.category||(r.category="uncategorized")}function a(e,t){return t&&t.range[0]<=e&&e<=t.range[1]}function i(e,t,r){var o=n.findNode(e.end,t.ast,{parents:!0});o?l(e,o,r):r.staticCheck={confidence:0}}function l(e,t,r){switch(t.type){case"FunctionDeclaration":case"FucntionExpression":case"VariableDeclarator":case"Literal":r.staticCheck={confidence:0};break;case"Identifier":if(Array.isArray(t.parents)){var n=t.parents.slice(t.parents.length-1)[0];l(e,n,r)}else r.staticCheck={confidence:25};break;case"AssignmentExpression":r.staticCheck="Identifier"===t.left.type&&t.left.name===e.origin.type.exprName?{confidence:25}:"Identifier"===t.right.type&&t.right.name===e.origin.type.exprName?{confidence:25}:{confidence:5};break;case"MemberExpression":r.staticCheck={confidence:10};break;case"CallExpression":t.callee.name===e.origin.type.exprName&&(r.staticCheck="fn()"===e.origin.type.type?{confidence:25}:{confidence:0});for(var o=0,s=t.arguments.length;s>o;o++){var a=t.arguments[o];"Identifier"===a.type?r.staticCheck="fn()"===e.origin.type.type?{confidence:0}:{confidence:40}:"FunctionExpression"===a.type&&a.id===e.origin.type.exprName&&(r.staticCheck={confidence:0})}break;default:r.staticCheck={confidence:0}}}var c=Object.create(null);t.registerPlugin("refs",function(){return{}}),t.defineQueryType("checkRef",{run:function(){},runAsync:function(e,r,n,s){var a=t.resolveFile(e,e.fileMap,r.file);a?o(r,a,e,s):(e.addFile(r.file),c[r.file]={callback:s,query:r},e.on("afterLoad",function(t){if(t&&t.name){var r=c[t.name];r&&(delete c[t.name],o(r.query,t,e,r.callback))}}.bind(e)))}})}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern"),require):"function"==typeof define&&define.amd?define("tern/plugin/openImplementation",["../lib/infer","../lib/tern","./resolver","javascript/finder"],e):void e(infer,tern,resolver)}(function(e,t,r,n){t.registerPlugin("openImplementation",function(){return{}}),t.defineQueryType("implementation",{run:function(e,t){t.end&&!t.start&&(t.start=t.end);var r=e.fileMap[t.file];return this.findImplRecurse(t.end,r,{implementation:{}},e)},findImplRecurse:function(e,r,o,s){var a,i,l;if(r){var c=n.findNode(e,r.ast,{parents:!0});if(c&&"Identifier"===c.type){var p=c.parents[c.parents.length-1];if(p){"MemberExpression"===p.type&&c.parents.length>=2&&(p=c.parents[c.parents.length-2]);var d;if("VariableDeclarator"===p.type&&p.init?d=p.init:"AssignmentExpression"===p.type&&p.right?d=p.right:"Property"===p.type&&p.value&&(d=p.value),d){if("Literal"===d.type||"FunctionExpression"===d.type)return{implementation:{start:c.start,end:c.end,file:r.name}};if(a={start:d.start,end:d.end,file:r.name},i=t.findDef(s,a,r),i&&"number"==typeof i.start&&"number"==typeof i.end&&(i.start!==c.start||i.end!==c.end))return l=s.fileMap[i.file],this.findImplRecurse(i.end,l,{implementation:{start:i.start,end:i.end,file:i.file}},s)}}return a={start:c.start,end:c.end,file:r.name},i=t.findDef(s,a,r),!i||"number"!=typeof i.start||"number"!=typeof i.end||i.start===c.start&&i.end===c.end?{implementation:{start:c.start,end:c.end,file:r.name}}:(l=s.fileMap[i.file],this.findImplRecurse(i.end,l,{implementation:{start:i.start,end:i.end,file:i.file}},s))}}return o}})}),function(e,t){"function"==typeof define&&define.amd?define("orion/Deferred",t):"object"==typeof exports?module.exports=t():(e.orion=e.orion||{},e.orion.Deferred=t())}(this,function(){function e(){for(var e;e=s.shift();)e();a=!1}function t(e){s.push(e),a||(a=!0,i())}function r(e){return function(t){e(t)}}function n(e,t,n){try{var o=e(t),s=o&&("object"==typeof o||"function"==typeof o)&&o.then;if("function"==typeof s)if(o===n.promise)n.reject(new TypeError);else{var a=o.cancel;"function"==typeof a?n._parentCancel=a.bind(o):delete n._parentCancel,s.call(o,r(n.resolve),r(n.reject),r(n.progress))}else n.resolve(o)}catch(i){n.reject(i)}}function o(){function e(){for(var e;e=c.shift();){var t=e.deferred,r="fulfilled"===l?"resolve":"reject",o=e[r];"function"==typeof o?n(o,i,t):t[r](i)}}function r(r){delete p._parentCancel,l="rejected",i=r,c.length&&t(e)}function s(n){function a(e){return function(t){l&&"assumed"!==l||e(t)}}delete p._parentCancel;try{var d=n&&("object"==typeof n||"function"==typeof n)&&n.then;if("function"==typeof d)if(n===p)r(new TypeError);else{l="assumed";var u=n&&n.cancel;if("function"!=typeof u){var h=new o;n=h.promise;try{d(h.resolve,h.reject,h.progress)}catch(f){h.reject(f)}u=n.cancel,d=n.then}i=n,d.call(n,a(s),a(r)),p._parentCancel=u.bind(n)}else l="fulfilled",i=n,c.length&&t(e)}catch(m){a(r)(m)}}function a(){var e=p._parentCancel;if(e)delete p._parentCancel,e();else if(!l){var t=new Error("Cancel");t.name="Cancel",r(t)}}var i,l,c=[],p=this;this.resolve=function(e){return l||s(e),p},this.reject=function(e){return l||r(e),p},this.progress=function(e){return l||c.forEach(function(t){if(t.progress)try{t.progress(e)}catch(r){}}),p.promise},this.cancel=function(){return p._parentCancel?setTimeout(a,0):a(),p},this.then=function(r,n,s){var a=new o;return a._parentCancel=p.promise.cancel,c.push({resolve:r,reject:n,progress:s,deferred:a}),("fulfilled"===l||"rejected"===l)&&t(e),a.promise},this.promise={then:p.then,cancel:p.cancel}}var s=[],a=!1,i=function(){if("undefined"!=typeof process&&"function"==typeof process.nextTick){var t=process.nextTick;return function(){t(e)}}if("function"==typeof MutationObserver){var r=document.createElement("div"),n=new MutationObserver(e);return n.observe(r,{attributes:!0}),function(){r.setAttribute("class","_tick")}}return function(){setTimeout(e,0)}}();return o.all=function(e,t){function r(e,t){i||(a[e]=t,0===--s&&l.resolve(a))}function n(e,n){if(!i){if(t)try{return void r(e,t(n))}catch(o){n=o}l.reject(n)}}var s=e.length,a=[],i=!1,l=new o;return l.then(void 0,function(){i=!0,e.forEach(function(e){e.cancel&&e.cancel()})}),0===s?l.resolve(a):e.forEach(function(e,t){e.then(r.bind(void 0,t),n.bind(void 0,t))}),l.promise},o.when=function(e,t,r,n){var s,a;return e&&"function"==typeof e.then?s=e:(a=new o,a.resolve(e),s=a.promise),s.then(t,r,n)},o}),define("javascript/compilationUnit",["orion/Deferred"],function(e){function t(e,t,r){this._blocks=e,this._metadata=t,this._ec=r,this._deps=[]}return t.prototype._init=function(){var e="this.",t=0;this._source="",this._blocks.sort(function(e,t){var r=e.offset?e.offset:0,n=t.offset?t.offset:0;return r-n});for(var r=0;r<this._blocks.length;r++){var n=this._blocks[r];n.dependencies&&this._deps.push(n.dependencies);var o=n.offset-t;if(n.isWrappedFunctionCall){if(o<e.length)continue;for(o-=e.length;o>0;)this._source+=" ",o--;this._source+=e,this._source+=n.text,n.text&&";"!==n.text.charAt(n.text.length-1)&&(this._source+=";")}else{for(;o>0;)this._source+=" ",o--;this._source+=n.text}t=this._source.length}},t.prototype.getSource=function(){return this._source||this._init(),this._source},t.prototype.validOffset=function(e){if(!this._blocks||this._blocks.length<1||0>e)return!1;for(var t=0;t<this._blocks.length;t++){var r=this._blocks[t],n=r.offset;if(e>=n&&e<=n+r.text.length)return!0}return!1},t.prototype.getEditorContext=function(){var t=Object.create(null),r=this;return t.getText=function(){return(new e).resolve(r.getSource())},t.getFileMetadata=function(){return(new e).resolve(r._metadata)},t.setText=function(t,n,o){return r._ec?r._ec.setText(t,n,o):(new e).resolve(null)},t},t.prototype.getDependencies=function(){return this._deps},t}),function(e){return"object"==typeof exports&&"object"==typeof module?e(require("../lib/infer"),require("../lib/tern")):"function"==typeof define&&define.amd?define("tern/plugin/htmlDependencies",["../lib/infer","../lib/tern","./resolver","javascript/compilationUnit","javascript/finder"],e):void e(tern,tern)}(function(e,t,r,n,o){"use strict";t.registerPlugin("orionHTML",function(t){function s(e){return/(?:html|htm|xhtml)$/g.test(e)}return t._htmlDeps=Object.create(null),t._htmlDeps.map=Object.create(null),t.on("beforeLoad",function(e){this._htmlDeps.file=e.name}),t.on("reset",function(){t._htmlDeps=Object.create(null),t._htmlDeps.map=Object.create(null)}),{passes:{postParse:function(n){if(s(n.sourceFile.name)){var o=t._htmlDeps.map[t._htmlDeps.file];Array.isArray(o)&&(n.dependencies=o.slice(0)),r.doPostParse(t,n,e.cx().definitions)}},preInfer:function(e){if(s(e.sourceFile.name)&&(r.doPreInfer(t),Array.isArray(e.dependencies)))for(var n=0;n<e.dependencies.length;n++){var o=e.dependencies[n],a=r.getResolved(o);a&&t.addFile(a.file,a.contents,t._htmlDeps.file)}},preParse:function(e,r){var a=r.directSourceFile.name;if(s(a)){var i=o.findScriptBlocks(e);if(Array.isArray(i)){var l=new n(i,{location:a});return t._htmlDeps.file=a,t._htmlDeps.map[a]=l.getDependencies(),l.getSource()}}}}}})}),define("requirejs/text",["module"],function(e){"use strict";var t,r,n,o,s,a=["Msxml2.XMLHTTP","Microsoft.XMLHTTP","Msxml2.XMLHTTP.4.0"],i=/^\s*<\?xml(\s)+version=[\'\"](\d)*.(\d)*[\'\"](\s)*\?>/im,l=/<body[^>]*>\s*([\s\S]+)\s*<\/body>/im,c="undefined"!=typeof location&&location.href,p=c&&location.protocol&&location.protocol.replace(/\:/,""),d=c&&location.hostname,u=c&&(location.port||void 0),h={},f=e.config&&e.config()||{};return t={version:"2.0.12",strip:function(e){if(e){e=e.replace(i,"");var t=e.match(l);t&&(e=t[1])}else e="";return e},jsEscape:function(e){return e.replace(/(['\\])/g,"\\$1").replace(/[\f]/g,"\\f").replace(/[\b]/g,"\\b").replace(/[\n]/g,"\\n").replace(/[\t]/g,"\\t").replace(/[\r]/g,"\\r").replace(/[\u2028]/g,"\\u2028").replace(/[\u2029]/g,"\\u2029")},createXhr:f.createXhr||function(){var e,t,r;if("undefined"!=typeof XMLHttpRequest)return new XMLHttpRequest;if("undefined"!=typeof ActiveXObject)for(t=0;3>t;t+=1){r=a[t];try{e=new ActiveXObject(r)}catch(n){}if(e){a=[r];break}}return e},parseName:function(e){var t,r,n,o=!1,s=e.indexOf("."),a=0===e.indexOf("./")||0===e.indexOf("../");return-1!==s&&(!a||s>1)?(t=e.substring(0,s),r=e.substring(s+1,e.length)):t=e,n=r||t,s=n.indexOf("!"),-1!==s&&(o="strip"===n.substring(s+1),n=n.substring(0,s),r?r=n:t=n),{moduleName:t,ext:r,strip:o}},xdRegExp:/^((\w+)\:)?\/\/([^\/\\]+)/,useXhr:function(e,r,n,o){var s,a,i,l=t.xdRegExp.exec(e);return l?(s=l[2],a=l[3],a=a.split(":"),i=a[1],a=a[0],!(s&&s!==r||a&&a.toLowerCase()!==n.toLowerCase()||(i||a)&&i!==o)):!0},finishLoad:function(e,r,n,o){n=r?t.strip(n):n,f.isBuild&&(h[e]=n),o(n)},load:function(e,r,n,o){if(o&&o.isBuild&&!o.inlineText)return void n();f.isBuild=o&&o.isBuild;var s=t.parseName(e),a=s.moduleName+(s.ext?"."+s.ext:""),i=r.toUrl(a),l=f.useXhr||t.useXhr;return 0===i.indexOf("empty:")?void n():void(!c||l(i,p,d,u)?t.get(i,function(r){t.finishLoad(e,s.strip,r,n)},function(e){n.error&&n.error(e)}):r([a],function(e){t.finishLoad(s.moduleName+"."+s.ext,s.strip,e,n)}))},write:function(e,r,n){if(h.hasOwnProperty(r)){var o=t.jsEscape(h[r]);n.asModule(e+"!"+r,"define(function () { return '"+o+"';});\n")}},writeFile:function(e,r,n,o,s){var a=t.parseName(r),i=a.ext?"."+a.ext:"",l=a.moduleName+i,c=n.toUrl(a.moduleName+i)+".js";t.load(l,n,function(){var r=function(e){return o(c,e)};r.asModule=function(e,t){return o.asModule(e,c,t)},t.write(e,l,r,s)},s)}},"node"===f.env||!f.env&&"undefined"!=typeof process&&process.versions&&process.versions.node&&!process.versions["node-webkit"]?(r=require.nodeRequire("fs"),t.get=function(e,t,n){try{var o=r.readFileSync(e,"utf8");0===o.indexOf("﻿")&&(o=o.substring(1)),t(o)}catch(s){n&&n(s)}}):"xhr"===f.env||!f.env&&t.createXhr()?t.get=function(e,r,n,o){var s,a=t.createXhr();if(a.open("GET",e,!0),o)for(s in o)o.hasOwnProperty(s)&&a.setRequestHeader(s.toLowerCase(),o[s]);f.onXhr&&f.onXhr(a,e),a.onreadystatechange=function(){var t,o;4===a.readyState&&(t=a.status||0,t>399&&600>t?(o=new Error(e+" HTTP status: "+t),o.xhr=a,n&&n(o)):r(a.responseText),f.onXhrComplete&&f.onXhrComplete(a,e))},a.send(null)}:"rhino"===f.env||!f.env&&"undefined"!=typeof Packages&&"undefined"!=typeof java?t.get=function(e,t){var r,n,o="utf-8",s=new java.io.File(e),a=java.lang.System.getProperty("line.separator"),i=new java.io.BufferedReader(new java.io.InputStreamReader(new java.io.FileInputStream(s),o)),l="";try{for(r=new java.lang.StringBuffer,n=i.readLine(),n&&n.length()&&65279===n.charAt(0)&&(n=n.substring(1)),null!==n&&r.append(n);null!==(n=i.readLine());)r.append(a),r.append(n);l=String(r.toString())}finally{i.close()}t(l)}:("xpconnect"===f.env||!f.env&&"undefined"!=typeof Components&&Components.classes&&Components.interfaces)&&(n=Components.classes,o=Components.interfaces,Components.utils["import"]("resource://gre/modules/FileUtils.jsm"),s="@mozilla.org/windows-registry-key;1"in n,t.get=function(e,t){var r,a,i,l={};s&&(e=e.replace(/\//g,"\\")),i=new FileUtils.File(e);try{r=n["@mozilla.org/network/file-input-stream;1"].createInstance(o.nsIFileInputStream),r.init(i,1,0,!1),a=n["@mozilla.org/intl/converter-input-stream;1"].createInstance(o.nsIConverterInputStream),a.init(r,"utf-8",r.available(),o.nsIConverterInputStream.DEFAULT_REPLACEMENT_CHARACTER),a.readString(r.available(),l),a.close(),r.close(),t(l.value)}catch(c){throw new Error((i&&i.path||"")+": "+c)}}),t}),define("json",["requirejs/text"],function(e){var t=Object.create(null);return{load:function(r,n,o,s){e.get(n.toUrl(r),function(e){if(s.isBuild)t[r]=e,o(e);else{try{var n=JSON.parse(e)}catch(a){o.error(a)}o(n)}},o.error,{accept:"application/json"})},write:function(e,r,n){var o=t[r];o&&n('define("'+e+"!"+r+'", function(){ return '+o+";});\n")}}}),define("json!tern/defs/ecma5.json",function(){return{"!name":"ecma5","!define":{"Error.prototype":"Error.prototype"},Infinity:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Infinity","!doc":"A numeric value representing infinity."},undefined:{"!type":"?","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/undefined","!doc":"The value undefined."},NaN:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/NaN","!doc":"A value representing Not-A-Number."},Object:{"!type":"fn()",getPrototypeOf:{"!type":"fn(obj: ?) -> ?","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/getPrototypeOf","!doc":"Returns the prototype (i.e. the internal prototype) of the specified object."},create:{"!type":"fn(proto: ?) -> !custom:Object_create","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/create","!doc":"Creates a new object with the specified prototype object and properties."},defineProperty:{"!type":"fn(obj: ?, prop: string, desc: ?) -> !custom:Object_defineProperty","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/defineProperty","!doc":"Defines a new property directly on an object, or modifies an existing property on an object, and returns the object. If you want to see how to use the Object.defineProperty method with a binary-flags-like syntax, see this article."},defineProperties:{"!type":"fn(obj: ?, props: ?) -> !custom:Object_defineProperties","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/defineProperty","!doc":"Defines a new property directly on an object, or modifies an existing property on an object, and returns the object. If you want to see how to use the Object.defineProperty method with a binary-flags-like syntax, see this article."},getOwnPropertyDescriptor:{"!type":"fn(obj: ?, prop: string) -> ?","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/getOwnPropertyDescriptor","!doc":"Returns a property descriptor for an own property (that is, one directly present on an object, not present by dint of being along an object's prototype chain) of a given object."},keys:{"!type":"fn(obj: ?) -> [string]","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/keys","!doc":"Returns an array of a given object's own enumerable properties, in the same order as that provided by a for-in loop (the difference being that a for-in loop enumerates properties in the prototype chain as well)."},getOwnPropertyNames:{"!type":"fn(obj: ?) -> [string]","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/getOwnPropertyNames","!doc":"Returns an array of all properties (enumerable or not) found directly upon a given object."},seal:{"!type":"fn(obj: ?)","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/seal","!doc":"Seals an object, preventing new properties from being added to it and marking all existing properties as non-configurable. Values of present properties can still be changed as long as they are writable."},isSealed:{"!type":"fn(obj: ?) -> bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/isSealed","!doc":"Determine if an object is sealed."},freeze:{"!type":"fn(obj: ?) -> !0","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/freeze","!doc":"Freezes an object: that is, prevents new properties from being added to it; prevents existing properties from being removed; and prevents existing properties, or their enumerability, configurability, or writability, from being changed. In essence the object is made effectively immutable. The method returns the object being frozen."},isFrozen:{"!type":"fn(obj: ?) -> bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/isFrozen","!doc":"Determine if an object is frozen."},preventExtensions:{"!type":"fn(obj: ?)","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/preventExtensions","!doc":"Prevents new properties from ever being added to an object."},isExtensible:{"!type":"fn(obj: ?) -> bool","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/isExtensible","!doc":"The Object.isExtensible() method determines if an object is extensible (whether it can have new properties added to it)."},prototype:{"!stdProto":"Object",toString:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/toString","!doc":"Returns a string representing the object."},toLocaleString:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/toLocaleString","!doc":"Returns a string representing the object. This method is meant to be overriden by derived objects for locale-specific purposes."},valueOf:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/valueOf","!doc":"Returns the primitive value of the specified object"},hasOwnProperty:{"!type":"fn(prop: string) -> bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/hasOwnProperty","!doc":"Returns a boolean indicating whether the object has the specified property."},propertyIsEnumerable:{"!type":"fn(prop: string) -> bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object/propertyIsEnumerable","!doc":"Returns a Boolean indicating whether the specified property is enumerable."},isPrototypeOf:{"!type":"fn(obj: ?) -> bool","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/isPrototypeOf","!doc":"Tests for an object in another object's prototype chain."}},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Object","!doc":"Creates an object wrapper."},Function:{"!type":"fn(body: string) -> fn()",prototype:{"!stdProto":"Function",apply:{"!type":"fn(this: ?, args: [?])","!effects":["call and return !this this=!0 !1.<i> !1.<i> !1.<i>"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Function/apply","!doc":"Calls a function with a given this value and arguments provided as an array (or an array like object)."},call:{"!type":"fn(this: ?, args?: ?) -> !this.!ret","!effects":["call and return !this this=!0 !1 !2 !3 !4"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Function/call","!doc":"Calls a function with a given this value and arguments provided individually."},bind:{"!type":"fn(this: ?, args?: ?) -> !custom:Function_bind","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Function/bind","!doc":"Creates a new function that, when called, has its this keyword set to the provided value, with a given sequence of arguments preceding any provided when the new function was called."},prototype:"?"},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Function","!doc":"Every function in JavaScript is actually a Function object."},Array:{"!type":"fn(size: number) -> !custom:Array_ctor",isArray:{"!type":"fn(value: ?) -> bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/isArray","!doc":"Returns true if an object is an array, false if it is not."},prototype:{"!stdProto":"Array",length:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/length","!doc":"An unsigned, 32-bit integer that specifies the number of elements in an array."},concat:{"!type":"fn(other: [?]) -> !this","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/concat","!doc":"Returns a new array comprised of this array joined with other array(s) and/or value(s)."},join:{"!type":"fn(separator?: string) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/join","!doc":"Joins all elements of an array into a string."},splice:{"!type":"fn(pos: number, amount: number)","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/splice","!doc":"Changes the content of an array, adding new elements while removing old elements."},pop:{"!type":"fn() -> !this.<i>","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/pop","!doc":"Removes the last element from an array and returns that element."},push:{"!type":"fn(newelt: ?) -> number","!effects":["propagate !0 !this.<i>"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/push","!doc":"Mutates an array by appending the given elements and returning the new length of the array."},shift:{"!type":"fn() -> !this.<i>","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/shift","!doc":"Removes the first element from an array and returns that element. This method changes the length of the array."},unshift:{"!type":"fn(newelt: ?) -> number","!effects":["propagate !0 !this.<i>"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/unshift","!doc":"Adds one or more elements to the beginning of an array and returns the new length of the array."},slice:{"!type":"fn(from: number, to?: number) -> !this","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/slice","!doc":"Returns a shallow copy of a portion of an array."},reverse:{"!type":"fn()","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/reverse","!doc":"Reverses an array in place.  The first array element becomes the last and the last becomes the first."},sort:{"!type":"fn(compare?: fn(a: ?, b: ?) -> number)","!effects":["call !0 !this.<i> !this.<i>"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/sort","!doc":"Sorts the elements of an array in place and returns the array."},indexOf:{"!type":"fn(elt: ?, from?: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/indexOf","!doc":"Returns the first index at which a given element can be found in the array, or -1 if it is not present."},lastIndexOf:{"!type":"fn(elt: ?, from?: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/lastIndexOf","!doc":"Returns the last index at which a given element can be found in the array, or -1 if it is not present. The array is searched backwards, starting at fromIndex."},every:{"!type":"fn(test: fn(elt: ?, i: number) -> bool, context?: ?) -> bool","!effects":["call !0 this=!1 !this.<i> number"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/every","!doc":"Tests whether all elements in the array pass the test implemented by the provided function."},some:{"!type":"fn(test: fn(elt: ?, i: number) -> bool, context?: ?) -> bool","!effects":["call !0 this=!1 !this.<i> number"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/some","!doc":"Tests whether some element in the array passes the test implemented by the provided function."},filter:{"!type":"fn(test: fn(elt: ?, i: number) -> bool, context?: ?) -> !this","!effects":["call !0 this=!1 !this.<i> number"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/filter","!doc":"Creates a new array with all elements that pass the test implemented by the provided function."},forEach:{"!type":"fn(f: fn(elt: ?, i: number), context?: ?)","!effects":["call !0 this=!1 !this.<i> number"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/forEach","!doc":"Executes a provided function once per array element."},map:{"!type":"fn(f: fn(elt: ?, i: number) -> ?, context?: ?) -> [!0.!ret]","!effects":["call !0 this=!1 !this.<i> number"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/map","!doc":"Creates a new array with the results of calling a provided function on every element in this array."},reduce:{"!type":"fn(combine: fn(sum: ?, elt: ?, i: number) -> ?, init?: ?) -> !0.!ret","!effects":["call !0 !1 !this.<i> number"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/Reduce","!doc":"Apply a function against an accumulator and each value of the array (from left-to-right) as to reduce it to a single value."},reduceRight:{"!type":"fn(combine: fn(sum: ?, elt: ?, i: number) -> ?, init?: ?) -> !0.!ret","!effects":["call !0 !1 !this.<i> number"],"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/ReduceRight","!doc":"Apply a function simultaneously against two values of the array (from right-to-left) as to reduce it to a single value."}},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array","!doc":"The JavaScript Array global object is a constructor for arrays, which are high-level, list-like objects."},String:{"!type":"fn(value: ?) -> string",fromCharCode:{"!type":"fn(code: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/fromCharCode","!doc":"Returns a string created by using the specified sequence of Unicode values."},prototype:{"!stdProto":"String",length:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/JavaScript/Reference/Global_Objects/String/length","!doc":"Represents the length of a string."},"<i>":"string",charAt:{"!type":"fn(i: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/charAt","!doc":"Returns the specified character from a string."},charCodeAt:{"!type":"fn(i: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/charCodeAt","!doc":"Returns the numeric Unicode value of the character at the given index (except for unicode codepoints > 0x10000)."},indexOf:{"!type":"fn(char: string, from?: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/indexOf","!doc":"Returns the index within the calling String object of the first occurrence of the specified value, starting the search at fromIndex,\nreturns -1 if the value is not found."},lastIndexOf:{"!type":"fn(char: string, from?: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/lastIndexOf","!doc":"Returns the index within the calling String object of the last occurrence of the specified value, or -1 if not found. The calling string is searched backward, starting at fromIndex."},substring:{"!type":"fn(from: number, to?: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/substring","!doc":"Returns a subset of a string between one index and another, or through the end of the string."},substr:{"!type":"fn(from: number, length?: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/substr","!doc":"Returns the characters in a string beginning at the specified location through the specified number of characters."},slice:{"!type":"fn(from: number, to?: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/slice","!doc":"Extracts a section of a string and returns a new string."},trim:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/Trim","!doc":"Removes whitespace from both ends of the string."},toUpperCase:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/toUpperCase","!doc":"Returns the calling string value converted to uppercase."},toLowerCase:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/toLowerCase","!doc":"Returns the calling string value converted to lowercase."},toLocaleUpperCase:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/toLocaleUpperCase","!doc":"Returns the calling string value converted to upper case, according to any locale-specific case mappings."},toLocaleLowerCase:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/toLocaleLowerCase","!doc":"Returns the calling string value converted to lower case, according to any locale-specific case mappings."},split:{"!type":"fn(pattern: string) -> [string]","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/split","!doc":"Splits a String object into an array of strings by separating the string into substrings."},concat:{"!type":"fn(other: string) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/concat","!doc":"Combines the text of two or more strings and returns a new string."},localeCompare:{"!type":"fn(other: string) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/localeCompare","!doc":"Returns a number indicating whether a reference string comes before or after or is the same as the given string in sort order."},match:{"!type":"fn(pattern: +RegExp) -> [string]","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/match","!doc":"Used to retrieve the matches when matching a string against a regular expression."},replace:{"!type":"fn(pattern: string|+RegExp, replacement: string) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/replace","!doc":"Returns a new string with some or all matches of a pattern replaced by a replacement.  The pattern can be a string or a RegExp, and the replacement can be a string or a function to be called for each match."},search:{"!type":"fn(pattern: +RegExp) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String/search","!doc":"Executes the search for a match between a regular expression and this String object."}},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/String","!doc":"The String global object is a constructor for strings, or a sequence of characters."},Number:{"!type":"fn(value: ?) -> number",MAX_VALUE:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/MAX_VALUE","!doc":"The maximum numeric value representable in JavaScript."},MIN_VALUE:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/MIN_VALUE","!doc":"The smallest positive numeric value representable in JavaScript."},POSITIVE_INFINITY:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/POSITIVE_INFINITY","!doc":"A value representing the positive Infinity value."},NEGATIVE_INFINITY:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/NEGATIVE_INFINITY","!doc":"A value representing the negative Infinity value."},prototype:{"!stdProto":"Number",toString:{"!type":"fn(radix?: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/toString","!doc":"Returns a string representing the specified Number object"},toFixed:{"!type":"fn(digits: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/toFixed","!doc":"Formats a number using fixed-point notation"},toExponential:{"!type":"fn(digits: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/toExponential","!doc":"Returns a string representing the Number object in exponential notation"},toPrecision:{"!type":"fn(digits: number) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number/toPrecision","!doc":"The toPrecision() method returns a string representing the number to the specified precision."}},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Number","!doc":"The Number JavaScript object is a wrapper object allowing you to work with numerical values. A Number object is created using the Number() constructor."},Boolean:{"!type":"fn(value: ?) -> bool",prototype:{"!stdProto":"Boolean"},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Boolean","!doc":"The Boolean object is an object wrapper for a boolean value."},RegExp:{"!type":"fn(source: string, flags?: string)",prototype:{"!stdProto":"RegExp",exec:{"!type":"fn(input: string) -> [string]","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/exec","!doc":"Executes a search for a match in a specified string. Returns a result array, or null."},test:{"!type":"fn(input: string) -> bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/test","!doc":"Executes the search for a match between a regular expression and a specified string. Returns true or false."},global:{"!type":"bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp","!doc":"Creates a regular expression object for matching text with a pattern."},ignoreCase:{"!type":"bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp","!doc":"Creates a regular expression object for matching text with a pattern."},multiline:{"!type":"bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/multiline","!doc":"Reflects whether or not to search in strings across multiple lines.\n"},source:{"!type":"string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/source","!doc":"A read-only property that contains the text of the pattern, excluding the forward slashes.\n"},lastIndex:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp/lastIndex","!doc":"A read/write integer property that specifies the index at which to start the next match."}},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RegExp","!doc":"Creates a regular expression object for matching text with a pattern."},Date:{"!type":"fn(ms: number)",parse:{"!type":"fn(source: string) -> +Date","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/parse","!doc":"Parses a string representation of a date, and returns the number of milliseconds since January 1, 1970, 00:00:00 UTC."},UTC:{"!type":"fn(year: number, month: number, date: number, hour?: number, min?: number, sec?: number, ms?: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/UTC","!doc":"Accepts the same parameters as the longest form of the constructor, and returns the number of milliseconds in a Date object since January 1, 1970, 00:00:00, universal time."},now:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/now","!doc":"Returns the number of milliseconds elapsed since 1 January 1970 00:00:00 UTC."},prototype:{toUTCString:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toUTCString","!doc":"Converts a date to a string, using the universal time convention."},toISOString:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toISOString","!doc":"JavaScript provides a direct way to convert a date object into a string in ISO format, the ISO 8601 Extended Format."},toDateString:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toDateString","!doc":"Returns the date portion of a Date object in human readable form in American English."},toTimeString:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toTimeString","!doc":"Returns the time portion of a Date object in human readable form in American English."},toLocaleDateString:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toLocaleDateString","!doc":"Converts a date to a string, returning the \"date\" portion using the operating system's locale's conventions.\n"},toLocaleTimeString:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/toLocaleTimeString","!doc":'Converts a date to a string, returning the "time" portion using the current locale\'s conventions.'},getTime:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getTime","!doc":"Returns the numeric value corresponding to the time for the specified date according to universal time."},getFullYear:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getFullYear","!doc":"Returns the year of the specified date according to local time."},getYear:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getYear","!doc":"Returns the year in the specified date according to local time."},getMonth:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getMonth","!doc":"Returns the month in the specified date according to local time."},getUTCMonth:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCMonth","!doc":"Returns the month of the specified date according to universal time.\n"},getDate:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getDate","!doc":"Returns the day of the month for the specified date according to local time."},getUTCDate:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCDate","!doc":"Returns the day (date) of the month in the specified date according to universal time.\n"},getDay:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getDay","!doc":"Returns the day of the week for the specified date according to local time."},getUTCDay:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCDay","!doc":"Returns the day of the week in the specified date according to universal time.\n"},getHours:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getHours","!doc":"Returns the hour for the specified date according to local time."},getUTCHours:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCHours","!doc":"Returns the hours in the specified date according to universal time.\n"},getMinutes:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getMinutes","!doc":"Returns the minutes in the specified date according to local time."},getUTCMinutes:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date","!doc":"Creates JavaScript Date instances which let you work with dates and times."},getSeconds:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getSeconds","!doc":"Returns the seconds in the specified date according to local time."},getUTCSeconds:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCSeconds","!doc":"Returns the seconds in the specified date according to universal time.\n"},getMilliseconds:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getMilliseconds","!doc":"Returns the milliseconds in the specified date according to local time."},getUTCMilliseconds:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getUTCMilliseconds","!doc":"Returns the milliseconds in the specified date according to universal time.\n"},getTimezoneOffset:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/getTimezoneOffset","!doc":"Returns the time-zone offset from UTC, in minutes, for the current locale."},setTime:{"!type":"fn(date: +Date) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setTime","!doc":"Sets the Date object to the time represented by a number of milliseconds since January 1, 1970, 00:00:00 UTC.\n"},setFullYear:{"!type":"fn(year: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setFullYear","!doc":"Sets the full year for a specified date according to local time.\n"},setUTCFullYear:{"!type":"fn(year: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCFullYear","!doc":"Sets the full year for a specified date according to universal time.\n"},setMonth:{"!type":"fn(month: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setMonth","!doc":"Set the month for a specified date according to local time."},setUTCMonth:{"!type":"fn(month: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCMonth","!doc":"Sets the month for a specified date according to universal time.\n"},setDate:{"!type":"fn(day: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setDate","!doc":"Sets the day of the month for a specified date according to local time."},setUTCDate:{"!type":"fn(day: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCDate","!doc":"Sets the day of the month for a specified date according to universal time.\n"},setHours:{"!type":"fn(hour: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setHours","!doc":"Sets the hours for a specified date according to local time, and returns the number of milliseconds since 1 January 1970 00:00:00 UTC until the time represented by the updated Date instance."},setUTCHours:{"!type":"fn(hour: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCHours","!doc":"Sets the hour for a specified date according to universal time.\n"},setMinutes:{"!type":"fn(min: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setMinutes","!doc":"Sets the minutes for a specified date according to local time."},setUTCMinutes:{"!type":"fn(min: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCMinutes","!doc":"Sets the minutes for a specified date according to universal time.\n"},setSeconds:{"!type":"fn(sec: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setSeconds","!doc":"Sets the seconds for a specified date according to local time."},setUTCSeconds:{"!type":"fn(sec: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCSeconds","!doc":"Sets the seconds for a specified date according to universal time.\n"},setMilliseconds:{"!type":"fn(ms: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setMilliseconds","!doc":"Sets the milliseconds for a specified date according to local time.\n"},setUTCMilliseconds:{"!type":"fn(ms: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date/setUTCMilliseconds","!doc":"Sets the milliseconds for a specified date according to universal time.\n"}},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Date","!doc":"Creates JavaScript Date instances which let you work with dates and times."},Error:{"!type":"fn(message: string)",prototype:{name:{"!type":"string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Error/name","!doc":"A name for the type of error."},message:{"!type":"string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Error/message","!doc":"A human-readable description of the error."}},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Error","!doc":"Creates an error object."},SyntaxError:{"!type":"fn(message: string)",prototype:"Error.prototype","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/SyntaxError","!doc":"Represents an error when trying to interpret syntactically invalid code."},ReferenceError:{"!type":"fn(message: string)",prototype:"Error.prototype","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/ReferenceError","!doc":"Represents an error when a non-existent variable is referenced."},URIError:{"!type":"fn(message: string)",prototype:"Error.prototype","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/URIError","!doc":"Represents an error when a malformed URI is encountered."},EvalError:{"!type":"fn(message: string)",prototype:"Error.prototype","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/EvalError","!doc":"Represents an error regarding the eval function."},RangeError:{"!type":"fn(message: string)",prototype:"Error.prototype","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/RangeError","!doc":"Represents an error when a number is not within the correct range allowed."},TypeError:{"!type":"fn(message: string)",prototype:"Error.prototype","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/TypeError","!doc":"Represents an error an error when a value is not of the expected type."},parseInt:{"!type":"fn(string: string, radix?: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/parseInt","!doc":"Parses a string argument and returns an integer of the specified radix or base."},parseFloat:{"!type":"fn(string: string) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/parseFloat","!doc":"Parses a string argument and returns a floating point number."},isNaN:{"!type":"fn(value: number) -> bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/isNaN","!doc":"Determines whether a value is NaN or not. Be careful, this function is broken. You may be interested in ECMAScript 6 Number.isNaN."},isFinite:{"!type":"fn(value: number) -> bool","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/isFinite","!doc":"Determines whether the passed value is a finite number."},eval:{"!type":"fn(code: string) -> ?","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/eval","!doc":"Evaluates JavaScript code represented as a string."},encodeURI:{"!type":"fn(uri: string) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/encodeURI","!doc":'Encodes a Uniform Resource Identifier (URI) by replacing each instance of certain characters by one, two, three, or four escape sequences representing the UTF-8 encoding of the character (will only be four escape sequences for characters composed of two "surrogate" characters).'},encodeURIComponent:{"!type":"fn(uri: string) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/encodeURIComponent","!doc":'Encodes a Uniform Resource Identifier (URI) component by replacing each instance of certain characters by one, two, three, or four escape sequences representing the UTF-8 encoding of the character (will only be four escape sequences for characters composed of two "surrogate" characters).'},decodeURI:{"!type":"fn(uri: string) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/decodeURI","!doc":"Decodes a Uniform Resource Identifier (URI) previously created by encodeURI or by a similar routine."},decodeURIComponent:{"!type":"fn(uri: string) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/decodeURIComponent","!doc":"Decodes a Uniform Resource Identifier (URI) component previously created by encodeURIComponent or by a similar routine."},Math:{E:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/E","!doc":"The base of natural logarithms, e, approximately 2.718."},LN2:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/LN2","!doc":"The natural logarithm of 2, approximately 0.693."},LN10:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/LN10","!doc":"The natural logarithm of 10, approximately 2.302."},LOG2E:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/LOG2E","!doc":"The base 2 logarithm of E (approximately 1.442)."},LOG10E:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/LOG10E","!doc":"The base 10 logarithm of E (approximately 0.434)."},SQRT1_2:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/SQRT1_2","!doc":"The square root of 1/2; equivalently, 1 over the square root of 2, approximately 0.707."},SQRT2:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/SQRT2","!doc":"The square root of 2, approximately 1.414."},PI:{"!type":"number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/PI","!doc":"The ratio of the circumference of a circle to its diameter, approximately 3.14159."},abs:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/abs","!doc":"Returns the absolute value of a number."},cos:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/cos","!doc":"Returns the cosine of a number."},sin:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/sin","!doc":"Returns the sine of a number."},tan:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/tan","!doc":"Returns the tangent of a number."},acos:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/acos","!doc":"Returns the arccosine (in radians) of a number."},asin:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/asin","!doc":"Returns the arcsine (in radians) of a number."},atan:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/atan","!doc":"Returns the arctangent (in radians) of a number."},atan2:{"!type":"fn(y: number, x: number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/atan2","!doc":"Returns the arctangent of the quotient of its arguments."},ceil:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/ceil","!doc":"Returns the smallest integer greater than or equal to a number."},floor:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/floor","!doc":"Returns the largest integer less than or equal to a number."},round:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/round","!doc":"Returns the value of a number rounded to the nearest integer."},exp:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/exp","!doc":"Returns Ex, where x is the argument, and E is Euler's constant, the base of the natural logarithms."},log:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/log","!doc":"Returns the natural logarithm (base E) of a number."},sqrt:{"!type":"fn(number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/sqrt","!doc":"Returns the square root of a number."},pow:{"!type":"fn(number, number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/pow","!doc":"Returns base to the exponent power, that is, baseexponent."},max:{"!type":"fn(number, number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/max","!doc":"Returns the largest of zero or more numbers."},min:{"!type":"fn(number, number) -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/min","!doc":"Returns the smallest of zero or more numbers."},random:{"!type":"fn() -> number","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math/random","!doc":"Returns a floating-point, pseudo-random number in the range [0, 1) that is, from 0 (inclusive) up to but not including 1 (exclusive), which you can then scale to your desired range."},"!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Math","!doc":"A built-in object that has properties and methods for mathematical constants and functions."},JSON:{parse:{"!type":"fn(json: string) -> ?","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/JSON/parse","!doc":"Parse a string as JSON, optionally transforming the value produced by parsing."},stringify:{"!type":"fn(value: ?) -> string","!url":"https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/JSON/stringify","!doc":"Convert a value to JSON, optionally replacing values if a replacer function is specified, or optionally including only the specified properties if a replacer array is specified."},"!url":"https://developer.mozilla.org/en-US/docs/JSON","!doc":"JSON (JavaScript Object Notation) is a data-interchange format.  It closely resembles a subset of JavaScript syntax, although it is not a strict subset. (See JSON in the JavaScript Reference for full details.)  It is useful when writing any kind of JavaScript-based application, including websites and browser extensions.  For example, you might store user information in JSON format in a cookie, or you might store extension preferences in JSON in a string-valued browser preference."}}
}),define("json!tern/defs/ecma6.json",function(){return{"!name":"ecma6","!define":{"Promise.prototype":{"catch":{"!doc":"The catch() method returns a Promise and deals with rejected cases only. It behaves the same as calling Promise.prototype.then(undefined, onRejected).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/catch","!type":"fn(onRejected: fn(reason: ?))"},then:{"!doc":"The then() method returns a Promise. It takes two arguments, both are callback functions for the success and failure cases of the Promise.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/then","!type":"fn(onFulfilled: fn(value: ?), onRejected: fn(reason: ?))","!effects":["call !0 !this.value"]}},promiseReject:{"!type":"fn(reason: ?)"}},Array:{from:{"!type":"fn(arrayLike: [], mapFn?: fn(), thisArg?: ?) -> !custom:Array_ctor","!doc":"The Array.from() method creates a new Array instance from an array-like or iterable object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/from"},of:{"!type":"fn(elementN: ?) -> !custom:Array_ctor","!doc":"The Array.of() method creates a new Array instance with a variable number of arguments, regardless of number or type of the arguments.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/of"},prototype:{copyWithin:{"!type":"fn(target: number, start: number, end?: number) -> !custom:Array_ctor","!doc":"The copyWithin() method copies the sequence of array elements within the array to the position starting at target. The copy is taken from the index positions of the second and third arguments start and end. The end argument is optional and defaults to the length of the array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/copyWithin"},entries:{"!type":"fn() -> TODO_ITERATOR","!doc":"The entries() method returns a new Array Iterator object that contains the key/value pairs for each index in the array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/entries"},fill:{"!type":"fn(value: ?, start?: number, end?: number)","!doc":"The fill() method fills all the elements of an array from a start index to an end index with a static value.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/fill"},find:{"!type":"fn(callback: fn(element: ?, index: number, array: []), thisArg?: ?) -> ?","!doc":"The find() method returns a value in the array, if an element in the array satisfies the provided testing function. Otherwise undefined is returned.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/find"},findIndex:{"!type":"fn(callback: fn(element: ?, index: number, array: []), thisArg?: ?) -> number","!doc":"The findIndex() method returns an index in the array, if an element in the array satisfies the provided testing function. Otherwise -1 is returned.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/findIndex"},keys:{"!type":"fn() -> !custom:Array_ctor","!doc":"The keys() method returns a new Array Iterator that contains the keys for each index in the array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/keys"},values:{"!type":"fn() -> !custom:Array_ctor","!doc":"The values() method returns a new Array Iterator object that contains the values for each index in the array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/values"}}},ArrayBuffer:{"!type":"fn(length: number)","!doc":"The ArrayBuffer object is used to represent a generic, fixed-length raw binary data buffer. You can not directly manipulate the contents of an ArrayBuffer; instead, you create one of the typed array objects or a DataView object which represents the buffer in a specific format, and use that to read and write the contents of the buffer.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer",isView:{"!type":"fn(arg: ?) -> bool","!doc":"The ArrayBuffer.isView() method returns true if arg is a view one of the ArrayBuffer views, such as typed array objects or a DataView; false otherwise.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer/isView"},transfer:{"!type":"fn(oldBuffer: ?, newByteLength: ?)","!doc":"The static ArrayBuffer.transfer() method returns a new ArrayBuffer whose contents are taken from the oldBuffer's data and then is either truncated or zero-extended by newByteLength. If newByteLength is undefined, the byteLength of the oldBuffer is used. This operation leaves oldBuffer in a detached state.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer/transfer"},prototype:{byteLength:{"!type":"number","!doc":"The byteLength accessor property represents the length of an ArrayBuffer in bytes.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer/byteLength"},slice:{"!type":"fn(begin: number, end?: number) -> +ArrayBuffer","!doc":"The slice() method returns a new ArrayBuffer whose contents are a copy of this ArrayBuffer's bytes from begin, inclusive, up to end, exclusive.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer/slice"}}},DataView:{"!type":"fn(buffer: +ArrayBuffer, byteOffset?: number, byteLength?: number)","!doc":"The DataView view provides a low-level interface for reading data from and writing it to an ArrayBuffer.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView",prototype:{buffer:{"!type":"+ArrayBuffer","!doc":"The buffer accessor property represents the ArrayBuffer referenced by the DataView at construction time.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/buffer"},byteLength:{"!type":"number","!doc":"The byteLength accessor property represents the length (in bytes) of this view from the start of its ArrayBuffer.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/byteLength"},byteOffset:{"!type":"number","!doc":"The byteOffset accessor property represents the offset (in bytes) of this view from the start of its ArrayBuffer.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/byteOffset"},getFloat32:{"!type":"fn(byteOffset: number, littleEndian?: bool) -> number","!doc":"The getFloat32() method gets a signed 32-bit integer (float) at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/getFloat32"},getFloat64:{"!type":"fn(byteOffset: number, littleEndian?: bool) -> number","!doc":"The getFloat64() method gets a signed 64-bit float (double) at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/getFloat64"},getInt16:{"!type":"fn(byteOffset: number, littleEndian?: bool) -> number","!doc":"The getInt16() method gets a signed 16-bit integer (short) at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/getInt16"},getInt32:{"!type":"fn(byteOffset: number, littleEndian?: bool) -> number","!doc":"The getInt32() method gets a signed 32-bit integer (long) at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/getInt32"},getInt8:{"!type":"fn(byteOffset: number, littleEndian?: bool) -> number","!doc":"The getInt8() method gets a signed 8-bit integer (byte) at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/getInt8"},getUint16:{"!type":"fn(byteOffset: number, littleEndian?: bool) -> number","!doc":"The getUint16() method gets an unsigned 16-bit integer (unsigned short) at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/getUint16"},getUint32:{"!type":"fn(byteOffset: number, littleEndian?: bool) -> number","!doc":"The getUint32() method gets an unsigned 32-bit integer (unsigned long) at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/getUint32"},getUint8:{"!type":"fn(byteOffset: number) -> number","!doc":"The getUint8() method gets an unsigned 8-bit integer (unsigned byte) at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/getUint8"},setFloat32:{"!type":"fn(byteOffset: number, value: number, littleEndian?: bool)","!doc":"The setFloat32() method stores a signed 32-bit integer (float) value at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/setFloat32"},setFloat64:{"!type":"fn(byteOffset: number, value: number, littleEndian?: bool)","!doc":"The setFloat64() method stores a signed 64-bit integer (double) value at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/setFloat64"},setInt16:{"!type":"fn(byteOffset: number, value: number, littleEndian?: bool)","!doc":"The setInt16() method stores a signed 16-bit integer (short) value at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/setInt16"},setInt32:{"!type":"fn(byteOffset: number, value: number, littleEndian?: bool)","!doc":"The setInt32() method stores a signed 32-bit integer (long) value at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/setInt32"},setInt8:{"!type":"fn(byteOffset: number, value: number)","!doc":"The setInt8() method stores a signed 8-bit integer (byte) value at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/setInt8"},setUint16:{"!type":"fn(byteOffset: number, value: number, littleEndian?: bool)","!doc":"The setUint16() method stores an unsigned 16-bit integer (unsigned short) value at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/setUint16"},setUint32:{"!type":"fn(byteOffset: number, value: number, littleEndian?: bool)","!doc":"The setUint32() method stores an unsigned 32-bit integer (unsigned long) value at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/setUint32"},setUint8:{"!type":"fn(byteOffset: number, value: number)","!doc":"The setUint8() method stores an unsigned 8-bit integer (byte) value at the specified byte offset from the start of the DataView.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView/setUint8"}}},Float32Array:{"!type":"fn(length: number)","!doc":"The Float32Array typed array represents an array of 32-bit floating point numbers (corresponding to the C float data type) in the platform byte order. If control over byte order is needed, use DataView instead. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Float32Array",prototype:{"!proto":"TypedArray.prototype"},length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of"},Float64Array:{"!type":"fn(length: number)","!doc":"The Float64Array typed array represents an array of 64-bit floating point numbers (corresponding to the C double data type) in the platform byte order. If control over byte order is needed, use DataView instead. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Float64Array",prototype:{"!proto":"TypedArray.prototype"},length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of"},Int16Array:{"!type":"fn(length: number)","!doc":"The Int16Array typed array represents an array of twos-complement 16-bit signed integers in the platform byte order. If control over byte order is needed, use DataView instead. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Int16Array",prototype:{"!proto":"TypedArray.prototype"},length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of"},Int32Array:{"!type":"fn(length: number)","!doc":"The Int32Array typed array represents an array of twos-complement 32-bit signed integers in the platform byte order. If control over byte order is needed, use DataView instead. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Int32Array",prototype:{"!proto":"TypedArray.prototype"},length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of"},Int8Array:{"!type":"fn(length: number)","!doc":"The Int8Array typed array represents an array of twos-complement 8-bit signed integers. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Int8Array",prototype:{"!proto":"TypedArray.prototype"},length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of"},Map:{"!type":"fn(iterable?: [])","!doc":"The Map object is a simple key/value map. Any value (both objects and primitive values) may be used as either a key or a value.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map",prototype:{clear:{"!type":"fn()","!doc":"The clear() method removes all elements from a Map object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/clear"},"delete":{"!type":"fn(key: ?)","!doc":"The delete() method removes the specified element from a Map object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/delete"},entries:{"!type":"fn() -> TODO_ITERATOR","!doc":"The entries() method returns a new Iterator object that contains the [key, value] pairs for each element in the Map object in insertion order.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/entries"},forEach:{"!type":"fn(callback: fn(value: ?, key: ?, map: +Map), thisArg?: ?)","!effects":["call !0 this=!1 !this.<i> number !this"],"!doc":"The forEach() method executes a provided function once per each key/value pair in the Map object, in insertion order.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/forEach"},get:{"!type":"fn(key: ?) -> !this.<i>","!doc":"The get() method returns a specified element from a Map object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/get"},has:{"!type":"fn(key: ?) -> bool","!doc":"The has() method returns a boolean indicating whether an element with the specified key exists or not.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/has"},keys:{"!type":"fn() -> TODO_ITERATOR","!doc":"The keys() method returns a new Iterator object that contains the keys for each element in the Map object in insertion order.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/keys"},set:{"!type":"fn(key: ?, value: ?) -> !this","!doc":"The set() method adds a new element with a specified key and value to a Map object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/set"},size:{"!type":"number","!doc":"The size accessor property returns the number of elements in a Map object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/size"},values:{"!type":"fn() -> TODO_ITERATOR","!doc":"The values() method returns a new Iterator object that contains the values for each element in the Map object in insertion order.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/values"},"prototype[@@iterator]":{"!type":"fn()","!doc":"The initial value of the @@iterator property is the same function object as the initial value of the entries property.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/@@iterator"}}},Math:{acosh:{"!type":"fn(x: number) -> number","!doc":"The Math.acosh() function returns the hyperbolic arc-cosine of a number, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/acosh"},asinh:{"!type":"fn(x: number) -> number","!doc":"The Math.asinh() function returns the hyperbolic arcsine of a number, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/asinh"},atanh:{"!type":"fn(x: number) -> number","!doc":"The Math.atanh() function returns the hyperbolic arctangent of a number, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/atanh"},cbrt:{"!type":"fn(x: number) -> number","!doc":"The Math.cbrt() function returns the cube root of a number, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/cbrt"},clz32:{"!type":"fn(x: number) -> number","!doc":"The Math.clz32() function returns the number of leading zero bits in the 32-bit binary representation of a number.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/clz32"},cosh:{"!type":"fn(x: number) -> number","!doc":"The Math.cosh() function returns the hyperbolic cosine of a number, that can be expressed using the constant e:","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/cosh"},expm1:{"!type":"fn(x: number) -> number","!doc":"The Math.expm1() function returns ex - 1, where x is the argument, and e the base of the natural logarithms.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/expm1"},fround:{"!type":"fn(x: number) -> number","!doc":"The Math.fround() function returns the nearest single precision float representation of a number.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/fround"},hypot:{"!type":"fn(value: number) -> number","!doc":"The Math.hypot() function returns the square root of the sum of squares of its arguments, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/hypot"},imul:{"!type":"fn(a: number, b: number) -> number","!doc":"The Math.imul() function returns the result of the C-like 32-bit multiplication of the two parameters.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/imul"},log10:{"!type":"fn(x: number) -> number","!doc":"The Math.log10() function returns the base 10 logarithm of a number, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/log10"},log1p:{"!type":"fn(x: number) -> number","!doc":"The Math.log1p() function returns the natural logarithm (base e) of 1 + a number, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/log1p"},log2:{"!type":"fn(x: number) -> number","!doc":"The Math.log2() function returns the base 2 logarithm of a number, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/log2"},sign:{"!type":"fn(x: number) -> number","!doc":"The Math.sign() function returns the sign of a number, indicating whether the number is positive, negative or zero.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/sign"},sinh:{"!type":"fn(x: number) -> number","!doc":"The Math.sinh() function returns the hyperbolic sine of a number, that can be expressed using the constant e:","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/sinh"},tanh:{"!type":"fn(x: number) -> number","!doc":"The Math.tanh() function returns the hyperbolic tangent of a number, that is","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/tanh"},trunc:{"!type":"fn(x: number) -> number","!doc":"The Math.trunc() function returns the integral part of a number by removing any fractional digits. It does not round any numbers. The function can be expressed with the floor() and ceil() function:","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/trunc"}},Number:{EPSILON:{"!type":"number","!doc":"The Number.EPSILON property represents the difference between one and the smallest value greater than one that can be represented as a Number.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/EPSILON"},MAX_SAFE_INTEGER:{"!type":"number","!doc":"The Number.MAX_SAFE_INTEGER constant represents the maximum safe integer in JavaScript (253 - 1).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/MAX_SAFE_INTEGER"},MIN_SAFE_INTEGER:{"!type":"number","!doc":"The Number.MIN_SAFE_INTEGER constant represents the minimum safe integer in JavaScript (-(253 - 1)).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/MIN_SAFE_INTEGER"},isFinite:{"!type":"fn(testValue: ?) -> bool","!doc":"The Number.isFinite() method determines whether the passed value is finite.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isFinite"},isInteger:{"!type":"fn(testValue: ?) -> bool","!doc":"The Number.isInteger() method determines whether the passed value is an integer.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isInteger"},isNaN:{"!type":"fn(testValue: ?) -> bool","!doc":"The Number.isNaN() method determines whether the passed value is NaN. More robust version of the original global isNaN().","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isNaN"},isSafeInteger:{"!type":"fn(testValue: ?) -> bool","!doc":"The Number.isSafeInteger() method determines whether the provided value is a number that is a safe integer. A safe integer is an integer that","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/isSafeInteger"},parseFloat:{"!type":"fn(string: string) -> number","!doc":"The Number.parseFloat() method parses a string argument and returns a floating point number. This method behaves identically to the global function parseFloat() and is part of ECMAScript 6 (its purpose is modularization of globals).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/parseFloat"},parseInt:{"!type":"fn(string: string, radix?: number) -> number","!doc":"The Number.parseInt() method parses a string argument and returns an integer of the specified radix or base. This method behaves identically to the global function parseInt() and is part of ECMAScript 6 (its purpose is modularization of globals).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number/parseInt"}},Object:{assign:{"!type":"fn(target: ?, sources: ?) -> ?","!doc":"The Object.assign() method is used to copy the values of all enumerable own properties from one or more source objects to a target object. It will return the target object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/assign"},getOwnPropertySymbols:{"!type":"fn(obj: ?) -> [?]","!doc":"The Object.getOwnPropertySymbols() method returns an array of all symbol properties found directly upon a given object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/getOwnPropertySymbols"},is:{"!type":"fn(value1: ?, value2: ?) -> bool","!doc":"The Object.is() method determines whether two values are the same value.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is"},setPrototypeOf:{"!type":"fn(obj: ?, prototype: ?)","!doc":"The Object.setPrototype() method sets the prototype (i.e., the internal [[Prototype]] property) of a specified object to another object or null.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/setPrototypeOf"}},Promise:{"!type":"fn(executor: fn(resolve: fn(value: ?), reject: promiseReject)) -> !custom:Promise_ctor","!doc":"The Promise object is used for deferred and asynchronous computations. A Promise is in one of the three states:","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise",all:{"!type":"fn(iterable: [+Promise]) -> !0.<i>","!doc":"The Promise.all(iterable) method returns a promise that resolves when all of the promises in the iterable argument have resolved.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/all"},race:{"!type":"fn(iterable: [+Promise]) -> !0.<i>","!doc":"The Promise.race(iterable) method returns a promise that resolves or rejects as soon as one of the promises in the iterable resolves or rejects, with the value or reason from that promise.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/race"},reject:{"!type":"fn(reason: ?) -> !this","!doc":"The Promise.reject(reason) method returns a Promise object that is rejected with the given reason.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/reject"},resolve:{"!type":"fn(value: ?) -> +Promise[value=!0]","!doc":"The Promise.resolve(value) method returns a Promise object that is resolved with the given value. If the value is a thenable (i.e. has a then method), the returned promise will 'follow' that thenable, adopting its eventual state; otherwise the returned promise will be fulfilled with the value.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/resolve"},prototype:"Promise.prototype"},Proxy:{"!type":"fn(target: ?, handler: ?)","!doc":"The Proxy object is used to define the custom behavior in JavaScript fundamental operation (e.g. property lookup, assignment, enumeration, function invocation, etc).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Proxy",revocable:{"!doc":"The Proxy.revocable() method is used to create a revocable Proxy object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Proxy/revocable"}},RegExp:{prototype:{flags:{"!type":"string","!doc":"The flags property returns a string consisting of the flags of the current regular expression object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp/flags"},sticky:{"!type":"bool","!doc":"The sticky property reflects whether or not the search is sticky (searches in strings only from the index indicated by the lastIndex property of this regular expression). sticky is a read-only property of an individual regular expression object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp/sticky"}}},Set:{"!type":"fn(iterable: [?])","!doc":"The Set object lets you store unique values of any type, whether primitive values or object references.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set",length:{"!type":"number","!doc":"The value of the length property is 1."},prototype:{add:{"!type":"fn(value: ?) -> !this","!doc":"The add() method appends a new element with a specified�value to the end of a Set object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/add"},clear:{"!type":"fn()","!doc":"The clear() method removes all elements from a Set object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/clear"},"delete":{"!type":"fn(value: ?) -> bool","!doc":"The delete() method removes the specified element from a Set object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/delete"},entries:{"!type":"fn() -> TODO_ITERATOR","!doc":"The entries() method returns a new Iterator object that contains an array of [value, value] for each element in the Set object, in insertion order. For Set objects there is no key like in Map objects. However, to keep the API similar to the Map object, each entry has the same value for its key and value here, so that an array [value, value] is returned.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/entries"},forEach:{"!type":"fn(callback: fn(value: ?, value2: ?, set: +Set), thisArg?: ?)","!effects":["call !0 this=!1 !this.<i> number !this"]},has:{"!type":"fn(value: ?) -> bool","!doc":"The has() method returns a boolean indicating whether an element with the specified value exists in a Set object or not.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/has"},keys:{"!type":"fn() -> TODO_ITERATOR","!doc":"The values() method returns a new Iterator object that contains the values for each element in the Set object in insertion order.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/keys"},size:{"!type":"number","!doc":"The size accessor property returns the number of elements in a Set object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/size"},values:{"!type":"fn() -> TODO_ITERATOR","!doc":"The values() method returns a new Iterator object that contains the values for each element in the Set object in insertion order.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/values"},"prototype[@@iterator]":{"!type":"fn()","!doc":"The initial value of the @@iterator property is the same function object as the initial value of the values property.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set/@@iterator"}}},String:{fromCodePoint:{"!type":"fn(num1: ?) -> string","!doc":"The static String.fromCodePoint() method returns a string created by using the specified sequence of code points.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/fromCodePoint"},raw:{"!type":"fn(callSite: ?, substitutions: ?, templateString: ?) -> string","!doc":"The static String.raw() method is a tag function of template strings, like the r prefix in Python or the @ prefix in C# for string literals, this function is used to get the raw string form of template strings.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/raw"},prototype:{codePointAt:{"!type":"fn(pos: number) -> number","!doc":"The codePointAt() method returns a non-negative integer that is the UTF-16 encoded code point value.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/codePointAt"},endsWith:{"!type":"fn(searchString: string, position?: number) -> bool","!doc":"The endsWith() method determines whether a string ends with the characters of another string, returning true or false as appropriate.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/endsWith"},includes:{"!type":"fn(searchString: string, position?: number) -> bool","!doc":"The includes() method determines whether one string may be found within another string, returning true or false as appropriate.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/contains"},normalize:{"!type":"fn(form: string) -> string","!doc":"The normalize() method returns the Unicode Normalization Form of a given string (if the value isn't a string, it will be converted to one first).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/normalize"},repeat:{"!type":"fn(count: number) -> string","!doc":"The repeat() method constructs and returns a new string which contains the specified number of copies of the string on which it was called, concatenated together.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/repeat"},startsWith:{"!type":"fn(searchString: string, position?: number) -> bool","!doc":"The startsWith() method determines whether a string begins with the characters of another string, returning true or false as appropriate.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/startsWith"}}},Symbol:{"!type":"fn(description?: string)","!doc":"A symbol is a unique and immutable data type and may be used as an identifier for object properties. The symbol object is an implicit object wrapper for the symbol primitive data type.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol","for":{"!type":"fn(key: string) -> +Symbol","!doc":"The Symbol.for(key) method searches for existing symbols in a runtime-wide symbol registry with the given key and returns it if found. Otherwise a new symbol gets created in the global symbol registry with this key.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/for"},keyFor:{"!type":"fn(sym: +Symbol) -> +Symbol","!doc":"The Symbol.keyFor(sym) method retrieves a shared symbol key from the global symbol registry for the given symbol.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/keyFor"},prototype:{toString:{"!type":"fn() -> string","!doc":"The toString() method returns a string representing the specified Symbol object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/toString"},valueOf:{"!type":"fn() -> ?","!doc":"The valueOf() method returns the primitive value of a Symbol object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol/valueOf"}}},TypedArray:{"!type":"fn(length: number)","!doc":"A TypedArray object describes an array-like view of an underlying binary data buffer. There is no global property named TypedArray, nor is there a directly visible TypedArray constructor.  Instead, there are a number of different global properties, whose values are typed array constructors for specific element types, listed below. On the following pages you will find common properties and methods that can be used with any typed array containing elements of any type.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray",BYTES_PER_ELEMENT:{"!type":"number","!doc":"The TypedArray.BYTES_PER_ELEMENT property represents the size in bytes of each element in an typed array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/BYTES_PER_ELEMENT"},length:{"!type":"number","!doc":"The length accessor property represents the length (in elements) of a typed array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/length"},name:{"!type":"string","!doc":"The TypedArray.name property represents a string value of the typed array constructor name.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/name"},prototype:{buffer:{"!type":"+ArrayBuffer","!doc":"The buffer accessor property represents the ArrayBuffer referenced by a TypedArray at construction time.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/buffer"},byteLength:{"!type":"number","!doc":"The byteLength accessor property represents the length (in bytes) of a typed array from the start of its ArrayBuffer.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/byteLength"},byteOffset:{"!type":"number","!doc":"The byteOffset accessor property represents the offset (in bytes) of a typed array from the start of its ArrayBuffer.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/byteOffset"},copyWithin:{"!type":"fn(target: number, start: number, end?: number) -> ?","!doc":"The copyWithin() method copies the sequence of array elements within the array to the position starting at target. The copy is taken from the index positions of the second and third arguments start and end. The end argument is optional and defaults to the length of the array. This method has the same algorithm as Array.prototype.copyWithin. TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/copyWithin"},entries:{"!type":"fn() -> TODO_ITERATOR","!doc":"The entries() method returns a new Array Iterator object that contains the key/value pairs for each index in the array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/entries"},every:{"!type":"fn(callback: fn(currentValue: ?, index: number, array: +TypedArray) -> bool, thisArg?: ?) -> bool","!effects":["call !0 this=!1 !this.<i> number !this"],"!doc":"The every() method tests whether all elements in the typed array pass the test implemented by the provided function. This method has the same algorithm as Array.prototype.every(). TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/every"},fill:{"!type":"fn(value: ?, start?: number, end?: number)","!doc":"The fill() method fills all the elements of a typed array from a start index to an end index with a static value. This method has the same algorithm as Array.prototype.fill(). TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/fill"},filter:{"!type":"fn(test: fn(elt: ?, i: number) -> bool, context?: ?) -> !this","!effects":["call !0 this=!1 !this.<i> number"],"!doc":"Creates a new array with all of the elements of this array for which the provided filtering function returns true. See also Array.prototype.filter().","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/filter"},find:{"!type":"fn(callback: fn(element: ?, index: number, array: +TypedArray) -> bool, thisArg?: ?) -> ?","!effects":["call !0 this=!1 !this.<i> number !this"],"!doc":"The find() method returns a value in the typed array, if an element satisfies the provided testing function. Otherwise undefined is returned. TypedArray is one of the typed array types here.\nSee also the findIndex() method, which returns the index of a found element in the typed array instead of its value.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/find"},findIndex:{"!type":"fn(callback: fn(element: ?, index: number, array: +TypedArray) -> bool, thisArg?: ?) -> number","!effects":["call !0 this=!1 !this.<i> number !this"],"!doc":"The findIndex() method returns an index in the typed array, if an element in the typed array satisfies the provided testing function. Otherwise -1 is returned.\nSee also the find() method, which returns the value of a found element in the typed array instead of its index.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/findIndex"},forEach:{"!type":"fn(callback: fn(value: ?, key: ?, array: +TypedArray), thisArg?: ?)","!effects":["call !0 this=!1 !this.<i> number !this"],"!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/forEach"},includes:{"!type":"fn(searchElement: ?, fromIndex?: number) -> bool","!doc":"The includes() method determines whether a typed array includes a certain element, returning true or false as appropriate. This method has the same algorithm as Array.prototype.includes(). TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/includes"},indexOf:{"!type":"fn(searchElement: ?, fromIndex?: number) -> number","!doc":"The indexOf() method returns the first index at which a given element can be found in the typed array, or -1 if it is not present. This method has the same algorithm as Array.prototype.indexOf(). TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/indexOf"},join:{"!type":"fn(separator?: string) -> string","!doc":"The join() method joins all elements of an array into a string. This method has the same algorithm as Array.prototype.join(). TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/join"},keys:{"!type":"fn() -> TODO_ITERATOR","!doc":"The keys() method returns a new Array Iterator object that contains the keys for each index in the array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/keys"},lastIndexOf:{"!type":"fn(searchElement: ?, fromIndex?: number) -> number","!doc":"The lastIndexOf() method returns the last index at which a given element can be found in the typed array, or -1 if it is not present. The typed array is searched backwards, starting at fromIndex. This method has the same algorithm as Array.prototype.lastIndexOf(). TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/lastIndexOf"},length:{"!type":"number","!doc":"Returns the number of elements hold in the typed array. Fixed at construction time and thus read only.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/length"},map:{"!type":"fn(f: fn(elt: ?, i: number) -> ?, context?: ?) -> [!0.!ret]","!effects":["call !0 this=!1 !this.<i> number"],"!doc":"Creates a new array with the results of calling a provided function on every element in this array. See also Array.prototype.map().","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/map"},reduce:{"!type":"fn(combine: fn(sum: ?, elt: ?, i: number) -> ?, init?: ?) -> !0.!ret","!effects":["call !0 !1 !this.<i> number"],"!doc":"Apply a function against an accumulator and each value of the array (from left-to-right) as to reduce it to a single value. See also Array.prototype.reduce().","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/reduce"},reduceRight:{"!type":"fn(combine: fn(sum: ?, elt: ?, i: number) -> ?, init?: ?) -> !0.!ret","!effects":["call !0 !1 !this.<i> number"],"!doc":"Apply a function against an accumulator and each value of the array (from right-to-left) as to reduce it to a single value. See also Array.prototype.reduceRight().","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/reduceRight"},reverse:{"!type":"fn()","!doc":"The reverse() method reverses a typed array in place. The first typed array element becomes the last and the last becomes the first. This method has the same algorithm as Array.prototype.reverse(). TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/reverse"},set:{"!type":"fn(array: [?], offset?: ?)","!doc":"The set() method stores multiple values in the typed array, reading input values from a specified array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/set"},slice:{"!type":"fn(from: number, to?: number) -> !this","!type":"Extracts a section of an array and returns a new array. See also Array.prototype.slice().","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/slice"},some:{"!type":"fn(test: fn(elt: ?, i: number) -> bool, context?: ?) -> bool","!effects":["call !0 this=!1 !this.<i> number"],"!doc":"The some() method tests whether some element in the typed array passes the test implemented by the provided function. This method has the same algorithm as Array.prototype.some(). TypedArray is one of the typed array types here.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/some"},sort:{"!type":"fn(compare?: fn(a: ?, b: ?) -> number)","!effects":["call !0 !this.<i> !this.<i>"],"!doc":"Sorts the elements of an array in place and returns the array. See also Array.prototype.sort().","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/sort"},subarray:{"!type":"fn(begin?: number, end?: number) -> +TypedArray","!doc":"The subarray() method returns a new TypedArray on the same ArrayBuffer store and with the same element types as for this TypedArray object. The begin offset is inclusive and the end offset is exclusive. TypedArray is one of the typed array types.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/subarray"},values:{"!type":"fn() -> TODO_ITERATOR","!doc":"The values() method returns a new Array Iterator object that contains the values for each index in the array.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/values"},"prototype[@@iterator]":{"!type":"fn()","!doc":"The initial value of the @@iterator property is the same function object as the initial value of the values property.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray/@@iterator"}}},Uint16Array:{"!type":"fn()","!doc":"The Uint16Array typed array represents an array of 16-bit unsigned integers in the platform byte order. If control over byte order is needed, use DataView instead. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint16Array",length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of",prototype:{"!proto":"TypedArray.prototype"}},Uint32Array:{"!type":"fn()","!doc":"The Uint32Array typed array represents an array of 32-bit unsigned integers in the platform byte order. If control over byte order is needed, use DataView instead. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint32Array",length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of",prototype:{"!proto":"TypedArray.prototype"}},Uint8Array:{"!type":"fn()","!doc":"The Uint8Array typed array represents an array of 8-bit unsigned integers. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array",length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of",prototype:{"!proto":"TypedArray.prototype"}},Uint8ClampedArray:{"!type":"fn()","!doc":"The Uint8ClampedArray typed array represents an array of 8-bit unsigned integers clamped to 0-255. The contents are initialized to 0. Once established, you can reference elements in the array using the object's methods, or using standard array index syntax (that is, using bracket notation).","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8ClampedArray",length:"TypedArray.length",BYTES_PER_ELEMENT:"TypedArray.BYTES_PER_ELEMENT",name:"TypedArray.name",from:"TypedArray.from",of:"TypedArray.of",prototype:{"!proto":"TypedArray.prototype"}},WeakMap:{"!type":"fn(iterable: [?])","!doc":"The WeakMap object is a collection of key/value pairs in which the keys are objects and the values can be arbitrary values.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap",prototype:{"delete":{"!type":"fn(key: ?) -> bool","!doc":"The delete() method removes the specified element from a WeakMap object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/delete"},get:{"!type":"fn(key: ?) !this.<i>","!doc":"The get() method returns a specified element from a WeakMap object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/get"},has:{"!type":"fn(key: ?) -> bool","!doc":"The has() method returns a boolean indicating whether an element with the specified key exists in the WeakMap object or not.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/has"},set:{"!type":"fn(key: ?, value: ?)","!doc":"The set() method adds a new element with a specified key and value to a WeakMap object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap/set"}}},WeakSet:{"!type":"fn(iterable: [?])","!doc":"The WeakSet object lets you store weakly held objects in a collection.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet",prototype:{add:{"!type":"fn(value: ?)","!doc":"The add() method appends a new object to the end of a WeakSet object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet/add"},"delete":{"!type":"fn(value: ?) -> bool","!doc":"The delete() method removes the specified element from a WeakSet object.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet/delete"},has:{"!type":"fn(value: ?) -> bool","!doc":"The has() method returns a boolean indicating whether an object exists in a WeakSet or not.","!url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet/has"}}}}
}),define("json!tern/defs/browser.json",function(){return{"!name":"browser",location:{assign:{"!type":"fn(url: string)","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"Load the document at the provided URL."},replace:{"!type":"fn(url: string)","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"Replace the current document with the one at the provided URL. The difference from the assign() method is that after using replace() the current page will not be saved in session history, meaning the user won't be able to use the Back button to navigate to it."},reload:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"Reload the document from the current URL. forceget is a boolean, which, when it is true, causes the page to always be reloaded from the server. If it is false or not specified, the browser may reload the page from its cache."},origin:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The origin of the URL."},hash:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The part of the URL that follows the # symbol, including the # symbol."},search:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The part of the URL that follows the ? symbol, including the ? symbol."},pathname:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The path (relative to the host)."},port:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The port number of the URL."},hostname:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The host name (without the port number or square brackets)."},host:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The host name and port number."},protocol:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The protocol of the URL."},href:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"The entire URL."},"!url":"https://developer.mozilla.org/en/docs/DOM/window.location","!doc":"Returns a location object with information about the current location of the document. Assigning to the location property changes the current page to the new address."},Node:{"!type":"fn()",prototype:{parentElement:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.parentElement","!doc":"Returns the DOM node's parent Element, or null if the node either has no parent, or its parent isn't a DOM Element."},textContent:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.textContent","!doc":"Gets or sets the text content of a node and its descendants."},baseURI:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.baseURI","!doc":"The absolute base URI of a node or null if unable to obtain an absolute URI."},localName:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.localName","!doc":"Returns the local part of the qualified name of this node."},prefix:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.prefix","!doc":"Returns the namespace prefix of the specified node, or null if no prefix is specified. This property is read only."},namespaceURI:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.namespaceURI","!doc":"The namespace URI of the node, or null if the node is not in a namespace (read-only). When the node is a document, it returns the XML namespace for the current document."},ownerDocument:{"!type":"+Document","!url":"https://developer.mozilla.org/en/docs/DOM/Node.ownerDocument","!doc":"The ownerDocument property returns the top-level document object for this node."},attributes:{"!type":"+NamedNodeMap","!url":"https://developer.mozilla.org/en/docs/DOM/Node.attributes","!doc":"A collection of all attribute nodes registered to the specified node. It is a NamedNodeMap,not an Array, so it has no Array methods and the Attr nodes' indexes may differ among browsers."},nextSibling:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.nextSibling","!doc":"Returns the node immediately following the specified one in its parent's childNodes list, or null if the specified node is the last node in that list."},previousSibling:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.previousSibling","!doc":"Returns the node immediately preceding the specified one in its parent's childNodes list, null if the specified node is the first in that list."},lastChild:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.lastChild","!doc":"Returns the last child of a node."},firstChild:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.firstChild","!doc":"Returns the node's first child in the tree, or null if the node is childless. If the node is a Document, it returns the first node in the list of its direct children."},childNodes:{"!type":"+NodeList","!url":"https://developer.mozilla.org/en/docs/DOM/Node.childNodes","!doc":"Returns a collection of child nodes of the given element."},parentNode:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.parentNode","!doc":"Returns the parent of the specified node in the DOM tree."},nodeType:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/Node.nodeType","!doc":"Returns an integer code representing the type of the node."},nodeValue:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.nodeValue","!doc":"Returns or sets the value of the current node."},nodeName:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.nodeName","!doc":"Returns the name of the current node as a string."},tagName:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.nodeName","!doc":"Returns the name of the current node as a string."},insertBefore:{"!type":"fn(newElt: +Element, before: +Element) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.insertBefore","!doc":"Inserts the specified node before a reference element as a child of the current node."},replaceChild:{"!type":"fn(newElt: +Element, oldElt: +Element) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.replaceChild","!doc":"Replaces one child node of the specified element with another."},removeChild:{"!type":"fn(oldElt: +Element) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.removeChild","!doc":"Removes a child node from the DOM. Returns removed node."},appendChild:{"!type":"fn(newElt: +Element) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.appendChild","!doc":"Adds a node to the end of the list of children of a specified parent node. If the node already exists it is removed from current parent node, then added to new parent node."},hasChildNodes:{"!type":"fn() -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/Node.hasChildNodes","!doc":"Returns a Boolean value indicating whether the current Node has child nodes or not."},cloneNode:{"!type":"fn(deep: bool) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/Node.cloneNode","!doc":"Returns a duplicate of the node on which this method was called."},normalize:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Node.normalize","!doc":'Puts the specified node and all of its subtree into a "normalized" form. In a normalized subtree, no text nodes in the subtree are empty and there are no adjacent text nodes.'},isSupported:{"!type":"fn(features: string, version: number) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/Node.isSupported","!doc":"Tests whether the DOM implementation implements a specific feature and that feature is supported by this node."},hasAttributes:{"!type":"fn() -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/Node.hasAttributes","!doc":"Returns a boolean value of true or false, indicating if the current element has any attributes or not."},lookupPrefix:{"!type":"fn(uri: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.lookupPrefix","!doc":"Returns the prefix for a given namespaceURI if present, and null if not. When multiple prefixes are possible, the result is implementation-dependent."},isDefaultNamespace:{"!type":"fn(uri: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/Node.isDefaultNamespace","!doc":"Accepts a namespace URI as an argument and returns true if the namespace is the default namespace on the given node or false if not."},lookupNamespaceURI:{"!type":"fn(uri: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/Node.lookupNamespaceURI","!doc":"Takes a prefix and returns the namespaceURI associated with it on the given node if found (and null if not). Supplying null for the prefix will return the default namespace."},addEventListener:{"!type":"fn(type: string, listener: fn(e: +Event), capture: bool)","!url":"https://developer.mozilla.org/en/docs/DOM/EventTarget.addEventListener","!doc":"Registers a single event listener on a single target. The event target may be a single element in a document, the document itself, a window, or an XMLHttpRequest."},removeEventListener:{"!type":"fn(type: string, listener: fn(), capture: bool)","!url":"https://developer.mozilla.org/en/docs/DOM/EventTarget.removeEventListener","!doc":"Allows the removal of event listeners from the event target."},isSameNode:{"!type":"fn(other: +Node) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/Node.isSameNode","!doc":"Tests whether two nodes are the same, that is they reference the same object."},isEqualNode:{"!type":"fn(other: +Node) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/Node.isEqualNode","!doc":"Tests whether two nodes are equal."},compareDocumentPosition:{"!type":"fn(other: +Node) -> number","!url":"https://developer.mozilla.org/en/docs/DOM/Node.compareDocumentPosition","!doc":"Compares the position of the current node against another node in any other document."},contains:{"!type":"fn(other: +Node) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/Node.contains","!doc":"Indicates whether a node is a descendent of a given node."},dispatchEvent:{"!type":"fn(event: +Event) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/EventTarget.dispatchEvent","!doc":"Dispatches an event into the event system. The event is subject to the same capturing and bubbling behavior as directly dispatched events."},ELEMENT_NODE:"number",ATTRIBUTE_NODE:"number",TEXT_NODE:"number",CDATA_SECTION_NODE:"number",ENTITY_REFERENCE_NODE:"number",ENTITY_NODE:"number",PROCESSING_INSTRUCTION_NODE:"number",COMMENT_NODE:"number",DOCUMENT_NODE:"number",DOCUMENT_TYPE_NODE:"number",DOCUMENT_FRAGMENT_NODE:"number",NOTATION_NODE:"number",DOCUMENT_POSITION_DISCONNECTED:"number",DOCUMENT_POSITION_PRECEDING:"number",DOCUMENT_POSITION_FOLLOWING:"number",DOCUMENT_POSITION_CONTAINS:"number",DOCUMENT_POSITION_CONTAINED_BY:"number",DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:"number"},"!url":"https://developer.mozilla.org/en/docs/DOM/Node","!doc":"A Node is an interface from which a number of DOM types inherit, and allows these various types to be treated (or tested) similarly."},Element:{"!type":"fn()",prototype:{"!proto":"Node.prototype",getAttribute:{"!type":"fn(name: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/element.getAttribute","!doc":'Returns the value of the named attribute on the specified element. If the named attribute does not exist, the value returned will either be null or "" (the empty string).'},setAttribute:{"!type":"fn(name: string, value: string)","!url":"https://developer.mozilla.org/en/docs/DOM/element.setAttribute","!doc":"Adds a new attribute or changes the value of an existing attribute on the specified element."},removeAttribute:{"!type":"fn(name: string)","!url":"https://developer.mozilla.org/en/docs/DOM/element.removeAttribute","!doc":"Removes an attribute from the specified element."},getAttributeNode:{"!type":"fn(name: string) -> +Attr","!url":"https://developer.mozilla.org/en/docs/DOM/element.getAttributeNode","!doc":"Returns the specified attribute of the specified element, as an Attr node."},getElementsByTagName:{"!type":"fn(tagName: string) -> +NodeList","!url":"https://developer.mozilla.org/en/docs/DOM/element.getElementsByTagName","!doc":"Returns a list of elements with the given tag name. The subtree underneath the specified element is searched, excluding the element itself. The returned list is live, meaning that it updates itself with the DOM tree automatically. Consequently, there is no need to call several times element.getElementsByTagName with the same element and arguments."},getElementsByTagNameNS:{"!type":"fn(ns: string, tagName: string) -> +NodeList","!url":"https://developer.mozilla.org/en/docs/DOM/element.getElementsByTagNameNS","!doc":"Returns a list of elements with the given tag name belonging to the given namespace."},getAttributeNS:{"!type":"fn(ns: string, name: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/element.getAttributeNS","!doc":'Returns the string value of the attribute with the specified namespace and name. If the named attribute does not exist, the value returned will either be null or "" (the empty string).'},setAttributeNS:{"!type":"fn(ns: string, name: string, value: string)","!url":"https://developer.mozilla.org/en/docs/DOM/element.setAttributeNS","!doc":"Adds a new attribute or changes the value of an attribute with the given namespace and name."},removeAttributeNS:{"!type":"fn(ns: string, name: string)","!url":"https://developer.mozilla.org/en/docs/DOM/element.removeAttributeNS","!doc":"removeAttributeNS removes the specified attribute from an element."},getAttributeNodeNS:{"!type":"fn(ns: string, name: string) -> +Attr","!url":"https://developer.mozilla.org/en/docs/DOM/element.getAttributeNodeNS","!doc":"Returns the Attr node for the attribute with the given namespace and name."},hasAttribute:{"!type":"fn(name: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/element.hasAttribute","!doc":"hasAttribute returns a boolean value indicating whether the specified element has the specified attribute or not."},hasAttributeNS:{"!type":"fn(ns: string, name: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/element.hasAttributeNS","!doc":"hasAttributeNS returns a boolean value indicating whether the current element has the specified attribute."},focus:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/element.focus","!doc":"Sets focus on the specified element, if it can be focused."},blur:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/element.blur","!doc":"The blur method removes keyboard focus from the current element."},scrollIntoView:{"!type":"fn(top: bool)","!url":"https://developer.mozilla.org/en/docs/DOM/element.scrollIntoView","!doc":"The scrollIntoView() method scrolls the element into view."},scrollByLines:{"!type":"fn(lines: number)","!url":"https://developer.mozilla.org/en/docs/DOM/window.scrollByLines","!doc":"Scrolls the document by the given number of lines."},scrollByPages:{"!type":"fn(pages: number)","!url":"https://developer.mozilla.org/en/docs/DOM/window.scrollByPages","!doc":"Scrolls the current document by the specified number of pages."},getElementsByClassName:{"!type":"fn(name: string) -> +NodeList","!url":"https://developer.mozilla.org/en/docs/DOM/document.getElementsByClassName","!doc":"Returns a set of elements which have all the given class names. When called on the document object, the complete document is searched, including the root node. You may also call getElementsByClassName on any element; it will return only elements which are descendants of the specified root element with the given class names."},querySelector:{"!type":"fn(selectors: string) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/Element.querySelector","!doc":"Returns the first element that is a descendent of the element on which it is invoked that matches the specified group of selectors."},querySelectorAll:{"!type":"fn(selectors: string) -> +NodeList","!url":"https://developer.mozilla.org/en/docs/DOM/Element.querySelectorAll","!doc":"Returns a non-live NodeList of all elements descended from the element on which it is invoked that match the specified group of CSS selectors."},getClientRects:{"!type":"fn() -> [+ClientRect]","!url":"https://developer.mozilla.org/en/docs/DOM/element.getClientRects","!doc":"Returns a collection of rectangles that indicate the bounding rectangles for each box in a client."},getBoundingClientRect:{"!type":"fn() -> +ClientRect","!url":"https://developer.mozilla.org/en/docs/DOM/element.getBoundingClientRect","!doc":"Returns a text rectangle object that encloses a group of text rectangles."},setAttributeNode:{"!type":"fn(attr: +Attr) -> +Attr","!url":"https://developer.mozilla.org/en/docs/DOM/element.setAttributeNode","!doc":"Adds a new Attr node to the specified element."},removeAttributeNode:{"!type":"fn(attr: +Attr) -> +Attr","!url":"https://developer.mozilla.org/en/docs/DOM/element.removeAttributeNode","!doc":"Removes the specified attribute from the current element."},setAttributeNodeNS:{"!type":"fn(attr: +Attr) -> +Attr","!url":"https://developer.mozilla.org/en/docs/DOM/element.setAttributeNodeNS","!doc":"Adds a new namespaced attribute node to an element."},insertAdjacentHTML:{"!type":"fn(position: string, text: string)","!url":"https://developer.mozilla.org/en/docs/DOM/element.insertAdjacentHTML","!doc":"Parses the specified text as HTML or XML and inserts the resulting nodes into the DOM tree at a specified position. It does not reparse the element it is being used on and thus it does not corrupt the existing elements inside the element. This, and avoiding the extra step of serialization make it much faster than direct innerHTML manipulation."},children:{"!type":"+HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/Element.children","!doc":"Returns a collection of child elements of the given element."},childElementCount:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/Element.childElementCount","!doc":"Returns the number of child elements of the given element."},className:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/element.className","!doc":"Gets and sets the value of the class attribute of the specified element."},style:{cssText:"string",alignmentBaseline:"string",background:"string",backgroundAttachment:"string",backgroundClip:"string",backgroundColor:"string",backgroundImage:"string",backgroundOrigin:"string",backgroundPosition:"string",backgroundPositionX:"string",backgroundPositionY:"string",backgroundRepeat:"string",backgroundRepeatX:"string",backgroundRepeatY:"string",backgroundSize:"string",baselineShift:"string",border:"string",borderBottom:"string",borderBottomColor:"string",borderBottomLeftRadius:"string",borderBottomRightRadius:"string",borderBottomStyle:"string",borderBottomWidth:"string",borderCollapse:"string",borderColor:"string",borderImage:"string",borderImageOutset:"string",borderImageRepeat:"string",borderImageSlice:"string",borderImageSource:"string",borderImageWidth:"string",borderLeft:"string",borderLeftColor:"string",borderLeftStyle:"string",borderLeftWidth:"string",borderRadius:"string",borderRight:"string",borderRightColor:"string",borderRightStyle:"string",borderRightWidth:"string",borderSpacing:"string",borderStyle:"string",borderTop:"string",borderTopColor:"string",borderTopLeftRadius:"string",borderTopRightRadius:"string",borderTopStyle:"string",borderTopWidth:"string",borderWidth:"string",bottom:"string",boxShadow:"string",boxSizing:"string",captionSide:"string",clear:"string",clip:"string",clipPath:"string",clipRule:"string",color:"string",colorInterpolation:"string",colorInterpolationFilters:"string",colorProfile:"string",colorRendering:"string",content:"string",counterIncrement:"string",counterReset:"string",cursor:"string",direction:"string",display:"string",dominantBaseline:"string",emptyCells:"string",enableBackground:"string",fill:"string",fillOpacity:"string",fillRule:"string",filter:"string","float":"string",floodColor:"string",floodOpacity:"string",font:"string",fontFamily:"string",fontSize:"string",fontStretch:"string",fontStyle:"string",fontVariant:"string",fontWeight:"string",glyphOrientationHorizontal:"string",glyphOrientationVertical:"string",height:"string",imageRendering:"string",kerning:"string",left:"string",letterSpacing:"string",lightingColor:"string",lineHeight:"string",listStyle:"string",listStyleImage:"string",listStylePosition:"string",listStyleType:"string",margin:"string",marginBottom:"string",marginLeft:"string",marginRight:"string",marginTop:"string",marker:"string",markerEnd:"string",markerMid:"string",markerStart:"string",mask:"string",maxHeight:"string",maxWidth:"string",minHeight:"string",minWidth:"string",opacity:"string",orphans:"string",outline:"string",outlineColor:"string",outlineOffset:"string",outlineStyle:"string",outlineWidth:"string",overflow:"string",overflowWrap:"string",overflowX:"string",overflowY:"string",padding:"string",paddingBottom:"string",paddingLeft:"string",paddingRight:"string",paddingTop:"string",page:"string",pageBreakAfter:"string",pageBreakBefore:"string",pageBreakInside:"string",pointerEvents:"string",position:"string",quotes:"string",resize:"string",right:"string",shapeRendering:"string",size:"string",speak:"string",src:"string",stopColor:"string",stopOpacity:"string",stroke:"string",strokeDasharray:"string",strokeDashoffset:"string",strokeLinecap:"string",strokeLinejoin:"string",strokeMiterlimit:"string",strokeOpacity:"string",strokeWidth:"string",tabSize:"string",tableLayout:"string",textAlign:"string",textAnchor:"string",textDecoration:"string",textIndent:"string",textLineThrough:"string",textLineThroughColor:"string",textLineThroughMode:"string",textLineThroughStyle:"string",textLineThroughWidth:"string",textOverflow:"string",textOverline:"string",textOverlineColor:"string",textOverlineMode:"string",textOverlineStyle:"string",textOverlineWidth:"string",textRendering:"string",textShadow:"string",textTransform:"string",textUnderline:"string",textUnderlineColor:"string",textUnderlineMode:"string",textUnderlineStyle:"string",textUnderlineWidth:"string",top:"string",unicodeBidi:"string",unicodeRange:"string",vectorEffect:"string",verticalAlign:"string",visibility:"string",whiteSpace:"string",width:"string",wordBreak:"string",wordSpacing:"string",wordWrap:"string",writingMode:"string",zIndex:"string",zoom:"string","!url":"https://developer.mozilla.org/en/docs/DOM/element.style","!doc":"Returns an object that represents the element's style attribute."},classList:{"!type":"+DOMTokenList","!url":"https://developer.mozilla.org/en/docs/DOM/element.classList","!doc":"Returns a token list of the class attribute of the element."},contentEditable:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/Element.contentEditable","!doc":"Indicates whether or not the element is editable."},firstElementChild:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Element.firstElementChild","!doc":"Returns the element's first child element or null if there are no child elements."},lastElementChild:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Element.lastElementChild","!doc":"Returns the element's last child element or null if there are no child elements."},nextElementSibling:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Element.nextElementSibling","!doc":"Returns the element immediately following the specified one in its parent's children list, or null if the specified element is the last one in the list."},previousElementSibling:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Element.previousElementSibling","!doc":"Returns the element immediately prior to the specified one in its parent's children list, or null if the specified element is the first one in the list."},tabIndex:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.tabIndex","!doc":"Gets/sets the tab order of the current element."},title:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/element.title","!doc":"Establishes the text to be displayed in a 'tool tip' popup when the mouse is over the displayed node."},width:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.offsetWidth","!doc":"Returns the layout width of an element."},height:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.offsetHeight","!doc":"Height of an element relative to the element's offsetParent."},getContext:{"!type":"fn(id: string) -> CanvasRenderingContext2D","!url":"https://developer.mozilla.org/en/docs/DOM/HTMLCanvasElement","!doc":"DOM canvas elements expose the HTMLCanvasElement interface, which provides properties and methods for manipulating the layout and presentation of canvas elements. The HTMLCanvasElement interface inherits the properties and methods of the element object interface."},supportsContext:"fn(id: string) -> bool",oncopy:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.oncopy","!doc":"The oncopy property returns the onCopy event handler code on the current element."},oncut:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.oncut","!doc":"The oncut property returns the onCut event handler code on the current element."},onpaste:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onpaste","!doc":"The onpaste property returns the onPaste event handler code on the current element."},onbeforeunload:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/HTML/Element/body","!doc":"The HTML <body> element represents the main content of an HTML document. There is only one <body> element in a document."},onfocus:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onfocus","!doc":"The onfocus property returns the onFocus event handler code on the current element."},onblur:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onblur","!doc":"The onblur property returns the onBlur event handler code, if any, that exists on the current element."},onchange:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onchange","!doc":"The onchange property sets and returns the onChange event handler code for the current element."},onclick:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onclick","!doc":"The onclick property returns the onClick event handler code on the current element."},ondblclick:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.ondblclick","!doc":"The ondblclick property returns the onDblClick event handler code on the current element."},onmousedown:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onmousedown","!doc":"The onmousedown property returns the onMouseDown event handler code on the current element."},onmouseup:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onmouseup","!doc":"The onmouseup property returns the onMouseUp event handler code on the current element."},onmousewheel:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Mozilla_event_reference/wheel","!doc":"The wheel event is fired when a wheel button of a pointing device (usually a mouse) is rotated. This event deprecates the legacy mousewheel event."},onmouseover:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onmouseover","!doc":"The onmouseover property returns the onMouseOver event handler code on the current element."},onmouseout:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onmouseout","!doc":"The onmouseout property returns the onMouseOut event handler code on the current element."},onmousemove:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onmousemove","!doc":"The onmousemove property returns the mousemove event handler code on the current element."},oncontextmenu:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.oncontextmenu","!doc":'An event handler property for right-click events on the window. Unless the default behavior is prevented, the browser context menu will activate. Note that this event will occur with any non-disabled right-click event and does not depend on an element possessing the "contextmenu" attribute.'},onkeydown:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onkeydown","!doc":"The onkeydown property returns the onKeyDown event handler code on the current element."},onkeyup:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onkeyup","!doc":"The onkeyup property returns the onKeyUp event handler code for the current element."},onkeypress:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onkeypress","!doc":"The onkeypress property sets and returns the onKeyPress event handler code for the current element."},onresize:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onresize","!doc":"onresize returns the element's onresize event handler code. It can also be used to set the code to be executed when the resize event occurs."},onscroll:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onscroll","!doc":"The onscroll property returns the onScroll event handler code on the current element."},ondragstart:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DragDrop/Drag_Operations","!doc":"The following describes the steps that occur during a drag and drop operation."},ondragover:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Mozilla_event_reference/dragover","!doc":"The dragover event is fired when an element or text selection is being dragged over a valid drop target (every few hundred milliseconds)."},ondragleave:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Mozilla_event_reference/dragleave","!doc":"The dragleave event is fired when a dragged element or text selection leaves a valid drop target."},ondragenter:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Mozilla_event_reference/dragenter","!doc":"The dragenter event is fired when a dragged element or text selection enters a valid drop target."},ondragend:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Mozilla_event_reference/dragend","!doc":"The dragend event is fired when a drag operation is being ended (by releasing a mouse button or hitting the escape key)."},ondrag:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Mozilla_event_reference/drag","!doc":"The drag event is fired when an element or text selection is being dragged (every few hundred milliseconds)."},offsetTop:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.offsetTop","!doc":"Returns the distance of the current element relative to the top of the offsetParent node."},offsetLeft:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.offsetLeft","!doc":"Returns the number of pixels that the upper left corner of the current element is offset to the left within the offsetParent node."},offsetHeight:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.offsetHeight","!doc":"Height of an element relative to the element's offsetParent."},offsetWidth:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.offsetWidth","!doc":"Returns the layout width of an element."},scrollTop:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.scrollTop","!doc":"Gets or sets the number of pixels that the content of an element is scrolled upward."},scrollLeft:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.scrollLeft","!doc":"Gets or sets the number of pixels that an element's content is scrolled to the left."},scrollHeight:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.scrollHeight","!doc":"Height of the scroll view of an element; it includes the element padding but not its margin."},scrollWidth:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.scrollWidth","!doc":"Read-only property that returns either the width in pixels of the content of an element or the width of the element itself, whichever is greater."},clientTop:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.clientTop","!doc":"The width of the top border of an element in pixels. It does not include the top margin or padding. clientTop is read-only."},clientLeft:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.clientLeft","!doc":"The width of the left border of an element in pixels. It includes the width of the vertical scrollbar if the text direction of the element is right-to-left and if there is an overflow causing a left vertical scrollbar to be rendered. clientLeft does not include the left margin or the left padding. clientLeft is read-only."},clientHeight:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.clientHeight","!doc":"Returns the inner height of an element in pixels, including padding but not the horizontal scrollbar height, border, or margin."},clientWidth:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.clientWidth","!doc":"The inner width of an element in pixels. It includes padding but not the vertical scrollbar (if present, if rendered), border or margin."},innerHTML:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/element.innerHTML","!doc":"Sets or gets the HTML syntax describing the element's descendants."},createdCallback:{"!type":"fn()","!url":"http://w3c.github.io/webcomponents/spec/custom/index.html#dfn-created-callback","!doc":"This callback is invoked after custom element instance is created and its definition is registered. The actual timing of this callback is defined further in this specification."},attachedCallback:{"!type":"fn()","!url":"http://w3c.github.io/webcomponents/spec/custom/index.html#dfn-entered-view-callback","!doc":"Unless specified otherwise, this callback must be enqueued whenever custom element is inserted into a document and this document has a browsing context."},detachedCallback:{"!type":"fn()","!url":"http://w3c.github.io/webcomponents/spec/custom/index.html#dfn-left-view-callback","!doc":"Unless specified otherwise, this callback must be enqueued whenever custom element is removed from the document and this document has a browsing context."},attributeChangedCallback:{"!type":"fn()","!url":"http://w3c.github.io/webcomponents/spec/custom/index.html#dfn-attribute-changed-callback","!doc":"Unless specified otherwise, this callback must be enqueued whenever custom element's attribute is added, changed or removed."}},"!url":"https://developer.mozilla.org/en/docs/DOM/Element","!doc":"Represents an element in an HTML or XML document."},Text:{"!type":"fn()",prototype:{"!proto":"Node.prototype",wholeText:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Text.wholeText","!doc":"Returns all text of all Text nodes logically adjacent to the node.  The text is concatenated in document order.  This allows you to specify any text node and obtain all adjacent text as a single string."},splitText:{"!type":"fn(offset: number) -> +Text","!url":"https://developer.mozilla.org/en/docs/DOM/Text.splitText","!doc":"Breaks the Text node into two nodes at the specified offset, keeping both nodes in the tree as siblings."}},"!url":"https://developer.mozilla.org/en/docs/DOM/Text","!doc":"In the DOM, the Text interface represents the textual content of an Element or Attr.  If an element has no markup within its content, it has a single child implementing Text that contains the element's text.  However, if the element contains markup, it is parsed into information items and Text nodes that form its children."},Document:{"!type":"fn()",prototype:{"!proto":"Node.prototype",activeElement:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.activeElement","!doc":"Returns the currently focused element, that is, the element that will get keystroke events if the user types any. This attribute is read only."},compatMode:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.compatMode","!doc":"Indicates whether the document is rendered in Quirks mode or Strict mode."},designMode:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.designMode","!doc":"Can be used to make any document editable, for example in a <iframe />:"},dir:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Document.dir","!doc":"This property should indicate and allow the setting of the directionality of the text of the document, whether left to right (default) or right to left."},height:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/document.height","!doc":"Returns the height of the <body> element of the current document."},width:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/document.width","!doc":"Returns the width of the <body> element of the current document in pixels."},characterSet:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.characterSet","!doc":"Returns the character encoding of the current document."},readyState:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.readyState","!doc":'Returns "loading" while the document is loading, "interactive" once it is finished parsing but still loading sub-resources, and "complete" once it has loaded.'},location:{"!type":"location","!url":"https://developer.mozilla.org/en/docs/DOM/document.location","!doc":"Returns a Location object, which contains information about the URL of the document and provides methods for changing that URL."},lastModified:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.lastModified","!doc":"Returns a string containing the date and time on which the current document was last modified."},head:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.head","!doc":"Returns the <head> element of the current document. If there are more than one <head> elements, the first one is returned."},body:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.body","!doc":"Returns the <body> or <frameset> node of the current document."},cookie:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.cookie","!doc":"Get and set the cookies associated with the current document."},URL:"string",domain:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.domain","!doc":"Gets/sets the domain portion of the origin of the current document, as used by the same origin policy."},referrer:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.referrer","!doc":"Returns the URI of the page that linked to this page."},title:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.title","!doc":"Gets or sets the title of the document."},defaultView:{"!url":"https://developer.mozilla.org/en/docs/DOM/document.defaultView","!doc":"In browsers returns the window object associated with the document or null if none available."},documentURI:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.documentURI","!doc":"Returns the document location as string. It is read-only per DOM4 specification."},xmlStandalone:"bool",xmlVersion:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.xmlVersion","!doc":'Returns the version number as specified in the XML declaration (e.g., <?xml version="1.0"?>) or "1.0" if the declaration is absent.'},xmlEncoding:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Document.xmlEncoding","!doc":"Returns the encoding as determined by the XML declaration. Should be null if unspecified or unknown."},inputEncoding:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/document.inputEncoding","!doc":"Returns a string representing the encoding under which the document was parsed (e.g. ISO-8859-1)."},documentElement:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.documentElement","!doc":"Read-only"},implementation:{hasFeature:"fn(feature: string, version: number) -> bool",createDocumentType:{"!type":"fn(qualifiedName: string, publicId: string, systemId: string) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/DOMImplementation.createDocumentType","!doc":"Returns a DocumentType object which can either be used with DOMImplementation.createDocument upon document creation or they can be put into the document via Node.insertBefore() or Node.replaceChild(): http://www.w3.org/TR/DOM-Level-3-Cor...l#ID-B63ED1A31 (less ideal due to features not likely being as accessible: http://www.w3.org/TR/DOM-Level-3-Cor...createDocument ). In any case, entity declarations and notations will not be available: http://www.w3.org/TR/DOM-Level-3-Cor...-createDocType   "},createHTMLDocument:{"!type":"fn(title: string) -> +Document","!url":"https://developer.mozilla.org/en/docs/DOM/DOMImplementation.createHTMLDocument","!doc":"This method (available from document.implementation) creates a new HTML document."},createDocument:{"!type":"fn(namespaceURI: string, qualifiedName: string, type: +Node) -> +Document","!url":"https://developer.mozilla.org/en-US/docs/DOM/DOMImplementation.createHTMLDocument","!doc":"This method creates a new HTML document."},"!url":"https://developer.mozilla.org/en/docs/DOM/document.implementation","!doc":"Returns a DOMImplementation object associated with the current document."},doctype:{"!type":"+Node","!url":"https://developer.mozilla.org/en/docs/DOM/document.doctype","!doc":"Returns the Document Type Declaration (DTD) associated with current document. The returned object implements the DocumentType interface. Use DOMImplementation.createDocumentType() to create a DocumentType."},open:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/document.open","!doc":"The document.open() method opens a document for writing."},close:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/document.close","!doc":"The document.close() method finishes writing to a document, opened with document.open()."},write:{"!type":"fn(html: string)","!url":"https://developer.mozilla.org/en/docs/DOM/document.write","!doc":"Writes a string of text to a document stream opened by document.open()."},writeln:{"!type":"fn(html: string)","!url":"https://developer.mozilla.org/en/docs/DOM/document.writeln","!doc":"Writes a string of text followed by a newline character to a document."},clear:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/document.clear","!doc":"In recent versions of Mozilla-based applications as well as in Internet Explorer and Netscape 4 this method does nothing."},hasFocus:{"!type":"fn() -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/document.hasFocus","!doc":"Returns a Boolean value indicating whether the document or any element inside the document has focus. This method can be used to determine whether the active element in a document has focus."},createElement:{"!type":"fn(tagName: string) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.createElement","!doc":"Creates the specified element."},createElementNS:{"!type":"fn(ns: string, tagName: string) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.createElementNS","!doc":"Creates an element with the specified namespace URI and qualified name."},createDocumentFragment:{"!type":"fn() -> +DocumentFragment","!url":"https://developer.mozilla.org/en/docs/DOM/document.createDocumentFragment","!doc":"Creates a new empty DocumentFragment."},createTextNode:{"!type":"fn(content: string) -> +Text","!url":"https://developer.mozilla.org/en/docs/DOM/document.createTextNode","!doc":"Creates a new Text node."},createComment:{"!type":"fn(content: string) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/document.createComment","!doc":"Creates a new comment node, and returns it."},createCDATASection:{"!type":"fn(content: string) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/document.createCDATASection","!doc":"Creates a new CDATA section node, and returns it. "},createProcessingInstruction:{"!type":"fn(content: string) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/document.createProcessingInstruction","!doc":"Creates a new processing instruction node, and returns it."},createAttribute:{"!type":"fn(name: string) -> +Attr","!url":"https://developer.mozilla.org/en/docs/DOM/document.createAttribute","!doc":"Creates a new attribute node, and returns it."},createAttributeNS:{"!type":"fn(ns: string, name: string) -> +Attr","!url":"https://developer.mozilla.org/en/docs/DOM/Attr","!doc":"This type represents a DOM element's attribute as an object. In most DOM methods, you will probably directly retrieve the attribute as a string (e.g., Element.getAttribute(), but certain functions (e.g., Element.getAttributeNode()) or means of iterating give Attr types."},importNode:{"!type":"fn(node: +Node, deep: bool) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.importNode","!doc":"Creates a copy of a node from an external document that can be inserted into the current document."},getElementById:{"!type":"fn(id: string) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.getElementById","!doc":"Returns a reference to the element by its ID."},getElementsByTagName:{"!type":"fn(tagName: string) -> +NodeList","!url":"https://developer.mozilla.org/en/docs/DOM/document.getElementsByTagName","!doc":"Returns a NodeList of elements with the given tag name. The complete document is searched, including the root node. The returned NodeList is live, meaning that it updates itself automatically to stay in sync with the DOM tree without having to call document.getElementsByTagName again."},getElementsByTagNameNS:{"!type":"fn(ns: string, tagName: string) -> +NodeList","!url":"https://developer.mozilla.org/en/docs/DOM/document.getElementsByTagNameNS","!doc":"Returns a list of elements with the given tag name belonging to the given namespace. The complete document is searched, including the root node."},createEvent:{"!type":"fn(type: string) -> +Event","!url":"https://developer.mozilla.org/en/docs/DOM/document.createEvent","!doc":"Creates an event of the type specified. The returned object should be first initialized and can then be passed to element.dispatchEvent."},createRange:{"!type":"fn() -> +Range","!url":"https://developer.mozilla.org/en/docs/DOM/document.createRange","!doc":"Returns a new Range object."},evaluate:{"!type":"fn(expr: ?) -> +XPathResult","!url":"https://developer.mozilla.org/en/docs/DOM/document.evaluate","!doc":"Returns an XPathResult based on an XPath expression and other given parameters."},execCommand:{"!type":"fn(cmd: string)","!url":"https://developer.mozilla.org/en-US/docs/Rich-Text_Editing_in_Mozilla#Executing_Commands","!doc":"Run command to manipulate the contents of an editable region."},queryCommandEnabled:{"!type":"fn(cmd: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/document","!doc":"Returns true if the Midas command can be executed on the current range."},queryCommandIndeterm:{"!type":"fn(cmd: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/document","!doc":"Returns true if the Midas command is in a indeterminate state on the current range."},queryCommandState:{"!type":"fn(cmd: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/document","!doc":"Returns true if the Midas command has been executed on the current range."},queryCommandSupported:{"!type":"fn(cmd: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/document.queryCommandSupported","!doc":"Reports whether or not the specified editor query command is supported by the browser."},queryCommandValue:{"!type":"fn(cmd: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/document","!doc":"Returns the current value of the current range for Midas command."},getElementsByName:{"!type":"fn(name: string) -> +HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/document.getElementsByName","!doc":"Returns a list of elements with a given name in the HTML document."},elementFromPoint:{"!type":"fn(x: number, y: number) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.elementFromPoint","!doc":"Returns the element from the document whose elementFromPoint method is being called which is the topmost element which lies under the given point.  To get an element, specify the point via coordinates, in CSS pixels, relative to the upper-left-most point in the window or frame containing the document."},getSelection:{"!type":"fn() -> +Selection","!url":"https://developer.mozilla.org/en/docs/DOM/document.getSelection","!doc":"The DOM getSelection() method is available on the Window and Document interfaces."},adoptNode:{"!type":"fn(node: +Node) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/document.adoptNode","!doc":"Adopts a node from an external document. The node and its subtree is removed from the document it's in (if any), and its ownerDocument is changed to the current document. The node can then be inserted into the current document."},createTreeWalker:{"!type":"fn(root: +Node, mask: number) -> ?","!url":"https://developer.mozilla.org/en/docs/DOM/document.createTreeWalker","!doc":"Returns a new TreeWalker object."},createExpression:{"!type":"fn(text: string) -> ?","!url":"https://developer.mozilla.org/en/docs/DOM/document.createExpression","!doc":"This method compiles an XPathExpression which can then be used for (repeated) evaluations."},createNSResolver:{"!type":"fn(node: +Node)","!url":"https://developer.mozilla.org/en/docs/DOM/document.createNSResolver","!doc":"Creates an XPathNSResolver which resolves namespaces with respect to the definitions in scope for a specified node."},scripts:{"!type":"+HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/Document.scripts","!doc":"Returns a list of the <script> elements in the document. The returned object is an HTMLCollection."},plugins:{"!type":"+HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/document.plugins","!doc":"Returns an HTMLCollection object containing one or more HTMLEmbedElements or null which represent the <embed> elements in the current document."},embeds:{"!type":"+HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/document.embeds","!doc":"Returns a list of the embedded OBJECTS within the current document."},anchors:{"!type":"+HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/document.anchors","!doc":"Returns a list of all of the anchors in the document."},links:{"!type":"+HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/document.links","!doc":"The links property returns a collection of all AREA elements and anchor elements in a document with a value for the href attribute. "},forms:{"!type":"+HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/document.forms","!doc":"Returns a collection (an HTMLCollection) of the form elements within the current document."},styleSheets:{"!type":"+HTMLCollection","!url":"https://developer.mozilla.org/en/docs/DOM/document.styleSheets","!doc":"Returns a list of stylesheet objects for stylesheets explicitly linked into or embedded in a document."},currentScript:{"!type":"+Node","!url":"https://developer.mozilla.org/en-US/docs/Web/API/document.currentScript","!doc":"Returns the <script> element whose script is currently being processed."},registerElement:{"!type":"fn(type: string, options?: ?)","!url":"http://w3c.github.io/webcomponents/spec/custom/#extensions-to-document-interface-to-register","!doc":"The registerElement method of the Document interface provides a way to register a custom element and returns its custom element constructor."},getElementsByClassName:"Element.prototype.getElementsByClassName",querySelector:"Element.prototype.querySelector",querySelectorAll:"Element.prototype.querySelectorAll"},"!url":"https://developer.mozilla.org/en/docs/DOM/document","!doc":"Each web page loaded in the browser has its own document object. This object serves as an entry point to the web page's content (the DOM tree, including elements such as <body> and <table>) and provides functionality global to the document (such as obtaining the page's URL and creating new elements in the document)."},document:{"!type":"+Document","!url":"https://developer.mozilla.org/en/docs/DOM/document","!doc":"Each web page loaded in the browser has its own document object. This object serves as an entry point to the web page's content (the DOM tree, including elements such as <body> and <table>) and provides functionality global to the document (such as obtaining the page's URL and creating new elements in the document)."},XMLDocument:{"!type":"fn()",prototype:"Document.prototype","!url":"https://developer.mozilla.org/en/docs/Parsing_and_serializing_XML","!doc":"The Web platform provides the following objects for parsing and serializing XML:"},HTMLElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement"},HTMLAnchorElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement"},HTMLAreaElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLAreaElement"},HTMLAudioElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLAudioElement"},HTMLBaseElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLBaseElement"},HTMLBodyElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLBodyElement"},HTMLBRElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLBRElement"},HTMLButtonElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLButtonElement"},HTMLCanvasElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLCanvasElement"},HTMLDataElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLDataElement"},HTMLDataListElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLDataListElement"},HTMLDivElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLDivElement"},HTMLDListElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLDListElement"},HTMLDocument:{"!type":"Document","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLDocument"},HTMLEmbedElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLEmbedElement"},HTMLFieldSetElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLFieldSetElement"},HTMLFormControlsCollection:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLFormControlsCollection"},HTMLFormElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLFormElement"},HTMLHeadElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLHeadElement"},HTMLHeadingElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLHeadingElement"},HTMLHRElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLHRElement"},HTMLHtmlElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLHtmlElement"},HTMLIFrameElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLIFrameElement"},HTMLImageElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageElement"},HTMLInputElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement"},HTMLKeygenElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLKeygenElement"},HTMLLabelElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLLabelElement"},HTMLLegendElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLLegendElement"},HTMLLIElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLLIElement"},HTMLLinkElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLLinkElement"},HTMLMapElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLMapElement"},HTMLMediaElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLMediaElement"},HTMLMetaElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLMetaElement"},HTMLMeterElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLMeterElement"},HTMLModElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLModElement"},HTMLObjectElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLObjectElement"},HTMLOListElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLOListElement"},HTMLOptGroupElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLOptGroupElement"},HTMLOptionElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLOptionElement"},HTMLOptionsCollection:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLOptionsCollection"},HTMLOutputElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLOutputElement"},HTMLParagraphElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLParagraphElement"},HTMLParamElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLParamElement"},HTMLPreElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLPreElement"},HTMLProgressElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLProgressElement"},HTMLQuoteElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLQuoteElement"},HTMLScriptElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLScriptElement"},HTMLSelectElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLSelectElement"},HTMLSourceElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLSourceElement"},HTMLSpanElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLSpanElement"},HTMLStyleElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLStyleElement"},HTMLTableCaptionElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableCaptionElement"},HTMLTableCellElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableCellElement"},HTMLTableColElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableColElement"},HTMLTableDataCellElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableDataCellElement"},HTMLTableElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableElement"},HTMLTableHeaderCellElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableHeaderCellElement"},HTMLTableRowElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableRowElement"},HTMLTableSectionElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableSectionElement"},HTMLTextAreaElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTextAreaElement"},HTMLTimeElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTimeElement"},HTMLTitleElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTitleElement"},HTMLTrackElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLTrackElement"},HTMLUListElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLUListElement"},HTMLUnknownElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLUnknownElement"},HTMLVideoElement:{"!type":"Element","!url":"https://developer.mozilla.org/en-US/docs/Web/API/HTMLVideoElement"},Attr:{"!type":"fn()",prototype:{isId:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/Attr","!doc":"This type represents a DOM element's attribute as an object. In most DOM methods, you will probably directly retrieve the attribute as a string (e.g., Element.getAttribute(), but certain functions (e.g., Element.getAttributeNode()) or means of iterating give Attr types."},name:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Attr","!doc":"This type represents a DOM element's attribute as an object. In most DOM methods, you will probably directly retrieve the attribute as a string (e.g., Element.getAttribute(), but certain functions (e.g., Element.getAttributeNode()) or means of iterating give Attr types."},value:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Attr","!doc":"This type represents a DOM element's attribute as an object. In most DOM methods, you will probably directly retrieve the attribute as a string (e.g., Element.getAttribute(), but certain functions (e.g., Element.getAttributeNode()) or means of iterating give Attr types."}},"!url":"https://developer.mozilla.org/en/docs/DOM/Attr","!doc":"This type represents a DOM element's attribute as an object. In most DOM methods, you will probably directly retrieve the attribute as a string (e.g., Element.getAttribute(), but certain functions (e.g., Element.getAttributeNode()) or means of iterating give Attr types."},NodeList:{"!type":"fn()",prototype:{length:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.length","!doc":"Returns the number of items in a NodeList."},item:{"!type":"fn(i: number) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/NodeList.item","!doc":"Returns a node from a NodeList by index."},"<i>":"+Element"},"!url":"https://developer.mozilla.org/en/docs/DOM/NodeList","!doc":"NodeList objects are collections of nodes returned by getElementsByTagName, getElementsByTagNameNS, Node.childNodes, querySelectorAll, getElementsByClassName, etc."},HTMLCollection:{"!type":"fn()",prototype:{length:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/HTMLCollection","!doc":"The number of items in the collection."},item:{"!type":"fn(i: number) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/HTMLCollection","!doc":"Returns the specific node at the given zero-based index into the list. Returns null if the index is out of range."},namedItem:{"!type":"fn(name: string) -> +Element","!url":"https://developer.mozilla.org/en/docs/DOM/HTMLCollection","!doc":"Returns the specific node whose ID or, as a fallback, name matches the string specified by name. Matching by name is only done as a last resort, only in HTML, and only if the referenced element supports the name attribute. Returns null if no node exists by the given name."},"<i>":"+Element"},"!url":"https://developer.mozilla.org/en/docs/DOM/HTMLCollection","!doc":"HTMLCollection is an interface representing a generic collection of elements (in document order) and offers methods and properties for traversing the list."},NamedNodeMap:{"!type":"fn()",prototype:{length:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"The number of items in the map."},getNamedItem:{"!type":"fn(name: string) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"Gets a node by name."},setNamedItem:{"!type":"fn(node: +Node) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"Adds (or replaces) a node by its nodeName."},removeNamedItem:{"!type":"fn(name: string) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"Removes a node (or if an attribute, may reveal a default if present)."},item:{"!type":"fn(i: number) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"Returns the item at the given index (or null if the index is higher or equal to the number of nodes)."},getNamedItemNS:{"!type":"fn(ns: string, name: string) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"Gets a node by namespace and localName."},setNamedItemNS:{"!type":"fn(node: +Node) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"Adds (or replaces) a node by its localName and namespaceURI."},removeNamedItemNS:{"!type":"fn(ns: string, name: string) -> +Node","!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"Removes a node (or if an attribute, may reveal a default if present)."},"<i>":"+Node"},"!url":"https://developer.mozilla.org/en/docs/DOM/NamedNodeMap","!doc":"A collection of nodes returned by Element.attributes (also potentially for DocumentType.entities, DocumentType.notations). NamedNodeMaps are not in any particular order (unlike NodeList), although they may be accessed by an index as in an array (they may also be accessed with the item() method). A NamedNodeMap object are live and will thus be auto-updated if changes are made to their contents internally or elsewhere."},DocumentFragment:{"!type":"fn()",prototype:{"!proto":"Node.prototype"},"!url":"https://developer.mozilla.org/en/docs/DOM/document.createDocumentFragment","!doc":"Creates a new empty DocumentFragment."},DOMTokenList:{"!type":"fn()",prototype:{length:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/DOMTokenList","!doc":"The amount of items in the list."},item:{"!type":"fn(i: number) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/DOMTokenList","!doc":"Returns an item in the list by its index."},contains:{"!type":"fn(token: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/DOMTokenList","!doc":"Return true if the underlying string contains token, otherwise false."},add:{"!type":"fn(token: string)","!url":"https://developer.mozilla.org/en/docs/DOM/DOMTokenList","!doc":"Adds token to the underlying string."},remove:{"!type":"fn(token: string)","!url":"https://developer.mozilla.org/en/docs/DOM/DOMTokenList","!doc":"Remove token from the underlying string."},toggle:{"!type":"fn(token: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/DOMTokenList","!doc":"Removes token from string and returns false. If token doesn't exist it's added and the function returns true."},"<i>":"string"},"!url":"https://developer.mozilla.org/en/docs/DOM/DOMTokenList","!doc":"This type represents a set of space-separated tokens. Commonly returned by HTMLElement.classList, HTMLLinkElement.relList, HTMLAnchorElement.relList or HTMLAreaElement.relList. It is indexed beginning with 0 as with JavaScript arrays. DOMTokenList is always case-sensitive."},XPathResult:{"!type":"fn()",prototype:{boolValue:"bool",invalidIteratorState:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/Introduction_to_using_XPath_in_JavaScript","!doc":"This document describes the interface for using XPath in JavaScript internally, in extensions, and from websites. Mozilla implements a fair amount of the DOM 3 XPath. Which means that XPath expressions can be run against both HTML and XML documents."},numberValue:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/XPathResult","!doc":"Refer to nsIDOMXPathResult for more detail."},resultType:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/document.evaluate","!doc":"Returns an XPathResult based on an XPath expression and other given parameters."},singleNodeValue:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/Introduction_to_using_XPath_in_JavaScript","!doc":"This document describes the interface for using XPath in JavaScript internally, in extensions, and from websites. Mozilla implements a fair amount of the DOM 3 XPath. Which means that XPath expressions can be run against both HTML and XML documents."},snapshotLength:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/XPathResult","!doc":"Refer to nsIDOMXPathResult for more detail."},stringValue:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/Introduction_to_using_XPath_in_JavaScript","!doc":"This document describes the interface for using XPath in JavaScript internally, in extensions, and from websites. Mozilla implements a fair amount of the DOM 3 XPath. Which means that XPath expressions can be run against both HTML and XML documents."},iterateNext:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/Introduction_to_using_XPath_in_JavaScript","!doc":"This document describes the interface for using XPath in JavaScript internally, in extensions, and from websites. Mozilla implements a fair amount of the DOM 3 XPath. Which means that XPath expressions can be run against both HTML and XML documents."},snapshotItem:{"!type":"fn()","!url":"https://developer.mozilla.org/en-US/docs/XPathResult#snapshotItem()"},ANY_TYPE:"number",NUMBER_TYPE:"number",STRING_TYPE:"number",BOOL_TYPE:"number",UNORDERED_NODE_ITERATOR_TYPE:"number",ORDERED_NODE_ITERATOR_TYPE:"number",UNORDERED_NODE_SNAPSHOT_TYPE:"number",ORDERED_NODE_SNAPSHOT_TYPE:"number",ANY_UNORDERED_NODE_TYPE:"number",FIRST_ORDERED_NODE_TYPE:"number"},"!url":"https://developer.mozilla.org/en/docs/XPathResult","!doc":"Refer to nsIDOMXPathResult for more detail."},ClientRect:{"!type":"fn()",prototype:{top:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.getClientRects","!doc":"Top of the box, in pixels, relative to the viewport."},left:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.getClientRects","!doc":"Left of the box, in pixels, relative to the viewport."},bottom:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.getClientRects","!doc":"Bottom of the box, in pixels, relative to the viewport."},right:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/element.getClientRects","!doc":"Right of the box, in pixels, relative to the viewport."}},"!url":"https://developer.mozilla.org/en/docs/DOM/element.getClientRects","!doc":"Returns a collection of rectangles that indicate the bounding rectangles for each box in a client."},Event:{"!type":"fn()",prototype:{stopPropagation:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/event.stopPropagation","!doc":"Prevents further propagation of the current event."},preventDefault:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/event.preventDefault","!doc":"Cancels the event if it is cancelable, without stopping further propagation of the event."},initEvent:{"!type":"fn(type: string, bubbles: bool, cancelable: bool)","!url":"https://developer.mozilla.org/en/docs/DOM/event.initEvent","!doc":"The initEvent method is used to initialize the value of an event created using document.createEvent."},stopImmediatePropagation:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/event.stopImmediatePropagation","!doc":"Prevents other listeners of the same event to be called."},type:{"!type":"string","!url":"https://developer.mozilla.org/en-US/docs/Web/API/event.type","!doc":"Returns a string containing the type of event."},NONE:"number",CAPTURING_PHASE:"number",AT_TARGET:"number",BUBBLING_PHASE:"number",MOUSEDOWN:"number",MOUSEUP:"number",MOUSEOVER:"number",MOUSEOUT:"number",MOUSEMOVE:"number",MOUSEDRAG:"number",CLICK:"number",DBLCLICK:"number",KEYDOWN:"number",KEYUP:"number",KEYPRESS:"number",DRAGDROP:"number",FOCUS:"number",BLUR:"number",SELECT:"number",CHANGE:"number",target:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/EventTarget","!doc":"An EventTarget is a DOM interface implemented by objects that can receive DOM events and have listeners for them. The most common EventTargets are DOM elements, although other objects can be EventTargets too, for example document, window, XMLHttpRequest, and others."},relatedTarget:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/event.relatedTarget","!doc":"Identifies a secondary target for the event."},pageX:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.pageX","!doc":"Returns the horizontal coordinate of the event relative to whole document."},pageY:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.pageY","!doc":"Returns the vertical coordinate of the event relative to the whole document."},clientX:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.clientX","!doc":"Returns the horizontal coordinate within the application's client area at which the event occurred (as opposed to the coordinates within the page). For example, clicking in the top-left corner of the client area will always result in a mouse event with a clientX value of 0, regardless of whether the page is scrolled horizontally."},clientY:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.clientY","!doc":"Returns the vertical coordinate within the application's client area at which the event occurred (as opposed to the coordinates within the page). For example, clicking in the top-left corner of the client area will always result in a mouse event with a clientY value of 0, regardless of whether the page is scrolled vertically."},keyCode:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.keyCode","!doc":"Returns the Unicode value of a non-character key in a keypress event or any key in any other type of keyboard event."},charCode:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.charCode","!doc":"Returns the Unicode value of a character key pressed during a keypress event."},which:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.which","!doc":"Returns the numeric keyCode of the key pressed, or the character code (charCode) for an alphanumeric key pressed."},button:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.button","!doc":"Indicates which mouse button caused the event."},shiftKey:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/event.shiftKey","!doc":"Indicates whether the SHIFT key was pressed when the event fired."},ctrlKey:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/event.ctrlKey","!doc":"Indicates whether the CTRL key was pressed when the event fired."},altKey:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/event.altKey","!doc":"Indicates whether the ALT key was pressed when the event fired."},metaKey:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/event.metaKey","!doc":"Indicates whether the META key was pressed when the event fired."},returnValue:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/window.onbeforeunload","!doc":"An event that fires when a window is about to unload its resources. The document is still visible and the event is still cancelable."},cancelBubble:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/event.cancelBubble","!doc":"bool is the boolean value of true or false."},dataTransfer:{dropEffect:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DragDrop/DataTransfer","!doc":"The actual effect that will be used, and should always be one of the possible values of effectAllowed."},effectAllowed:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DragDrop/Drag_Operations","!doc":"Specifies the effects that are allowed for this drag."},files:{"!type":"+FileList","!url":"https://developer.mozilla.org/en/docs/DragDrop/DataTransfer","!doc":"Contains a list of all the local files available on the data transfer."},types:{"!type":"[string]","!url":"https://developer.mozilla.org/en-US/docs/DragDrop/DataTransfer","!doc":"Holds a list of the format types of the data that is stored for the first item, in the same order the data was added. An empty list will be returned if no data was added."},addElement:{"!type":"fn(element: +Element)","!url":"https://developer.mozilla.org/en/docs/DragDrop/DataTransfer","!doc":"Set the drag source."},clearData:{"!type":"fn(type?: string)","!url":"https://developer.mozilla.org/en/docs/DragDrop/Drag_Operations","!doc":"Remove the data associated with a given type."},getData:{"!type":"fn(type: string) -> string","!url":"https://developer.mozilla.org/en/docs/DragDrop/Drag_Operations","!doc":"Retrieves the data for a given type, or an empty string if data for that type does not exist or the data transfer contains no data."},setData:{"!type":"fn(type: string, data: string)","!url":"https://developer.mozilla.org/en/docs/DragDrop/Drag_Operations","!doc":"Set the data for a given type."},setDragImage:{"!type":"fn(image: +Element)","!url":"https://developer.mozilla.org/en/docs/DragDrop/Drag_Operations","!doc":"Set the image to be used for dragging if a custom one is desired."},"!url":"https://developer.mozilla.org/en/docs/DragDrop/DataTransfer","!doc":"This object is available from the dataTransfer property of all drag events. It cannot be created separately."}},"!url":"https://developer.mozilla.org/en-US/docs/DOM/event","!doc":"The DOM Event interface is accessible from within the handler function, via the event object passed as the first argument."},TouchEvent:{"!type":"fn()",prototype:"Event.prototype","!url":"https://developer.mozilla.org/en/docs/DOM/Touch_events","!doc":"In order to provide quality support for touch-based user interfaces, touch events offer the ability to interpret finger activity on touch screens or trackpads."},WheelEvent:{"!type":"fn()",prototype:"Event.prototype","!url":"https://developer.mozilla.org/en/docs/DOM/WheelEvent","!doc":"The DOM WheelEvent represents events that occur due to the user moving a mouse wheel or similar input device."},MouseEvent:{"!type":"fn()",prototype:"Event.prototype","!url":"https://developer.mozilla.org/en/docs/DOM/MouseEvent","!doc":"The DOM MouseEvent represents events that occur due to the user interacting with a pointing device (such as a mouse). It's represented by the nsINSDOMMouseEvent interface, which extends the nsIDOMMouseEvent interface."},KeyboardEvent:{"!type":"fn()",prototype:"Event.prototype","!url":"https://developer.mozilla.org/en/docs/DOM/KeyboardEvent","!doc":"KeyboardEvent objects describe a user interaction with the keyboard. Each event describes a key; the event type (keydown, keypress, or keyup) identifies what kind of activity was performed."},HashChangeEvent:{"!type":"fn()",prototype:"Event.prototype","!url":"https://developer.mozilla.org/en/docs/DOM/window.onhashchange","!doc":"The hashchange event fires when a window's hash changes."},ErrorEvent:{"!type":"fn()",prototype:"Event.prototype","!url":"https://developer.mozilla.org/en/docs/DOM/DOM_event_reference/error","!doc":"The error event is fired whenever a resource fails to load."},CustomEvent:{"!type":"fn()",prototype:"Event.prototype","!url":"https://developer.mozilla.org/en/docs/DOM/Event/CustomEvent","!doc":"The DOM CustomEvent are events initialized by an application for any purpose."},BeforeLoadEvent:{"!type":"fn()",prototype:"Event.prototype","!url":"https://developer.mozilla.org/en/docs/DOM/window","!doc":"This section provides a brief reference for all of the methods, properties, and events available through the DOM window object. The window object implements the Window interface, which in turn inherits from the AbstractView interface. Some additional global functions, namespaces objects, and constructors, not typically associated with the window, but available on it, are listed in the JavaScript Reference."},WebSocket:{"!type":"fn(url: string)",prototype:{close:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/WebSockets/WebSockets_reference/CloseEvent","!doc":"A CloseEvent is sent to clients using WebSockets when the connection is closed. This is delivered to the listener indicated by the WebSocket object's onclose attribute."},send:{"!type":"fn(data: string)","!url":"https://developer.mozilla.org/en/docs/WebSockets/WebSockets_reference/WebSocket","!doc":"The WebSocket object provides the API for creating and managing a WebSocket connection to a server, as well as for sending and receiving data on the connection."},binaryType:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/WebSockets/WebSockets_reference/WebSocket","!doc":"The WebSocket object provides the API for creating and managing a WebSocket connection to a server, as well as for sending and receiving data on the connection."},bufferedAmount:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/WebSockets/Writing_WebSocket_client_applications","!doc":"WebSockets is a technology that makes it possible to open an interactive communication session between the user's browser and a server. Using a WebSocket connection, Web applications can perform real-time communication instead of having to poll for changes back and forth."},extensions:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/WebSockets/WebSockets_reference/WebSocket","!doc":"The WebSocket object provides the API for creating and managing a WebSocket connection to a server, as well as for sending and receiving data on the connection."},onclose:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/WebSockets/WebSockets_reference/CloseEvent","!doc":"A CloseEvent is sent to clients using WebSockets when the connection is closed. This is delivered to the listener indicated by the WebSocket object's onclose attribute."},onerror:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/WebSockets/Writing_WebSocket_client_applications","!doc":"WebSockets is a technology that makes it possible to open an interactive communication session between the user's browser and a server. Using a WebSocket connection, Web applications can perform real-time communication instead of having to poll for changes back and forth."},onmessage:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/WebSockets/WebSockets_reference/WebSocket","!doc":"The WebSocket object provides the API for creating and managing a WebSocket connection to a server, as well as for sending and receiving data on the connection."},onopen:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/WebSockets/WebSockets_reference/WebSocket","!doc":"The WebSocket object provides the API for creating and managing a WebSocket connection to a server, as well as for sending and receiving data on the connection."},protocol:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/WebSockets","!doc":"WebSockets is an advanced technology that makes it possible to open an interactive communication session between the user's browser and a server. With this API, you can send messages to a server and receive event-driven responses without having to poll the server for a reply."},url:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/WebSockets/Writing_WebSocket_client_applications","!doc":"WebSockets is a technology that makes it possible to open an interactive communication session between the user's browser and a server. Using a WebSocket connection, Web applications can perform real-time communication instead of having to poll for changes back and forth."},CONNECTING:"number",OPEN:"number",CLOSING:"number",CLOSED:"number"},"!url":"https://developer.mozilla.org/en/docs/WebSockets","!doc":"WebSockets is an advanced technology that makes it possible to open an interactive communication session between the user's browser and a server. With this API, you can send messages to a server and receive event-driven responses without having to poll the server for a reply."},Worker:{"!type":"fn(scriptURL: string)",prototype:{postMessage:{"!type":"fn(message: ?)","!url":"https://developer.mozilla.org/en/docs/DOM/Worker","!doc":"Sends a message to the worker's inner scope. This accepts a single parameter, which is the data to send to the worker. The data may be any value or JavaScript object handled by the structured clone algorithm, which includes cyclical references."},terminate:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Worker","!doc":"Immediately terminates the worker. This does not offer the worker an opportunity to finish its operations; it is simply stopped at once."},onmessage:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Worker","!doc":"An event listener that is called whenever a MessageEvent with type message bubbles through the worker. The message is stored in the event's data member."},onerror:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Worker","!doc":"An event listener that is called whenever an ErrorEvent with type error bubbles through the worker."}},"!url":"https://developer.mozilla.org/en/docs/DOM/Worker","!doc":"Workers are background tasks that can be easily created and can send messages back to their creators. Creating a worker is as simple as calling the Worker() constructor, specifying a script to be run in the worker thread."},localStorage:{setItem:{"!type":"fn(name: string, value: string)","!url":"https://developer.mozilla.org/en/docs/DOM/Storage","!doc":"Store an item in storage."},getItem:{"!type":"fn(name: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/Storage","!doc":"Retrieve an item from storage."},"!url":"https://developer.mozilla.org/en/docs/DOM/Storage","!doc":"The DOM Storage mechanism is a means through which string key/value pairs can be securely stored and later retrieved for use."},sessionStorage:{setItem:{"!type":"fn(name: string, value: string)","!url":"https://developer.mozilla.org/en/docs/DOM/Storage","!doc":"Store an item in storage."},getItem:{"!type":"fn(name: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/Storage","!doc":"Retrieve an item from storage."},"!url":"https://developer.mozilla.org/en/docs/DOM/Storage","!doc":"This is a global object (sessionStorage) that maintains a storage area that's available for the duration of the page session. A page session lasts for as long as the browser is open and survives over page reloads and restores. Opening a page in a new tab or window will cause a new session to be initiated."},FileList:{"!type":"fn()",prototype:{length:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/FileList","!doc":"A read-only value indicating the number of files in the list."},item:{"!type":"fn(i: number) -> +File","!url":"https://developer.mozilla.org/en/docs/DOM/FileList","!doc":"Returns a File object representing the file at the specified index in the file list."},"<i>":"+File"},"!url":"https://developer.mozilla.org/en/docs/DOM/FileList","!doc":'An object of this type is returned by the files property of the HTML input element; this lets you access the list of files selected with the <input type="file"> element. It\'s also used for a list of files dropped into web content when using the drag and drop API.'},File:{"!type":"fn()",prototype:{"!proto":"Blob.prototype",fileName:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/File.fileName","!doc":"Returns the name of the file. For security reasons the path is excluded from this property."},fileSize:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/File.fileSize","!doc":"Returns the size of a file in bytes."},lastModifiedDate:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/File.lastModifiedDate","!doc":"Returns the last modified date of the file. Files without a known last modified date use the current date instead."},name:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/File.name","!doc":"Returns the name of the file. For security reasons, the path is excluded from this property."}},"!url":"https://developer.mozilla.org/en/docs/DOM/File","!doc":"The File object provides information about -- and access to the contents of -- files. These are generally retrieved from a FileList object returned as a result of a user selecting files using the input element, or from a drag and drop operation's DataTransfer object."},Blob:{"!type":"fn(parts: [?], properties?: ?)",prototype:{size:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/Blob","!doc":"The size, in bytes, of the data contained in the Blob object. Read only."},type:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/Blob","!doc":"An ASCII-encoded string, in all lower case, indicating the MIME type of the data contained in the Blob. If the type is unknown, this string is empty. Read only."},slice:{"!type":"fn(start: number, end?: number, type?: string) -> +Blob","!url":"https://developer.mozilla.org/en/docs/DOM/Blob","!doc":"Returns a new Blob object containing the data in the specified range of bytes of the source Blob."}},"!url":"https://developer.mozilla.org/en/docs/DOM/Blob","!doc":"A Blob object represents a file-like object of immutable, raw data. Blobs represent data that isn't necessarily in a JavaScript-native format. The File interface is based on Blob, inheriting blob functionality and expanding it to support files on the user's system."},FileReader:{"!type":"fn()",prototype:{abort:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Aborts the read operation. Upon return, the readyState will be DONE."},readAsArrayBuffer:{"!type":"fn(blob: +Blob)","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Starts reading the contents of the specified Blob, producing an ArrayBuffer."},readAsBinaryString:{"!type":"fn(blob: +Blob)","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Starts reading the contents of the specified Blob, producing raw binary data."},readAsDataURL:{"!type":"fn(blob: +Blob)","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Starts reading the contents of the specified Blob, producing a data: url."},readAsText:{"!type":"fn(blob: +Blob, encoding?: string)","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Starts reading the contents of the specified Blob, producing a string."},EMPTY:"number",LOADING:"number",DONE:"number",error:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"The error that occurred while reading the file. Read only."},readyState:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Indicates the state of the FileReader. This will be one of the State constants. Read only."},result:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"The file's contents. This property is only valid after the read operation is complete, and the format of the data depends on which of the methods was used to initiate the read operation. Read only."},onabort:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Called when the read operation is aborted."},onerror:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Called when an error occurs."},onload:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Called when the read operation is successfully completed."},onloadend:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Called when the read is completed, whether successful or not. This is called after either onload or onerror."},onloadstart:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Called when reading the data is about to begin."},onprogress:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"Called periodically while the data is being read."}},"!url":"https://developer.mozilla.org/en/docs/DOM/FileReader","!doc":"The FileReader object lets web applications asynchronously read the contents of files (or raw data buffers) stored on the user's computer, using File or Blob objects to specify the file or data to read. File objects may be obtained from a FileList object returned as a result of a user selecting files using the <input> element, from a drag and drop operation's DataTransfer object, or from the mozGetAsFile() API on an HTMLCanvasElement."},URL:{createObjectURL:{"!type":"fn(blob: +Blob) -> string","!url":"https://developer.mozilla.org/en-US/docs/Web/API/URL.createObjectURL","!doc":"The URL.createObjectURL() static method creates a DOMString containing an URL representing the object given in parameter."},revokeObjectURL:{"!type":"fn(string)","!url":"https://developer.mozilla.org/en-US/docs/Web/API/URL.revokeObjectURL","!doc":"The URL.revokeObjectURL() static method releases an existing object URL which was previously created by calling window.URL.createObjectURL()."}},Range:{"!type":"fn()",prototype:{collapsed:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/range.collapsed","!doc":"Returns a boolean indicating whether the range's start and end points are at the same position."},commonAncestorContainer:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/range.commonAncestorContainer","!doc":"Returns the deepest Node that contains the  startContainer and  endContainer Nodes."},endContainer:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/range.endContainer","!doc":"Returns the Node within which the Range ends."},endOffset:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/range.endOffset","!doc":"Returns a number representing where in the  endContainer the Range ends."},startContainer:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/range.startContainer","!doc":"Returns the Node within which the Range starts."},startOffset:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/range.startOffset","!doc":"Returns a number representing where in the startContainer the Range starts."},setStart:{"!type":"fn(node: +Element, offset: number)","!url":"https://developer.mozilla.org/en/docs/DOM/range.setStart","!doc":"Sets the start position of a Range."},setEnd:{"!type":"fn(node: +Element, offset: number)","!url":"https://developer.mozilla.org/en/docs/DOM/range.setEnd","!doc":"Sets the end position of a Range."},setStartBefore:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/range.setStartBefore","!doc":"Sets the start position of a Range relative to another Node."},setStartAfter:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/range.setStartAfter","!doc":"Sets the start position of a Range relative to a Node."},setEndBefore:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/range.setEndBefore","!doc":"Sets the end position of a Range relative to another Node."},setEndAfter:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/range.setEndAfter","!doc":"Sets the end position of a Range relative to another Node."},selectNode:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/range.selectNode","!doc":"Sets the Range to contain the Node and its contents."},selectNodeContents:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/range.selectNodeContents","!doc":"Sets the Range to contain the contents of a Node."},collapse:{"!type":"fn(toStart: bool)","!url":"https://developer.mozilla.org/en/docs/DOM/range.collapse","!doc":"Collapses the Range to one of its boundary points."},cloneContents:{"!type":"fn() -> +DocumentFragment","!url":"https://developer.mozilla.org/en/docs/DOM/range.cloneContents","!doc":"Returns a DocumentFragment copying the Nodes of a Range."},deleteContents:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/range.deleteContents","!doc":"Removes the contents of a Range from the Document."},extractContents:{"!type":"fn() -> +DocumentFragment","!url":"https://developer.mozilla.org/en/docs/DOM/range.extractContents","!doc":"Moves contents of a Range from the document tree into a DocumentFragment."},insertNode:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/range.insertNode","!doc":"Insert a node at the start of a Range."},surroundContents:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/range.surroundContents","!doc":"Moves content of a Range into a new node, placing the new node at the start of the specified range."},compareBoundaryPoints:{"!type":"fn(how: number, other: +Range) -> number","!url":"https://developer.mozilla.org/en/docs/DOM/range.compareBoundaryPoints","!doc":"Compares the boundary points of two Ranges."},cloneRange:{"!type":"fn() -> +Range","!url":"https://developer.mozilla.org/en/docs/DOM/range.cloneRange","!doc":"Returns a Range object with boundary points identical to the cloned Range."},detach:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/range.detach","!doc":"Releases a Range from use to improve performance. This lets the browser choose to release resources associated with this Range. Subsequent attempts to use the detached range will result in a DOMException being thrown with an error code of INVALID_STATE_ERR."},END_TO_END:"number",END_TO_START:"number",START_TO_END:"number",START_TO_START:"number"},"!url":"https://developer.mozilla.org/en/docs/DOM/range.detach","!doc":"Releases a Range from use to improve performance. This lets the browser choose to release resources associated with this Range. Subsequent attempts to use the detached range will result in a DOMException being thrown with an error code of INVALID_STATE_ERR."},XMLHttpRequest:{"!type":"fn()",prototype:{abort:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"Aborts the request if it has already been sent."},getAllResponseHeaders:{"!type":"fn() -> string","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"Returns all the response headers as a string, or null if no response has been received. Note: For multipart requests, this returns the headers from the current part of the request, not from the original channel."},getResponseHeader:{"!type":"fn(header: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"Returns the string containing the text of the specified header, or null if either the response has not yet been received or the header doesn't exist in the response."},open:{"!type":"fn(method: string, url: string, async?: bool, user?: string, password?: string)","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"Initializes a request."},overrideMimeType:{"!type":"fn(type: string)","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"Overrides the MIME type returned by the server."},send:{"!type":"fn(data?: string)","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"Sends the request. If the request is asynchronous (which is the default), this method returns as soon as the request is sent. If the request is synchronous, this method doesn't return until the response has arrived."},setRequestHeader:{"!type":"fn(header: string, value: string)","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"Sets the value of an HTTP request header.You must call setRequestHeader() after open(), but before send()."},onreadystatechange:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"A JavaScript function object that is called whenever the readyState attribute changes."},readyState:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"The state of the request. (0=unsent, 1=opened, 2=headers_received, 3=loading, 4=done)"},response:{"!type":"+Document","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":'The response entity body according to responseType, as an ArrayBuffer, Blob, Document, JavaScript object (for "json"), or string. This is null if the request is not complete or was not successful.'},responseText:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"The response to the request as text, or null if the request was unsuccessful or has not yet been sent."},responseType:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"Can be set to change the response type."},responseXML:{"!type":"+Document","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"The response to the request as a DOM Document object, or null if the request was unsuccessful, has not yet been sent, or cannot be parsed as XML or HTML."},status:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"The status of the response to the request. This is the HTTP result code"},statusText:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":'The response string returned by the HTTP server. Unlike status, this includes the entire text of the response message ("200 OK", for example).'},timeout:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest/Synchronous_and_Asynchronous_Requests","!doc":"The number of milliseconds a request can take before automatically being terminated. A value of 0 (which is the default) means there is no timeout."},UNSENT:"number",OPENED:"number",HEADERS_RECEIVED:"number",LOADING:"number",DONE:"number"},"!url":"https://developer.mozilla.org/en/docs/DOM/XMLHttpRequest","!doc":"XMLHttpRequest is a JavaScript object that was designed by Microsoft and adopted by Mozilla, Apple, and Google. It's now being standardized in the W3C. It provides an easy way to retrieve data at a URL. Despite its name, XMLHttpRequest can be used to retrieve any type of data, not just XML, and it supports protocols other than HTTP (including file and ftp)."},DOMParser:{"!type":"fn()",prototype:{parseFromString:{"!type":"fn(data: string, mime: string) -> +Document","!url":"https://developer.mozilla.org/en/docs/DOM/DOMParser","!doc":"DOMParser can parse XML or HTML source stored in a string into a DOM Document. DOMParser is specified in DOM Parsing and Serialization."}},"!url":"https://developer.mozilla.org/en/docs/DOM/DOMParser","!doc":"DOMParser can parse XML or HTML source stored in a string into a DOM Document. DOMParser is specified in DOM Parsing and Serialization."},FormData:{"!type":"fn()","!url":"https://developer.mozilla.org/en-US/docs/Web/API/FormData",prototype:{append:{"!type":"fn(name: string, value: ?, filename: string)","!url":"https://developer.mozilla.org/en-US/docs/Web/API/FormData/append","!doc":"Appends a new value onto an existing key inside a FormData object, or adds the key if it does not already exist."},"delete":{"!type":"fn(name: string)","!url":"https://developer.mozilla.org/en-US/docs/Web/API/FormData/delete","!doc":"Deletes a key/value pair from a FormData object."},get:{"!type":"fn(name: string)","!url":"https://developer.mozilla.org/en-US/docs/Web/API/FormData/get","!doc":"Returns the first value associated with a given key from within a FormData object."},getAll:{"!type":"fn(name: string)","!url":"https://developer.mozilla.org/en-US/docs/Web/API/FormData/getAll","!doc":"Returns an array of all the values associated with a given key from within a FormData."},has:{"!type":"fn(name: string)","!url":"https://developer.mozilla.org/en-US/docs/Web/API/FormData/has","!doc":"Returns a boolean stating whether a FormData object contains a certain key/value pair."},set:{"!type":"fn(name: string, value: ?, filename: string)","!url":"https://developer.mozilla.org/en-US/docs/Web/API/FormData/set","!doc":"Sets a new value for an existing key inside a FormData object, or adds the key/value if it does not already exist."}}},Selection:{"!type":"fn()",prototype:{anchorNode:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/anchorNode","!doc":"Returns the node in which the selection begins."},anchorOffset:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/anchorOffset","!doc":"Returns the number of characters that the selection's anchor is offset within the anchorNode."},focusNode:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/focusNode","!doc":"Returns the node in which the selection ends."},focusOffset:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/focusOffset","!doc":"Returns the number of characters that the selection's focus is offset within the focusNode. "},isCollapsed:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/isCollapsed","!doc":"Returns a boolean indicating whether the selection's start and end points are at the same position."},rangeCount:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/rangeCount","!doc":"Returns the number of ranges in the selection."},getRangeAt:{"!type":"fn(i: number) -> +Range","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/getRangeAt","!doc":"Returns a range object representing one of the ranges currently selected."},collapse:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/collapse","!doc":"Collapses the current selection to a single point. The document is not modified. If the content is focused and editable, the caret will blink there."},extend:{"!type":"fn(node: +Element, offset: number)","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/extend","!doc":"Moves the focus of the selection to a specified point. The anchor of the selection does not move. The selection will be from the anchor to the new focus regardless of direction."},collapseToStart:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/collapseToStart","!doc":"Collapses the selection to the start of the first range in the selection.  If the content of the selection is focused and editable, the caret will blink there."},collapseToEnd:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/collapseToEnd","!doc":"Collapses the selection to the end of the last range in the selection.  If the content the selection is in is focused and editable, the caret will blink there."},selectAllChildren:{"!type":"fn(node: +Element)","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/selectAllChildren","!doc":"Adds all the children of the specified node to the selection. Previous selection is lost."},addRange:{"!type":"fn(range: +Range)","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/addRange","!doc":"Adds a Range to a Selection."},removeRange:{"!type":"fn(range: +Range)","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/removeRange","!doc":"Removes a range from the selection."},removeAllRanges:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/removeAllRanges","!doc":"Removes all ranges from the selection, leaving the anchorNode and focusNode properties equal to null and leaving nothing selected. "},deleteFromDocument:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/deleteFromDocument","!doc":"Deletes the actual text being represented by a selection object from the document's DOM."},containsNode:{"!type":"fn(node: +Element) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/Selection/containsNode","!doc":"Indicates if the node is part of the selection."}},"!url":"https://developer.mozilla.org/en/docs/DOM/Selection","!doc":"Selection is the class of the object returned by window.getSelection() and other methods. It represents the text selection in the greater page, possibly spanning multiple elements, when the user drags over static text and other parts of the page. For information about text selection in an individual text editing element."},console:{error:{"!type":"fn(text: string)","!url":"https://developer.mozilla.org/en/docs/DOM/console.error","!doc":"Outputs an error message to the Web Console."},info:{"!type":"fn(text: string)","!url":"https://developer.mozilla.org/en/docs/DOM/console.info","!doc":"Outputs an informational message to the Web Console."},log:{"!type":"fn(text: string)","!url":"https://developer.mozilla.org/en/docs/DOM/console.log","!doc":"Outputs a message to the Web Console."},warn:{"!type":"fn(text: string)","!url":"https://developer.mozilla.org/en/docs/DOM/console.warn","!doc":"Outputs a warning message to the Web Console."},"!url":"https://developer.mozilla.org/en/docs/DOM/console","!doc":"The console object provides access to the browser's debugging console. The specifics of how it works vary from browser to browser, but there is a de facto set of features that are typically provided."},top:{"!type":"<top>","!url":"https://developer.mozilla.org/en/docs/DOM/window.top","!doc":"Returns a reference to the topmost window in the window hierarchy."},parent:{"!type":"<top>","!url":"https://developer.mozilla.org/en/docs/DOM/window.parent","!doc":"A reference to the parent of the current window or subframe."},window:{"!type":"<top>","!url":"https://developer.mozilla.org/en/docs/DOM/window","!doc":"The window object represents a window containing a DOM document."},opener:{"!type":"<top>","!url":"https://developer.mozilla.org/en/docs/DOM/window.opener","!doc":"Returns a reference to the window that opened this current window."},self:{"!type":"<top>","!url":"https://developer.mozilla.org/en/docs/DOM/window.self","!doc":"Returns an object reference to the window object. "},devicePixelRatio:"number",name:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/JavaScript/Reference/Global_Objects/Function/name","!doc":"The name of the function."},closed:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/window.closed","!doc":"This property indicates whether the referenced window is closed or not."},pageYOffset:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.scrollY","!doc":"Returns the number of pixels that the document has already been scrolled vertically."},pageXOffset:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.scrollX","!doc":"Returns the number of pixels that the document has already been scrolled vertically."},scrollY:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.scrollY","!doc":"Returns the number of pixels that the document has already been scrolled vertically."},scrollX:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.scrollX","!doc":"Returns the number of pixels that the document has already been scrolled vertically."},screenTop:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.top","!doc":"Returns the distance in pixels from the top side of the current screen."},screenLeft:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.left","!doc":"Returns the distance in pixels from the left side of the main screen to the left side of the current screen."},screenY:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.screenY","!doc":"Returns the vertical coordinate of the event within the screen as a whole."},screenX:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/event.screenX","!doc":"Returns the horizontal coordinate of the event within the screen as a whole."},innerWidth:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.innerWidth","!doc":"Width (in pixels) of the browser window viewport including, if rendered, the vertical scrollbar."},innerHeight:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.innerHeight","!doc":"Height (in pixels) of the browser window viewport including, if rendered, the horizontal scrollbar."},outerWidth:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.outerWidth","!doc":"window.outerWidth gets the width of the outside of the browser window. It represents the width of the whole browser window including sidebar (if expanded), window chrome and window resizing borders/handles."},outerHeight:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.outerHeight","!doc":"window.outerHeight gets the height in pixels of the whole browser window."},frameElement:{"!type":"+Element","!url":"https://developer.mozilla.org/en/docs/DOM/window.frameElement","!doc":"Returns the element (such as <iframe> or <object>) in which the window is embedded, or null if the window is top-level."},crypto:{getRandomValues:{"!type":"fn([number])","!url":"https://developer.mozilla.org/en/docs/DOM/window.crypto.getRandomValues","!doc":"This methods lets you get cryptographically random values."},"!url":"https://developer.mozilla.org/en/docs/DOM/window.crypto.getRandomValues","!doc":"This methods lets you get cryptographically random values."},navigator:{appName:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator.appName","!doc":'Returns the name of the browser. The HTML5 specification also allows any browser to return "Netscape" here, for compatibility reasons.'},appVersion:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator.appVersion","!doc":'Returns the version of the browser as a string. It may be either a plain version number, like "5.0", or a version number followed by more detailed information. The HTML5 specification also allows any browser to return "4.0" here, for compatibility reasons.'},language:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator.language","!doc":"Returns a string representing the language version of the browser."},platform:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator.platform","!doc":"Returns a string representing the platform of the browser."},plugins:{"!type":"[?]","!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator.plugins","!doc":"Returns a PluginArray object, listing the plugins installed in the application."},userAgent:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator.userAgent","!doc":"Returns the user agent string for the current browser."},vendor:{"!type":"string","!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator.vendor","!doc":"Returns the name of the browser vendor for the current browser."},javaEnabled:{"!type":"bool","!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator.javaEnabled","!doc":"This method indicates whether the current browser is Java-enabled or not."},"!url":"https://developer.mozilla.org/en/docs/DOM/window.navigator","!doc":"Returns a reference to the navigator object, which can be queried for information about the application running the script."},history:{state:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Manipulating_the_browser_history","!doc":"The DOM window object provides access to the browser's history through the history object. It exposes useful methods and properties that let you move back and forth through the user's history, as well as -- starting with HTML5 -- manipulate the contents of the history stack."},length:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/Manipulating_the_browser_history","!doc":"The DOM window object provides access to the browser's history through the history object. It exposes useful methods and properties that let you move back and forth through the user's history, as well as -- starting with HTML5 -- manipulate the contents of the history stack."},go:{"!type":"fn(delta: number)","!url":"https://developer.mozilla.org/en/docs/DOM/window.history","!doc":"Returns a reference to the History object, which provides an interface for manipulating the browser session history (pages visited in the tab or frame that the current page is loaded in)."},forward:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Manipulating_the_browser_history","!doc":"The DOM window object provides access to the browser's history through the history object. It exposes useful methods and properties that let you move back and forth through the user's history, as well as -- starting with HTML5 -- manipulate the contents of the history stack."},back:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/Manipulating_the_browser_history","!doc":"The DOM window object provides access to the browser's history through the history object. It exposes useful methods and properties that let you move back and forth through the user's history, as well as -- starting with HTML5 -- manipulate the contents of the history stack."},pushState:{"!type":"fn(data: ?, title: string, url?: string)","!url":"https://developer.mozilla.org/en/docs/DOM/Manipulating_the_browser_history","!doc":"The DOM window object provides access to the browser's history through the history object. It exposes useful methods and properties that let you move back and forth through the user's history, as well as -- starting with HTML5 -- manipulate the contents of the history stack."},replaceState:{"!type":"fn(data: ?, title: string, url?: string)","!url":"https://developer.mozilla.org/en/docs/DOM/Manipulating_the_browser_history","!doc":"The DOM window object provides access to the browser's history through the history object. It exposes useful methods and properties that let you move back and forth through the user's history, as well as -- starting with HTML5 -- manipulate the contents of the history stack."},"!url":"https://developer.mozilla.org/en/docs/DOM/Manipulating_the_browser_history","!doc":"The DOM window object provides access to the browser's history through the history object. It exposes useful methods and properties that let you move back and forth through the user's history, as well as -- starting with HTML5 -- manipulate the contents of the history stack."},screen:{availWidth:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.availWidth","!doc":"Returns the amount of horizontal space in pixels available to the window."},availHeight:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.availHeight","!doc":"Returns the amount of vertical space available to the window on the screen."},availTop:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.availTop","!doc":"Specifies the y-coordinate of the first pixel that is not allocated to permanent or semipermanent user interface features."},availLeft:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.availLeft","!doc":"Returns the first available pixel available from the left side of the screen."},pixelDepth:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.pixelDepth","!doc":"Returns the bit depth of the screen."},colorDepth:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.colorDepth","!doc":"Returns the color depth of the screen."},width:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.width","!doc":"Returns the width of the screen."},height:{"!type":"number","!url":"https://developer.mozilla.org/en/docs/DOM/window.screen.height","!doc":"Returns the height of the screen in pixels."},"!url":"https://developer.mozilla.org/en/docs/DOM/window.screen","!doc":"Returns a reference to the screen object associated with the window."},postMessage:{"!type":"fn(message: string, targetOrigin: string)","!url":"https://developer.mozilla.org/en/docs/DOM/window.postMessage","!doc":"window.postMessage, when called, causes a MessageEvent to be dispatched at the target window when any pending script that must be executed completes (e.g. remaining event handlers if window.postMessage is called from an event handler, previously-set pending timeouts, etc.). The MessageEvent has the type message, a data property which is set to the value of the first argument provided to window.postMessage, an origin property corresponding to the origin of the main document in the window calling window.postMessage at the time window.postMessage was called, and a source property which is the window from which window.postMessage is called. (Other standard properties of events are present with their expected values.)"},close:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/window.close","!doc":"Closes the current window, or a referenced window."},blur:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/element.blur","!doc":"The blur method removes keyboard focus from the current element."},focus:{"!type":"fn()","!url":"https://developer.mozilla.org/en/docs/DOM/element.focus","!doc":"Sets focus on the specified element, if it can be focused."},onload:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onload","!doc":"An event handler for the load event of a window."},onunload:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onunload","!doc":"The unload event is raised when the window is unloading its content and resources. The resources removal is processed after the unload event occurs."},onscroll:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onscroll","!doc":"Specifies the function to be called when the window is scrolled."},onresize:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onresize","!doc":"An event handler for the resize event on the window."},ononline:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/document.ononline","!doc":'"online" event is fired when the browser switches between online and offline mode.'},onoffline:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/Online_and_offline_events","!doc":"Some browsers implement Online/Offline events from the WHATWG Web Applications 1.0 specification."},onmousewheel:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/DOM_event_reference/mousewheel","!doc":"The DOM mousewheel event is fired asynchronously when mouse wheel or similar device is operated. It's represented by the MouseWheelEvent interface."},onmouseup:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onmouseup","!doc":"An event handler for the mouseup event on the window."},onmouseover:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onmouseover","!doc":"The onmouseover property returns the onMouseOver event handler code on the current element."},onmouseout:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onmouseout","!doc":"The onmouseout property returns the onMouseOut event handler code on the current element."},onmousemove:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onmousemove","!doc":"The onmousemove property returns the mousemove event handler code on the current element."},onmousedown:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onmousedown","!doc":"An event handler for the mousedown event on the window."},onclick:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onclick","!doc":"The onclick property returns the onClick event handler code on the current element."},ondblclick:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.ondblclick","!doc":"The ondblclick property returns the onDblClick event handler code on the current element."},onmessage:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/Worker","!doc":"Dedicated Web Workers provide a simple means for web content to run scripts in background threads.  Once created, a worker can send messages to the spawning task by posting messages to an event handler specified by the creator."},onkeyup:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onkeyup","!doc":"The onkeyup property returns the onKeyUp event handler code for the current element."},onkeypress:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onkeypress","!doc":"The onkeypress property sets and returns the onKeyPress event handler code for the current element."},onkeydown:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onkeydown","!doc":"An event handler for the keydown event on the window."},oninput:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/DOM_event_reference/input","!doc":"The DOM input event is fired synchronously when the value of an <input> or <textarea> element is changed. Additionally, it's also fired on contenteditable editors when its contents are changed. In this case, the event target is the editing host element. If there are two or more elements which have contenteditable as true, \"editing host\" is the nearest ancestor element whose parent isn't editable. Similarly, it's also fired on root element of designMode editors."},onpopstate:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onpopstate","!doc":"An event handler for the popstate event on the window."},onhashchange:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onhashchange","!doc":"The hashchange event fires when a window's hash changes."},onfocus:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onfocus","!doc":"The onfocus property returns the onFocus event handler code on the current element."},onblur:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onblur","!doc":"The onblur property returns the onBlur event handler code, if any, that exists on the current element."},onerror:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onerror","!doc":"An event handler for runtime script errors."},ondrop:{"!type":"?","!url":"https://developer.mozilla.org/en-US/docs/DOM/Mozilla_event_reference/drop","!doc":"The drop event is fired when an element or text selection is dropped on a valid drop target."},ondragstart:{"!type":"?","!url":"https://developer.mozilla.org/en-US/docs/DOM/Mozilla_event_reference/dragstart","!doc":"The dragstart event is fired when the user starts dragging an element or text selection."},ondragover:{"!type":"?","!url":"https://developer.mozilla.org/en-US/docs/DOM/Mozilla_event_reference/dragover","!doc":"The dragover event is fired when an element or text selection is being dragged over a valid drop target (every few hundred milliseconds)."},ondragleave:{"!type":"?","!url":"https://developer.mozilla.org/en-US/docs/DOM/Mozilla_event_reference/dragleave","!doc":"The dragleave event is fired when a dragged element or text selection leaves a valid drop target."},ondragenter:{"!type":"?","!url":"https://developer.mozilla.org/en-US/docs/DOM/Mozilla_event_reference/dragenter","!doc":"The dragenter event is fired when a dragged element or text selection enters a valid drop target."},ondragend:{"!type":"?","!url":"https://developer.mozilla.org/en-US/docs/DOM/Mozilla_event_reference/dragend","!doc":"The dragend event is fired when a drag operation is being ended (by releasing a mouse button or hitting the escape key)."},ondrag:{"!type":"?","!url":"https://developer.mozilla.org/en-US/docs/DOM/Mozilla_event_reference/drag","!doc":"The drag event is fired when an element or text selection is being dragged (every few hundred milliseconds)."},oncontextmenu:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.oncontextmenu","!doc":'An event handler property for right-click events on the window. Unless the default behavior is prevented, the browser context menu will activate (though IE8 has a bug with this and will not activate the context menu if a contextmenu event handler is defined). Note that this event will occur with any non-disabled right-click event and does not depend on an element possessing the "contextmenu" attribute.'},onchange:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/element.onchange","!doc":"The onchange property sets and returns the onChange event handler code for the current element."},onbeforeunload:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onbeforeunload","!doc":"An event that fires when a window is about to unload its resources. The document is still visible and the event is still cancelable."},onabort:{"!type":"?","!url":"https://developer.mozilla.org/en/docs/DOM/window.onabort","!doc":"An event handler for abort events sent to the window."},getSelection:{"!type":"fn() -> +Selection","!url":"https://developer.mozilla.org/en/docs/DOM/window.getSelection","!doc":"Returns a selection object representing the range of text selected by the user. "},alert:{"!type":"fn(message: string)","!url":"https://developer.mozilla.org/en/docs/DOM/window.alert","!doc":"Display an alert dialog with the specified content and an OK button."},confirm:{"!type":"fn(message: string) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/window.confirm","!doc":"Displays a modal dialog with a message and two buttons, OK and Cancel."},prompt:{"!type":"fn(message: string, value: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/window.prompt","!doc":"Displays a dialog with a message prompting the user to input some text."},scrollBy:{"!type":"fn(x: number, y: number)","!url":"https://developer.mozilla.org/en/docs/DOM/window.scrollBy","!doc":"Scrolls the document in the window by the given amount."},scrollTo:{"!type":"fn(x: number, y: number)","!url":"https://developer.mozilla.org/en/docs/DOM/window.scrollTo","!doc":"Scrolls to a particular set of coordinates in the document."},scroll:{"!type":"fn(x: number, y: number)","!url":"https://developer.mozilla.org/en/docs/DOM/window.scroll","!doc":"Scrolls the window to a particular place in the document."},setTimeout:{"!type":"fn(f: fn(), ms: number) -> number","!url":"https://developer.mozilla.org/en/docs/DOM/window.setTimeout","!doc":"Calls a function or executes a code snippet after specified delay."},clearTimeout:{"!type":"fn(timeout: number)","!url":"https://developer.mozilla.org/en/docs/DOM/window.clearTimeout","!doc":"Clears the delay set by window.setTimeout()."},setInterval:{"!type":"fn(f: fn(), ms: number) -> number","!url":"https://developer.mozilla.org/en/docs/DOM/window.setInterval","!doc":"Calls a function or executes a code snippet repeatedly, with a fixed time delay between each call to that function."},clearInterval:{"!type":"fn(interval: number)","!url":"https://developer.mozilla.org/en/docs/DOM/window.clearInterval","!doc":"Cancels repeated action which was set up using setInterval."},atob:{"!type":"fn(encoded: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/window.atob","!doc":"Decodes a string of data which has been encoded using base-64 encoding."},btoa:{"!type":"fn(data: string) -> string","!url":"https://developer.mozilla.org/en/docs/DOM/window.btoa","!doc":"Creates a base-64 encoded ASCII string from a string of binary data."},addEventListener:{"!type":"fn(type: string, listener: fn(e: +Event), capture: bool)","!url":"https://developer.mozilla.org/en/docs/DOM/EventTarget.addEventListener","!doc":"Registers a single event listener on a single target. The event target may be a single element in a document, the document itself, a window, or an XMLHttpRequest."},removeEventListener:{"!type":"fn(type: string, listener: fn(), capture: bool)","!url":"https://developer.mozilla.org/en/docs/DOM/EventTarget.removeEventListener","!doc":"Allows the removal of event listeners from the event target."},dispatchEvent:{"!type":"fn(event: +Event) -> bool","!url":"https://developer.mozilla.org/en/docs/DOM/EventTarget.dispatchEvent","!doc":"Dispatches an event into the event system. The event is subject to the same capturing and bubbling behavior as directly dispatched events."},getComputedStyle:{"!type":"fn(node: +Element, pseudo?: string) -> Element.prototype.style","!url":"https://developer.mozilla.org/en/docs/DOM/window.getComputedStyle","!doc":"Gives the final used values of all the CSS properties of an element."},CanvasRenderingContext2D:{canvas:"+Element",width:"number",height:"number",commit:"fn()",save:"fn()",restore:"fn()",currentTransform:"?",scale:"fn(x: number, y: number)",rotate:"fn(angle: number)",translate:"fn(x: number, y: number)",transform:"fn(a: number, b: number, c: number, d: number, e: number, f: number)",setTransform:"fn(a: number, b: number, c: number, d: number, e: number, f: number)",resetTransform:"fn()",globalAlpha:"number",globalCompositeOperation:"string",imageSmoothingEnabled:"bool",strokeStyle:"string",fillStyle:"string",createLinearGradient:"fn(x0: number, y0: number, x1: number, y1: number) -> ?",createPattern:"fn(image: ?, repetition: string) -> ?",shadowOffsetX:"number",shadowOffsetY:"number",shadowBlur:"number",shadowColor:"string",clearRect:"fn(x: number, y: number, w: number, h: number)",fillRect:"fn(x: number, y: number, w: number, h: number)",strokeRect:"fn(x: number, y: number, w: number, h: number)",fillRule:"string",fill:"fn()",beginPath:"fn()",stroke:"fn()",clip:"fn()",resetClip:"fn()",fillText:"fn(text: string, x: number, y: number, maxWidth: number)",strokeText:"fn(text: string, x: number, y: number, maxWidth: number)",measureText:"fn(text: string) -> ?",drawImage:"fn(image: ?, dx: number, dy: number)",createImageData:"fn(sw: number, sh: number) -> ?",getImageData:"fn(sx: number, sy: number, sw: number, sh: number) -> ?",putImageData:"fn(imagedata: ?, dx: number, dy: number)",lineWidth:"number",lineCap:"string",lineJoin:"string",miterLimit:"number",setLineDash:"fn(segments: [number])",getLineDash:"fn() -> [number]",lineDashOffset:"number",font:"string",textAlign:"string",textBaseline:"string",direction:"string",closePath:"fn()",moveTo:"fn(x: number, y: number)",lineTo:"fn(x: number, y: number)",quadraticCurveTo:"fn(cpx: number, cpy: number, x: number, y: number)",bezierCurveTo:"fn(cp1x: number, cp1y: number, cp2x: number, cp2y: number, x: number, y: number)",arcTo:"fn(x1: number, y1: number, x2: number, y2: number, radius: number)",rect:"fn(x: number, y: number, w: number, h: number)",arc:"fn(x: number, y: number, radius: number, startAngle: number, endAngle: number, anticlockwise?: bool)",ellipse:"fn(x: number, y: number, radiusX: number, radiusY: number, rotation: number, startAngle: number, endAngle: number, anticlockwise: bool)"}}
}),function(){"use strict";function e(e,t,r,n,o,s){t[e]&&(r.push(e),(t[e]===!0||1===t[e])&&n.push(o+e+"/"+s))}function t(e,t,r,n,o){var s=n+t+"/"+o;require._fileExists(e.toUrl(s+".js"))&&r.push(s)}function r(e,t,n){var o;for(o in t)!t.hasOwnProperty(o)||e.hasOwnProperty(o)&&!n?"object"==typeof t[o]&&(!e[o]&&t[o]&&(e[o]={}),r(e[o],t[o],n)):e[o]=t[o]}var n=/(^.*(^|\/)nls(\/|$))([^\/]*)\/?([^\/]*)/;define("i18n",["module"],function(o){var s=o.config?o.config():{};return{version:"2.0.4",load:function(o,a,i,l){l=l||{},l.locale&&(s.locale=l.locale);var c,p,d,u=n.exec(o),h=u[1],f=u[4],m=u[5],g=f.split("-"),b=[],y={},v="";if(u[5]?(h=u[1],c=h+m):(c=o,m=u[4],f=s.locale,f||(f=s.locale="undefined"==typeof navigator?"root":(navigator.language||navigator.userLanguage||"root").toLowerCase()),g=f.split("-")),l.isBuild){for(b.push(c),t(a,"root",b,h,m),p=0;p<g.length;p++)d=g[p],v+=(v?"-":"")+d,t(a,v,b,h,m);if(l.locales){var w,_;for(w=0;w<l.locales.length;w++)for(f=l.locales[w],g=f.split("-"),v="",_=0;_<g.length;_++)d=g[_],v+=(v?"-":"")+d,t(a,v,b,h,m)}a(b,function(){i()})}else a([c],function(t){var n,o=[];for(e("root",t,o,b,h,m),p=0;p<g.length;p++)n=g[p],v+=(v?"-":"")+n,e(v,t,o,b,h,m);a(b,function(){var e,n,s;for(e=o.length-1;e>-1&&o[e];e--)s=o[e],n=t[s],(n===!0||1===n)&&(n=a(h+s+"/"+m)),r(y,n);i(y)})})}}})}(),define("javascript/nls/workermessages",{root:!0}),define("javascript/nls/root/workermessages",{ternDocPluginName:"Doc Comments",ternDocPluginDescription:"Tern plug-in to parse and use JSDoc-like comments for inferencing",orionAMQPPluginName:"Orion AMQP",orionAMQPPluginDescription:"Plug-in that contributes type information and code templates for AMQP.",orionAngularPluginName:"AngularJS",orionAngularPluginDescription:"Plug-in that contributes type information and code templates for AngularJS.",orionComponentPluginName:"ComponentJS",orionComponentPluginDescription:"Plug-in that contributes type information and code templates for ComponentJS.",orionExpressPluginName:"Orion ExpressJS",orionExpressPluginDescription:"Plug-in that contributes type information and code templates for ExpressJS.",orionMongoDBPluginName:"Orion MongoDB",orionMongoDBPluginDescription:"Plug-in that contributes type information and code templates for MongoDB.",orionMySQLPluginName:"Orion MySQL",orionMySQLPluginDescription:"Plug-in that contributes type information and code templates for MySQL.",orionNodePluginName:"Orion Node.js",orionNodePluginDescription:"Plug-in that contributes type information and code templates for Node.js.",orionPostgresPluginName:"Orion PostgreSQL",orionPostgresPluginDescription:"Plug-in that contributes type information and code templates for PostgreSQL.",orionRequirePluginName:"Orion RequireJS",orionRequirePluginDescription:"Plug-in that contributes type information and code templates for RequireJS.",orionRedisPluginName:"Orion Redis",orionRedisPluginDescription:"Plug-in that contributes type information and code templates for Redis.",ternPluginsPluginName:"Orion Tern Plug-in Support",ternPluginsPluginDescription:"Plug-in that allows Orion to inspect and modify plug-ins running in Tern.",openImplPluginName:"Orion Open Implementation Support",openImplPluginDescription:"Plug-in that allows Orion to try to find implementation locations of elements rather than simple declarations",htmlDepPluginName:"Orion HTML Dependency Analysis",htmlDepPluginDescription:"Resolves script block and script tag dependencies",findTypesName:"Orion References Support",findTypesDescription:"Plug-in that provides expanded type-finding support in Orion",unknownError:"An unknown error occurred.",failedDeleteRequest:"Failed to delete file from Tern: ${0}",failedReadRequest:"Failed to read file into Tern: ${0}",failedToComputeProposals:"Failed to compute proposals",failedToComputeProposalsNoServer:"Failed to compute proposals, server not started",failedToComputeDecl:"Failed to compute declaration",failedToComputeDeclNoServer:"Failed to compute declaration, server not started",failedToComputeImpl:"Failed to compute implementation",failedToComputeImplNoServer:"Failed to compute implementation, server not started",failedToComputeDoc:"Failed to compute documentation",failedToComputeDocNoServer:"Failed to compute documentation, server not started",failedToComputeOccurrences:"Failed to compute occurrences",failedToComputeOccurrencesNoServer:"failed to compute occurrences, server not started",failedGetInstalledPlugins:"Failed to get installed plug-ins",failedGetInstalledPluginsNoServer:"Failed to get installed plug-ins, server not started",failedInstallPlugins:"Failed to install plug-ins",failedInstallPluginsNoServer:"Failed to install plug-ins, server not started",failedRemovePlugins:"Failed to remove plug-ins",failedRemovePluginsNoServer:"Failed to remove plug-ins, server not started",failedEnablementPlugins:"Failed to set enablement of plug-ins",failedEnablementPluginsNoServer:"Failed to set enablement of plug-ins, server not started",failedGetEnvs:"Failed to get contributed environments",failedGetEnvsNoServer:"Failed to get contributed environments, server not started",failedRename:"Failed to compute rename changes",failedRenameNoServer:"Failed to compute rename changes, server not started",failedRefs:"Failed to find refs",failedRefsNoServer:"failed to find refs - server not started",failedType:"Failed to find type",unknownRequest:"The request '${0}' is unknown",serverNotStarted:"The server has not been started. Request: '${0}'"}),define("orion/i18nUtil",[],function(){function e(e){var t=/\$\{([^\}]+)\}/g,r=arguments;return 2===r.length&&r[1]&&"object"==typeof r[1]?e.replace(t,function(e,t){return r[1][t]}):e.replace(t,function(e,t){return r[(t<<0)+1]})}return{formatMessage:e}});var lang="en",sear=self.location.search;if(sear){var langs=sear.split("worker-language");Array.isArray(langs)&&2===langs.length&&(lang=langs[1].slice(1),lang&&(lang=lang.toLocaleLowerCase()))}requirejs.config({locale:lang}),require(["tern/lib/tern","tern/plugin/doc_comment","tern/plugin/orionAmqp","tern/plugin/angular","tern/plugin/orionExpress","tern/plugin/orionMongoDB","tern/plugin/orionMySQL","tern/plugin/node","tern/plugin/orionPostgres","tern/plugin/orionRedis","tern/plugin/requirejs","tern/plugin/ternPlugins","tern/plugin/refs","tern/plugin/openImplementation","tern/plugin/htmlDependencies","json!tern/defs/ecma5.json","json!tern/defs/ecma6.json","json!tern/defs/browser.json","i18n!javascript/nls/workermessages","orion/i18nUtil"],function(e,t,r,n,o,s,a,i,l,c,p,d,u,h,f,m,g,b,y,v){function w(t){x&&(x.reset(),x=null);var r={async:!0,debug:!1,defs:[m,g,b],projectDir:"/",plugins:{doc_comment:{name:y.ternDocPluginName,description:y.ternDocPluginDescription,fullDocs:!0,version:"0.12.0",removable:!1},orionAmqp:{name:y.orionAMQPPluginName,description:y.orionAMQPPluginDescription,version:"0.9.1",removable:!0,env:"amqp"},angular:{name:y.orionAngularPluginName,description:y.orionAngularPluginDescription,version:"0.12.0",removable:!0},orionExpress:{name:y.orionExpressPluginName,description:y.orionExpressPluginDescription,version:"4.12.4",removable:!0,env:"express"},orionMongoDB:{name:y.orionMongoDBPluginName,description:y.orionMongoDBPluginDescription,version:"1.1.21",removable:!0,env:"mongodb"},orionMySQL:{name:y.orionMySQLPluginName,description:y.orionMySQLPluginDescription,version:"2.7.0",removable:!0,env:"mysql"},node:{name:y.orionNodePluginName,description:y.orionNodePluginDescription,version:"0.12.0",removable:!0},orionPostgres:{name:y.orionPostgresPluginName,description:y.orionPostgresPluginDescription,version:"4.4.0",removable:!0,env:"pg"},orionRedis:{name:y.orionRedisPluginName,description:y.orionRedisPluginDescription,version:"0.12.1",removable:!0,env:"redis"},requirejs:{name:y.orionRequirePluginName,description:y.orionRequirePluginDescription,version:"0.12.0",removable:!0},plugins:{name:y.ternPluginsPluginName,description:y.ternPluginsPluginDescription,version:"1.0",removable:!1},openImplementation:{name:y.openImplPluginName,description:y.openImplPluginDescription,version:"1.0",removable:!1},orionHTML:{name:y.htmlDepPluginName,description:y.htmlDepPluginDescription,version:"1.0",removable:!1},refs:{name:y.findTypesName,description:y.findTypesDescription,version:"1.0",removable:!1}},getFile:E};t&&(t.plugins&&(r.plugins=t.plugins),Array.isArray(t.libs)&&(r.libs=t.libs),"number"==typeof t.ecmaVersion&&(r.ecmaVersion=t.ecmaVersion),"number"==typeof t.dependencyBudget&&(r.dependencyBudget=t.dependencyBudget)),x=new e.Server(r),T("server_ready")}function _(e){var t=Object.create(null);t.request=e.request,e.messageID?t.messageID=e.messageID:e.ternID&&(t.ternID=e.ternID),t.error=v.formatMessage(y.unknownRequest,t.request),T(t)}function S(e){var t=Object.create(null);t.request=e.request,e.messageID?t.messageID=e.messageID:e.ternID&&(t.ternID=e.ternID),t.error=v.formatMessage(y.serverNotStarted,t.request),T(t)}function T(e,t){e||(e=new Error(t?t:y.unknownError)),this.port?this.port.postMessage(e):postMessage(e)}function E(e,t){if(x){var r={request:"read",ternID:O++,args:{file:e}};k[r.ternID]=t,T(r,null)}else T(v.formatMessage(y.failedReadRequest,"object"==typeof e?e.logical:e))}var x=null;T("worker_ready");var j={start_server:function(e){w(e&&e.options)},addFile:function(e,t){x.addFile(e.file,e.source),t({request:"addFile"})},completions:function(e,t){x?x.request({query:{type:"completions",file:e.meta.location,types:!0,origins:!0,urls:!0,docs:!0,end:e.params.offset,sort:!0,includeKeywords:e.params.keywords,caseInsensitive:!0},files:e.files},function(e,r){t(e?{request:"completions",error:e.message,message:y.failedToComputeProposals}:r&&r.completions?{request:"completions",proposals:r.completions}:{request:"completions",proposals:[]})}):t({request:"completions",message:y.failedToComputeProposalsNoServer})},definition:function(e,t){x?x.request({query:{type:"definition",file:e.meta.location,end:e.params.offset},files:e.files},function(e,r){e&&t({request:"definition",error:e.message,message:y.failedToComputeDecl}),t(r&&"number"==typeof r.start&&"number"==typeof r.end?{request:"definition",declaration:r}:{request:"definition",declaration:null})}):t({request:"definition",message:y.failedToComputeDeclNoServer})},delFile:function(e,t){x&&"string"==typeof e.file?(x.delFile(e.file),t({request:"delFile"})):t({request:"delFile",message:v.formatMessage(y.failedDeleteRequest,e.file)})},documentation:function(e,t){x?x.request({query:{type:"documentation",file:e.meta.location,end:e.params.offset,docFormat:e.params.docFormat},files:e.files},function(e,r){t(e?{request:"documentation",error:e.message,message:y.failedToComputeDoc}:r&&r.doc?{request:"documentation",doc:r}:{request:"documentation",doc:null})}):t({request:"documentation",message:y.failedToComputeDocNoServer})},environments:function(e,t){x?x.request({query:{type:"environments"}},function(e,r){e&&t({request:"environments",error:e.message,message:y.failedGetEnvs}),t("object"==typeof r?{request:"environments",envs:r}:{request:"environments",envs:null})}):t({request:"environments",message:y.failedGetEnvsNoServer})},implementation:function(e,t){x?x.request({query:{type:"implementation",file:e.meta.location,end:e.params.offset},files:e.files},function(e,r){e&&t({request:"implementation",error:e.message,message:y.failedToComputeImpl}),t(r&&r.implementation&&"number"==typeof r.implementation.start&&"number"==typeof r.implementation.end?{request:"implementation",implementation:r.implementation}:{request:"implementation",implementation:null})}):t({request:"implementation",message:y.failedToComputeImplNoServer})},install_plugins:function(e,t){x?x.request({query:{type:"install_plugins"}},function(e,r){e&&t({request:"install_plugins",error:e.message,message:y.failedInstallPlugins}),t("object"==typeof r?{request:"install_plugins",status:r}:{request:"install_plugins",status:{state:-1}})}):t({request:"install_plugins",message:y.failedInstallPluginsNoServer})},installed_plugins:function(e,t){x?x.request({query:{type:"installed_plugins"}},function(e,r){e&&t({request:"installed_plugins",error:e.message,message:y.failedGetInstalledPlugins}),t("object"==typeof r?{request:"installed_plugins",plugins:r}:{request:"installed_plugins",plugins:null})}):t({request:"installed_plugins",message:y.failedGetInstalledPluginsNoServer})},occurrences:function(e,t){x?x.request({query:{type:"refs",file:e.meta.location,end:e.params.selection.start}},function(e,r){t(e?{request:"occurrences",error:e.message,message:y.failedToComputeOccurrences}:r&&Array.isArray(r)?{request:"occurrences",refs:r}:{request:"occurrences",refs:[]})}):t({request:"occurrences",message:y.failedToComputeOccurrencesNoServer})},plugin_enablement:function(e,t){x?x.request({query:{type:"plugin_enablement"}},function(e,r){e&&t({request:"plugin_enablement",error:e.message,message:y.failedEnablementPlugins}),t("object"==typeof r?{request:"plugin_enablement",status:r}:{request:"plugin_enablement",status:{state:-1}})}):t({request:"plugin_enablement",message:y.failedEnablementPluginsNoServer})},remove_plugins:function(e,t){x?x.request({query:{type:"remove_plugins"}},function(e,r){e&&t({request:"remove_plugins",error:e.message,message:y.failedRemovePlugins}),t("object"==typeof r?{request:"remove_plugins",status:r}:{request:"remove_plugins",status:{state:-1}})}):t({request:"remove_plugins",message:y.failedRemovePluginsNoServer})},rename:function(e,t){x?x.request({query:{type:"rename",file:e.meta.location,end:e.params.offset,newName:e.newname},files:e.files},function(e,r){t(e?{request:"rename",error:e.message,message:y.failedRename}:r&&Array.isArray(r.changes)?{request:"rename",changes:r}:{request:"rename",changes:[]})}):t({request:"rename",message:y.failedRenameNoServer})},type:function(e,t){x.request({query:{type:"type",file:e.meta.location,end:e.params.offset}},function(e,r){t(e?{request:"type",error:"string"==typeof e?e:e.message,message:y.failedType}:{request:"type",type:r})})},checkRef:function(e,t){x.request({query:{type:"checkRef",file:e.meta.location,end:e.params.offset,origin:e.origin}},function(e,r){t(e?{request:"checkRef",error:"string"==typeof e?e:e.message,message:y.failedType}:{request:"checkRef",type:r})})}},O=0,k=Object.create(null);onmessage=function(e){if("object"==typeof e.data){var t=e.data;x||"start_server"===t.request||S(t);var r=j[t.request];if("function"==typeof r)r(t.args,function(e){"number"==typeof t.messageID?e.messageID=t.messageID:"number"==typeof t.ternID&&(e.ternID=t.ternID),T(e)});else{if("read"===t.request){var n=k[t.ternID];return void("function"==typeof n&&n(t.args.error,{contents:t.args.contents?t.args.contents:"",file:t.args.file,logical:t.args.logical}))}_(t)}}},onerror=function(e){T(e)},onconnect=function(e){this.port=e.ports[0],this.port.onmessage=onmessage,this.port.start()}}),define("javascript/plugins/ternWorkerCore",function(){});