public static IReferenceDataCollection GetCollection(Type type) { if (!cacheDict.ContainsKey(Check.NotNull(type, nameof(type)))) { throw new ArgumentException(string.Format("Type {0} does not exist within the ReferenceDataDataSvc cache.", type.Name)); } IReferenceDataCache rdc = (IReferenceDataCache)cacheDict[type]; return(rdc.GetCollection()); }
public static IReferenceDataCollection GetCollection(Type type) { if (type == null) { throw new ArgumentNullException(nameof(type)); } if (!cacheDict.ContainsKey(type)) { throw new ArgumentException($"Type {type.Name} does not exist within the ReferenceDataDataSvc cache.", nameof(type)); } IReferenceDataCache rdc = (IReferenceDataCache)cacheDict[type]; return(rdc.GetCollection()); }