Index: fedd/abac-src/rbtm/util/CVS/Entries
===================================================================
--- fedd/abac-src/rbtm/util/CVS/Entries	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
+++ fedd/abac-src/rbtm/util/CVS/Entries	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
@@ -0,0 +1,6 @@
+/Debug.java/1.1.1.1/Tue Nov 13 17:28:45 2001//
+/Predicate.java/1.1/Wed Dec 19 23:58:54 2001//
+/ResultEvidenceMap.java/1.4/Fri May 17 16:17:54 2002//
+/SmallSet.java/1.1.1.1/Tue Nov 13 17:28:45 2001//
+/package.html/1.2/Tue Dec 18 01:38:12 2001//
+D
Index: fedd/abac-src/rbtm/util/CVS/Repository
===================================================================
--- fedd/abac-src/rbtm/util/CVS/Repository	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
+++ fedd/abac-src/rbtm/util/CVS/Repository	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
@@ -0,0 +1,1 @@
+rbtm/util
Index: fedd/abac-src/rbtm/util/CVS/Root
===================================================================
--- fedd/abac-src/rbtm/util/CVS/Root	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
+++ fedd/abac-src/rbtm/util/CVS/Root	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
@@ -0,0 +1,1 @@
+:ext:jjacobs@src.columbia.sparta.com/cvs/abac
Index: fedd/abac-src/rbtm/util/Debug.java
===================================================================
--- fedd/abac-src/rbtm/util/Debug.java	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
+++ fedd/abac-src/rbtm/util/Debug.java	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
@@ -0,0 +1,16 @@
+package edu.stanford.peer.rbtm.util;
+
+import java.io.*;
+
+public class Debug
+{
+	static PrintStream out = System.out;
+
+	static public void debugInfo(String s) {
+		out.println(s);
+	}
+
+	static public void setOutputStream(PrintStream out) {
+		Debug.out = out;
+	}
+}
Index: fedd/abac-src/rbtm/util/Predicate.java
===================================================================
--- fedd/abac-src/rbtm/util/Predicate.java	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
+++ fedd/abac-src/rbtm/util/Predicate.java	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
@@ -0,0 +1,24 @@
+package edu.stanford.peer.rbtm.util;
+
+
+import edu.stanford.peer.rbtm.credential.EntityExpression;
+
+/**
+ * A predicate function which tests an object and returns the results. The
+ * class also provides an object reference which may be null.
+ */
+public interface Predicate extends java.io.Serializable 
+{
+    public static final String SIMP = "simple";
+
+    public static final String SENS = "sensitive";
+
+    public static final String OPPO = "opponent";
+
+    /** 
+     * The testing function for a predicate.
+     * @return the success or failure of the predicate 
+     */
+    public boolean test(EntityExpression expr);
+
+}
Index: fedd/abac-src/rbtm/util/ResultEvidenceMap.java
===================================================================
--- fedd/abac-src/rbtm/util/ResultEvidenceMap.java	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
+++ fedd/abac-src/rbtm/util/ResultEvidenceMap.java	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
@@ -0,0 +1,81 @@
+package edu.stanford.peer.rbtm.util;
+
+import java.util.*;
+
+import edu.stanford.peer.rbtm.RBTMConstants;
+//import edu.stanford.peer.rbtm.util.*;
+
+/** Stores results and their evidences. */
+public class ResultEvidenceMap implements RBTMConstants
+{
+	static final public int DEFAULT_CAPACITY = 23;
+
+    //private int  	_type = TRACK_NONE;
+    private int  	_type = TRACK_ALL;
+    private HashMap _map;
+
+    public ResultEvidenceMap(int trackType, int capacity) {
+    	_type = trackType; 
+    	_map = new HashMap(capacity);
+    }
+
+    public ResultEvidenceMap() { 
+		this(TRACK_ALL, DEFAULT_CAPACITY);
+    }
+
+    public ResultEvidenceMap(int trackType) { 
+	    this(trackType, DEFAULT_CAPACITY);
+	}
+
+    /**
+     * Retrieve a Result-to-Evidence mapping. If constructed with trackType
+     * TRACK_NONE, the evidence will be null.
+     * @return the evidence, if any, bound to the result.
+     */
+    public Object getResultEvidence(Object result) {
+	return _map.get(result);
+    }
+
+	/**
+	 * Add a Result-to-Evidence mapping.  
+	 * @return true if this is a new Result, false if it is not
+	 */
+    public boolean putResultEvidence(Object result, Object evidence) {
+        if (! _map.containsKey(result)) {  // New result
+			switch (_type) {
+			case TRACK_NONE:
+	            _map.put(result, null);
+				break;
+			case TRACK_ANY:
+				_map.put(result, evidence);
+				break;
+			case TRACK_ALL:
+				HashSet eviSet = new HashSet(7);
+				eviSet.add(evidence);
+				System.out.println("###Adding " + result + ","
+						   + evidence);
+				_map.put(result, eviSet);
+				break;
+			}
+            return true;
+        } else {  // Result already exist
+            if (_type == TRACK_ALL) {
+                ((Set)_map.get(result)).add(evidence);
+            }
+            return false;
+        }
+    }
+    
+    public boolean containsResult(Object result) {
+        return _map.containsKey(result);
+    }
+
+	public Set resultSet() {
+		return _map.keySet();
+	}
+
+	public String toString() {
+	    return  "["+ _type + "]" + _map.toString();
+	    //return _map.toString();
+	}
+}
Index: fedd/abac-src/rbtm/util/SmallSet.java
===================================================================
--- fedd/abac-src/rbtm/util/SmallSet.java	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
+++ fedd/abac-src/rbtm/util/SmallSet.java	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
@@ -0,0 +1,17 @@
+package edu.stanford.peer.rbtm.util;
+
+import java.util.*;
+
+/** A set that typically contains just one member, but may contain
+    more than one.  Using SmallSet instead of HashSet could avoid 
+	the cost of creating lots of HashSet when it is not necessary.
+	The current implementation simply extends HashSet.
+ */
+public class SmallSet extends HashSet
+{
+	Object o;
+    public SmallSet(Object o) {
+        super();
+        add(o);
+    }
+}
Index: fedd/abac-src/rbtm/util/package.html
===================================================================
--- fedd/abac-src/rbtm/util/package.html	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
+++ fedd/abac-src/rbtm/util/package.html	(revision 8780cbecc6db2bdc2b9ef31eec6e5209ad3bff15)
@@ -0,0 +1,5 @@
+<BODY>
+<P>
+Utility classes which are intended for generic use in other packages.
+</P>
+</BODY>
