@Override
public Map<String, Object> getOptions(FacesContext facesContext, UIComponent component) {
Map<String, Object> options = new HashMap<String, Object>();
if (component instanceof AbstractDropTarget) {
JSReference dragSourceId = new JSReference("dragSourceId");
JSFunctionDefinition function = new JSFunctionDefinition(JSReference.EVENT, dragSourceId);
AjaxFunction ajaxFunction = AjaxRendererUtils.buildAjaxFunction(facesContext, component);
ajaxFunction.getOptions().setParameter("dragSource", dragSourceId);
ajaxFunction.getOptions().setParameter(component.getClientId(facesContext), component.getClientId(facesContext));
ajaxFunction.setSource(new JSReference("event", "target"));
ajaxFunction.getOptions().setAjaxComponent(component.getClientId(facesContext));
function.addToBody(ajaxFunction);
AbstractDropTarget dropTarget = (AbstractDropTarget) component;
Set<String> acceptedTypes = Sets.asSet(dropTarget.getAcceptedTypes());