50#ifndef _SO_AUDITOR_LIST_
51#define _SO_AUDITOR_LIST_
53#include <Inventor/misc/SoNotification.h>
54#include <Inventor/STL/vector>
58#pragma warning(disable:4251)
85 struct AuditorListValue {
89 AuditorListValue(
void* auditor_, SoNotRec::Type type_)
90 : auditor(auditor_), type(type_)
95 : auditor(0), type(SoNotRec::UNDEFINED)
99 typedef std::vector<AuditorListValue> ListContainer;
102 typedef AuditorListValue value_type;
105 virtual ~SoAuditorList();
107 typedef ListContainer::iterator iterator;
108 typedef ListContainer::const_iterator const_iterator;
111 void append(
void *auditor, SoNotRec::Type type);
114 iterator find(
void *auditor, SoNotRec::Type type);
115 const_iterator find(
void *auditor, SoNotRec::Type type)
const;
118 size_t remove(
void *auditor, SoNotRec::Type type);
120 virtual int getLength()
const;
125 template<
typename Func>
126 void traverse(
const Func& func)
131 ListContainer::size_type i = m_list.size();
135 const value_type& v = m_list[i];
136 void* auditor = v.auditor;
139 SoNotRec::Type type = v.type;
147 template<
typename Func>
148 void traverse_forward(
const Func& func)
153 for (ListContainer::size_type i = 0, e = m_list.size();
157 const value_type& v = m_list[i];
158 void* auditor = v.auditor;
161 SoNotRec::Type type = v.type;
168 void notify(SoNotList *list);
171 const_iterator begin()
const;
172 const_iterator cbegin()
const;
174 const_iterator end()
const;
175 const_iterator cend()
const;
178 ListContainer m_list;
182 AuditorMap* m_fastFindDict;