Alexander Afanasyev | 6e3d1ac | 2014-07-21 12:47:49 -0700 | [diff] [blame] | 1 | /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ |
| 2 | /** |
| 3 | * Copyright (c) 2014, Regents of the University of California. |
shockjiang | e9c1ab9 | 2014-07-21 12:02:52 -0700 | [diff] [blame] | 4 | * |
Alexander Afanasyev | 6e3d1ac | 2014-07-21 12:47:49 -0700 | [diff] [blame] | 5 | * This file is part of NDNS (Named Data Networking Domain Name Service). |
| 6 | * See AUTHORS.md for complete list of NDNS authors and contributors. |
| 7 | * |
| 8 | * NDNS 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 | * NDNS 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 | * NDNS, e.g., in COPYING.md file. If not, see <http://www.gnu.org/licenses/>. |
shockjiang | e9c1ab9 | 2014-07-21 12:02:52 -0700 | [diff] [blame] | 18 | */ |
shockjiang | a5ae48c | 2014-07-27 23:21:41 -0700 | [diff] [blame] | 19 | #include "ndn-app.hpp" |
shockjiang | e9c1ab9 | 2014-07-21 12:02:52 -0700 | [diff] [blame] | 20 | |
| 21 | namespace ndn { |
Alexander Afanasyev | 6e3d1ac | 2014-07-21 12:47:49 -0700 | [diff] [blame] | 22 | namespace ndns { |
shockjiang | e9c1ab9 | 2014-07-21 12:02:52 -0700 | [diff] [blame] | 23 | |
shockjiang | a5ae48c | 2014-07-27 23:21:41 -0700 | [diff] [blame] | 24 | NDNApp::NDNApp(const char *programName, const char *prefix) |
| 25 | : m_programName(programName) |
| 26 | , m_prefix(prefix) |
| 27 | , m_hasError(false) |
| 28 | , m_contentFreshness(time::milliseconds(40000)) |
| 29 | , m_interestLifetime(time::milliseconds(4000)) |
| 30 | , m_interestTriedMax(2) |
| 31 | , m_interestTriedNum(0) |
| 32 | , m_face(m_ioService) |
shockjiang | 99ad389 | 2014-08-03 14:56:13 -0700 | [diff] [blame] | 33 | , m_enableForwardingHint(0) |
| 34 | , m_forwardingHint("/") |
Alexander Afanasyev | 6e3d1ac | 2014-07-21 12:47:49 -0700 | [diff] [blame] | 35 | { |
shockjiang | e9c1ab9 | 2014-07-21 12:02:52 -0700 | [diff] [blame] | 36 | } |
Alexander Afanasyev | 6e3d1ac | 2014-07-21 12:47:49 -0700 | [diff] [blame] | 37 | |
shockjiang | a5ae48c | 2014-07-27 23:21:41 -0700 | [diff] [blame] | 38 | NDNApp::~NDNApp() |
Alexander Afanasyev | 6e3d1ac | 2014-07-21 12:47:49 -0700 | [diff] [blame] | 39 | { |
shockjiang | a5ae48c | 2014-07-27 23:21:41 -0700 | [diff] [blame] | 40 | m_programName = 0; |
| 41 | m_prefix = 0; |
shockjiang | e9c1ab9 | 2014-07-21 12:02:52 -0700 | [diff] [blame] | 42 | } |
Alexander Afanasyev | 6e3d1ac | 2014-07-21 12:47:49 -0700 | [diff] [blame] | 43 | |
shockjiang | a5ae48c | 2014-07-27 23:21:41 -0700 | [diff] [blame] | 44 | } //namespace ndns |
| 45 | } /* namespace ndn */ |