?? dhkeyobject.java
字號:
package src;
import java.io.*;
import java.util.Date;
import java.math.BigInteger;
import java.security.*;
/*
* This object is used for Public Key Exchange.
* The Crypto routines require it. I haven't put the heavy
* duty methods in here because I want it to stay small
*/
class DHKeyObject implements Serializable {
BigInteger n,g; /* These two make up the public Key */
String Description;
Date created;
DHKeyObject(BigInteger N, BigInteger G,String what) {
n = N;
g = G;
Description = what;
created = new Date();
}
/* You may wish to customize the following */
public String toString() {
StringBuffer scratch = new StringBuffer();
scratch.append("Public Key(n): " + n.toString(32) + "\n" );
scratch.append("Public Key(g): " + g.toString(32) + "\n" );
scratch.append("Description: " + Description + "\n" );
scratch.append("Created: " + created );
return scratch.toString();
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -