}
}
private MetaData setupMetaData(Class<?> clazz, Annotation...annotations)
{
MutableMetaDataRepository repository = new BasicMetaDataRepository();
ScopeKey scopeKey = ScopeKey.DEFAULT_SCOPE.clone();
scopeKey.addScope(CommonLevels.INSTANCE, "Test");
scopeKey.addScope(CommonLevels.CLASS, clazz.getName());
scopeKey.addScope(CommonLevels.WORK, String.valueOf(hashCode()));
ScopeKey mutableScope = new ScopeKey(CommonLevels.INSTANCE, "Test".toString());
MemoryMetaDataLoader mutable = new MemoryMetaDataLoader(mutableScope);
repository.addMetaDataRetrieval(mutable);
addClassAnnotations(clazz, mutable, annotations);
MetaData metadata = new MetaDataRetrievalToMetaDataBridge(mutable);
return metadata;