示例#1
0
        private void UpdateCoveragePoints(CompoundTerm action)
        {
            int hash = this.currState.GetHashCode();

            //System.Console.WriteLine("action taken "+ action.ToString());
            if (!cps.ContainsKey(hash))
            {
                cps[hash] = new Set <int>();
            }
            cps[hash] = cps[hash].Add(action.GetHashCode());
        }
示例#2
0
        private void Update(IState iState, CompoundTerm action)
        {
            int hash = iState.GetHashCode();

            //System.Console.WriteLine("action taken "+ action.ToString());
            if (!cps.ContainsKey(hash))
            {
                cps[hash] = new Set <int>();
            }
            cps[hash] = cps[hash].Add(action.GetHashCode());

            /*
             * foreach (Symbol s in this.ObservableActionSymbols)
             * {
             *  System.Console.WriteLine(s);
             * }*/
        }
示例#3
0
 /// <summary>
 /// Returns a bag containing a single coverage point that is a pair of integers
 /// that are the hashcodes of the state and the action.
 /// </summary>
 static Bag <Term> DefaultCoveragePointProvider(IState state, CompoundTerm action)
 {
     return(new Bag <Term>(new Pair <int, int>(state.GetHashCode(), action.GetHashCode()).AsTerm));
 }