📄 resultviewer.java
字号:
import java.util.Observable;
import java.util.Observer;
import java.awt.BorderLayout;
import javax.swing.JPanel;
/**
* Description of the Class
*
* @author kilo
* @created 2003年12月22日
*/
public abstract class ResultViewer
extends JPanel
implements Observer {
/**
* Description of the Field
*/
protected DataManager dataManager;
/**
* Constructor for the ResultViewer object
*
* @param d Description of the Parameter
* @exception NullPointerException Description of the Exception
*/
public ResultViewer( DataManager d )
throws NullPointerException {
super.setLayout( new BorderLayout() );
if ( d == null )
throw new NullPointerException();
dataManager = d;
dataManager.addObserver( this );
}
/**
* Gets the dataManager attribute of the ResultViewer object
*
* @return The dataManager value
*/
public final DataManager getDataManager() {
return dataManager;
}
/**
* Description of the Method
*
* @param observable Description of the Parameter
* @param object Description of the Parameter
*/
public final void update( Observable observable, Object object ) {
updateDisplay();
}
/**
* Description of the Method
*/
protected abstract void updateDisplay();
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -