예제 #1
0
        public void AddNode(string label)
        {
            FuzzyNode node = new FuzzyNode(label);

            nodes.Add(node);
            eventToNode.Add(label, node);
        }
예제 #2
0
        public void AddEdge(FuzzyNode from, FuzzyNode to)
        {
            FuzzyEdge e = new FuzzyEdge(from, to);

            edges.Add(e);
            from.AddOutEdges(e);
            to.AddInEdges(e);
        }
예제 #3
0
 public bool IsCluster(FuzzyNode fn)
 {
     if (clusters.Contains(fn))
     {
         return(true);
     }
     return(false);
 }
예제 #4
0
 public FuzzyNodeCluster GetCluster(FuzzyNode fn)
 {
     foreach (FuzzyNodeCluster fnc in clusters)
     {
         if (fnc.Equals(fn))
         {
             return(fnc);
         }
     }
     return(null);
 }
예제 #5
0
 public FuzzyEdge GetEdge(FuzzyNode from, FuzzyNode to)
 {
     foreach (FuzzyEdge fe in edges)
     {
         if ((fe.GetFromNode() == from) && (fe.GetToNode() == to))
         {
             return(fe);
         }
     }
     return(null);
 }
예제 #6
0
 public void RemoveNode(FuzzyNode fn)
 {
     nodes.Remove(fn);
     foreach (FuzzyEdge fe in edges)
     {
         if (fe.GetFromNode() == fn || fe.GetToNode() == fn)
         {
             RemoveEdge(fe);
         }
     }
 }
예제 #7
0
 public FuzzyEdge(FuzzyNode from, FuzzyNode to)
 {
     this.fromNode      = from;
     this.toNode        = to;
     this.durationsList = new List <double>();
     ComputeEndpointCorrelation();
     if (fromNode.GetAttributes().Keys.Contains <string>("time:timestamp") && toNode.GetAttributes().Keys.Contains <string>("time:timestamp"))
     {
         ComputeProximityCorrelation();
     }
     if (fromNode.GetAttributes().Keys.Contains <string>("org:resource") && toNode.GetAttributes().Keys.Contains <string>("org:resource"))
     {
         ComputeOriginatorCorrelation();
     }
 }
예제 #8
0
 public void AddNode(FuzzyNode node)
 {
     nodes.Add(node);
     eventToNode.Add(node.GetLabel(), node);
 }
예제 #9
0
 public void AddNodeToCluster(FuzzyNode fn)
 {
     nodesClustered.Add(fn);
     ComputeSignificance();
 }
예제 #10
0
 public FuzzyNodeCluster(FuzzyNode fn, string label) : base(label)
 {
     nodesClustered.Add(fn);
     ComputeSignificance();
 }