Warning, file /include/orange/detail/DepthCalculator.hh was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004
0005
0006
0007 #pragma once
0008
0009 #include <unordered_map>
0010 #include <vector>
0011
0012 #include "corecel/cont/VariantUtils.hh"
0013
0014 #include "../OrangeInput.hh"
0015
0016 namespace celeritas
0017 {
0018 namespace detail
0019 {
0020
0021
0022
0023
0024 class DepthCalculator
0025 {
0026 public:
0027
0028
0029 using VecVarUniv = std::vector<VariantUniverseInput>;
0030
0031
0032 public:
0033
0034 explicit DepthCalculator(VecVarUniv const&);
0035
0036
0037 size_type operator()();
0038
0039
0040 size_type operator()(UnitInput const& u);
0041
0042
0043 size_type operator()(RectArrayInput const& u);
0044
0045 private:
0046 ContainerVisitor<VecVarUniv const&> visit_univ_;
0047 std::size_t num_univ_{0};
0048 std::unordered_map<UniverseId, size_type> depths_;
0049
0050
0051 size_type operator()(UniverseId univ_id);
0052 };
0053
0054
0055 }
0056 }