if(view instanceof CustomEdgeView)
if(graph.getModel().isEdge(cell))
    public void actionPerformed(ActionEvent e)    {      Object cell = graph.getFirstCellForLocation(location.x, location.y);      if(cell == null)      {        return;      }      else      {        CellView view = graph.getGraphLayoutCache().getMapping(cell, false);        if(view instanceof CustomEdgeView)        {          GraphConstants.setForeground(((ResultEdge)cell).getAttributes(), cColor);          view.update();          view.refresh(graph.getModel(), graph.getGraphLayoutCache(), false);          graph.getSelectionModel().setSelectionCell(view.getCell());        }      }    }