accessPathClassNames.add(meta.getDescribedType().getName());
}
// if any of the types are currently dirty, we can't cache this query
StoreContext ctx = q.getStoreContext();
if (intersects(accessPathClassNames, ctx.getPersistedTypes())
|| intersects(accessPathClassNames, ctx.getUpdatedTypes())
|| intersects(accessPathClassNames, ctx.getDeletedTypes()))
return null;
// calculate the timeout for the key
MetaDataRepository repos = ctx.getConfiguration().
getMetaDataRepositoryInstance();
// won't find metadata for interfaces.
if (candidateClass.isInterface())
return null;
meta = repos.getMetaData(candidateClass, ctx.getClassLoader(), true);
int timeout = meta.getDataCacheTimeout();
if (subclasses) {
metas = meta.getPCSubclassMetaDatas();
int subTimeout;
for (int i = 0; i < metas.length; i++) {