Main Page | Namespace List | Compound List | File List | Compound Members | File Members

main.cc

Go to the documentation of this file.
00001 /*--------------------------------------------------------------------
00002  *
00003  * (C) Copyright Koninklijke Philips Electronics NV 2006. 
00004  * All rights reserved. This software is licensed under the terms of
00005  * version 2.1 of the GNU Lesser General Public License as published 
00006  * by the Free Software Foundation. For licensing and warranty
00007  * information, see the file COPYING in the main directory.
00008  *
00009  *------------------------------------------------------------------*/
00010 
00011 #include "yapi.h"
00012 #include "pc.h"
00013 #include <fstream>
00014 
00015 using namespace std;
00016 
00017 int main()
00018 {
00019   // create yapi run-time environment
00020   RTE rte;
00021 
00022   // redirect standard output
00023   ofstream f("./Results/pc.out");
00024   rte.setOutStream(f);
00025 
00026   // redirect standard error
00027   ofstream g("./Results/pc.err");
00028   rte.setErrorStream(g);
00029 
00030   // create toplevel process network
00031   PC pc( id("pc") );
00032 
00033   // start the process network and
00034   // wait for processes to finish
00035   rte.start(pc);
00036 
00037   // print workload
00038   ofstream h("./Results/pc.workload");
00039   printWorkload(pc, h);
00040 
00041   // generate dotty file
00042   ofstream i("./Results/pc.dot");
00043   printDotty(pc, i);
00044 
00045   f.close();
00046   g.close();
00047   h.close();
00048   i.close();
00049   
00050   return 0;
00051 }

Generated on Wed Feb 15 14:52:42 2006 for pc by doxygen 1.3.2