package futils;
import java.io.File;
public class Server {
private static String serverPath;
public static void main(String args[]) {
startServer(args);
}
public static void setServerPath() {
File f =
Futil.getReadFile("locate webserver.xml");
serverPath = f.getParent();
}
public static void checkResources() {
File f = new File("webserver.xml");
if (f.exists()) {
serverPath = f.getParent();
return;
}
setServerPath();
}
public static void startServer(String args[]) {
checkResources();
if (args != null) {
com.sun.web.shell.Startup.main(args);
return;
}
startServer();
}
public static void startServer() {
String args[] ={serverPath};
startServer(args);
}
}