public interface IHook { /// <summary> /// 二维地图控件对象 /// </summary> ESRI.ArcGIS.Controls.IMapControl4 MapControl { get; set; } }
public class HookHelper: IHook { private static HookHelper mHookHelper = null; private HookHelper() { } public static HookHelper GetInstance() { if (mHookHelper == null) { mHookHelper = new HookHelper(); } return HookHelper; } public IEventAggregator EventAggregator { get; set; } public ESRI.ArcGIS.Controls.IMapControl4 MapControl { get; set; } public ESRI.ArcGIS.Carto.IMap Map { get; set; } }
从一个黑箱中有引n条线。