67 lines
1.7 KiB
Java
67 lines
1.7 KiB
Java
package org.gcube.portlets.user.statisticalalgorithmsimporter.client.event;
|
|
|
|
import org.gcube.portlets.user.statisticalalgorithmsimporter.shared.project.InputData;
|
|
|
|
import com.google.gwt.event.shared.EventHandler;
|
|
import com.google.gwt.event.shared.GwtEvent;
|
|
import com.google.gwt.event.shared.HandlerRegistration;
|
|
import com.google.gwt.event.shared.HasHandlers;
|
|
|
|
/**
|
|
* Input Save Ready Event
|
|
*
|
|
*
|
|
* @author "Giancarlo Panichi" <a
|
|
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
|
*
|
|
*/
|
|
public class InputSaveReadyEvent extends
|
|
GwtEvent<InputSaveReadyEvent.InputSaveReadyEventHandler> {
|
|
|
|
public static Type<InputSaveReadyEventHandler> TYPE = new Type<InputSaveReadyEventHandler>();
|
|
private InputData inputData;
|
|
|
|
public interface InputSaveReadyEventHandler extends EventHandler {
|
|
void onInputSaveReady(InputSaveReadyEvent event);
|
|
}
|
|
|
|
public interface HasInputSaveReadyEventHandler extends HasHandlers {
|
|
public HandlerRegistration addInputSaveReadyEventHandler(
|
|
InputSaveReadyEventHandler handler);
|
|
}
|
|
|
|
public InputSaveReadyEvent(InputData inputData) {
|
|
this.inputData = inputData;
|
|
}
|
|
|
|
@Override
|
|
protected void dispatch(InputSaveReadyEventHandler handler) {
|
|
handler.onInputSaveReady(this);
|
|
}
|
|
|
|
@Override
|
|
public Type<InputSaveReadyEventHandler> getAssociatedType() {
|
|
return TYPE;
|
|
}
|
|
|
|
public static Type<InputSaveReadyEventHandler> getType() {
|
|
return TYPE;
|
|
}
|
|
|
|
public static void fire(HasHandlers source,
|
|
InputSaveReadyEvent inputSaveReadyEvent) {
|
|
source.fireEvent(inputSaveReadyEvent);
|
|
}
|
|
|
|
public InputData getInputData() {
|
|
return inputData;
|
|
}
|
|
|
|
@Override
|
|
public String toString() {
|
|
return "InputSaveReadyEvent [inputData=" + inputData + "]";
|
|
}
|
|
|
|
|
|
}
|