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



Top Method Summary
Options Name Purpose
+ LOGICAL AcquireLock (character, character, integer, logical) Aquire logical application lock for a record
+ LOGICAL AcquireLock (character, integer, logical) Aquire 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: Aquire 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: Aquire 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: Indepentedly 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-2020 Consultingwerk Ltd.         info@consultingwerk.de         http://www.consultingwerk.de       04.02.2020 23:21:12