blob: 68ffd668c2ec1650795116a85c8a98e652a93353 [file] [log] [blame]
tylerliubcd83482020-10-07 14:45:28 -07001//
2// Created by Tyler on 10/6/20.
3//
4
5#ifndef NDNCERT_ASSIGNMENT_OR_HPP
6#define NDNCERT_ASSIGNMENT_OR_HPP
7
8#include "assignment-funcs.hpp"
9
10namespace ndn {
11namespace ndncert {
12
13/**
14 * assign names base on client probe parameter
15 */
16class AssignmentOr: public NameAssignmentFuncFactory{
17public:
18 AssignmentOr();
19
20 NameAssignmentFunc getFunction(std::list<NameAssignmentFunc> funcs);
21
22 NameAssignmentFunc getFunction(const std::string &factoryParam) override;
23
24 class OrAssignmentFunc {
25 public:
26 OrAssignmentFunc(std::list<NameAssignmentFunc> funcList);
27
28 std::vector<PartialName>
29 operator() (const std::vector<std::tuple<std::string, std::string>> params);
30 private:
31 std::list<NameAssignmentFunc> m_funcList;
32 };
33
34};
35}
36}
37
38
39
40#endif //NDNCERT_ASSIGNMENT_OR_HPP