Package hudson.slaves
Class WorkspaceList.Lease
java.lang.Object
hudson.slaves.WorkspaceList.Lease
- All Implemented Interfaces:
 Closeable,AutoCloseable
- Enclosing class:
 - WorkspaceList
 
Represents a leased workspace that needs to be returned later.
- 
Field Summary
Fields - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionvoidclose()By default, callsrelease(), but should be idempotent.static WorkspaceList.LeaseCreates a dummyWorkspaceList.Leaseobject that does no-op in the release.static WorkspaceList.LeasecreateLinkedDummyLease(FilePath p, WorkspaceList.Lease parent) Creates aWorkspaceList.Leaseobject that points to the specified path, but the lock is controlled by the given parent lease object.abstract voidrelease()Releases this lease. 
- 
Field Details
- 
path
 
 - 
 - 
Constructor Details
- 
Lease
 
 - 
 - 
Method Details
- 
release
public abstract void release()Releases this lease. - 
close
public void close()By default, callsrelease(), but should be idempotent.- Specified by:
 closein interfaceAutoCloseable- Specified by:
 closein interfaceCloseable- Since:
 - 1.600
 
 - 
createDummyLease
Creates a dummyWorkspaceList.Leaseobject that does no-op in the release. - 
createLinkedDummyLease
public static WorkspaceList.Lease createLinkedDummyLease(@NonNull FilePath p, WorkspaceList.Lease parent) Creates aWorkspaceList.Leaseobject that points to the specified path, but the lock is controlled by the given parent lease object. 
 -