Prepared documentation for release 0.4
[AXE.git] / demos / timesheet.cpp
index 169f340..da349c4 100644 (file)
@@ -1,4 +1,4 @@
-#include "date.h"
+#include <AXE/date.h>
 
 class activity
 {
@@ -41,17 +41,17 @@ main()
    hour t1, t2;
    String action1, action2, datestring;
 
-   cin >> datestring;
-   cin >> action1;
+   std::cin >> datestring;
+   std::cin >> action1;
    d1 = date(datestring);
    t1 = hour(datestring);
 
-   while (cin)
+   while (std::cin)
    {
-      cin >> datestring;
+      std::cin >> datestring;
       d2 = date(datestring);
       t2 = hour(datestring);
-      cin >> action2;
+      std::cin >> action2;
 
       //   process the activity from nr 1 to nr 2.
 
@@ -87,7 +87,7 @@ main()
       action1 = action2;
    }
 
-   cout << "Activity\tJan\tFeb\tMar\tApr\tMay\tJun\tJul\tAug\tSep\tOct\tNov\tDec\tTOTAL\n\n";
+   std::cout << "Activity\tJan\tFeb\tMar\tApr\tMay\tJun\tJul\tAug\tSep\tOct\tNov\tDec\tTOTAL\n\n";
 
    for (a = timesheet; a; a = a->next)
    {
@@ -109,11 +109,11 @@ void activity::print(void)
 {
    hour total;
 
-   cout << description << "\t";
+   std::cout << description << "\t";
    for (int i=0; i<12; i++)
    {
-      cout << spent_in_month[i] << "\t";
+      std::cout << spent_in_month[i] << "\t";
       total += spent_in_month[i];
    }
-   cout << total << "\t" << description << "\n";
+   std::cout << total << "\t" << description << "\n";
 }