title: how can i store and reuse pieces of my lambda expressions
body: <p>I have a block of code where a piece of the lambda expression is used again and again. How can store this logic so that i can reuse this expression piece?</p>
  
  <p>Eg: lets take the example of the code given below</p>
  
  <pre><code>Session.Query&lt;DimensionGroup&gt;()(dimgroup=&gt;(dimgroup.Users.Where(map =&gt; 
  ((map.User.Key == _users.PublicUser.Key || map.User.Key == _users.CurrentUser.Key) &amp;&amp;
  map.AccessLevel.ToAccessLevel() == AccessLevel.Write)).Count() &gt; 0));
  </code></pre>
  
  <p><code>(map.User.Key == _users.PublicUser.Key || map.User.Key == _users.CurrentUser.Key)</code> being the portion I want to reuse.</p>
  
  <p>and a similar piece of code...  </p>
  
  <pre><code>Session.Query&lt;DimensionGroup&gt;()(dimgroup =&gt;(dimgroup.Users.Where(map =&gt; ((map.User.Key
  ==_users.PublicUser.Key || map.User.Key == _users.CurrentUser.Key) &amp;&amp;
  map.AccessLevel.ToAccessLevel() ==  AccessLevel.Read)).Count() &gt; 0));
  </code></pre>
  
  <p><code>(map.User.Key
      == _users.PublicUser.Key || map.User.Key == _users.CurrentUser.Key)</code> being the portion I want to reuse.</p>
  
  <p>Is there some way I can reuse just those parts of the expression? </p>