Custom Gis Application with Arcgis Javascript API with modern layouting
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

6 lines
1.4 KiB

// All material copyright Esri, All Rights Reserved, unless otherwise specified.
// See https://js.arcgis.com/4.30/esri/copyright.txt for details.
//>>built
define(["exports","../../../geometry/GeometryCursor","../CIMCursor","../CurveHelper"],function(h,n,p,q){class d{static local(){null===d.instance&&(d.instance=new d);return d.instance}execute(a,b,c,e,f){return new r(a,b,c)}}d.instance=null;class r extends p.PathEffectCursor{constructor(a,b,c){super(a,!1,!0);this._curveHelper=new q.CurveHelper;this._length=(void 0!==b.length?b.length:20)*c;this._angle=void 0!==b.angle?b.angle:225;this._position=void 0!==b.position?b.position:50;0>this._length&&(this._length=
-this._length);20>this._position&&(this._position=20);80<this._position&&(this._position=80);this._mirror=!1}processPath(a){const b=n.GeometryCursor.createEmptyOptimizedCIM("esriGeometryPolyline");if(this._curveHelper.isEmpty(a))return null;a.seekInPath(0);const c=a.x,e=a.y;a.seekInPath(a.pathSize-1);const f=a.x;a=a.y;this._curveHelper.normalize([f-c,a-e]);const k=c+(f-c)*this._position/100,l=e+(a-e)*this._position/100,m=Math.cos((90-this._angle)/180*Math.PI);let g=Math.sin((90-this._angle)/180*Math.PI);
this._mirror&&(g=-g);this._mirror=!this._mirror;b.pushPath([[c,e],[k-this._length/2*m,l-this._length/2*g],[k+this._length/2*m,l+this._length/2*g],[f,a]]);return b}}h.EffectJog=d;Object.defineProperty(h,Symbol.toStringTag,{value:"Module"})});