Object url = getAttributes().getAttribute(Attribute.SRC); if (url == null) return null;
Element el = getElement(); String src = (String) el.getAttributes().getAttribute(Attribute.SRC); URL url = null; if (src != null) { URL base = ((HTMLDocument) getDocument()).getBase();
  public URL getImageURL()  {    Object url = getAttributes().getAttribute(Attribute.SRC);    if (url == null)      return null;    try      {        return new URL(url.toString());      }    catch (MalformedURLException e)      {        // The URL is malformed - no image.        return null;      }  }