title: Sharepoint 2010 Client Object Model get a List item from a Url
body: <p>Is there a way to get a List object by a Url?</p>
  
  <p>I know you can get a list by a title:</p>
  
  <pre><code>ClientContext context = new ClientContext("http://foo");
  
  List list = context.Web.Lists.GetByTitle("title");
  
  context.Load(list);
  context.ExecuteQuery();
  </code></pre>
  
  <p>But I want the user to be able to copy-paste a url from their browser in a textbox (e.g. <a href="http://foo/subsite/ListName/Forms/AllItems.aspx">http://foo/subsite/ListName/Forms/AllItems.aspx</a>) and then extract the List object from that url.</p>