/*
 COPYRIGHT 2009 ESRI

 TRADE SECRETS: ESRI PROPRIETARY AND CONFIDENTIAL
 Unpublished material - all rights reserved under the
 Copyright Laws of the United States and applicable international
 laws, treaties, and conventions.

 For additional information, contact:
 Environmental Systems Research Institute, Inc.
 Attn: Contracts and Legal Services Department
 380 New York Street
 Redlands, California, 92373
 USA

 email: contracts@esri.com
 */

window[esri._dojoScopeName||"dojo"]._xdResourceLoaded(function(_1,_2,_3){return {depends:[["provide","esri.graphic"],["require","esri.geometry"],["require","esri.symbol"]],defineResource:function(_4,_5,_6){if(!_4._hasResource["esri.graphic"]){_4._hasResource["esri.graphic"]=true;_4.provide("esri.graphic");_4.require("esri.geometry");_4.require("esri.symbol");_4.declare("esri.Graphic",null,{constructor:function(_7,_8,_9,_a){if(_7&&!(_7 instanceof esri.geometry.Geometry)){this.geometry=_7.geometry?esri.geometry.fromJson(_7.geometry):null;this.symbol=_7.symbol?esri.symbol.fromJson(_7.symbol):null;this.attributes=_7.attributes||null;this.infoTemplate=_7.infoTemplate?new esri.InfoTemplate(_7.infoTemplate):null;}else{this.geometry=_7;this.symbol=_8;this.attributes=_9;this.infoTemplate=_a;}},_shape:null,_graphicsLayer:null,_visible:true,visible:true,getDojoShape:function(){return this._shape;},getLayer:function(){return this._graphicsLayer;},setGeometry:function(_b){this.geometry=_b;var gl=this._graphicsLayer;if(gl){gl._updateExtent(this);gl._draw(this,true);}return this;},setSymbol:function(_c,_d){var gl=this._graphicsLayer,_e=this._shape;this.symbol=_c;if(_c){this.symbol._stroke=this.symbol._fill=null;}if(gl){if(_d){if(_e){gl._removeShape(this);}gl._draw(this,true);return this;}if(!this.geometry){return this;}var _f=this.geometry.type;if(_f==="point"||_f==="multipoint"){gl._draw(this,true);}else{if(_e){gl._symbolizeShape(this);}}}return this;},setAttributes:function(_10){this.attributes=_10;return this;},setInfoTemplate:function(_11){this.infoTemplate=_11;return this;},_getEffInfoTemplate:function(){var _12=this.getLayer();return this.infoTemplate||(_12&&_12.infoTemplate);},getTitle:function(){var _13=this._getEffInfoTemplate();var _14=_13&&_13.title;if(_4.isFunction(_14)){_14=_14.call(_13,this);}else{if(_4.isString(_14)){var _15=this._graphicsLayer;var _16=_15&&_15._getDateOpts;_14=esri.substitute(this.attributes,_14,{first:true,dateFormat:_16&&_16.call(_15)});}}return _14;},getContent:function(){var _17=this._getEffInfoTemplate();var _18=_17&&_17.content;if(_4.isFunction(_18)){_18=_18.call(_17,this);}else{if(_4.isString(_18)){var _19=this._graphicsLayer;var _1a=_19&&_19._getDateOpts;_18=esri.substitute(this.attributes,_18,{dateFormat:_1a&&_1a.call(_19)});}}return _18;},show:function(){this.visible=this._visible=true;if(this._shape){var _1b=this._shape.getEventSource();if(_1b){esri.show(_1b);}}else{if(this._graphicsLayer){this._graphicsLayer._draw(this,true);}}return this;},hide:function(){this.visible=this._visible=false;var _1c=this._shape;if(_1c){var _1d=_1c.getEventSource();if(_1d){esri.hide(_1d);}else{var _1e=this._graphicsLayer;if(_1e){_1e._removeShape(this);}}}return this;},toJson:function(){var _1f={};if(this.geometry){_1f.geometry=this.geometry.toJson();}if(this.attributes){_1f.attributes=_4.mixin({},this.attributes);}if(this.symbol){_1f.symbol=this.symbol.toJson();}if(this.infoTemplate){_1f.infoTemplate=this.infoTemplate.toJson();}return _1f;}});_4.declare("esri.InfoTemplate",null,{constructor:function(_20,_21){if(_20&&_4.isObject(_20)&&!_4.isFunction(_20)){_4.mixin(this,_20);}else{this.title=_20||"${*}";this.content=_21||"${*}";}},setTitle:function(_22){this.title=_22;return this;},setContent:function(_23){this.content=_23;return this;},toJson:function(){return esri._sanitize({title:this.title,content:this.content});}});}}};});