1.Using collection

STL or ATL already provides the collection classes such as std.map, std.vector, CFastArray, CAtlArray, CAtlMap and etc. Since ProudNet can't use both STL and ATL all together, it provides the most effective classes for situations that require high performance.

1.1Array class

Proud.CFastArray is array class which can use The internal link is invalid..

1.2Linked List class

Proud.CFastList is Linked List class which can use The internal link is invalid..

The basics about Linked List Class

(What has explained below is the brief concept of list which you can ignore if you are already familiar with the subject.)

In array, there are several contents in one memory block. On the other hand, Linked List has a memory block for each content that gets connected with other contents in surrounding by link (pointer).

Comparing to array, Linked List has the following advantage and disadvantage.

그림 1-1Array vs Linked List

1.3Map class

Proud.CFastMap is Map class which can use The internal link is invalid..

The basics of map

(A brief explanation on map. You can skip this part if you already know the subject.)

The common limitation of array or Linked List is it is slow in searching. To find a specific content that has a wanted value from array or Linked List, it compares with every content one by one until the match is found. But this can be done must faster with map.

If the searching subject can be converted to the narrow range of integer value, then it could accelerate the searching speed.

First, convert value of each content to the narrow range of integer for all contents that need to be searched and group together for contents that gets converted to a same value. Then, when you want to search for content with a specific value, it will only start comparing with contents within one group that corresponds to the converted integer value of your wanted value.

The act of converting to the narrow ranged integer value is called hashing and the converted value is called hash value. And a group of contents that get converted to a same value is called bucket and a number of buckets is called hash table.

Load of map class

The size of hash table that Map class has and the number of contents that map class are related as shown in below.

Thus if there are too much of gab between the number of contents and size of hash table, you need to re-size the hash table. If hash table is too small then you need to enlarge it or the other way around.

For example, if the size of hash table is 3 times bigger than the number of contents or small as less than 10% of contents then you need to re-size it. The appropriate proportion would be for the number of contents to be 75% of the size of hash table. The hash table being 3 times bigger can be considered as maximum load, less than 10% as minimum load, and 75% as optimal load.

If you want to control such load of map, you can do so with Proud.CFastMap.CFastMap or Proud.CFastMap.SetOptimalLoad.