Namespace: Consultingwerk.SmartFramework.Lock
Interface 
ISmartLockService Copy to Clipboard
Parent classes:
Inherits: Progress.Lang.Object
Implemented by: Consultingwerk.SmartFramework.Lock.SmartLockService

File:ISmartLockService
Purpose:Interface definition for SmartLockService
Author(s):Richard Kelters / Consultingwerk Ltd.
Created:Fri Feb 09 16:19:49 CET 2018
Purpose: Acquire logical application lock for a record
Notes: This method is only implemented by SmartLockService
Tries to create or update a SmartLock record



Top Method Summary
Options Name Purpose
+ LOGICAL AcquireLock (character, character, integer, logical) Acquire logical application lock for a record
+ LOGICAL AcquireLock (character, integer, logical) Acquire logical application lock for a resource
+ ReleaseAllExpiredLocks () Delete all expired SmartLock record
+ ReleaseAllSessionLocks (character) Delete all SmartLock records of a session
+ LOGICAL ReleaseLock (character) Release a logical application lock for a record or a resource
+ LOGICAL ReleaseLock (character, character) Release a logical application lock for a record or a resource


Method Detail
Top

PUBLIC LOGICAL AcquireLock (character, character, integer, logical)

Purpose: Acquire logical application lock for a record
Notes: This method is only implemented by SmartLockService
Tries to create or update a SmartLock record

Parameters:
pcTableGuid CHARACTER
Reference to unique record in SmartTable
pcKeyValues CHARACTER
Values of a unique key field(s)
piLockDuration INTEGER
How long the lock may be hold in seconds
plThrowOnAlreadyLocked LOGICAL
Logical indication to throw a record ... or not
Returns LOGICAL
True if lock is given else false
Top

PUBLIC LOGICAL AcquireLock (character, integer, logical)

Purpose: Acquire logical application lock for a resource
Notes: This method is only implemented by SmartLockService
Tries to create or update a SmartLock record

Parameters:
pcResourceIdentifier CHARACTER
Resource only known to the one using it
piLockDuration INTEGER
How long the lock may be hold in seconds
plThrowOnAlreadyLocked LOGICAL
Logical indication to throw a record ... or not
Returns LOGICAL
True if lock is given else false
Top

PUBLIC ReleaseAllExpiredLocks ()

Purpose: Delete all expired SmartLock record
Notes: Called from the SmartScheduler

Top

PUBLIC ReleaseAllSessionLocks (character)

Purpose: Delete all SmartLock records of a session
Notes: Independently of the LockExpires datetime

Parameters:
pcSessionIdentifier CHARACTER
SessionId as provided by the SessionManager
Top

PUBLIC LOGICAL ReleaseLock (character)

Purpose: Release a logical application lock for a record or a resource
Notes: This method is only implemented by SmartLockService
Tries to delete a SmartLock record

Parameters:
pcResourceIdentifier CHARACTER
Resource only known to the one using it
Returns LOGICAL
True if lock is found and released else false
Top

PUBLIC LOGICAL ReleaseLock (character, character)

Purpose: Release a logical application lock for a record or a resource
Notes: This method is only implemented by SmartLockService
Tries to delete a SmartLock record

Parameters:
pcTableGuid CHARACTER
Reference to unique record in SmartTable
pcKeyValues CHARACTER
Values of a unique key field(s)
Returns LOGICAL
True if lock is found and released else false


©2006-2023 Consultingwerk Ltd.         info@consultingwerk.de         http://www.consultingwerk.de       08.12.2024 13:06:54