blob: 4d7a5b0b083da2c3d0ec6d33fb6f8d91c3315280 [file] [log] [blame]
Junxiao Shid3c792f2014-01-30 00:46:13 -07001/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2/**
3 * Copyright (C) 2014 Named Data Networking Project
4 * See COPYING for copyright and distribution information.
5 */
6
7#ifndef NFD_FW_BEST_ROUTE_STRATEGY_HPP
8#define NFD_FW_BEST_ROUTE_STRATEGY_HPP
9
10#include "strategy.hpp"
11
12namespace nfd {
Junxiao Shi8c8d2182014-01-30 22:33:00 -070013namespace fw {
Junxiao Shid3c792f2014-01-30 00:46:13 -070014
15/** \class BestRouteStrategy
16 * \brief a forwarding strategy that forwards Interest
17 * to the first nexthop
18 */
19class BestRouteStrategy : public Strategy
20{
21public:
22 explicit
Junxiao Shi8c8d2182014-01-30 22:33:00 -070023 BestRouteStrategy(Forwarder& forwarder);
Junxiao Shid3c792f2014-01-30 00:46:13 -070024
25 virtual
26 ~BestRouteStrategy();
27
28 virtual void
29 afterReceiveInterest(const Face& inFace,
30 const Interest& interest,
31 shared_ptr<fib::Entry> fibEntry,
Junxiao Shi8c8d2182014-01-30 22:33:00 -070032 shared_ptr<pit::Entry> pitEntry);
Junxiao Shid3c792f2014-01-30 00:46:13 -070033};
34
Junxiao Shi8c8d2182014-01-30 22:33:00 -070035} // namespace fw
Junxiao Shid3c792f2014-01-30 00:46:13 -070036} // namespace nfd
37
38#endif // NFD_FW_BEST_ROUTE_STRATEGY_HPP