Package org.dashj.bls
Class PrivateKey
- java.lang.Object
-
- org.dashj.bls.PrivateKey
-
public class PrivateKey extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static intPRIVATE_KEY_SIZEprotected booleanswigCMemOwn
-
Constructor Summary
Constructors Modifier Constructor Description PrivateKey()protectedPrivateKey(long cPtr, boolean cMemoryOwn)PrivateKey(PrivateKey k)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static PrivateKeyaggregate(PrivateKeyVector privateKeys)voiddelete()protected voidfinalize()static PrivateKeyfromBytes(byte[] bytes)static PrivateKeyfromBytes(byte[] bytes, boolean modOrder)static PrivateKeyfromSeedBIP32(byte[] seed)protected static longgetCPtr(PrivateKey obj)G1ElementgetG1Element()G2ElementgetG2Element()G2ElementgetG2Power(G2Element element)booleanhasKeyData()booleanisZero()static PrivateKeyrandomPrivateKey()byte[]serialize()byte[]serialize(boolean fLegacy)voidserialize(byte[] buffer)G2ElementsignG2(byte[] msg, long len, byte[] dst, long dst_len)G2ElementsignG2(byte[] msg, long len, byte[] dst, long dst_len, boolean fLegacy)
-
-
-
Constructor Detail
-
PrivateKey
protected PrivateKey(long cPtr, boolean cMemoryOwn)
-
PrivateKey
public PrivateKey()
-
PrivateKey
public PrivateKey(PrivateKey k)
-
-
Method Detail
-
getCPtr
protected static long getCPtr(PrivateKey obj)
-
delete
public void delete()
-
fromSeedBIP32
public static PrivateKey fromSeedBIP32(byte[] seed)
-
randomPrivateKey
public static PrivateKey randomPrivateKey()
-
fromBytes
public static PrivateKey fromBytes(byte[] bytes, boolean modOrder)
-
fromBytes
public static PrivateKey fromBytes(byte[] bytes)
-
aggregate
public static PrivateKey aggregate(PrivateKeyVector privateKeys)
-
getG1Element
public G1Element getG1Element()
-
getG2Element
public G2Element getG2Element()
-
isZero
public boolean isZero()
-
serialize
public void serialize(byte[] buffer)
-
serialize
public byte[] serialize(boolean fLegacy)
-
serialize
public byte[] serialize()
-
signG2
public G2Element signG2(byte[] msg, long len, byte[] dst, long dst_len, boolean fLegacy)
-
signG2
public G2Element signG2(byte[] msg, long len, byte[] dst, long dst_len)
-
hasKeyData
public boolean hasKeyData()
-
-