Exemple #1
0
        public override Type BindToType(string assemblyName, string typeName)
        {
            if (_typesRegistry.TryGetValue(typeName, out var type))
            {
                return(type);
            }

            _logger.LogWarn($"Unable to resolve type-name: {typeName}");
            return(base.BindToType(assemblyName, typeName));
        }
Exemple #2
0
        public IEnumerable <T> GetAll <T>() where T : Resource
        {
            IList result;

            if (_resByType.TryGetValue(typeof(T), out result))
            {
                return(result.Cast <T>());
            }

            _logger.LogWarn("Cannot find ");
            return(new List <T>());
        }