segregator< Allocators > Class Template Reference
Adapters and Wrappers

## Detailed Description

template<class... Allocators>
class foonathan::memory::segregator< Allocators >

Creates multiple nested binary_segregator.

If you pass one type, it must be a Segregatable. Then the result is a binary_segregator with that `Segregatable` and null_allocator as fallback. If you pass two types, the first one must be a `Segregatable`, the second one a RawAllocator. Then the result is a simple binary_segregator with those arguments. If you pass more than one, the last one must be a `RawAllocator` all others `Segregatable`, the result is `binary_segregator<Head, segregator<Tail...>>`.

Note
  It will result in an allocator that tries each `Segregatable` in the order specified using the last parameter as final fallback.

## Related Symbols

template<std::size_t I, class Segregator >
using | segregatable_allocator_type = typename detail::segregatable_type< I, Segregator >::type
| The type of the `I`th Segregatable.
template<class Segregator >
using | fallback_allocator_type = typename detail::fallback_type< Segregator >::type
| The type of the final fallback RawAllocator.
template<typename... Args>
auto | make_segregator (Args &&... args) -> segregator< typename std::decay< Args >::type... >

## Related Functions

## segregatable_allocator_type

template<class... Allocators>
template<std::size_t I, class Segregator >

using segregatable_allocator_type = typename detail::segregatable_type<I, Segregator>::type

related

The type of the `I`th Segregatable.

## fallback_allocator_type

template<class... Allocators>
template<class Segregator >

using fallback_allocator_type = typename detail::fallback_type<Segregator>::type

related

The type of the final fallback RawAllocator.

## make_segregator()

template<typename... Args>

auto make_segregator | ( | Args &&... | args | ) | -> segregator<typename std::decay<Args>::type...>

related

Returns:
  A segregator created from the allocators `args`.