Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Everything / collections

Collections

collections

Great Reads

by Aydin Homay
In this article, I tried to show a real benchmark based on presser test method, for a Big Data collection deals on C++, C#, and VB.NET.
by Maciej Los
If you want to know the way you can serialize and deserialize custom class collection, this tip is for you.
by rtybase
There is one ambiguous moment in the Java documentation of the compute() method from the ConcurrentHashMap class.
by honey the codewitch
A circular buffer implementing IList

Latest Articles

by Aydin Homay
In this article, I tried to show a real benchmark based on presser test method, for a Big Data collection deals on C++, C#, and VB.NET.
by Maciej Los
If you want to know the way you can serialize and deserialize custom class collection, this tip is for you.
by rtybase
There is one ambiguous moment in the Java documentation of the compute() method from the ConcurrentHashMap class.
by honey the codewitch
A circular buffer implementing IList

All Articles

Sort by Score

collections 

by Maciej Los
If you want to know the way you can serialize and deserialize custom class collection, this tip is for you.
by honey the codewitch
A circular buffer implementing IList
by honey the codewitch
A fully generic ordered dictionary class in C#
by B. Verboven
Convert a generic list of (recursive) objects into a simple hierarchical TreeList
by B. Verboven
This is an alternative for "A simple generic TreeList".
by Yuriy Magurdumov
Simple generic data structure to maintain hierarchical objects
by Bohdan Stupak
Batching is a nice technique that allows you to handle big amounts of data gracefully. Directory.EnumerateFiles is the API that allows you to organize batch processing for the directory with a large number of files.
by honey the codewitch
A B-tree, an AVL tree, and a Splay tree in C#
by CalicoSkies
How to use istream_iterator and the copy algorithm to populate an STL collection from a text file with very little code
by Gordon Kushner
If you try to enumerate through a Dictionary's key collection and attempt to change the values as in the code below, Dictionary _items = new Dictionary();...int i = 0;//Attempt to set the values for this Dictionary item.foreach (string key in...
by nit_singh
This is an example to Convert from a datatable to a specific type of collection using Generic
by Vano Maisuradze
Very nice!I've modified ToCollection(this DataTable dt) extension function, so if DataTable column names and class property names are different, then you can use this alternative:public static List ToCollection(this DataTable table, Dictionary dic){ List lst = new...
by Damian Flynn
Here's a couple of gems...From IList to DataTable.From DataTable to array of T.// DataTable: from IListpublic static DataTable ToDataTable(this IList iList){ DataTable dataTable = new DataTable(); PropertyDescriptorCollection propertyDescriptorCollection = ...
by honey the codewitch
A relatively safe, simple, yet high performance technique for using lists as dictionary keys.
by honey the codewitch
This tip shows you a robust way to get the type of items a collection can hold. It works with non-generic collections too.
by honey the codewitch
Fills a gap in Microsoft's Queue offering with an alternative allowing efficient indexed access
by vudangngoc
Travelling over Java collections is just a piece of cake, but when the size of the collections increases you have to choose wisely
by honey the codewitch
Easily implement efficient backtracking capabilities over any enumeration
by #realJSOP
In WPF/Silverlight, you might want to bind to a dictionary. Here's a couple of websites I found.
by Nick Alexeev
Returning read-only collection
by Mohammad Mir mostafa
Another good idea is to return the list as enumerable using:return m_privateCollection.AsEnumerable();Now what are the differences?AsReadOnly() creates a completely new collection of list. Depending on the count of items and where the resource is, this may take a long...
by honey the codewitch
Easily compare collections for equality
by honey the codewitch
Using IEqualityComparer to allow collections to be keys in dictionaries and hashsets
by Gregory Morse
WRL Collection library ported to native C++