28 #ifndef TABLES_TABLELOCK_H
29 #define TABLES_TABLELOCK_H
33 #include <casacore/casa/aips.h>
34 #include <casacore/casa/IO/LockFile.h>
TableLock(LockOption option, double inspectionInterval, uInt maxWait=0)
LockOption
Define the possible table locking options.
@ UserLocking
The user is taking care of locking the table by means of the Table functions lock and unlock.
@ AutoLocking
The system takes care of acquiring/releasing locks.
@ AutoNoReadLocking
The system takes care of acquiring/releasing locks.
@ DefaultLocking
This is the default locking option.
@ UserNoReadLocking
The user is taking care of locking the table by means of the Table functions lock and unlock.
@ PermanentLocking
The table is permanently locked.
@ NoLocking
Do not do any locking at all.
@ PermanentLockingWait
The same as above, but the table constructor waits until the lock gets available.
Bool isPermanent() const
Is permanent locking used?
void init()
Set itsOption and itsReadLocking when needed.
TableLock(LockOption option=DefaultLocking)
Construct with given option and interval.
Bool readLocking() const
Is read locking needed?
static Bool lockingDisabled()
Is table locking disabled (because AIPS_TABLE_NOLOCKING or table.nolocking is set)?
double interval() const
Get the inspection interval.
uInt maxWait() const
Get the maximum wait period in AutoLocking mode.
Bool itsIsDefaultInterval
TableLock(const TableLock &that)
Copy constructor.
void merge(const TableLock &that)
Merge that TableLock with this TableLock object by taking the maximum option and minimum inspection i...
TableLock & operator=(const TableLock &that)
Assignment.
LockOption option() const
Get the locking option.
this file contains all the compiler specific defines
bool Bool
Define the standard types used by Casacore.