Exemplo n.º 1
0
 private void BindListCollectionView()
 {
     QueryObject q = new QueryObject(null, new List<SortObject>(), 3, 0);
     int totalResults = -1;
     _sourceList = (IList)new Person().Get(q, out totalResults);
     ListCollectionView lcv = new ListCollectionView(_sourceList);
     using (IDisposable defer = lcv.DeferRefresh())
     {
         PeopleGrid.ItemsSource = lcv;
         lcv.SortDescriptions.Add(new SortDescription("Age", ListSortDirection.Descending));
         lcv.GroupDescriptions.Add(new PropertyGroupDescription("Country"));
     }
 }
Exemplo n.º 2
0
 private void BindListCollectionView2()
 {
     QueryObject q = new QueryObject(null, new List<SortObject>(), 3, 3);
     int totalResults = -1;
     _sourceList = (IList)new Person().Get(q, out totalResults);
 }
Exemplo n.º 3
0
 public IList<Identity> Get(QueryObject Query)
 {
     return _identities;
 }
Exemplo n.º 4
0
 public List<Person> Get(QueryObject Query, out int totalResults)
 {
     List<Person> people = People.Skip(Query.Offset).Take(Query.PageSize).ToList();
     totalResults = 8;
     return people;
 }