1 #ifndef guard_value_traits_hpp
2 #define guard_value_traits_hpp
6 * @brief Implement the element manipulation traits for types with
7 * value-like semantics.
9 * @author Carlos O'Ryan
12 #include /**/ "tao/Versioned_Namespace.h"
16 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
22 template<typename T
, bool dummy
>
26 typedef T
const const_value_type
;
28 inline static void zero_range(
29 value_type
* begin
, value_type
* end
)
31 std::fill(begin
, end
, value_type ());
34 inline static void initialize_range(
35 value_type
* begin
, value_type
* end
)
37 std::fill(begin
, end
, value_type ());
40 inline static void release_range(
41 value_type
*, value_type
*)
43 // Noop for value sequences
46 // Allow MSVC++ >= 8 checked iterators to be used.
47 template <typename iter
>
48 inline static void copy_range(
49 value_type
* begin
, value_type
* end
, iter dst
)
51 std::copy(begin
, end
, dst
);
54 // Allow MSVC++ >= 8 checked iterators to be used.
55 template <typename iter
>
56 inline static void copy_swap_range(
57 value_type
* begin
, value_type
* end
, iter dst
)
59 copy_range(begin
, end
, dst
);
62 } // namespace details
65 TAO_END_VERSIONED_NAMESPACE_DECL
67 #endif // guard_value_traits_hpp