Use Server name and version directly from helma.main.Server.version

instead of having a separate server anme and version fields.
This commit is contained in:
hns 2002-02-25 16:02:10 +00:00
parent 41abbaa3ad
commit 1db50720f7
2 changed files with 6 additions and 6 deletions

View file

@ -457,8 +457,7 @@ public class Serve implements ServletContext, Runnable
// Same as the CGI variable SERVER_SOFTWARE.
public String getServerInfo()
{
return ServeUtils.serverName + " " + ServeUtils.serverVersion +
" (" + ServeUtils.serverUrl + ")";
return helma.main.Server.version + " (" + ServeUtils.serverUrl + ")";
}
/// Returns the value of the named attribute of the network service, or
@ -685,7 +684,7 @@ class ServeConnection implements Runnable, HttpServletRequest, HttpServletRespon
setStatus( SC_OK );
setDateHeader( "Date", System.currentTimeMillis() );
setHeader(
"Server", ServeUtils.serverName + "/" + ServeUtils.serverVersion );
"Server", helma.main.Server.version );
setHeader( "Connection", "close" );
try
{

View file

@ -42,8 +42,9 @@ public class ServeUtils
{
// Server identification.
public static final String serverName = "Helma";
public static final String serverVersion = "1.2 p1";
// public static final String serverName = "Helma";
// public static final String serverVersion = "1.2 p1";
// we're using the server version from helma.main.Server class.
public static final String serverUrl = "http://helma.org/";
/// Write a standard-format HTML address for this server.
@ -52,7 +53,7 @@ public class ServeUtils
PrintStream p = new PrintStream( o );
p.println(
"<ADDRESS><A HREF=\"" + serverUrl + "\">" +
serverName + " " + serverVersion + "</A></ADDRESS>" );
helma.main.Server.version + "</A></ADDRESS>" );
}