1 #ifndef STLEMITTER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 2 #define STLEMITTER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 4 #if defined(_MSC_VER) || \ 5 (defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \ 6 (__GNUC__ >= 4)) // GCC supports "pragma once" correctly since 3.4 16 template <
typename Seq>
17 inline Emitter& EmitSeq(Emitter& emitter,
const Seq& seq) {
19 for (
typename Seq::const_iterator it = seq.begin(); it != seq.end(); ++it)
26 inline Emitter& operator<<(Emitter& emitter, const std::vector<T>& v) {
27 return EmitSeq(emitter, v);
31 inline Emitter& operator<<(Emitter& emitter, const std::list<T>& v) {
32 return EmitSeq(emitter, v);
36 inline Emitter& operator<<(Emitter& emitter, const std::set<T>& v) {
37 return EmitSeq(emitter, v);
40 template <
typename K,
typename V>
41 inline Emitter& operator<<(Emitter& emitter, const std::map<K, V>& m) {
42 typedef typename std::map<K, V> map;
44 for (
typename map::const_iterator it = m.begin(); it != m.end(); ++it)
45 emitter << Key << it->first << Value << it->second;
51 #endif // STLEMITTER_H_62B23520_7C8E_11DE_8A39_0800200C9A66 Definition: DrawableObjectLoader.h:10