code: @SuppressWarnings("unchecked")
    public <T extends DbEntity> T get(Class<T> type, String id) {
      Class<?> cacheKey = cacheKeyMapping.getEntityCacheKey(type);
      CachedDbEntity cachedDbEntity = getCachedEntity(cacheKey, id);
      if(cachedDbEntity != null) {
        DbEntity dbEntity = cachedDbEntity.getEntity();
        try {
          return (T) dbEntity;
        } catch(ClassCastException e) {
          throw LOG.entityCacheLookupException(type, id, dbEntity.getClass(), e);
        }
      } else {
        return null;
      }
    }
docs: get an object from the cache
  
  @param type the type of the object
  @param id the id of the object
  @return the object or 'null' if the object is not in the cache
  @throws ProcessEngineException if an object for the given id can be found but is of the wrong type.