org.eodisp.ui.rm.models
Class ReposModel

java.lang.Object
  extended by org.eodisp.ui.common.components.AbstractEodispModel
      extended by org.eodisp.ui.rm.models.ReposModel
All Implemented Interfaces:
EodispModel

public class ReposModel
extends AbstractEodispModel

Version:
$Id:$
Author:
eglimi

Nested Class Summary
 class ReposModel.CatListModel
           
 class ReposModel.MmListModel
           
 class ReposModel.SmListModel
           
 class ReposModel.SomsListModel
           
 
Field Summary
static java.lang.String CAT_CLOSED
           
static java.lang.String CAT_DESCRIPTION
           
static java.lang.String CAT_ID
           
static java.lang.String CAT_NAME
           
(package private) static org.apache.log4j.Logger logger
          Log4J logger for this class
static java.lang.String MM_DESCRIPTION
           
static java.lang.String MM_ID
           
static java.lang.String MM_NAME
           
static java.lang.String SM_DESCRIPTION
           
static java.lang.String SM_ID
           
static java.lang.String SM_NAME
           
static java.lang.String SOM_DESCRIPTION
           
static java.lang.String SOM_FILE_NAME
           
static java.lang.String SOM_NAME
           
static java.lang.String SOM_VERSION
           
 
Constructor Summary
ReposModel()
           
 
Method Summary
 void doSave()
          Executes the save command in the model.
 void doUpdate()
           Instructs the model to do an update of its data.
 ReposModel.CatListModel getCatListModel()
           
 ReposModel.MmListModel getMmListModel()
           
 ReposModel.SmListModel getSmListModel()
           
 ReposModel.SomsListModel getSomsListModel()
           
 boolean hasChanges()
          Returns a value stating whether the model has some changes since the last change.
 boolean isReposConntected()
          This is only a convenient method to test the connection to the repository
 
Methods inherited from class org.eodisp.ui.common.components.AbstractEodispModel
addModelListener, fireModelChanged, getModelListener, redo, removeModelListener, undo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

static org.apache.log4j.Logger logger
Log4J logger for this class


CAT_NAME

public static final java.lang.String CAT_NAME
See Also:
Constant Field Values

CAT_DESCRIPTION

public static final java.lang.String CAT_DESCRIPTION
See Also:
Constant Field Values

CAT_ID

public static final java.lang.String CAT_ID
See Also:
Constant Field Values

CAT_CLOSED

public static final java.lang.String CAT_CLOSED
See Also:
Constant Field Values

SM_NAME

public static final java.lang.String SM_NAME
See Also:
Constant Field Values

SM_DESCRIPTION

public static final java.lang.String SM_DESCRIPTION
See Also:
Constant Field Values

SM_ID

public static final java.lang.String SM_ID
See Also:
Constant Field Values

MM_NAME

public static final java.lang.String MM_NAME
See Also:
Constant Field Values

MM_DESCRIPTION

public static final java.lang.String MM_DESCRIPTION
See Also:
Constant Field Values

MM_ID

public static final java.lang.String MM_ID
See Also:
Constant Field Values

SOM_NAME

public static final java.lang.String SOM_NAME
See Also:
Constant Field Values

SOM_VERSION

public static final java.lang.String SOM_VERSION
See Also:
Constant Field Values

SOM_DESCRIPTION

public static final java.lang.String SOM_DESCRIPTION
See Also:
Constant Field Values

SOM_FILE_NAME

public static final java.lang.String SOM_FILE_NAME
See Also:
Constant Field Values
Constructor Detail

ReposModel

public ReposModel()
Method Detail

doSave

public void doSave()
            throws java.io.IOException
Executes the save command in the model. This saves the changes since the last save persistently.

Throws:
java.io.IOException - thrown when the data could not be saved persistently. This should lead to a visual indication to the user.

doUpdate

public void doUpdate()

Instructs the model to do an update of its data. Many EodispModels are just intermediated models for view components and do not hold the actual data. The actual data is usually retrieved and maintained by a persistency framework. Thus, if the real data has been changed, a model can be informed of this updated and it can be instructed to reload the data.

This should in most cases lead to an update of the visual component representing the data as well.

Specified by:
doUpdate in interface EodispModel
Overrides:
doUpdate in class AbstractEodispModel

hasChanges

public boolean hasChanges()
Returns a value stating whether the model has some changes since the last change.

Returns:
True if the model has changes since the last change or false, if there are no changes.

getCatListModel

public ReposModel.CatListModel getCatListModel()

getSmListModel

public ReposModel.SmListModel getSmListModel()

getMmListModel

public ReposModel.MmListModel getMmListModel()

getSomsListModel

public ReposModel.SomsListModel getSomsListModel()

isReposConntected

public boolean isReposConntected()
This is only a convenient method to test the connection to the repository

Returns:
true, if there is a connection, otherwise false