Home | Libraries | People | FAQ | More |
boost::container::devector_growth_policy
// In header: <boost/container/devector.hpp> struct devector_growth_policy { // public static functions template<typename SizeType> static SizeType new_capacity(SizeType); template<typename SizeType> static bool should_shrink(SizeType, SizeType, SizeType); };
Controls a devectors reallocation policy.
Models the GrowthPolicy
concept of the devector class.
devector_growth_policy
public static functionstemplate<typename SizeType> static SizeType new_capacity(SizeType capacity);
Returns: 4 times the old capacity or 16 if it's 0.
Parameters: |
|
template<typename SizeType> static bool should_shrink(SizeType size, SizeType capacity, SizeType small_buffer_size);
Returns: true, if the contents fit in the small buffer.
Parameters: |
|