code: public static void setImageLink(String path, Map<String, String> attributes, String linkPath, String target) {
  
          CmsJSONMap attributesJS = CmsJSONMap.createJSONMap();
          for (Entry<String, String> entry : attributes.entrySet()) {
              attributesJS.put(entry.getKey(), entry.getValue());
          }
          nativeSetImageLink(path, attributesJS, linkPath, target);
      }
docs: Sets the image link within the rich text editor (FCKEditor, CKEditor, ...).<p>
  
  @param path the image path
  @param attributes the image tag attributes
  @param linkPath the link path
  @param target the link target attribute