public SitemapRepository( IEnumerable <ISitemapStrategy> strategies, IEntryConverter converter, IHostBindingsService hostBindingsService, ICache <byte[]> cache) { if (strategies == null) { throw new ArgumentNullException("strategies"); } if (converter == null) { throw new ArgumentNullException("converter"); } if (hostBindingsService == null) { throw new ArgumentNullException("hostBindingsService"); } if (cache == null) { throw new ArgumentNullException("cache"); } _strategies = strategies; _converter = converter; _hostBindingsService = hostBindingsService; _cache = cache; }
public void Configure(XElement xml) { EntryFormatter = ConstructOrDefault<IEntryConverter<string>>(xml.GetAttributeValue("EntryFormatter", "Formatter")); var cap = xml.GetAttributeValue("cap") ?? xml.GetAttributeValue("capacity"); Capacity = Attempt.Get<int?>(() => int.Parse(cap)).Value; }
public SitemapRepository( IEnumerable<ISitemapStrategy> strategies, IEntryConverter converter, IHostBindingsService hostBindingsService, ICache<byte[]> cache) { if (strategies == null) throw new ArgumentNullException("strategies"); if (converter == null) throw new ArgumentNullException("converter"); if (hostBindingsService == null) throw new ArgumentNullException("hostBindingsService"); if (cache == null) throw new ArgumentNullException("cache"); _strategies = strategies; _converter = converter; _hostBindingsService = hostBindingsService; _cache = cache; }
public void Configure(XElement xml) { EntryFormatter = ConstructOrDefault<IEntryConverter<string>>(xml.GetAttributeValue("EntryFormatter", "Formatter")); }