/// <summary> /// Reads archive type Atom+xml feeds /// </summary> /// <param name="uri">Recent Atom feed</param> /// <param name="stateSettings">State settings</param> /// <param name="securitysettings">Security settings</param> public AtomReader(string uri, StateSettings stateSettings, SecuritySettings securitysettings, int max) { StateSettings = stateSettings; SecuritySettings = securitysettings; feedMax = max; if (stateSettings.Id == String.Empty) { feedMax = Int32.MaxValue; } nextFeed = uri; secReader = new SecureXmlReader(securitysettings); if (stateSettings.Id == String.Empty && StateSettings.WorkingFeed == String.Empty) { throw new InvalidConfiguration("Both Entry Id (state file) and First feed (configuration) cannot be empty!"); } else if (stateSettings.Id == String.Empty) { if (StateSettings.FindFirst == true) { //Find all feeds from first feed in specified atom feed MoveToFirstFeed(stateSettings.WorkingFeed); } else { //Find all feeds beginning with specified feed this.reader = secReader.Create(stateSettings.WorkingFeed); } } else { MoveToFirstFeed(uri); } }
public AtomReader(string uri, StateSettings stateSettings, SecuritySettings securitysettings) : this(uri, stateSettings, securitysettings, 10) { }