📄 fishconstants.java
字号:
//FishConstants定义了一些常量比如端口和组播地址
package fish;
public interface FishConstants
{
//组播datagrams的IP地址
public static final String MULTICAST_ADDRESS = "239.0.0.1";
//监听组播datagrams的端口
public static final int MULTICAST_LISTENING_PORT = 5555;
//发送组播datagrams的端口
public static final int MULTICAST_SENDING_PORT = 5554;
//FishServer的Socket端口
public static final int SERVER_PORT = 12345;
//显示断开的字符串
public static final String DISCONNECT_STRING = "DISCONNECT";
//分开消息信息和clientID的分隔符
public static final String MESSAGE_SEPARATOR = ">>>";
//分开fish状态的分隔符
public static String ARRAY_SEPARATOR = "&";
//消息大小
public static final int MESSAGE_SIZE = 512;
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -