torc-master
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
BrowserMain.cpp
Go to the documentation of this file.
1 // Torc - Copyright 2011-2013 University of Southern California. All Rights Reserved.
2 // $HeadURL$
3 // $Id$
4 
5 // This program is free software: you can redistribute it and/or modify it under the terms of the
6 // GNU General Public License as published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
8 //
9 // This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
10 // without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
11 // the GNU General Public License for more details.
12 //
13 // You should have received a copy of the GNU General Public License along with this program. If
14 // not, see <http://www.gnu.org/licenses/>.
15 
16 /// \file
17 /// \brief Source for a PhysicalDiff command line utility.
18 /// \details Opens up two designs with the XDLImporter and then compares them with PhysicalDiff.
19 
20 #include <fstream>
21 #include "ArchitectureBrowser.hpp"
23 
24 /// \brief Main entry point for the architecture browser tool.
25 int main(int argc, char *argv[]) {
26  typedef std::string string;
27  torc::common::DirectoryTree directoryTree(argv[0]);
28 
29  if (argc != 2) {
30  std::cout << "Usage: " << argv[0] << " <device>" << std::endl;
31  return 1;
32  }
33  string device_arg = argv[1];
34 
35  torc::common::DeviceDesignator device(device_arg);
36  torc::architecture::DDB db(device);
38  ab.browse();
39 
40  return 0;
41 }
42 
Utility class for exploring database contents.
Encapsulation of a device designator and its constituent elements.
Device database, including complete wiring and logic support.
Definition: DDB.hpp:42
int main(int argc, char *argv[])
Main entry point for the architecture browser tool.
Definition: BrowserMain.cpp:25
Header for the DirectoryTree class.
std::string string
void browse()
Function to begin an interactive browsing session.
Encapsulation of filesystem paths that are used by the library.
ArchitectureBrowser class for exploring database contents.