?? request.java
字號:
package BS.server.datastructure;
/**
* @author 束罡
*
* TODO To change the template for this generated type comment go to Window -
* Preferences - Java - Code Style - Code Templates
*/
/**
* 類:ClientRequest
* 功能:類ClientRequest中的屬性對應了客戶向服務器的請求消息。
* */
public class Request {
private int timestamp = 0; //時間戳
private int accountNumber =-1; //帳戶號
private char transactionType = '#'; //交易類型
private float amount = -1; //交易額
/**
* 方法:SET**
* 功能:負責設置對象的私有屬性
* 調用參數:相應的參數
* 返回值:void
* */
public void SETtimestamp (int str)
{
timestamp = str;
}
public void SETaccountNumber (int str)
{
accountNumber = str;
}
public void SETtransactionType (char str)
{
transactionType = str;
}
public void SETamount (float str)
{
amount = str;
}
/**
* 方法:GET**
* 功能:負責獲取對象的私有屬性
* 調用參數:無
* 返回值:返回相應參數
* */
public int GETtimestamp ()
{
return timestamp;
}
public int GETaccountNumber ()
{
return accountNumber;
}
public char GETtransactionType ()
{
return transactionType;
}
public float GETamount ()
{
return amount;
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -