de.uni_paderborn.fujaba.coobra
Class FujabaChangeManager

java.lang.Object
  extended byde.uni_paderborn.fujaba.coobra.FujabaChangeManager

public class FujabaChangeManager
extends java.lang.Object

The change manager provides access to the CoObRA LocalRepository for the current Virtual Machine. (Fujaba uses only one repository at a time)

Version:
$Revision: 1.32.2.7 $
Author:
$Author: lowende $

Constructor Summary
FujabaChangeManager()
           
 
Method Summary
static void addActionCauseListener()
          Adds a listener to the UserInterfaceManager to push a cause on the begin of every Action tyken by the user.
static void executeTransient(java.lang.Runnable runnable)
          No comment provided by developer, please add a comment to improve documentation.
static UMLProject getUMLProject()
          Get the uMLProject attribute of the FujabaChangeManager class
static de.tu_bs.coobra.LocalRepository getVMRepository()
          Get the vMRepository attribute of the CoObRAPersistentObject class
static boolean isCollectionField(java.lang.Class cls, java.lang.String fieldName)
          Helper method to determine if a field may contain multiple items
static boolean isInUndoRedo()
           
static void setVMRepository(de.tu_bs.coobra.LocalRepository vMRepository)
          Changes the repository for CoObRAPersistentObjects in this Virtual Machine.
static void updateUndoRedoActions()
          update the enabled state of undo- and redo-action
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FujabaChangeManager

public FujabaChangeManager()
Method Detail

getVMRepository

public static de.tu_bs.coobra.LocalRepository getVMRepository()
Get the vMRepository attribute of the CoObRAPersistentObject class

Returns:
The VMRepository

setVMRepository

public static void setVMRepository(de.tu_bs.coobra.LocalRepository vMRepository)
Changes the repository for CoObRAPersistentObjects in this Virtual Machine.
Use with care!

Parameters:
vMRepository - the new repository for all newly created CoObRAPersistentObjects

addActionCauseListener

public static void addActionCauseListener()
Adds a listener to the UserInterfaceManager to push a cause on the begin of every Action tyken by the user.


isCollectionField

public static boolean isCollectionField(java.lang.Class cls,
                                        java.lang.String fieldName)
Helper method to determine if a field may contain multiple items

Parameters:
cls - Class in which the field resides
fieldName - name of the field (e.g. "position")
Returns:
true when field is a collection (has an addTo-Method)

getUMLProject

public static UMLProject getUMLProject()
Get the uMLProject attribute of the FujabaChangeManager class

Returns:
The uMLProject value

isInUndoRedo

public static boolean isInUndoRedo()
Returns:
true when an undo or redo operation is in progress (in current thread)

updateUndoRedoActions

public static void updateUndoRedoActions()
update the enabled state of undo- and redo-action


executeTransient

public static void executeTransient(java.lang.Runnable runnable)
No comment provided by developer, please add a comment to improve documentation.

Parameters:
runnable - No description provided