Home    |    Concepts   |   API   |   Samples
Concepts > Schema Objects > Locking
What are application object locks?

Object locks allow you to set an arbitrary, application-defined lock on an object. Object locks can be used by the application to provide general purpose lock services. Objects are identified by an application-defined object type and the ID of the object. Object locks are released when the application disconnects from the geodatabase.

Information about an object lock is contained in an SE_OBJECTLOCKINFO opaque pointer. A set of functions of the format SE_objectlockinfo_* allows you to retrieve and set the various object lock parameters. You must call SE_objectlockinfo_create before using any other function that uses an SE_OBJECTLOCKINFO object.

Lock Types

  • SE_OBJECTLOCK_SHARED_LOCK—A shared lock prevents others from establishing an exclusive lock. Other users can establish shared locks on the same object, but no users can establish an exclusive lock until all shared locks are freed.
     
  • SE_OBJECTLOCK_EXCLUSIVE_LOCK—An exclusive lock prevents any other user from establishing any kind of lock on the object until the exclusive lock is released.
     
  • SE_OBJECTLOCK_NO_LOCK_SET—Indicates that no lock is present on this object.
feedback | privacy | legal