public final class BigIntUtils extends Object
Modifier and Type | Method and Description |
---|---|
static boolean |
equals(BigInteger[] a,
BigInteger[] b)
Checks if two BigInteger arrays contain the same entries
|
static void |
fill(BigInteger[] array,
BigInteger value)
Fill the given BigInteger array with the given value.
|
static BigInteger[] |
subArray(BigInteger[] input,
int start,
int end)
Generates a subarray of a given BigInteger array.
|
static int[] |
toIntArray(BigInteger[] input)
Converts a BigInteger array into an integer array
|
static int[] |
toIntArrayModQ(int q,
BigInteger[] input)
Converts a BigInteger array into an integer array, reducing all
BigIntegers mod q.
|
static byte[] |
toMinimalByteArray(BigInteger value)
Return the value of big as a byte array.
|
public static boolean equals(BigInteger[] a, BigInteger[] b)
a
- first BigInteger arrayb
- second BigInteger arraypublic static void fill(BigInteger[] array, BigInteger value)
array
- the arrayvalue
- the valuepublic static BigInteger[] subArray(BigInteger[] input, int start, int end)
input
- -
the input BigInteger arraystart
- -
the start indexend
- -
the end indexpublic static int[] toIntArray(BigInteger[] input)
input
- -
the BigInteger arraypublic static int[] toIntArrayModQ(int q, BigInteger[] input)
q
- -
the modulusinput
- -
the BigInteger arraypublic static byte[] toMinimalByteArray(BigInteger value)
value
- the BigInteger value to be converted to a byte
arrayCopyright © 2016 BouncyCastle.org. All rights reserved.