org.apache.karaf.main
Interface Lock

All Known Implementing Classes:
DefaultJDBCLock, DerbyJDBCLock, MySQLJDBCLock, OracleJDBCLock, SimpleFileLock

public interface Lock


Method Summary
 boolean isAlive()
          Indicates whether or not the lock still exists.
 boolean lock()
          A KeepAlive function to maintain the lock.
 void release()
          Terminate the lock connection safely.
 

Method Detail

lock

boolean lock()
             throws Exception
A KeepAlive function to maintain the lock. Indicates whether or not the lock could be aquired.

Returns:
true if connection lock retained, false otherwise.
Throws:
Exception

release

void release()
             throws Exception
Terminate the lock connection safely.

Throws:
Exception

isAlive

boolean isAlive()
                throws Exception
Indicates whether or not the lock still exists.

Returns:
true, if the lock still exists, otherwise false.
Throws:
Exception


Copyright © 2007-2011 Apache Software Foundation. All Rights Reserved.