Moving around path weight tagging. Now CcnxFace owns metric field, which is used for tagging.

Correcting bugs in blackhole-sprint scenario.  This time it should be
the right one:
- instead of a hijacker app, all faces on hijacked node are turned down
- there was a trick with RTT estimation (when batch, it is necessary to
  reset history upon a new batch)
- instead of random runs, trying all possible combinations of
  producer/hijacker
diff --git a/helper/ccnx-trace-helper.cc b/helper/ccnx-trace-helper.cc
index f5df0cb..0e958fa 100644
--- a/helper/ccnx-trace-helper.cc
+++ b/helper/ccnx-trace-helper.cc
@@ -372,23 +372,15 @@
 
   CcnxPathWeightTracer::PrintHeader (*m_pathWeightsTrace);
   *m_pathWeightsTrace << "\n";
-}
 
-void
-CcnxTraceHelper::WeightsConnect (Ptr<Node> node, Ptr<Application> app)
-{
-  // small hack to find out app index
-  uint32_t appId = 0;
-  for (uint32_t appId = 0; appId < node->GetNApplications (); appId++)
+  for (NodeList::Iterator node = NodeList::Begin ();
+       node != NodeList::End ();
+       node++)
     {
-      if (app == node->GetApplication (appId)) break;
+      Ptr<CcnxPathWeightTracer> trace = Create<CcnxPathWeightTracer> (boost::ref(*m_pathWeightsTrace),
+                                                                      *node);
+      m_pathWeights.push_back (trace);
     }
-  NS_ASSERT (appId != node->GetNApplications ());
-
-  Ptr<CcnxPathWeightTracer> trace = Create<CcnxPathWeightTracer> (boost::ref(*m_pathWeightsTrace),
-                                                                  node,
-                                                                  lexical_cast<string> (appId));
-  m_pathWeights.push_back (trace);
 }
 
 } // namespace ns3
diff --git a/helper/ccnx-trace-helper.h b/helper/ccnx-trace-helper.h
index 37565f5..59f0a53 100644
--- a/helper/ccnx-trace-helper.h
+++ b/helper/ccnx-trace-helper.h
@@ -123,13 +123,6 @@
   void
   EnablePathWeights (const std::string &pathWeights);
 
-  /**
-   * @brief Should be called with node pointer after TCP application
-   *
-   * Workaround because NS-3 needs object to exist before connecting trace
-   */
-  void WeightsConnect (Ptr<Node> node, Ptr<Application> AppId);
-
 private:
   std::string m_appTrace;
   std::list<Ptr<CcnxAppTracer> > m_apps;
diff --git a/helper/tracers/ccnx-path-weight-tracer.cc b/helper/tracers/ccnx-path-weight-tracer.cc
index 4d6aa7d..b2685bd 100644
--- a/helper/tracers/ccnx-path-weight-tracer.cc
+++ b/helper/tracers/ccnx-path-weight-tracer.cc
@@ -36,10 +36,9 @@
 
 namespace ns3 {
     
-CcnxPathWeightTracer::CcnxPathWeightTracer (std::ostream &os, Ptr<Node> node, std::string appId)
+CcnxPathWeightTracer::CcnxPathWeightTracer (std::ostream &os, Ptr<Node> node)
   : m_os (os)
   , m_nodePtr (node)
-  , m_appId (appId)
 {
   m_node = boost::lexical_cast<string> (m_nodePtr->GetId ());
 
@@ -55,16 +54,13 @@
 void
 CcnxPathWeightTracer::Connect ()
 {
-  Config::Set ("/NodeList/"+m_node+"/$ns3::CcnxL3Protocol/ForwardingStrategy/MetricTagging",
+  Config::Set ("/NodeList/"+m_node+"/$ns3::CcnxL3Protocol/FaceList/*/MetricTagging",
                BooleanValue (true));
 
-  Config::Connect ("/NodeList/"+m_node+"/ApplicationList/"+m_appId+"/PathWeightsTrace",
+  Config::Connect ("/NodeList/"+m_node+"/ApplicationList/*/PathWeightsTrace",
                    MakeCallback (&CcnxPathWeightTracer::InLocalFace, this));
-  // Config::Connect ("/NodeList/"+m_node+"/$ns3::CcnxL3Protocol/FaceList/*/$ns3::CcnxLocalFace/PathWeightsTrace",
-  //                  MakeCallback (&CcnxPathWeightTracer::InLocalFace, this));
 }
 
-
 void
 CcnxPathWeightTracer::PrintHeader (std::ostream &os)
 {
diff --git a/helper/tracers/ccnx-path-weight-tracer.h b/helper/tracers/ccnx-path-weight-tracer.h
index 868e61f..f4bd187 100644
--- a/helper/tracers/ccnx-path-weight-tracer.h
+++ b/helper/tracers/ccnx-path-weight-tracer.h
@@ -35,7 +35,7 @@
 class CcnxPathWeightTracer : public SimpleRefCount<CcnxPathWeightTracer>
 {
 public:
-  CcnxPathWeightTracer (std::ostream &os, Ptr<Node> node, std::string appId);
+  CcnxPathWeightTracer (std::ostream &os, Ptr<Node> node);
   virtual ~CcnxPathWeightTracer () { };
 
   void
@@ -55,7 +55,6 @@
   std::ostream &m_os;
   std::string m_node;
   Ptr<Node> m_nodePtr;
-  std::string m_appId;
 };
 
 } // namespace ns3