📄 alertsinfo.java
字号:
/*
* @author : Umesh Kulkarni
* @version 1.0
*
* Development Environment : Oracle9i JDeveloper
*
* Name of the File : AlertsInfo.java
*
* Creation / Modification History
* Umesh 26-Apr-2002 Created
*
*/
package oracle.otnsamples.ibfbs.usermanagement.ejb;
import java.io.Serializable;
/**
* This Class encapsulates Alert Information for a particular User Account.
* Whenever Session Facade Bean namely UserManagementSessionFacadeBean, needs
* to get the Alert Info for a particular User Account, the Session Facade
* Bean gets this information as AlertInfo value object. Thus this class acts
* as Value object while getting/setting alert information between Session
* Facade Bean and User Account Entity Bean.
*
* @version 1.0
* @since 1.0
*/
public class AlertsInfo implements Serializable {
private String symbol; // Variable holding Stock Symbol
private Integer minLimit; // Main Limit in the Alert
private Integer maxLimit; // Max Limit in the Alert
/**
* Empty Constructor of this Class.
* @since 1.0
*/
public AlertsInfo() {}
/**
* Constructor with appropriate parameters. Sets the value of instance
* variables with appropriate values.
*
* @param symbol Value of the symbol field
* @param minLimit Minimum Limit Value of this alert setting.
* @param maxLimit Maximum Limit Value of this Alert Setting.
* @since 1.0
*/
public AlertsInfo(String symbol, Integer minLimit, Integer maxLimit) {
this.symbol = symbol;
this.minLimit = minLimit;
this.maxLimit = maxLimit;
}
/**
* Method to retrieve the value of Symbol instance variable
*
* @return The Desired Symbol Value
* @since 1.0
*/
public String getSymbol() {
return symbol;
}
/**
* Assign the new Symbol value to symbol instance variable.
*
* @param symbol New symbol Value
* @since 1.0
*/
public void setSymbol(String symbol) {
this.symbol = symbol;
}
/**
* Method to retrieve the value of Minimum Limit instance variable
*
* @return The Desired Minimum Limit Value
* @since 1.0
*/
public Integer getMinLimit() {
return minLimit;
}
/**
* Assign the new Minimum Limit value to minLimit instance variable.
* @param minLimit Minimum Value of Stock Quote below which
* this alert should get activated
* @since 1.0
*/
public void setMinLimit(Integer minLimit) {
this.minLimit = minLimit;
}
/**
* Method to retrieve the value of Maximum Value instance variable
*
* @return The Desired Maximum Value Value
* @since 1.0
*/
public Integer getMaxLimit() {
return maxLimit;
}
/**
* Assign the new Maximum Limit value to maxLimit instance variable.
* @param maxLimit Maximum Value of Stock Quote above which
* this alert should get activated.
* @since 1.0
*/
public void setMaxLimit(Integer maxLimit) {
this.maxLimit = maxLimit;
}
/**
* Method to get String representation of this class. Overrides the method
* toString() in java.lang.Object
*
* @return String representation of this class.
* @since 1.0
*/
public String toString() {
StringBuffer sb = new StringBuffer();
sb.append("Symbol : ")
.append(this.getSymbol())
.append(" Min Limit : ")
.append(this.getMinLimit())
.append(" Max Limit : ")
.append(this.getMaxLimit());
return sb.toString();
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -