private WebContentRetrievingProfile CreateRetrievingProfile() { var profile = new WebContentRetrievingProfile(@"<form name=""Login"".*action=""(?<url>.*?)"""); profile.AddExpression(@"<input.*name=""__EVENTTARGET"".*value=""(?<eventTarget>.*?)"""); profile.AddExpression(@"<input.*name=""__EVENTARGUMENT"".*value=""(?<eventArgument>.*?)"""); profile.AddExpression(@"<input.*name=""__VIEWSTATE"".*value=""(?<viewstate>.*?)"""); profile.AddExpression(@"<input.*name=""__VIEWSTATEGENERATOR"".*value=""(?<viewstateGenerator>.*?)"""); return profile; }
public WebContentRetriever(WebContentRetrievingProfile profile) { _profile = profile; }