[Webfunds-commits] java/webfunds/client AccountInfo.java

Jeroen C. van Gelderen gelderen@cypherpunks.ai
Tue, 20 Feb 2001 17:42:52 -0400 (AST)


gelderen    01/02/20 17:42:52

  Modified:    webfunds/client AccountInfo.java
  Log:
  - Remove commented-out method.
  - Add constructor that takes an AccountId instead of byte[]. Deprecate the
    old (byte[]) constructor while we're at it.

Revision  Changes    Path
1.22      +13 -2     java/webfunds/client/AccountInfo.java

Index: AccountInfo.java
===================================================================
RCS file: /home/webfunds/cvsroot/java/webfunds/client/AccountInfo.java,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- AccountInfo.java	2000/10/14 01:21:14	1.21
+++ AccountInfo.java	2001/02/20 21:42:51	1.22
@@ -1,5 +1,5 @@
 /*
- * $Id: AccountInfo.java,v 1.21 2000/10/14 01:21:14 iang Exp $
+ * $Id: AccountInfo.java,v 1.22 2001/02/20 21:42:51 gelderen Exp $
  *
  * Copyright (c) Systemics Ltd 1995-1999 on behalf of
  * the WebFunds Development Team.  All Rights Reserved.
@@ -22,7 +22,6 @@
     protected byte[] id;
 
     public byte[]      getId()           { return id; }
-    //public String      getStringId()     { return Hex.data2hex(id); }
     public void        setId(byte[] id)
     {
         // check that it is valid for hashCode, 1,2,3 bytes doesn't work
@@ -77,6 +76,18 @@
         setWalletInterface(null);
     }
 
+
+    public AccountInfo(AccountId id, String name, WalletInterface wi)
+    {
+        setId(id.getByteArray());
+        setName(name);
+        setWalletInterface(wi);
+    }
+
+
+    /**
+     * @deprecated we don't want to pass byte[] around, use AccountIds instead.
+     */
     public AccountInfo(byte[] id, String name, WalletInterface wi)
     {
         setId(id);