// Path: com.gregorbyte.buildxpages.ant/src/com/gregorbyte/buildxpages/task/ControlHttpBxpTask.java
// public class ControlHttpBxpTask extends AbstractBxTask {
// 
// 	private static final String ACTION_START = "start";
// 	private static final String ACTION_STOP = "stop";
// 	private static final String ACTION_RESTART = "restart";
// 
// 	private static final String CMD_START = "load http";
// 	private static final String CMD_STOP = "tell http quit";
// 	private static final String CMD_RESTART = "restart task http";
// 
// 	private String server;
// 	private String action;
// 
// 	public ControlHttpBxpTask(String server, String action) {
// 		this.server = server;
// 		this.action = action;
// 	}
// 
// 	public String getConsoleCommand() {
// 
// 		if (action == null)
// 			return null;
// 
// 		if (action.equalsIgnoreCase(ACTION_START)) {
// 			return CMD_START;
// 		} else if (action.equalsIgnoreCase(ACTION_STOP)) {
// 			return CMD_STOP;
// 		} else if (action.equalsIgnoreCase(ACTION_RESTART)) {
// 			return CMD_RESTART;
// 		}
// 
// 		return null;
// 	}
// 
// 	@Override
// 	protected void doTask() {
// 
// 		String command = getConsoleCommand();
// 
// 		if (command == null)
// 			throw new RuntimeException(
// 					"Could not determine action: must be start, stop or restart");
// 
// 		NotesNativeLibrary notes = NotesNativeLibrary.SYNC_INSTANCE;
// 
// 		IntByReference retInfo = new IntByReference();
// 		notes.NSFRemoteConsole(server, command, retInfo);
// 
// 	}
// 
// }


import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.Task;
import com.gregorbyte.buildxpages.task.ControlHttpBxpTask;
package com.gregorbyte.buildxpages.ant;



public class ControlHttpTask extends Task {

	private String server;
	private String action;

	public void setServer(String server) {
		this.server = server;
	}

	public void setAction(String action) {
		this.action = action;
	}

	@Override
	public void execute() throws BuildException {

// Path: com.gregorbyte.buildxpages.ant/src/com/gregorbyte/buildxpages/task/ControlHttpBxpTask.java
// public class ControlHttpBxpTask extends AbstractBxTask {
// 
// 	private static final String ACTION_START = "start";
// 	private static final String ACTION_STOP = "stop";
// 	private static final String ACTION_RESTART = "restart";
// 
// 	private static final String CMD_START = "load http";
// 	private static final String CMD_STOP = "tell http quit";
// 	private static final String CMD_RESTART = "restart task http";
// 
// 	private String server;
// 	private String action;
// 
// 	public ControlHttpBxpTask(String server, String action) {
// 		this.server = server;
// 		this.action = action;
// 	}
// 
// 	public String getConsoleCommand() {
// 
// 		if (action == null)
// 			return null;
// 
// 		if (action.equalsIgnoreCase(ACTION_START)) {
// 			return CMD_START;
// 		} else if (action.equalsIgnoreCase(ACTION_STOP)) {
// 			return CMD_STOP;
// 		} else if (action.equalsIgnoreCase(ACTION_RESTART)) {
// 			return CMD_RESTART;
// 		}
// 
// 		return null;
// 	}
// 
// 	@Override
// 	protected void doTask() {
// 
// 		String command = getConsoleCommand();
// 
// 		if (command == null)
// 			throw new RuntimeException(
// 					"Could not determine action: must be start, stop or restart");
// 
// 		NotesNativeLibrary notes = NotesNativeLibrary.SYNC_INSTANCE;
// 
// 		IntByReference retInfo = new IntByReference();
// 		notes.NSFRemoteConsole(server, command, retInfo);
// 
// 	}
// 
// }


// Path: com.gregorbyte.buildxpages.ant/src/com/gregorbyte/buildxpages/ant/ControlHttpTask.java
import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.Task;
import com.gregorbyte.buildxpages.task.ControlHttpBxpTask;

package com.gregorbyte.buildxpages.ant;



public class ControlHttpTask extends Task {

	private String server;
	private String action;

	public void setServer(String server) {
		this.server = server;
	}

	public void setAction(String action) {
		this.action = action;
	}

	@Override
	public void execute() throws BuildException {

		ControlHttpBxpTask task = new ControlHttpBxpTask(server, action);