Package org.dreambot.api.settings
Class CacheSettings
- java.lang.Object
-
- org.dreambot.api.settings.CacheSettings
-
public class CacheSettings extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
GAME_OBJECTS_CACHE_TIMER
static java.lang.String
GROUND_ITEM_CACHE_TIMER
static java.lang.String
NPC_CACHE_TIMER
static java.lang.String
PLAYER_CACHE_TIMER
static java.lang.String
WIDGET_CACHE_TIMER
static java.lang.String
WORLD_CACHE_TIMER
-
Constructor Summary
Constructors Constructor Description CacheSettings()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
getCacheTime(java.lang.String key)
Gets the time in ms for a cache keystatic void
resetToDefaults()
Clears the cache timers and resets internal cache timers to defaults.static void
setCacheTimer(java.lang.String key, java.lang.Integer cacheTime)
Sets a cache time for the given key.
-
-
-
Field Detail
-
NPC_CACHE_TIMER
public static final java.lang.String NPC_CACHE_TIMER
- See Also:
- Constant Field Values
-
GAME_OBJECTS_CACHE_TIMER
public static final java.lang.String GAME_OBJECTS_CACHE_TIMER
- See Also:
- Constant Field Values
-
GROUND_ITEM_CACHE_TIMER
public static final java.lang.String GROUND_ITEM_CACHE_TIMER
- See Also:
- Constant Field Values
-
WIDGET_CACHE_TIMER
public static final java.lang.String WIDGET_CACHE_TIMER
- See Also:
- Constant Field Values
-
PLAYER_CACHE_TIMER
public static final java.lang.String PLAYER_CACHE_TIMER
- See Also:
- Constant Field Values
-
WORLD_CACHE_TIMER
public static final java.lang.String WORLD_CACHE_TIMER
- See Also:
- Constant Field Values
-
-
Method Detail
-
setCacheTimer
public static void setCacheTimer(java.lang.String key, java.lang.Integer cacheTime)
Sets a cache time for the given key.- Parameters:
key
- Key of cache to set, see class docs for internal DreamBot timerscacheTime
- Time in MS
-
getCacheTime
public static int getCacheTime(java.lang.String key)
Gets the time in ms for a cache key- Parameters:
key
- Key of cache to get, see class docs for internal DreamBot timers- Returns:
- Time in MS for the given key, default of 0
-
resetToDefaults
public static void resetToDefaults()
Clears the cache timers and resets internal cache timers to defaults. See class docs for internal DreamBot cache timers and their defaults.
-
-