Class MTModelStoreAdapter

java.lang.Object
se.conciliate.extensions.store.event.MTModelStoreAdapter
All Implemented Interfaces:
EventListener, MTModelStoreListener

public class MTModelStoreAdapter extends Object implements MTModelStoreListener
  • Constructor Details

    • MTModelStoreAdapter

      public MTModelStoreAdapter()
  • Method Details

    • modelAdded

      public void modelAdded(MTModel model, MTWorkspace workspace, MTRepository repo)
      Description copied from interface: MTModelStoreListener
      Called when a model is added through the store api, but before it is saved.

      NOTE: No guarantees are made about wich thread this method is called upon. It is up to the implementation to handle thread safety.
      Specified by:
      modelAdded in interface MTModelStoreListener
      Parameters:
      model - The model that was added
      workspace - The workspace in which the model was added
      repo - The repository in which the model was added
    • modelChanged

      public void modelChanged(MTModelHeader model, ModelChangeEvent event)
      Description copied from interface: MTModelStoreListener
      Called when a model is changed through the store api.

      NOTE: No guarantees are made about wich thread this method is called upon. It is up to the implementation to handle thread safety.
      Specified by:
      modelChanged in interface MTModelStoreListener
      Parameters:
      model - The model that was changed.
      event - An event describing the change.
      See Also:
    • modelRemoved

      public void modelRemoved(String modelUUID, ModelType type, MTWorkspace workspace, MTRepository repo)
      Description copied from interface: MTModelStoreListener
      Called when a model has been removed through the store api. Since the model no longer exist, it cannot be sent as a parameter. Instead, the unique identifier (UUID) is sent as a string.

      NOTE: No guarantees are made about wich thread this method is called upon. It is up to the implementation to handle thread safety.
      Specified by:
      modelRemoved in interface MTModelStoreListener
      Parameters:
      modelUUID - The uuid of the model that was removed.
      type - The type of the model that was removed.
      workspace - The workspace from which the model was removed
      repo - The repository from which the model was removed.
    • revisionChanged

      public void revisionChanged(MTModel model, MTWorkspace workspace, MTRepository repo)
      Description copied from interface: MTModelStoreListener
      Called when a change was made to the current revision of a model, i.e. the revision log was updated.

      NOTE: No guarantees are made about wich thread this method is called upon. It is up to the implementation to handle thread safety.
      Specified by:
      revisionChanged in interface MTModelStoreListener
      Parameters:
      model - The model where the change was made.
      workspace - The workspace in which the revision of the model was changed.
      repo - The repository in which the revision of the model was changed.
    • revisionCreated

      public void revisionCreated(MTModel model, MTWorkspace workspace, MTRepository repo)
      Description copied from interface: MTModelStoreListener
      Called when a new revision of a model is created through the store api.

      NOTE: No guarantees are made about wich thread this method is called upon. It is up to the implementation to handle thread safety.
      Specified by:
      revisionCreated in interface MTModelStoreListener
      Parameters:
      model - The model that now has a new revision.
      workspace - The workspace in which the new revision of the model was created.
      repo - The repository in which the new revision of the model was created.
    • revisionLocked

      public void revisionLocked(MTModel model, MTWorkspace workspace, MTRepository repo)
      Description copied from interface: MTModelStoreListener
      Called when the current revision of a model is locked.

      NOTE: No guarantees are made about wich thread this method is called upon. It is up to the implementation to handle thread safety.
      Specified by:
      revisionLocked in interface MTModelStoreListener
      Parameters:
      model - The model that now has its revision locked.
      workspace - The workspace in which the revision of the model was locked.
      repo - The repository in which the revision of the model was locked.