ArcGIS for JavaScript API default parameters

Source: Internet
Author: User

"Esri.config" is a substitute for "esriconfig" in version 1.3. If you are using a version of 1.2 or lower, you should refer to the default API v1.2 and lower configuration. For version 1.3 or later, you can use "esri.config" in place of "Esriconfig". Although "Esriconfig" can continue to be used, with version 1.3, you should update your application instead of using "Esri.config".
There are some default configurations in the JavaScript API of ArcGIS that can be rewritten programmatically.
For example:
var zoomsymbol = new esri.symbol.SimpleFillSymbol ( Esri.symbol.SimpleFillSymbol.STYLE_SOLID,
                         New Esri.symbol.SimpleLineSymbol (
                                          Esri.symbol.SimpleLineSymbol.STYLE_DASHDOT, New Dojo. Color ([0, 0, 255]), 0.5]);
        Esri.config.defaults.map.zoomSymbol = Zoomsymbol.tojson ();

The following list contains the default JavaScript API configurations.
(1)Esri.config.defaults.io.alwaysUseProxy No matter how you use proxies: default: false
EsriConfig.defaults.io.alwaysUseProxy = true;
(2) Esri.config.defaults.io.corsEnabledServers adds the URL of the server to this array that enables cross-domain resource sharing. A cross-domain resource sharing (CORS) Web application can bypass the browser's same origin policy file and access resources or services on different servers/domains. When the Web server and browser support Cors,esri.request will not use the proxy to perform cross-domain requests. The API provides some of the ESRI's servers by default, so it is important to push to this array instead of overwriting its items.

(3) Esri.config.defaults.geometryService specifies the parts and operations used by the default geometry service. (2.2)
Esri.config.defaults.geometryService = new Esri.tasks.GeometryService (< input geometry service URL >);
(4) The location of the endpoint proxy URL for a large payload should be used when the ESRI.CONFIG.DEFAULTS.IO.PROXYURL is released. This must be in an HTML application in the same domain.default: null
ESRICONFIG.DEFAULTS.IO.PROXYURL = "/arcgisserver/apis/javascript/proxy/proxy.ashx";
(5) The maximum allowable time for each esri.config.defaults.io.timeout is 60 seconds per request through Esri.request. If no response is returned or a server-side error is returned,
Esri. Error and errors return the order in which handlers are called. (1.3)default: 60 Seconds
(6) Esri.config.defaults.map.panDuration The length of time (in milliseconds) that the map will take to translate. Default: 350
(7) Esri.config.defaults.map.panRate The length of time (in milliseconds), which is refreshed on the map because it pans to the next area.Default:
(8) The Esri.config.defaults.map.slider parameter defines the position, size and orientation of the slide.
default: {left: "30px", Top: "30px", Width:null,height: "200px"}
(9) Esri.config.defaults.map.sliderLabel defines the slider scale for the parameters and the corresponding tick mark. If NULL, the slider displays the scale.
defaults: Default: {tick:5,labels:null,style: "WIDTH:2EM; Font-family:verdana; font-size:75%; "}
Esri.config.defaults.map.zoomDuration the length of time, in milliseconds, of the map magnification.Default:
(one) esri.config.defaults.map.zoomRate the length of time, in milliseconds, to enlarge the next map to be refreshed.Default:
Esri.config.defaults.map.zoomSymbol Simplefillsymbol uses the rubber zoom that represents the color, fill, and profile properties.
This is the JSON representation of the Simplefillsymbol.
defaults: Default: {color:[0,0,0,64],outline:{color:[255,0,0,255],width:1.5,style: "Esrislssolid"},style: " Esrisfssolid "}

ArcGIS for JavaScript API default parameters

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.