You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by th...@apache.org on 2006/10/09 13:59:20 UTC
svn commit: r454350 -
/webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/SimpleHTTPServer.java
Author: thilina
Date: Mon Oct 9 04:59:20 2006
New Revision: 454350
URL: http://svn.apache.org/viewvc?view=rev&rev=454350
Log: (empty)
Modified:
webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/SimpleHTTPServer.java
Modified: webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/SimpleHTTPServer.java
URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/SimpleHTTPServer.java?view=diff&rev=454350&r1=454349&r2=454350
==============================================================================
--- webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/SimpleHTTPServer.java (original)
+++ webservices/axis2/branches/java/1_1/modules/kernel/src/org/apache/axis2/transport/http/SimpleHTTPServer.java Mon Oct 9 04:59:20 2006
@@ -133,12 +133,25 @@
if (paramPort != null) {
port = Integer.parseInt(paramPort);
}
+
boolean startAllTransports = "all".equals(optionsParser.isValueSet('t'));
- args = optionsParser.getRemainingArgs();
+ String repository= optionsParser.isValueSet('r');
+ if (repository ==null)
+ {
+ args = optionsParser.getRemainingArgs();
+ if (args!=null && args[0]!=null && args[0]!="")
+ {
+ repository = args[0];
+ }
+ else
+ {
+ printUsage();
+ }
+ }
System.out.println("[SimpleHTTPServer] Starting");
System.out.println("[SimpleHTTPServer] Using the Axis2 Repository "
- + new File(args[0]).getAbsolutePath());
+ + new File(repository).getAbsolutePath());
System.out.println("[SimpleHTTPServer] Listening on port " + port);
try {
ConfigurationContext configctx = ConfigurationContextFactory.createConfigurationContextFromFileSystem(args[0], null);
@@ -177,11 +190,11 @@
}
public static void printUsage() {
- System.out.println("Usage: SimpleHTTPServer [options] <repository>");
+ System.out.println("Usage: SimpleHTTPServer [options] -r <repository>");
System.out.println(" Opts: -? this message");
System.out.println();
- System.out.println(" -p port to listen on (default is 8080)");
- System.out.println(" -t all to start all transports defined in the axis2 configuration");
+ System.out.println(" -p port :to listen on (default is 8080)");
+ System.out.println(" -t all :to start all transports defined in the axis2 configuration");
System.exit(1);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org