blob: 769cff32ef5e581e52598a5d2a01711fe9207853 [file] [log] [blame]
/*********************************************************************
* Copyright (c) 2019 The University of York.
*
* This program and the accompanying materials are made
* available under the terms of the Eclipse Public License 2.0
* which is available at https://www.eclipse.org/legal/epl-2.0/
*
* SPDX-License-Identifier: EPL-2.0
**********************************************************************/
package org.eclipse.epsilon.executors.egl;
import org.eclipse.epsilon.egl.EglTemplateFactory;
import org.eclipse.epsilon.egl.EglTemplateFactoryModuleAdapter;
import org.eclipse.epsilon.executors.AbstractLanguageExecutor;
import org.eclipse.epsilon.eol.exceptions.EolRuntimeException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
/**
* The EGL executor
* @author Horacio Hoyos Rodriguez
*/
public class EglExecutor extends AbstractLanguageExecutor {
private static final Logger logger = LoggerFactory.getLogger(EglExecutor.class);
public EglExecutor() {
super(new EglTemplateFactoryModuleAdapter(new EglTemplateFactory()));
logger.info("Creating the EglStandaloneEngine");
}
@Override
public void postProcess() {
System.out.println(result);
}
@Override
protected String executeInternal() throws EolRuntimeException {
logger.info("Executing EGL template.");
return (String) getModule().execute();
}
}