public void dispatchMessage(android.os.Message msg) {
          try {
            jsonArray = new JSONArray(jsonResult);
            points.clear();
            for (int i = 0; i < jsonArray.length(); i++) {
              Point startpt =
                  new Point(
                      StringToDouble(jsonArray.getJSONObject(i).getString("LONG1")),
                      StringToDouble(jsonArray.getJSONObject(i).getString("LAT"))); // 创建一个点对象
              points.add(startpt);
              Graphic startgp =
                  new Graphic(
                      startpt,
                      new PictureMarkerSymbol(
                          context.getResources().getDrawable(R.drawable.mark))); // 设置样式
              GetGraphicLayer(mapView).addGraphic(startgp);
              sx = sy = ex = ey = 0;
              SelectionView.this.invalidate();
            }
            final Callout callout = mapView.getCallout(); // 通过MapView获取Callout实例对象
            callout.setStyle(R.xml.callout_style); // 为Callout设置样式文件
            final View popView =
                ((Activity) context).getLayoutInflater().inflate(R.layout.pop_entinfo, null);
            mapView.setOnSingleTapListener(
                new OnSingleTapListener() {
                  private static final long serialVersionUID = 1L;

                  @Override
                  public void onSingleTap(float x, float y) {
                    int gapOldValue = 1000;
                    int currentIndex = -1;
                    for (int i = 0; i < points.size(); i++) {
                      Point targetPoint = mapView.toScreenPoint(points.get(i));
                      int gapValue =
                          (int)
                              ((x - targetPoint.getX()) * (x - targetPoint.getX())
                                  + (y - targetPoint.getY()) * (y - targetPoint.getY()));
                      if (gapOldValue > gapValue) {
                        currentIndex = i;
                        gapOldValue = gapValue;
                      }
                    }
                    callout.setMaxHeight(700);
                    callout.setMaxWidth(1500);
                    callout.hide();
                    callout.setOffset(0, -15); // 设置偏移量
                    try {
                      ((TextView) popView.findViewById(R.id.content))
                          .setText(
                              "公司名称 :"
                                  + jsonArray.getJSONObject(currentIndex).getString("NAME")
                                  + "\n"
                                  + "公司地址 :"
                                  + jsonArray.getJSONObject(currentIndex).getString("ADDRESS")
                                  + "\n"
                                  + "企业注册号 :"
                                  + jsonArray.getJSONObject(currentIndex).getString("ENROL"));
                      callout.show(points.get(currentIndex), popView); // 设置弹出窗显示的内容
                    } catch (Exception e) {
                      e.printStackTrace();
                    }
                  }
                });
          } catch (JSONException e) {
            e.printStackTrace();
          }
        }