getlocalhostexploreritem.java
来自「一个agent 工具包,可以开发移动设备应用,考虑了安全措施」· Java 代码 · 共 33 行
JAVA
33 行
package SOMA.utility;
import java.io.*;
import java.util.*;
/** Restituisce il localhost address.
*
* @author Livio Profiri
*/
public class GetLocalHostExplorerItem extends SOMA.explorer.ExplorerItem
{
public GetLocalHostExplorerItem()
{
super( "Prints the Local Host address" );
}
public Object Execute( Collection Parameters, PrintStream out )
{
String Answer;
try
{
Answer = "Local Host: " + GetLocalHost.getCurrentLocalHost( out ).toString();
}
catch( java.net.UnknownHostException e )
{
Answer = "I don't know the Local Host address";
}
out.println( Answer );
return Answer;
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?