public class SimpleRevisionComparePresenter extends Object implements ItemListener, ChangeListener, ActionListener
| Modifier and Type | Class and Description |
|---|---|
static interface |
SimpleRevisionComparePresenter.FileHandler
This interface is used by the SimpleRevisionComparePresenter to handle the file loading.
|
| Constructor and Description |
|---|
SimpleRevisionComparePresenter(SimpleRevisionCompareModel model,
SimpleRevisionCompareView view)
Default Ctor: registers the view as listener to the correct model.
|
| Modifier and Type | Method and Description |
|---|---|
void |
actionPerformed(ActionEvent ev) |
void |
itemStateChanged(ItemEvent ev) |
static void |
main(String[] args)
Functional Test method: Only shows the view in a JFrame to test resize behavior.
|
void |
setFileHandler(SimpleRevisionComparePresenter.FileHandler handler)
Sets a file handler responsible for filtering the open file dialog and loading
the selected file.
|
void |
stateChanged(ChangeEvent ev) |
public SimpleRevisionComparePresenter(SimpleRevisionCompareModel model, SimpleRevisionCompareView view)
public void setFileHandler(SimpleRevisionComparePresenter.FileHandler handler)
handler - An implementation of the FileHandler interface or null. If null is given
then the default handler is used which cannot open any files.public void actionPerformed(ActionEvent ev)
actionPerformed in interface ActionListenerpublic void stateChanged(ChangeEvent ev)
stateChanged in interface ChangeListenerpublic void itemStateChanged(ItemEvent ev)
itemStateChanged in interface ItemListenerpublic static void main(String[] args)
Copyright © 2018. All rights reserved.