howdy.java

来自「Howdy Communication System的目的是提供一个简单、易用的」· Java 代码 · 共 66 行

JAVA
66
字号
package Howdy;/*    This file is part of Howdy.    Howdy is free software; you can redistribute it and/or modify    it under the terms of the GNU General Public License as published by    the Free Software Foundation; either version 2 of the License, or    (at your option) any later version.    Howdy is distributed in the hope that it will be useful,    but WITHOUT ANY WARRANTY; without even the implied warranty of    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the    GNU General Public License for more details.    You should have received a copy of the GNU General Public License    along with Foobar; if not, write to the Free Software    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA*/import java.io.*;public class Howdy // Gives the user a choice between starting the server or client.{	public static void main(String[] args) throws IOException	{		Server server;		Client client;		int version = 2;		//BufferedReader in = new BufferedReader( new InputStreamReader(System.in) );		//String input;		System.out.println("Howdy version " + version + ", Copyright (C) 2003-2004 Serban Giuroiu");		System.out.println("Howdy comes with ABSOLUTELY NO WARRANTY; for details see  the `COPYING' file.");		System.out.println("This is free software, and you are welcome to redistribute it under certain ");		System.out.println("conditions; see the 'COPYING' file for details.\n");		if( args.length > 0 && args[0].equals("s") )			server = new Server(version);		else //if( args.length > 0 && args[0].equals("c") )		{			System.out.println("If you want to run the server, give the \'s\' argument next time.\n");			client = new Client(version);		}		/*else		{			System.out.println("Valid argument needed!\n");			System.out.println("The possibilities are...");			System.out.println("s\tStart the server.");			System.out.println("c\tStart the client.");			System.out.print("\nSo what shall it be, master? ");			input = in.readLine();			if( input.toLowerCase().equals("s") )				server = new Server(version);			else if( input.toLowerCase().equals("c") )				client = new Client(version);			else				System.out.println("Invalid input.");		}*/	}}// Copyright (C) 2003-2004 Serban Giuroiu

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?