|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.sourceforge.espro.gui.QuestionnaireManager
public class QuestionnaireManager
The QuestionnaireManager manges the questionnaires. It creates, saves and opens that. This works like a model, so the view can be updated on data changes. The questionnaire manager can handle many questionnaires at once, so we can have a buffer of questionnaires so more than one questionnaire can be opened at the same time.
This returns also Actions which can be used for gui creation.
Method Summary | |
---|---|
void |
addPropertyChangeListener(java.beans.PropertyChangeListener listener)
Adds a general Listener to the object. |
void |
addPropertyChangeListener(java.lang.String propertyName,
java.beans.PropertyChangeListener listener)
Adds a listener to the object, which is only called if the property with the propertyName has changed. |
void |
cleanData()
Removes all data from the actual questionnaire. |
void |
exportData()
Exports the data from the current questionnaire. |
void |
exportData(java.io.File file)
Exports the data to an csv file. |
Questionnaire |
getActualQuestionnaire()
Returns the actual questionnaire. |
org.sourceforge.espro.gui.QuestionnaireManager.CleanDataAction |
getCleanDataAction()
Returns the clean data action. |
org.sourceforge.espro.gui.QuestionnaireManager.ExportDataAction |
getExportDataAction()
Returns the action for the export data method. |
org.sourceforge.espro.gui.QuestionnaireManager.FreezeQuestionnaireAction |
getFreezeQuestionnaireAction()
DOCUMENT ME! |
static QuestionnaireManager |
getInstance()
This returns an object of the class. |
org.sourceforge.espro.gui.QuestionnaireManager.NewItemAction |
getNewItemAction()
Returns the new item action. |
ModelInterface |
getNewQuestionnaire()
Creates a new Questionnaire and sets this as actual questionnaire. |
org.sourceforge.espro.gui.QuestionnaireManager.NewQuestionnaireAction |
getNewQuestionnaireAction()
This returns the action which is able to create a new questionnaire. |
org.sourceforge.espro.gui.QuestionnaireManager.OpenQuestionnaireAction |
getOpenQuestionnaireAction()
This creates an openQuestionnaireAction and returns it. |
org.sourceforge.espro.gui.QuestionnaireManager.RemoveItemAction |
getRemoveItemAction()
Returns the remove item action. |
org.sourceforge.espro.gui.QuestionnaireManager.SaveQuestionnaireAction |
getSaveQuestionnaireAction()
This creates an saveQuestionnaireAction and returns it. |
org.sourceforge.espro.gui.QuestionnaireManager.SaveUnfrozenQuestionnaireAction |
getSaveUnfrozenQuestionnaireAction()
DOCUMENT ME! |
ModelInterface |
openQuestionnaire(java.io.File file)
Opens a questionnaire by the given file and sets this as actualQuestionnaire. |
void |
removePropertyChangeListener(java.beans.PropertyChangeListener listener)
Removes the given listener from the object. |
boolean |
saveQuestionnaire(java.io.File file)
Saves the actual questionnaire to the given file. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static QuestionnaireManager getInstance()
public void addPropertyChangeListener(java.beans.PropertyChangeListener listener)
listener
- the listener instance.public void addPropertyChangeListener(java.lang.String propertyName, java.beans.PropertyChangeListener listener)
propertyName
- The name of the property to bind to.listener
- The listener.public void cleanData()
public void exportData()
exportData(File)
afterwards.
public void exportData(java.io.File file)
file
- The file to save the csv data.public Questionnaire getActualQuestionnaire()
public org.sourceforge.espro.gui.QuestionnaireManager.CleanDataAction getCleanDataAction()
public org.sourceforge.espro.gui.QuestionnaireManager.ExportDataAction getExportDataAction()
public org.sourceforge.espro.gui.QuestionnaireManager.FreezeQuestionnaireAction getFreezeQuestionnaireAction()
public org.sourceforge.espro.gui.QuestionnaireManager.NewItemAction getNewItemAction()
public ModelInterface getNewQuestionnaire()
This is done by the new questionnaire action. Fires the 'actualQuestionnaire' property change.
public org.sourceforge.espro.gui.QuestionnaireManager.NewQuestionnaireAction getNewQuestionnaireAction()
public org.sourceforge.espro.gui.QuestionnaireManager.OpenQuestionnaireAction getOpenQuestionnaireAction()
public org.sourceforge.espro.gui.QuestionnaireManager.RemoveItemAction getRemoveItemAction()
public org.sourceforge.espro.gui.QuestionnaireManager.SaveQuestionnaireAction getSaveQuestionnaireAction()
public org.sourceforge.espro.gui.QuestionnaireManager.SaveUnfrozenQuestionnaireAction getSaveUnfrozenQuestionnaireAction()
public ModelInterface openQuestionnaire(java.io.File file)
Fires the 'actualQuestionnaire' property change.
file
- The file to open.
public void removePropertyChangeListener(java.beans.PropertyChangeListener listener)
listener
- the listener to removepublic boolean saveQuestionnaire(java.io.File file)
This is done by the save actual questionnaire action.
file
- The file to save the questionnaire.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |