Home
last modified time | relevance | path

Searched refs:BigInteger (Results 1 – 17 of 17) sorted by relevance

/packages/apps/Test/connectivity/sl4n/rapidjson/test/unittest/
Dbigintegertest.cpp21 #define BIGINTEGER_LITERAL(s) BigInteger(s, sizeof(s) - 1)
23 static const BigInteger kZero(0);
24 static const BigInteger kOne(1);
25 static const BigInteger kUint64Max = BIGINTEGER_LITERAL("18446744073709551615");
26 static const BigInteger kTwo64 = BIGINTEGER_LITERAL("18446744073709551616");
28 TEST(BigInteger, Constructor) { in TEST() argument
34 const BigInteger a(123); in TEST()
44 TEST(BigInteger, AddUint64) { in TEST() argument
45 BigInteger a = kZero; in TEST()
53 EXPECT_TRUE(BigInteger(2) == a); in TEST()
[all …]
Dstrtodtest.cpp19 #define BIGINTEGER_LITERAL(s) BigInteger(s, sizeof(s) - 1)
101 BigInteger dS = BIGINTEGER_LITERAL(dInt); in TEST()
104 BigInteger bS(bInt); in TEST()
107 BigInteger hS(1); in TEST()
116 BigInteger delta(0); in TEST()
/packages/apps/Car/libs/connected-device-lib/tests/unit/src/com/android/car/connecteddevice/util/
DScanDataAnalyzerTest.java26 import java.math.BigInteger;
30 private static final BigInteger CORRECT_DATA =
31 new BigInteger(
36 private static final BigInteger CORRECT_MASK =
37 new BigInteger("00000000000000000000000000200000", 16);
39 private static final BigInteger MULTIPLE_BIT_MASK =
40 new BigInteger("00000000000000000100000000200000", 16);
69 new BigInteger( in containsUuidsInOverflow_incorrectLengthByte_shouldReturnFalse()
74 BigInteger mask = new BigInteger("00000000000000000000000000200000", 16); in containsUuidsInOverflow_incorrectLengthByte_shouldReturnFalse()
82 new BigInteger( in containsUuidsInOverflow_incorrectAdTypeByte_shouldReturnFalse()
[all …]
/packages/apps/Test/connectivity/sl4n/rapidjson/include/rapidjson/internal/
Dbiginteger.h28 class BigInteger {
32 BigInteger(const BigInteger& rhs) : count_(rhs.count_) { in BigInteger() function
36 explicit BigInteger(uint64_t u) : count_(1) { in BigInteger() function
40 BigInteger(const char* decimals, size_t length) : count_(1) { in BigInteger() function
55 BigInteger& operator=(const BigInteger &rhs)
64 BigInteger& operator=(uint64_t u) {
70 BigInteger& operator+=(uint64_t u) {
87 BigInteger& operator*=(uint64_t u) {
105 BigInteger& operator*=(uint32_t u) {
128 BigInteger& operator<<=(size_t shift) {
[all …]
Dstrtod.h55 inline int CheckWithinHalfULP(double b, const BigInteger& d, int dExp) { in CheckWithinHalfULP()
97 BigInteger dS = d; in CheckWithinHalfULP()
100 BigInteger bS(bInt); in CheckWithinHalfULP()
103 BigInteger hS(1); in CheckWithinHalfULP()
106 BigInteger delta(0); in CheckWithinHalfULP()
208 const BigInteger dInt(decimals, length); in StrtodBigInteger()
/packages/modules/IPsec/tests/iketests/src/java/com/android/internal/net/ipsec/ike/message/
DIkeKePayloadTest.java37 import java.math.BigInteger;
106 BigInteger primeValue = in setUp()
108 BigInteger baseGenValue = in setUp()
110 BigInteger privateKeyValue = in setUp()
167 BigInteger primeValue = privateKeySpec.getP(); in testGetIkeKePayload()
168 BigInteger expectedPrimeValue = new BigInteger(IkeDhParams.PRIME_1024_BIT_MODP, 16); in testGetIkeKePayload()
171 BigInteger genValue = privateKeySpec.getG(); in testGetIkeKePayload()
172 BigInteger expectedGenValue = BigInteger.valueOf(IkeDhParams.BASE_GENERATOR_MODP); in testGetIkeKePayload()
/packages/modules/IPsec/src/java/com/android/internal/net/utils/
DBigIntegerUtils.java18 import java.math.BigInteger;
29 public static BigInteger unsignedHexStringToBigInteger(String hexString) { in unsignedHexStringToBigInteger()
30 return new BigInteger(hexString, 16); in unsignedHexStringToBigInteger()
39 public static BigInteger unsignedByteArrayToBigInteger(byte[] byteArray) { in unsignedByteArrayToBigInteger()
40 return new BigInteger(1/** positive */, byteArray); in unsignedByteArrayToBigInteger()
51 public static byte[] bigIntegerToUnsignedByteArray(BigInteger bigInteger, int size) { in bigIntegerToUnsignedByteArray()
/packages/apps/Camera2/src/com/android/camera/settings/
DResolutionUtil.java30 import java.math.BigInteger;
289 BigInteger width = BigInteger.valueOf(aspectRatio.width()); in reduce()
290 BigInteger height = BigInteger.valueOf(aspectRatio.height()); in reduce()
291 BigInteger gcd = width.gcd(height); in reduce()
333 BigInteger width = BigInteger.valueOf(size.width()); in aspectRatioDenominator()
334 BigInteger height = BigInteger.valueOf(size.height()); in aspectRatioDenominator()
335 BigInteger gcd = width.gcd(height); in aspectRatioDenominator()
/packages/apps/Car/libs/connected-device-lib/src/com/android/car/connecteddevice/util/
DScanDataAnalyzer.java24 import java.math.BigInteger;
81 @NonNull BigInteger serviceUuidMask) { in containsUuidsInOverflow()
103 if (!new BigInteger(idBytes).equals(BigInteger.valueOf(IOS_OVERFLOW_CUSTOM_ID))) { in containsUuidsInOverflow()
114 BigInteger overflowBytesValue = new BigInteger(overflowBytes); in containsUuidsInOverflow()
/packages/modules/IPsec/src/java/com/android/internal/net/eap/crypto/
DFips186_2Prf.java23 import java.math.BigInteger;
50 BigInteger xkey = unsignedByteArrayToBigInteger(seed); in getRandom()
51 BigInteger exp_b = new BigInteger("2").pow(SEED_LEN_BYTES * 8); in getRandom()
67 BigInteger xval = xkey.mod(exp_b); in getRandom()
79 xkey = xkey.add(BigInteger.ONE).add(unsignedByteArrayToBigInteger(w_i)); in getRandom()
/packages/modules/IPsec/src/java/com/android/internal/net/ipsec/ike/message/
DIkeKePayload.java28 import java.math.BigInteger;
160 BigInteger prime = BigInteger.ZERO; in IkeKePayload()
192 BigInteger baseGen = BigInteger.valueOf(IkeDhParams.BASE_GENERATOR_MODP); in IkeKePayload()
266 BigInteger publicKeyValue = BigIntegerUtils.unsignedByteArrayToBigInteger(remotePublicKey); in getSharedKey()
267 BigInteger primeValue = privateKeySpec.getP(); in getSharedKey()
268 BigInteger baseGenValue = privateKeySpec.getG(); in getSharedKey()
/packages/modules/IPsec/tests/iketests/src/java/com/android/internal/net/utils/
DBigIntegerUtilsTest.java23 import java.math.BigInteger;
35 BigInteger bigIntA = new BigInteger(TEST_BIGINTEGER_A, 16); in testBigIntegerToUnsignedByteArray()
36 BigInteger bigIntB = new BigInteger(TEST_BIGINTEGER_B, 16); in testBigIntegerToUnsignedByteArray()
/packages/apps/Camera2/src/com/android/camera/util/
DAspectRatio.java23 import java.math.BigInteger;
49 int gcd = BigInteger.valueOf(width).gcd(BigInteger.valueOf(height)).intValue(); in of()
/packages/apps/Car/libs/connected-device-lib/src/com/android/car/connecteddevice/ble/
DCarBleCentralManager.java41 import java.math.BigInteger;
80 private final BigInteger mParsedBgServiceBitMask;
107 mParsedBgServiceBitMask = new BigInteger(bgServiceMask, 16); in CarBleCentralManager()
/packages/apps/Bluetooth/src/com/android/bluetooth/mapclient/obex/
DRequestPushMessage.java22 import java.math.BigInteger;
60 new BigInteger(handle, 16); in readResponseHeaders()
DEventReport.java29 import java.math.BigInteger;
53 new BigInteger(attrs.get("handle"), 16); in EventReport()
DMessage.java22 import java.math.BigInteger;
73 new BigInteger(attrs.get("handle"), 16); in Message()