Example #1
0
 public TaintState this[int index]
 {
     get
     {
         while (index >= taints.Count)
         {
             taints.Add(TaintState.UnTainted);
         }
         if (index >= 0 && index < taints.Count)
         {
             return(taints[index]);
         }
         return(TaintState.UnTainted);
     }
     set
     {
         while (index >= taints.Count)
         {
             taints.Add(TaintState.UnTainted);
         }
         if (index >= 0)
         {
             TaintState former = taints[index];
             taints[index] = value;
             if (TaintIndexChanged != null)
             {
                 TaintIndexChanged(this, new TaintIndexChangedEventArgs(index, former, value));
             }
         }
     }
 }
Example #2
0
 public TaintIndexChangedEventArgs(int index, TaintState former, TaintState latter)
 {
     this.Index  = index;
     this.Former = former;
     this.Latter = latter;
 }