Class BuildMetadataCacheResetHandler
- java.lang.Object
-
- jetbrains.buildServer.serverSide.metadata.impl.indexer.BuildMetadataCacheResetHandler
-
- All Implemented Interfaces:
ResetCacheHandler,PositionAware,PositionConstraintAware
public class BuildMetadataCacheResetHandler extends Object implements ResetCacheHandler, PositionAware
- Author:
- Evgeniy.Koshkin
-
-
Constructor Summary
Constructors Constructor Description BuildMetadataCacheResetHandler(ResetCacheRegister register, MetadataIndexerService indexerService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PositionConstraintgetConstraint()Constraint to be respected during objects sorting.StringgetOrderId()Returns object id that can be referenced by {PositionConstraint}booleanisEmpty(String name)Returns whether the cache denoted bynameis empty.List<String>listCaches()Returns the list of cache names.voidresetCache(String name)Resets the cache (erases all stored entries).
-
-
-
Constructor Detail
-
BuildMetadataCacheResetHandler
public BuildMetadataCacheResetHandler(@NotNull ResetCacheRegister register, @NotNull MetadataIndexerService indexerService)
-
-
Method Detail
-
getOrderId
@NotNull public String getOrderId()
Description copied from interface:PositionAwareReturns object id that can be referenced by {PositionConstraint}- Specified by:
getOrderIdin interfacePositionAware- Returns:
- object id
-
getConstraint
@NotNull public PositionConstraint getConstraint()
Description copied from interface:PositionConstraintAwareConstraint to be respected during objects sorting.- Specified by:
getConstraintin interfacePositionConstraintAware- Returns:
- position constraint
-
listCaches
@NotNull public List<String> listCaches()
Description copied from interface:ResetCacheHandlerReturns the list of cache names. Try to make this method fast.- Specified by:
listCachesin interfaceResetCacheHandler- Returns:
- list of cache names
-
isEmpty
public boolean isEmpty(@NotNull String name)Description copied from interface:ResetCacheHandlerReturns whether the cache denoted bynameis empty. The specifiednameis guaranteed to be from the list returned bylistCaches.- Specified by:
isEmptyin interfaceResetCacheHandler- Parameters:
name- cache name- Returns:
- true if the cache is empty
-
resetCache
public void resetCache(@NotNull String name)Description copied from interface:ResetCacheHandlerResets the cache (erases all stored entries). After reset the cache should be empty. The specifiednameis guaranteed to be from the list returned bylistCaches.- Specified by:
resetCachein interfaceResetCacheHandler- Parameters:
name- cache name
-
-