palio.designer.portal.versionControl
Class VersionControlServicePerInstance

java.lang.Object
  extended by palio.designer.AbstractInstanceService
      extended by palio.designer.portal.versionControl.VersionControlServicePerInstance
All Implemented Interfaces:
torn.omea.framework.core.ContextListener

public class VersionControlServicePerInstance
extends AbstractInstanceService
implements torn.omea.framework.core.ContextListener

This class is responsible for managing of information which object is currently edited and/or was recently edited.

Old behaviour of this class treated recent edition of object as object had been last time saved less then 15 minutes ago. New behaviour of this class treats recent edition as object was saved and not yed included in any revision.

Author:
Szymon Kuklewicz

Constructor Summary
VersionControlServicePerInstance(Instance instance, PalioConnectorContext connector)
           
 
Method Summary
 void addVersionControlListener(VersionControlListener listener)
           
 void contextClosed()
           
 void contextOpened()
           
 pl.com.torn.jpalio.portal.versionControl.VersionControlState getDeepCopy()
           
 java.lang.String getLastTransactionUser(torn.omea.framework.core.OmeaObjectId id)
           
 void markObjectsAsEdited(java.util.Set<java.lang.Long> ids)
           
 void refreshEditionState()
           
 void removeVersionControlListener(VersionControlListener listener)
           
 void revisionCreated(java.util.Collection<torn.omea.framework.core.OmeaObjectId> objects)
          Notify service that some objects has been put into revision
 void transactionCommited(torn.omea.framework.transaction.TransactionNotice notice)
           
 
Methods inherited from class palio.designer.AbstractInstanceService
isInitialized
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VersionControlServicePerInstance

public VersionControlServicePerInstance(Instance instance,
                                        PalioConnectorContext connector)
Method Detail

getLastTransactionUser

public java.lang.String getLastTransactionUser(torn.omea.framework.core.OmeaObjectId id)

refreshEditionState

public void refreshEditionState()

markObjectsAsEdited

public void markObjectsAsEdited(java.util.Set<java.lang.Long> ids)

getDeepCopy

public pl.com.torn.jpalio.portal.versionControl.VersionControlState getDeepCopy()

transactionCommited

public void transactionCommited(torn.omea.framework.transaction.TransactionNotice notice)
Specified by:
transactionCommited in interface torn.omea.framework.core.ContextListener

revisionCreated

public void revisionCreated(java.util.Collection<torn.omea.framework.core.OmeaObjectId> objects)
Notify service that some objects has been put into revision


contextOpened

public void contextOpened()
Specified by:
contextOpened in interface torn.omea.framework.core.ContextListener

contextClosed

public void contextClosed()
Specified by:
contextClosed in interface torn.omea.framework.core.ContextListener

addVersionControlListener

public void addVersionControlListener(VersionControlListener listener)

removeVersionControlListener

public void removeVersionControlListener(VersionControlListener listener)