No, I understood your point, I was just saying that because the default behavior of 
this client is different already (local, not 
remote-to-"http://localhost:8080/axis/servlet/AxisServlet";), having to type the extra 
"-l" to be consistent with some of the other clients in setting a remote URL didn't 
seem like that big a deal.

In thinking about it a bit more, I could see the user/pw options being useful for 
doing this for a protected server too, so I'll add setting this up with Options to the 
TODO list.  If you're psyched to do it, go for it!

--G

> -----Original Message-----
> From: Doug Davis [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, March 20, 2002 11:28 AM
> To: [EMAIL PROTECTED]
> Subject: RE: cvs commit: xml-axis/java/src/org/apache/axis 
> Version.java
> 
> 
> You missed my point - for the no arg case use the default to get the
> client version.  But the going to a server (from a usability point of
> view) having the same command line args for all samples/exes
> make it easier for people.   And that's what the Options class
> is there for, but to each his own...
> -Dug
> 
> 
> Glen Daniels <[EMAIL PROTECTED]> on 03/20/2002 11:23:32 AM
> 
> Please respond to [EMAIL PROTECTED]
> 
> To:    "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
> cc:
> Subject:    RE: cvs commit: xml-axis/java/src/org/apache/axis 
> Version.java
> 
> 
> 
> 
> Hi Doug:
> 
> I explicitly want the default behavior of this class to be getting the
> *local* version (i.e. the client), not querying a remote server, so it
> seemed simpler to just do that in the no-arg case, and take a 
> URL for the
> case where you want to do it remotely.  I suppose we could 
> use options to
> match the "-l" syntax, but it didn't quite seem worth it for this.
> 
> --Glen
> 
> > -----Original Message-----
> > From: Doug Davis [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, March 20, 2002 11:17 AM
> > To: [EMAIL PROTECTED]
> > Subject: Re: cvs commit: xml-axis/java/src/org/apache/axis
> > Version.java
> >
> >
> > Glen - if you use the Options class it will default the to
> > the proper URL.
> > Plus then changing it will match the other samples' cmd 
> line options.
> > -Dug
> >
> >
> > [EMAIL PROTECTED] on 03/20/2002 11:14:30 AM
> >
> > Please respond to [EMAIL PROTECTED]
> >
> > To:    [EMAIL PROTECTED]
> > cc:
> > Subject:    cvs commit: xml-axis/java/src/org/apache/axis 
> Version.java
> >
> >
> >
> > gdaniels    02/03/20 08:14:29
> >
> >   Modified:    java/src/org/apache/axis Version.java
> >   Log:
> >   Add the ability to query a remote Axis server for its version.
> >
> >   Revision  Changes    Path
> >   1.3       +18 -1     
> xml-axis/java/src/org/apache/axis/Version.java
> >
> >   Index: Version.java
> >   
> ===================================================================
> >   RCS file: 
> /home/cvs/xml-axis/java/src/org/apache/axis/Version.java,v
> >   retrieving revision 1.2
> >   retrieving revision 1.3
> >   diff -u -r1.2 -r1.3
> >   --- Version.java      14 Feb 2002 23:01:48 -0000    1.2
> >   +++ Version.java      20 Mar 2002 16:14:29 -0000    1.3
> >   @@ -56,6 +56,7 @@
> >    package org.apache.axis;
> >
> >    import org.apache.axis.utils.JavaUtils;
> >   +import org.apache.axis.client.Call;
> >
> >    /**
> >     * Little utility to get the version and build date of the
> > axis.jar.
> >   @@ -72,7 +73,23 @@
> >                   JavaUtils.getMessage("builtOn");
> >        }
> >
> >   +    /**
> >   +     * Entry point.
> >   +     *
> >   +     * Calling this with no arguments returns the version of the
> >   client-side
> >   +     * axis.jar.  Passing a URL which points to a remote
> > Axis server
> >   will
> >   +     * attempt to retrieve the version of the server via a
> > SOAP call.
> >   +     */
> >        public static void main(String[] args) {
> >   -        System.out.println(getVersion());
> >   +        if (args.length != 1)
> >   +            System.out.println(getVersion());
> >   +
> >   +        try {
> >   +            Call call = new Call(args[0]);
> >   +            String result = (String)call.invoke("Version",
> > "getVersion",
> >   null);
> >   +            System.out.println(result);
> >   +        } catch (Exception e) {
> >   +            e.printStackTrace();
> >   +        }
> >        }
> >    }
> >
> >
> >
> >
> >
> 
> 

Reply via email to