c# - Ignoring items in collection with Automapper when mapping collection -


i mapping collection of items

var list<a> mycollection = new list<a>();  public class {     bool haschanges {get;set;} }  var mappedcollection = map(mycollection); 

then want map items haschanges == true

is possible?

with linq:

var mappedcollection = map(mycollection.where(x => x.haschanges == true).tolist()); 

Comments

Popular posts from this blog

angularjs - ADAL JS Angular- WebAPI add a new role claim to the token -

php - CakePHP HttpSockets send array of paramms -

node.js - Using Node without global install -