Class LockCleanupTask
A background task that removes expired locks
Inherited Members
Namespace:FubarDev.WebDavServer.Locking
Assembly:FubarDev.WebDavServer.dll
Syntax
public class LockCleanupTask : ILockCleanupTask, IDisposable
Constructors
| Improve this Doc View SourceLockCleanupTask(ISystemClock, ILogger<LockCleanupTask>)
Initializes a new instance of the LockCleanupTask class.
Declaration
public LockCleanupTask([NotNull] ISystemClock systemClock, [NotNull] ILogger<LockCleanupTask> logger)
Parameters
Type | Name | Description |
---|---|---|
ISystemClock | systemClock | The system clock |
Microsoft.Extensions.Logging.ILogger<LockCleanupTask> | logger | The logger for the cleanup task |
Methods
| Improve this Doc View SourceAdd(ILockManager, IActiveLock)
Adds a lock to be tracked by this cleanup task.
Declaration
public void Add(ILockManager lockManager, IActiveLock activeLock)
Parameters
Type | Name | Description |
---|---|---|
ILockManager | lockManager | The lock manager that created this active lock. |
IActiveLock | activeLock | The active lock to track |
Implements
| Improve this Doc View SourceDispose()
Declaration
public void Dispose()
Implements
| Improve this Doc View SourceRemove(IActiveLock)
Removes the active lock so that it isn't tracked any more by this cleanup task.
Declaration
public void Remove(IActiveLock activeLock)
Parameters
Type | Name | Description |
---|---|---|
IActiveLock | activeLock | The active lock to remove |