diff --git a/src/torrent-manager.hpp b/src/torrent-manager.hpp
new file mode 100644
index 0000000..3c4b923
--- /dev/null
+++ b/src/torrent-manager.hpp
@@ -0,0 +1,128 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
+/**
+* Copyright (c) 2016 Regents of the University of California.
+*
+* This file is part of the nTorrent codebase.
+*
+* nTorrent is free software: you can redistribute it and/or modify it under the
+* terms of the GNU Lesser General Public License as published by the Free Software
+* Foundation, either version 3 of the License, or (at your option) any later version.
+*
+* nTorrent is distributed in the hope that it will be useful, but WITHOUT ANY
+* WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+* PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
+*
+* You should have received copies of the GNU General Public License and GNU Lesser
+* General Public License along with nTorrent, e.g., in COPYING.md file. If not, see
+* <http://www.gnu.org/licenses/>.
+*
+* See AUTHORS for complete list of nTorrent authors and contributors.
+*/
+#ifndef INCLUDED_TORRENT_FILE_MANAGER_H
+#define INCLUDED_TORRENT_FILE_MANAGER_H
+
+#include "torrent-file.hpp"
+#include "file-manifest.hpp"
+
+#include <ndn-cxx/name.hpp>
+#include <ndn-cxx/data.hpp>
+
+#include <boost/filesystem/fstream.hpp>
+#include <boost/utility.hpp>
+
+#include <functional>
+#include <memory>
+#include <string>
+#include <unordered_map>
+#include <vector>
+
+namespace fs = boost::filesystem;
+
+namespace ndn {
+namespace ntorrent {
+
+class TorrentManager : boost::noncopyable {
+  /**
+   * \class TorrentManager
+   *
+   * \brief A class to manage the interaction with the system in seeding/leaching a torrent
+   */
+ public:
+  typedef std::function<void(const ndn::Name&)>                     DataReceivedCallback;
+  typedef std::function<void(const std::vector<ndn::Name>&)>        ManifestReceivedCallback;
+  typedef std::function<void(const ndn::Name&, const std::string&)> FailedCallback;
+
+  TorrentManager(const ndn::Name&   torrentFileName,
+                 const std::string& dataPath);
+  /*
+   * \brief Create a new Torrent manager with the specified parameters.
+   * @param torrentFileName The full name of the initial segment of the torrent file
+   * @param filePath The path to the location on disk to use for the torrent data
+   *
+   * The behavior is undefined unless Initialize() is called before calling any other method on a
+   * TorrentManger object.
+   */
+
+  void Initialize();
+  /*
+   * \brief Initialize the state of this object.
+   * Read and validate from disk all torrent file segments, file manifests, and data packets for
+   * the torrent file managed by this object initializing all state in this manager respectively.
+   * Also seeds all validated data.
+   */
+
+  std::vector<Name> downloadTorrentFile(const std::string& path = "");
+  // Request from the network the all segments of the 'torrentFileName' and write onto local disk at
+  // the specified 'path'.
+
+  void download_file_manifest(const Name&              manifestName,
+                              const std::string&       path,
+                              ManifestReceivedCallback onSuccess,
+                              FailedCallback           onFailed) const;
+  // Request from the network the all segments of the 'manifestName' and write onto local disk at
+  // the specified 'path'.
+
+  void download_data_packet(const Name&          packetName,
+                            DataReceivedCallback onSuccess,
+                            FailedCallback       onFailed) const;
+  // Request from the network the Data with the specified 'packetName' and write onto local disk at
+  // 'm_dataPath'.
+
+  void seed(const Data& data) const;
+  // Seed the specified 'data' to the network.
+
+ protected:
+  void onDataReceived(const Data& data);
+
+  void onInterestReceived(const Name& name);
+
+  // A map from each fileManifest to corresponding file stream on disk and a bitmap of which Data
+  // packets this manager currently has
+  mutable std::unordered_map<Name,
+                             std::pair<std::shared_ptr<fs::fstream>,
+                                       std::vector<bool>>>            m_fileStates;
+  // The segments of the TorrentFile this manager has
+  std::vector<TorrentFile>                                            m_torrentSegments;
+  // The FileManifests this manager has
+  std::vector<FileManifest>                                           m_fileManifests;
+  // The name of the initial segment of the torrent file for this manager
+  Name                                                                m_torrentFileName;
+  // The path to the location on disk of the Data packet for this manager
+  std::string                                                         m_dataPath;
+};
+
+inline
+TorrentManager::TorrentManager(const ndn::Name&   torrentFileName,
+                               const std::string& dataPath)
+: m_fileStates()
+, m_torrentSegments()
+, m_fileManifests()
+, m_torrentFileName(torrentFileName)
+, m_dataPath(dataPath)
+{
+}
+
+}  // end ntorrent
+}  // end ndn
+
+#endif // INCLUDED_TORRENT_FILE_MANAGER_H
\ No newline at end of file
