Package dev.getelements.elements.rt
Interface ResourceService.ResourceAcquisition
- All Superinterfaces:
AutoCloseable
- Enclosing interface:
ResourceService
Acquires a
Resource, guaranteeing it will stay in memory until this object is closed. This does not
provide access to the Resource. Use a ResourceService.ResourceTransaction for that purpose to guarantee
synchronized access to the resource.-
Method Summary
Modifier and TypeMethodDescriptionbegin()Creates a newResourceService.ResourceTransactionfrom this acquisition.voidclose()Closes the transactionGets theResourceId.
-
Method Details
-
getResourceId
ResourceId getResourceId()Gets theResourceId.- Returns:
- the
ResourceId
-
close
void close()Closes the transaction- Specified by:
closein interfaceAutoCloseable
-
begin
Creates a newResourceService.ResourceTransactionfrom this acquisition.- Returns:
- the
ResourceService.ResourceTransaction
-