Files
Flintstones/bundles/flintstones.application.control/src/flintstones/application/control/handler/NewHandler.java
T
Francisco Jesús Martínez Mimbrera 759a8968a2 public code v1
2026-05-23 00:32:57 +02:00

38 lines
877 B
Java

package flintstones.application.control.handler;
import javax.inject.Inject;
import org.eclipse.e4.core.contexts.ContextInjectionFactory;
import org.eclipse.e4.core.contexts.IEclipseContext;
import org.eclipse.e4.core.di.annotations.Execute;
import flintstones.application.model.IApplicationService;
import flintstones.application.handlers.PerspectiveSwitcher;
/**
* The Class NewHandler creates a new proyect.
*/
public class NewHandler {
/** The context. */
@Inject
IEclipseContext context;
/** The app service. */
@Inject
IApplicationService appService;
/**
* Execute.
*
* @throws IOException Signals that an I/O exception has occurred.
*/
@Execute
public void execute() {
this.appService.newProblem();
ContextInjectionFactory.make(PerspectiveSwitcher.class, context).changePerspective("flintstones.application.perspective.framework");
}
}