-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathagsWalk.min.js
1 lines (1 loc) · 8.57 KB
/
agsWalk.min.js
1
!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).agsWalk=e()}}(function(){return function e(n,t,r){function o(u,s){if(!t[u]){if(!n[u]){var c="function"==typeof require&&require;if(!s&&c)return c(u,!0);if(i)return i(u,!0);var a=new Error("Cannot find module '"+u+"'");throw a.code="MODULE_NOT_FOUND",a}var f=t[u]={exports:{}};n[u][0].call(f.exports,function(e){var t=n[u][1][e];return o(t||e)},f,f.exports,e,n,t,r)}return t[u].exports}for(var i="function"==typeof require&&require,u=0;u<r.length;u++)o(r[u]);return o}({1:[function(e,n,t){var r=e("request"),o=e("run-parallel-limit"),i=e("flatten");n.exports=function(e,n,t){function u(e){return void 0!==e.currentVersion}function s(e,n){return n?n.map(function(n){return function(t){var o={url:e+"/"+n+"?f=json",json:!0};r.get(o,function(e,n,r){if(e)return t(e);t(null,r)})}}):[]}"function"==typeof n&&(t=n,n={});var c=n.limit||5,a=this.services=[];try{r.get({url:e+"?f=json",json:!0},function(n,r,f){if(n)return t(n);if(404===r.statusCode)return t(r.statusMessage||"Not Found");if(!u(f))return t("Is not a valid ArcGIS Server URL");a.push(f.services);var l=s(e,f.folders);o(l,c,function(e,n){if(e)throw e;a.push(n.map(function(e){return e.services})),t(null,i(a))})})}catch(e){return t(e)}}},{flatten:3,request:10,"run-parallel-limit":8}],2:[function(e,n,t){function r(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function i(e){if(l===setTimeout)return setTimeout(e,0);if((l===r||!l)&&setTimeout)return l=setTimeout,setTimeout(e,0);try{return l(e,0)}catch(n){try{return l.call(null,e,0)}catch(n){return l.call(this,e,0)}}}function u(e){if(p===clearTimeout)return clearTimeout(e);if((p===o||!p)&&clearTimeout)return p=clearTimeout,clearTimeout(e);try{return p(e)}catch(n){try{return p.call(null,e)}catch(n){return p.call(this,e)}}}function s(){m&&h&&(m=!1,h.length?y=h.concat(y):w=-1,y.length&&c())}function c(){if(!m){var e=i(s);m=!0;for(var n=y.length;n;){for(h=y,y=[];++w<n;)h&&h[w].run();w=-1,n=y.length}h=null,m=!1,u(e)}}function a(e,n){this.fun=e,this.array=n}function f(){}var l,p,d=n.exports={};!function(){try{l="function"==typeof setTimeout?setTimeout:r}catch(e){l=r}try{p="function"==typeof clearTimeout?clearTimeout:o}catch(e){p=o}}();var h,y=[],m=!1,w=-1;d.nextTick=function(e){var n=new Array(arguments.length-1);if(arguments.length>1)for(var t=1;t<arguments.length;t++)n[t-1]=arguments[t];y.push(new a(e,n)),1!==y.length||m||i(c)},a.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=f,d.addListener=f,d.once=f,d.off=f,d.removeListener=f,d.removeAllListeners=f,d.emit=f,d.prependListener=f,d.prependOnceListener=f,d.listeners=function(e){return[]},d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},{}],3:[function(e,n,t){n.exports=function(e,n){function t(e,r){return e.reduce(function(e,o){return Array.isArray(o)&&r<n?e.concat(t(o,r+1)):e.concat(o)},[])}return(n="number"==typeof n?n:1/0)?t(e,1):Array.isArray(e)?e.map(function(e){return e}):e}},{}],4:[function(e,n,t){function r(e,n,t){for(var r=0,o=e.length;r<o;r++)c.call(e,r)&&n.call(t,e[r],r,e)}function o(e,n,t){for(var r=0,o=e.length;r<o;r++)n.call(t,e.charAt(r),r,e)}function i(e,n,t){for(var r in e)c.call(e,r)&&n.call(t,e[r],r,e)}var u=e("is-function");n.exports=function(e,n,t){if(!u(n))throw new TypeError("iterator must be a function");arguments.length<3&&(t=this),"[object Array]"===s.call(e)?r(e,n,t):"string"==typeof e?o(e,n,t):i(e,n,t)};var s=Object.prototype.toString,c=Object.prototype.hasOwnProperty},{"is-function":6}],5:[function(e,n,t){(function(e){var t;t="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{},n.exports=t}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],6:[function(e,n,t){n.exports=function(e){var n=r.call(e);return"[object Function]"===n||"function"==typeof e&&"[object RegExp]"!==n||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)};var r=Object.prototype.toString},{}],7:[function(e,n,t){var r=e("trim"),o=e("for-each"),i=function(e){return"[object Array]"===Object.prototype.toString.call(e)};n.exports=function(e){if(!e)return{};var n={};return o(r(e).split("\n"),function(e){var t=e.indexOf(":"),o=r(e.slice(0,t)).toLowerCase(),u=r(e.slice(t+1));void 0===n[o]?n[o]=u:i(n[o])?n[o].push(u):n[o]=[n[o],u]}),n}},{"for-each":4,trim:9}],8:[function(e,n,t){(function(e){n.exports=function(n,t,r){function o(n){function t(){r&&r(n,u),r=null}l?e.nextTick(t):t()}function i(e,t,r){if(u[e]=r,t&&(f=!0),0==--c||t)o(t);else if(!f&&p<s){var l;a?(l=a[p],p+=1,n[l](function(e,n){i(l,e,n)})):(l=p,p+=1,n[l](function(e,n){i(l,e,n)}))}}if("number"!=typeof t)throw new Error("second argument must be a Number");var u,s,c,a,f,l=!0;Array.isArray(n)?(u=[],c=s=n.length):(a=Object.keys(n),u={},c=s=a.length);var p=t;c?a?a.some(function(e,r){if(n[e](function(n,t){i(e,n,t)}),r===t-1)return!0}):n.some(function(e,n){if(e(function(e,t){i(n,e,t)}),n===t-1)return!0}):o(null),l=!1}}).call(this,e("_process"))},{_process:2}],9:[function(e,n,t){(t=n.exports=function(e){return e.replace(/^\s*|\s*$/g,"")}).left=function(e){return e.replace(/^\s*/,"")},t.right=function(e){return e.replace(/\s*$/,"")}},{}],10:[function(e,n,t){"use strict";function r(e){for(var n in e)if(e.hasOwnProperty(n))return!1;return!0}function o(e,n,t){var r=e;return a(n)?(t=n,"string"==typeof e&&(r={uri:e})):r=l(n,{uri:e}),r.callback=t,r}function i(e,n,t){return n=o(e,n,t),u(n)}function u(e){function n(){var e=void 0;if(e=a.response?a.response:a.responseText||s(a),g)try{e=JSON.parse(e)}catch(e){}return e}function t(e){return clearTimeout(d),e instanceof Error||(e=new Error(""+(e||"Unknown XMLHttpRequest Error"))),e.statusCode=0,c(e,b)}function o(){if(!p){var t;clearTimeout(d),t=e.useXDR&&void 0===a.status?200:1223===a.status?204:a.status;var r=b,o=null;return 0!==t?(r={body:n(),statusCode:t,method:y,headers:{},url:h,rawRequest:a},a.getAllResponseHeaders&&(r.headers=f(a.getAllResponseHeaders()))):o=new Error("Internal XMLHttpRequest Error"),c(o,r,r.body)}}if(void 0===e.callback)throw new Error("callback argument missing");var u=!1,c=function(n,t,r){u||(u=!0,e.callback(n,t,r))},a=e.xhr||null;a||(a=e.cors||e.useXDR?new i.XDomainRequest:new i.XMLHttpRequest);var l,p,d,h=a.url=e.uri||e.url,y=a.method=e.method||"GET",m=e.body||e.data,w=a.headers=e.headers||{},v=!!e.sync,g=!1,b={body:void 0,headers:{},statusCode:0,method:y,url:h,rawRequest:a};if("json"in e&&!1!==e.json&&(g=!0,w.accept||w.Accept||(w.Accept="application/json"),"GET"!==y&&"HEAD"!==y&&(w["content-type"]||w["Content-Type"]||(w["Content-Type"]="application/json"),m=JSON.stringify(!0===e.json?m:e.json))),a.onreadystatechange=function(){4===a.readyState&&setTimeout(o,0)},a.onload=o,a.onerror=t,a.onprogress=function(){},a.onabort=function(){p=!0},a.ontimeout=t,a.open(y,h,!v,e.username,e.password),v||(a.withCredentials=!!e.withCredentials),!v&&e.timeout>0&&(d=setTimeout(function(){if(!p){p=!0,a.abort("timeout");var e=new Error("XMLHttpRequest timeout");e.code="ETIMEDOUT",t(e)}},e.timeout)),a.setRequestHeader)for(l in w)w.hasOwnProperty(l)&&a.setRequestHeader(l,w[l]);else if(e.headers&&!r(e.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in e&&(a.responseType=e.responseType),"beforeSend"in e&&"function"==typeof e.beforeSend&&e.beforeSend(a),a.send(m||null),a}function s(e){if("document"===e.responseType)return e.responseXML;var n=e.responseXML&&"parsererror"===e.responseXML.documentElement.nodeName;return""!==e.responseType||n?null:e.responseXML}var c=e("global/window"),a=e("is-function"),f=e("parse-headers"),l=e("xtend");n.exports=i,i.XMLHttpRequest=c.XMLHttpRequest||function(){},i.XDomainRequest="withCredentials"in new i.XMLHttpRequest?i.XMLHttpRequest:c.XDomainRequest,function(e,n){for(var t=0;t<e.length;t++)n(e[t])}(["get","put","post","patch","head","delete"],function(e){i["delete"===e?"del":e]=function(n,t,r){return t=o(n,t,r),t.method=e.toUpperCase(),u(t)}})},{"global/window":5,"is-function":6,"parse-headers":7,xtend:11}],11:[function(e,n,t){n.exports=function(){for(var e={},n=0;n<arguments.length;n++){var t=arguments[n];for(var o in t)r.call(t,o)&&(e[o]=t[o])}return e};var r=Object.prototype.hasOwnProperty},{}]},{},[1])(1)});