Code example for Cache

Methods: invalidateAll

  public InMemorySessionTokenCache reset(int duration, TimeUnit unit) {
    // Build the cache 
    if (sessionTokenCache != null) {
    // If there is no activity against a key then we want 
    // it to be expired from the cache, but each fresh write 
    // will reset the expiry timer 
    sessionTokenCache = CacheBuilder
      .expireAfterWrite(duration, unit)
    return INSTANCE;
Connect your IDE to all the code out there  Get Codota for Java