org.eclipse.emf.emfstore.internal.server.core
Class MonitorProvider

java.lang.Object
  extended by org.eclipse.emf.emfstore.internal.server.core.MonitorProvider

public final class MonitorProvider
extends Object

Holds the monitor objects for synchronizing the access on the serverspace. It's implemented as a singleton.

Author:
wesendon

Method Summary
static MonitorProvider getInstance()
          Returns an singleton instance of the monitor provider.
 Object getMonitor()
          Returns the main monitor objects.
 Object getMonitor(String namespace)
          Returns a monitor for a given namespace.
 boolean removeMonitor(String namespace)
          Removes a monitor of a certain namespace.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static MonitorProvider getInstance()
Returns an singleton instance of the monitor provider.

Returns:
the singleton instance

getMonitor

public Object getMonitor()
Returns the main monitor objects.

Returns:
the monitor

getMonitor

public Object getMonitor(String namespace)
Returns a monitor for a given namespace.

Parameters:
namespace - namespace.
Returns:
monitor object

removeMonitor

public boolean removeMonitor(String namespace)
Removes a monitor of a certain namespace.

Parameters:
namespace - the namespace
Returns:
true if it was deleted, false if it didn't exist anyway or if it's the main monitor, which can't be deleted.


Copyright © 2015. All Rights Reserved.