Node Director
Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
sfi.director.util.Lock Class Reference

Public Member Functions

 Lock (boolean islocal) throws DirectorException
synchronized void unlock () throws DirectorException
synchronized void setOption (String name, String value)
 set lock option.
Options getOptions ()
 get options associated with this lock.

Static Public Member Functions

static Lock inspect (String what) throws DirectorException
static Lock inspect (String what, boolean islocal) throws DirectorException
static void startLocking ()
static Lock LocalLock (String what, int timeout) throws DirectorException
static Lock LocalLock (String what) throws DirectorException
static Lock Lock (String what, int timeout) throws DirectorException
static Lock Lock (String what) throws DirectorException
static Lock Lock (String what, int timeout, boolean islocal) throws DirectorException
static Lock Lock (String what, boolean islocal) throws DirectorException
static void shutdown ()

Protected Member Functions

void finalize ()

Constructor & Destructor Documentation

sfi.director.util.Lock.Lock ( boolean  islocal) throws DirectorException
static Lock sfi.director.util.Lock.Lock ( String  what,
int  timeout 
) throws DirectorException
static
static Lock sfi.director.util.Lock.Lock ( String  what) throws DirectorException
static
static Lock sfi.director.util.Lock.Lock ( String  what,
int  timeout,
boolean  islocal 
) throws DirectorException
static
static Lock sfi.director.util.Lock.Lock ( String  what,
boolean  islocal 
) throws DirectorException
static

Member Function Documentation

void sfi.director.util.Lock.finalize ( )
protected
Options sfi.director.util.Lock.getOptions ( )

get options associated with this lock.

Note that you must set options via the setOption() method rather than using something like getOptions().setOption(...).

Referenced by sfi.director.schedule.Scheduler.getRunningSchedulerOpts().

static Lock sfi.director.util.Lock.inspect ( String  what) throws DirectorException
static
static Lock sfi.director.util.Lock.inspect ( String  what,
boolean  islocal 
) throws DirectorException
static
static Lock sfi.director.util.Lock.LocalLock ( String  what,
int  timeout 
) throws DirectorException
static
static Lock sfi.director.util.Lock.LocalLock ( String  what) throws DirectorException
static
synchronized void sfi.director.util.Lock.setOption ( String  name,
String  value 
)

set lock option.

The option/value is stored in the lock object and is not interpreted by the Lock class. This can be used to pass data about the lock holder to anyone inspecting this lock.

References sfi.director.util.Options.getOptions(), sfi.director.repository.DBObject.removeAttribute(), sfi.director.repository.DBConnection.replace(), and sfi.director.util.Options.setOption().

Referenced by sfi.director.schedule.Scheduler.attach().

static void sfi.director.util.Lock.shutdown ( )
static
static void sfi.director.util.Lock.startLocking ( )
static
synchronized void sfi.director.util.Lock.unlock ( ) throws DirectorException

The documentation for this class was generated from the following file: