5 years ago (2015-06-12)  Algorithm language |   First to comment  4 
post score 0 times, average 0.0
[Slideup] Catalog

Because it is inconvenient to add running parameters in the eclipse running configuration, it is recommended to export the debugged java project as a jar package that can be run. Then open the jar in the command line and use the "java -jar <package name> <main function. Parameter 1 Parameter 2 ......> ". The help command in the figure below is the first element arg[0] of the parameter array arg[] when the main function is executed.The parameters are separated by spaces, followed by arg[1], arg[2]. Knowing this, making a java command line navigation menu is simple.In order to facilitate the operation, the extremely guest also produced a GUI for this experiment, supporting GUI, command line dual interface mode operation and application.The benefits of the command line may only be understood by programmers. Its greatest benefit, personally believed, is that it can be batched. This is something that GUI users cannot understand.

Effect preview:

java command line navigation menu

MeetingClient.java

The following code performs the methods defined in the previous article by matching the main function parameters entered by the user.Entering the GUI and not entering parameters will start the GUI mode. java command line navigation menu 2  

Series links:

SSD8_Ex3 [JAVA_RMI Service] (1) Overview of RMI and Network APIs

SSD8_Ex3[JAVA_RMI](2) Remote Interface Declaration

SSD8_Ex3 [JAVA_RMI] (3) Open RMI Service

SSD8_Ex3 [JAVA_RMI] (4) conference database table

SSD8_Ex3 [JAVA_RMI] (5) database connection and meeting method definition

SSD8_Ex3 [JAVA_RMI] (6) Create Command Line Navigation Menu

 

  
 

This article has been printed on copyright and is protected by copyright laws. It must not be reproduced without permission.If you need to reprint, please contact the author or visit the copyright to obtain the authorization. If you feel that this article is useful to you, you can click the "Sponsoring Author" below to call the author!

Reprinted Note Source: Baiyuan's Blog>>https://wangbaiyuan.cn/en/java-rmi-6-making-the-command-line-navigation-menu-2.html

Post comment

Style

No Comment

登录

Forget password?

您也可以使用第三方帐号快捷登录

切换登录

注册

TW