[e-cvs] cvs commit: e/src/jsrc/net/captp/jcomm Far3Desc.java Vow3Desc.java ProxyConnection.java LookupDesc.java
markm@eros.cs.jhu.edu
markm@eros.cs.jhu.edu
Thu, 10 May 2001 02:03:44 -0400
markm 01/05/10 02:03:44
Modified: src/jsrc/net/captp/jcomm ProxyConnection.java
Added: src/jsrc/net/captp/jcomm Far3Desc.java Vow3Desc.java
Removed: src/jsrc/net/captp/jcomm LookupDesc.java
Log:
further 3-vat case splitting
Revision Changes Path
1.11 +25 -5 e/src/jsrc/net/captp/jcomm/ProxyConnection.java
Index: ProxyConnection.java
===================================================================
RCS file: /cvs/e/src/jsrc/net/captp/jcomm/ProxyConnection.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- ProxyConnection.java 2001/05/10 05:28:27 1.10
+++ ProxyConnection.java 2001/05/10 06:03:44 1.11
@@ -482,23 +482,43 @@
}
/**
- * Dereferencing of a LookupDesc
+ * Dereferencing of a Vow3Desc
*
* @param searchPath hints to find the vat identified by vatID
* @param vatID The fingerprint of the public key of the vat hosting the
* object to be looked up.
* @param nonce Identifies the object in that vat's appropriate
* gift table.
- * @param optSwissHash identity of object being looked up. If non-null,
- * then getLookup returns a resolved reference with
- * that identity.
* @param optFarVine Hold on to this until the object has been retrieved.
* @return A promise for the looked up object.
*/
/*package*/ Ref getLookup(ConstList searchPath,
String vatID,
BigInteger nonce,
- BigInteger optSwissHash,
+ Object optFarVine)
+ {
+ throw new RuntimeException("XXX not yet implemented");
+ }
+
+ /**
+ * Dereferencing of a Far3Desc
+ *
+ * @param searchPath hints to find the vat identified by vatID
+ * @param vatID The fingerprint of the public key of the vat hosting the
+ * object to be looked up.
+ * @param nonce Identifies the object in that vat's appropriate
+ * gift table.
+ * @param swissHash Identity of object being looked up. getLookup
+ * returns a resolved reference with that identity. If
+ * it can't return a FarRef with that identity, then it
+ * returns a DisconnectedRef with that identity.
+ * @param optFarVine Hold on to this until the object has been retrieved.
+ * @return A promise for the looked up object.
+ */
+ /*package*/ Ref getLookup(ConstList searchPath,
+ String vatID,
+ BigInteger nonce,
+ BigInteger swissHash,
Object optFarVine)
{
throw new RuntimeException("XXX not yet implemented");
1.1 e/src/jsrc/net/captp/jcomm/Far3Desc.java
Index: Far3Desc.java
===================================================================
package net.captp.jcomm;
/*
The contents of this file are subject to the Electric Communities E Open
Source Code License Version 1.0 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of the License
at http://www.communities.com/EL/.
Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
the specific language governing rights and limitations under the License.
The Original Code is the Distributed E Language Implementation, released
July 20, 1998.
The Initial Developer of the Original Code is Electric Communities.
Copyright (C) 1998 Electric Communities. All Rights Reserved.
Contributor(s): ______________________________________.
*/
import java.math.BigInteger;
import net.captp.tables.Vine;
import net.vattp.data.EARL;
import org.erights.e.develop.trace.Trace;
import org.erights.e.elib.tables.ConstList;
/**
* The encoding of FarRef over the wire to someone other than the vat it
* points into.
*/
/*package*/ class Far3Desc implements ObjectRefDesc {
private ConstList mySearchPath;
private String myHostID;
private BigInteger myNonce;
private BigInteger mySwissHash;
private Object myOptFarVine;
/**
* Constructor.
*/
/*package*/ Far3Desc(ConstList searchPath,
String hostID,
BigInteger nonce,
BigInteger swissHash,
Object optFarVine)
{
mySearchPath = searchPath;
myHostID = hostID;
myNonce = nonce;
mySwissHash = swissHash;
myOptFarVine = optFarVine;
}
/**
* What the other side imported (from somebody other than ourselves), we
* dereference as a FarRef to the same object.
*/
public Object dereference(ProxyConnection conn) {
if (Trace.captp.debug && Trace.ON) {
Trace.captp.debugm(conn + " deref Far3Desc: " + this);
}
Vine optVine = null;
if (null != myOptFarVine) {
optVine = new Vine(myOptFarVine);
}
return conn.getLookup(mySearchPath,
myHostID,
myNonce,
mySwissHash,
optVine);
}
/**
*
*/
public String toString() {
return "Far3Desc(" + mySearchPath + ",\n "
+ myHostID.substring(0,4) + ",\n "
+ myNonce + ",\n "
+ mySwissHash + ",\n "
+ myOptFarVine + ")";
}
}
1.1 e/src/jsrc/net/captp/jcomm/Vow3Desc.java
Index: Vow3Desc.java
===================================================================
package net.captp.jcomm;
/*
The contents of this file are subject to the Electric Communities E Open
Source Code License Version 1.0 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of the License
at http://www.communities.com/EL/.
Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for
the specific language governing rights and limitations under the License.
The Original Code is the Distributed E Language Implementation, released
July 20, 1998.
The Initial Developer of the Original Code is Electric Communities.
Copyright (C) 1998 Electric Communities. All Rights Reserved.
Contributor(s): ______________________________________.
*/
import java.math.BigInteger;
import net.captp.tables.Vine;
import net.vattp.data.EARL;
import org.erights.e.develop.trace.Trace;
import org.erights.e.elib.tables.ConstList;
/**
* The encoding of a RemoteVow over the wire to someone other than the vat it
* points into.
*/
/*package*/ class Vow3Desc implements ObjectRefDesc {
private ConstList mySearchPath;
private String myHostID;
private BigInteger myNonce;
private Object myOptFarVine;
/**
* Constructor.
*/
/*package*/ Vow3Desc(ConstList searchPath,
String hostID,
BigInteger nonce,
Object optFarVine)
{
mySearchPath = searchPath;
myHostID = hostID;
myNonce = nonce;
myOptFarVine = optFarVine;
}
/**
* What the other side imported (from somebody other than ourselves), we
* dereference as a RemoteVow to the same arrowhead.
*/
public Object dereference(ProxyConnection conn) {
if (Trace.captp.debug && Trace.ON) {
Trace.captp.debugm(conn + " deref Vow3Desc: " + this);
}
Vine optVine = null;
if (null != myOptFarVine) {
optVine = new Vine(myOptFarVine);
}
return conn.getLookup(mySearchPath,
myHostID,
myNonce,
optVine);
}
/**
*
*/
public String toString() {
return "Vow3Desc(" + mySearchPath + ",\n "
+ myHostID.substring(0,4) + ",\n "
+ myNonce + ",\n "
+ myOptFarVine + ")";
}
}