Class ResourceStore
java.lang.Object
com._1c.g5.v8.dt.internal.compare.ResourceStore
- All Implemented Interfaces:
IResourceStore
A resource store. Current implementation relies on a LRU cache.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear
(ComparisonProcessHandle handle) Clears all resources of the specified comparison process.getResource
(ComparisonProcessHandle handle, long nodeId) Returns the resource for the specified comparison process handle and node identifier.void
putResource
(ComparisonProcessHandle handle, long nodeId, IResource resource) Puts the specified resource in the store for the specified comparison process handle and model node identifier.void
Reduces the cache usage temporarily (depends on the implementation) to reduce overall resource strain on the system during high-load operations
-
Constructor Details
-
ResourceStore
public ResourceStore()
-
-
Method Details
-
getResource
Description copied from interface:IResourceStore
Returns the resource for the specified comparison process handle and node identifier.- Specified by:
getResource
in interfaceIResourceStore
- Parameters:
handle
- comparison process handle, notnull
nodeId
- model node identifier, notnull
- Returns:
- the resource or
null
if not available
-
putResource
Description copied from interface:IResourceStore
Puts the specified resource in the store for the specified comparison process handle and model node identifier.- Specified by:
putResource
in interfaceIResourceStore
- Parameters:
handle
- comparison process handle, notnull
nodeId
- model node identifier, notnull
resource
- the resource to put,null
to remove the resource from the store
-
clear
Description copied from interface:IResourceStore
Clears all resources of the specified comparison process.- Specified by:
clear
in interfaceIResourceStore
- Parameters:
handle
- the handle specifying the comparison process
-
reduceCacheUsageTemporarily
public void reduceCacheUsageTemporarily()Description copied from interface:IResourceStore
Reduces the cache usage temporarily (depends on the implementation) to reduce overall resource strain on the system during high-load operations- Specified by:
reduceCacheUsageTemporarily
in interfaceIResourceStore
-