package org.gcube.portlets.user.geoportaldataentry.client.events; import java.util.List; import org.gcube.application.geoportalcommon.shared.geoportal.HandlerDeclarationDV; import org.gcube.application.geoportalcommon.shared.geoportal.config.GcubeProfileDV; import com.google.gwt.event.shared.GwtEvent; /** * The Class CreateNewProjectEvent. * * @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it * * Mar 17, 2022 */ public class CreateNewProjectEvent extends GwtEvent { /** The type. */ public static Type TYPE = new Type(); private HandlerDeclarationDV handler; private List listGcubeProfiles; /** * Instantiates a new creates the new project event. * * @param handler the handler * @param listGcubeProfiles the list gcube profiles */ // (passing this second argument in order to avoid twice the casting as // List) public CreateNewProjectEvent(HandlerDeclarationDV handler, List listGcubeProfiles) { this.handler = handler; this.listGcubeProfiles = listGcubeProfiles; } /** * Gets the associated type. * * @return the associated type */ /* * (non-Javadoc) * * @see com.google.gwt.event.shared.GwtEvent#getAssociatedType() */ @Override public Type getAssociatedType() { return TYPE; } /** * Dispatch. * * @param handler the handler */ /* * (non-Javadoc) * * @see * com.google.gwt.event.shared.GwtEvent#dispatch(com.google.gwt.event.shared. * EventHandler) */ @Override protected void dispatch(CreateNewProjectEventHandler handler) { handler.onCreateNewProject(this); } public HandlerDeclarationDV getHandler() { return handler; } /** * Gets the list gcube profiles. * * @return the list gcube profiles */ public List getListGcubeProfiles() { return listGcubeProfiles; } }