blob: 2fa27b998d2edb45ce48e5dcd524bebba26347f5 [file] [log] [blame]
Shuo Chen9c2477f2014-03-13 15:01:06 -07001/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
Alexander Afanasyevc0e26582017-08-13 21:16:49 -04002/*
Davide Pesavento11904062022-04-14 22:33:28 -04003 * Copyright (c) 2014-2022, Regents of the University of California.
Alexander Afanasyeve1e6f2a2014-04-25 11:28:12 -07004 *
5 * This file is part of NDN repo-ng (Next generation of NDN repository).
6 * See AUTHORS.md for complete list of repo-ng authors and contributors.
7 *
8 * repo-ng is free software: you can redistribute it and/or modify it under the terms
9 * of the GNU General Public License as published by the Free Software Foundation,
10 * either version 3 of the License, or (at your option) any later version.
11 *
12 * repo-ng is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
13 * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 * PURPOSE. See the GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License along with
17 * repo-ng, e.g., in COPYING.md file. If not, see <http://www.gnu.org/licenses/>.
Shuo Chen9c2477f2014-03-13 15:01:06 -070018 */
Shuo Chenba793e92014-03-17 17:17:16 -070019
Alexander Afanasyev39d98072014-05-04 12:46:29 -070020#ifndef REPO_COMMON_HPP
21#define REPO_COMMON_HPP
Shuo Chen9c2477f2014-03-13 15:01:06 -070022
Nick Gordon190e4dc2017-10-04 16:54:10 -050023#include "config.hpp"
24
weijia yuan3aa8d2b2018-03-06 15:35:57 -080025#include <ndn-cxx/data.hpp>
Alexander Afanasyeve291caf2014-04-25 11:17:36 -070026#include <ndn-cxx/face.hpp>
Alexander Afanasyev39d98072014-05-04 12:46:29 -070027#include <ndn-cxx/interest.hpp>
weijia yuan3aa8d2b2018-03-06 15:35:57 -080028#include <ndn-cxx/name.hpp>
Alexander Afanasyeve291caf2014-04-25 11:17:36 -070029#include <ndn-cxx/util/scheduler.hpp>
Davide Pesavento11904062022-04-14 22:33:28 -040030#include <ndn-cxx/util/time.hpp>
Alexander Afanasyev39d98072014-05-04 12:46:29 -070031
Davide Pesavento11904062022-04-14 22:33:28 -040032#include <boost/core/noncopyable.hpp>
Alexander Afanasyev39d98072014-05-04 12:46:29 -070033
Davide Pesavento49f3a5f2017-09-23 01:36:33 -040034#include <algorithm>
35#include <functional>
Davide Pesavento11904062022-04-14 22:33:28 -040036#include <iosfwd>
Davide Pesavento49f3a5f2017-09-23 01:36:33 -040037#include <list>
Shuo Chen9c2477f2014-03-13 15:01:06 -070038#include <map>
Davide Pesavento49f3a5f2017-09-23 01:36:33 -040039#include <memory>
Davide Pesavento11904062022-04-14 22:33:28 -040040#include <stdexcept>
Alexander Afanasyev39d98072014-05-04 12:46:29 -070041#include <string>
42#include <vector>
Shuo Chen9c2477f2014-03-13 15:01:06 -070043
Nick Gordon190e4dc2017-10-04 16:54:10 -050044#ifdef HAVE_TESTS
45#define PUBLIC_WITH_TESTS_ELSE_PRIVATE public
46#else
47#define PUBLIC_WITH_TESTS_ELSE_PRIVATE private
48#endif
49
Shuo Chen9c2477f2014-03-13 15:01:06 -070050namespace repo {
Shuo Chenba793e92014-03-17 17:17:16 -070051
Alexander Afanasyev39d98072014-05-04 12:46:29 -070052using boost::noncopyable;
53
Davide Pesavento11904062022-04-14 22:33:28 -040054using ndn::Face;
55using ndn::Block;
56using ndn::Name;
57using ndn::Interest;
58using ndn::Data;
59using ndn::Scheduler;
60
61using ndn::operator""_block;
62namespace time = ndn::time;
63using namespace ndn::time_literals;
64
65using ProcessId = uint64_t;
66using SegmentNo = uint64_t;
Shuo Chen29c77fe2014-03-18 11:29:41 -070067
Alexander Afanasyev39d98072014-05-04 12:46:29 -070068} // namespace repo
Shuo Chen9c2477f2014-03-13 15:01:06 -070069
Alexander Afanasyev39d98072014-05-04 12:46:29 -070070#endif // REPO_COMMON_HPP