OpenMW
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
subcellcollection.hpp
Go to the documentation of this file.
1 #ifndef CSM_WOLRD_SUBCOLLECTION_H
2 #define CSM_WOLRD_SUBCOLLECTION_H
3 
4 #include "nestedidcollection.hpp"
5 
6 namespace ESM
7 {
8  class ESMReader;
9 }
10 
11 namespace CSMWorld
12 {
13  struct Cell;
14  template<typename T, typename AT>
15  class IdCollection;
16 
18  template<typename ESXRecordT, typename IdAccessorT = IdAccessor<ESXRecordT> >
19  class SubCellCollection : public NestedIdCollection<ESXRecordT, IdAccessorT>
20  {
22 
23  virtual void loadRecord (ESXRecordT& record, ESM::ESMReader& reader, bool& isDeleted);
24 
25  public:
26 
28  };
29 
30  template<typename ESXRecordT, typename IdAccessorT>
32  ESM::ESMReader& reader,
33  bool& isDeleted)
34  {
35  record.load (reader, isDeleted, mCells);
36  }
37 
38  template<typename ESXRecordT, typename IdAccessorT>
40  const IdCollection<Cell>& cells)
41  : mCells (cells)
42  {}
43 }
44 
45 #endif
Single type collection of top level records.
Definition: idcollection.hpp:12
Definition: esmreader.hpp:21
virtual void loadRecord(ESXRecordT &record, ESM::ESMReader &reader, bool &isDeleted)
Definition: subcellcollection.hpp:31
const IdCollection< Cell > & mCells
Definition: subcellcollection.hpp:21
SubCellCollection(const IdCollection< Cell > &cells)
Definition: subcellcollection.hpp:39