table.java

来自「PDA餐饮管理系统,在掌上电脑实现的,可以开台,点菜等多功能模块」· Java 代码 · 共 74 行

JAVA
74
字号
package rms;

/**
 * 桌台类
 * @author hong
 *
 */
public class Table{

	public final static int ST_free=1;
	public final static int ST_use=2;
	public final static int ST_engage=3;
	public final static int ST_stop=4;

	private String tableNo;
	private String tableName;
	private int status;

	public Table(){
		this.tableNo="";
		this.status=ST_free;
	}
		
	public Table(String tableNo,String tableName,int status){
	
		this.tableNo=tableNo;
		this.status=status;
		this.tableName=tableName;
	}

	public int getStatus() {
		return status;
	}

	public void setStatus(int status) {
		this.status = status;
	}

	public String getTableNo() {
		return tableNo;
	}

	public void setTableNo(String tableNo) {
		this.tableNo = tableNo;
	}
	
	public String getStatusName(){
		String s="";
		switch(status){
		case ST_free:
			s="空闲";
			break;
		case ST_use:
			s="使用中";
			break;
		case ST_engage:
			s="已预定";
			break;
		case ST_stop:
			s="停用";
			break;
		}
		return s;
	}

	public String getTableName() {
		return tableName;
	}

	public void setTableName(String tableName) {
		this.tableName = tableName;
	}
}

⌨️ 快捷键说明

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