private ITypeSpecImmutable GetSpecificationFromCache(Type type) { var key = classStrategy.GetKeyForType(type); TypeUtils.GetType(type.FullName); // This should ensure type is cached return(cache.GetSpecification(key)); }
public IObjectSpecImmutable GetSpecification(string name) { try { Type type = TypeUtils.GetType(name); return(GetSpecification(type)); } catch (Exception e) { Log.InfoFormat("Failed to Load Specification for: {0} error: {1} trying cache", name, e); IObjectSpecImmutable spec = cache.GetSpecification(name); if (spec != null) { Log.InfoFormat("Found {0} in cache", name); return(spec); } throw; } }