${iServerJava6R_QueryByGeometryService_Tile}

${iServerJava6R_QueryByGeometryService_Description}

Inheritance: QueryService
        //几何对象绘制结束触发事件
        private void DrawCompleted(object sender, DrawEventArgs e)
        {
            //隐藏 FeatureDataGrid 控件
            MyDataGrid.Visibility = Visibility.Collapsed;

            //设置几何查询参数,FilterParameters、Geometry 和 SpatialQueryMode 为必设属性
            QueryByGeometryParameters parameter = new QueryByGeometryParameters
            {
                FilterParameters = new List<FilterParameter>()
                {
                        new FilterParameter()
                       {
                           Name = "Countries@World",
                       }
                },
                Geometry = e.Geometry,
                SpatialQueryMode = SpatialQueryMode.INTERSECT,

                //设置是返回查询结果资源(false)还是返回查询结果记录集(true)
                ReturnContent = notHighlight
            };

            //与服务器交互
            QueryByGeometryService service = new QueryByGeometryService(url);
            service.ProcessAsync(parameter);
            service.ProcessCompleted += new EventHandler<QueryEventArgs>(service_ProcessCompleted);
            service.Failed += new EventHandler<ServiceFailedEventArgs>(service_Failed);

            //当在 FeaturesLayer 上通过鼠标左键点击触发的事件
            flayer.MouseLeftButtonDown += flayer_MouseLeftButtonDown;
        }
 private void sp_Click(object sender, RoutedEventArgs e)
 {
     QueryByGeometryParameters param = new QueryByGeometryParameters
     {
         FilterParameters = new List<FilterParameter>()
             {
                 new FilterParameter()
                {
                    Name = "World@World",
                }
             },
         ReturnContent = false,
         Geometry = new GeoRegion()
         {
             Parts = new ObservableCollection<Point2DCollection>()
         { new Point2DCollection()
         {
             new Point2D(0, 0),
             new Point2D(20, 0),
             new Point2D(20, 20),
             new Point2D(0, 20)
         }
         }
         },
         SpatialQueryMode = SpatialQueryMode.INTERSECT
     };
     QueryByGeometryService sp = new QueryByGeometryService(url);
     sp.ProcessAsync(param);
     sp.ProcessCompleted += new EventHandler<QueryEventArgs>(service_ProcessCompleted);
     sp.Failed += new EventHandler<ServiceFailedEventArgs>(service_Failed);
 }