Home
last modified time | relevance | path

Searched refs:mParcel (Results 1 – 11 of 11) sorted by relevance

/packages/modules/AppSearch/testing/safeparceltests/src/android/app/appsearch/safeparcel/
DSafeParcelableTest.java49 private Parcel mParcel; field in SafeParcelableTest
54 mParcel = Parcel.obtain(); in setUp()
55 mParcel.setDataPosition(0); in setUp()
60 mParcel.recycle(); in tearDown()
66 SafeParcelWriter.writeByteArray(mParcel, TEST_ID, buffer, false); in testReadWriteByteArray()
69 byte[] readBuffer = SafeParcelReader.createByteArray(mParcel, header); in testReadWriteByteArray()
80 SafeParcelWriter.writeByteArray(mParcel, TEST_ID, null, true); in testReadWriteByteArrayNull()
83 byte[] readBuffer = SafeParcelReader.createByteArray(mParcel, header); in testReadWriteByteArrayNull()
91 SafeParcelWriter.writeByteArray(mParcel, TEST_ID, null, false); in testReadWriteByteArrayNullIgnore()
92 assertEquals(0, mParcel.dataPosition()); in testReadWriteByteArrayNullIgnore()
[all …]
DSafeParcelableSparseArrayTest.java37 private final Parcel mParcel = Parcel.obtain(); field in SafeParcelableSparseArrayTest
65 mParcel, TEST_ID, sparseArray, /* writeNull= */ false); in testReadWriteBytesSparseArray()
69 SafeParcelReader.createByteArraySparseArray(mParcel, header); in testReadWriteBytesSparseArray()
81 mParcel, TEST_ID, sparseArray, /* writeNull= */ false); in testReadWriteBundleSparseArray()
85 SafeParcelReader.createTypedSparseArray(mParcel, header, Bundle.CREATOR); in testReadWriteBundleSparseArray()
145 SafeParcelWriter.writeParcelable(mParcel, TEST_ID, val, 0, false); in testReadWriteSafeParcelableWithSparseArray()
150 mParcel, header, TestSafeParcelableWithSparseArray.CREATOR); in testReadWriteSafeParcelableWithSparseArray()
223 mParcel.setDataPosition(0); in prepareToReadFromParcel()
224 return SafeParcelReader.readHeader(mParcel); in prepareToReadFromParcel()
/packages/modules/Connectivity/Tethering/tests/unit/src/android/net/dhcp/
DDhcpServingParamsParcelExtTest.java57 private DhcpServingParamsParcelExt mParcel; field in DhcpServingParamsParcelExtTest
61 mParcel = new DhcpServingParamsParcelExt(); in setUp()
66 mParcel.setServerAddr(new LinkAddress(TEST_ADDRESS, TEST_PREFIX_LENGTH)); in testSetServerAddr()
68 assertEquals(TEST_ADDRESS_PARCELED, mParcel.serverAddr); in testSetServerAddr()
69 assertEquals(TEST_PREFIX_LENGTH, mParcel.serverAddrPrefixLength); in testSetServerAddr()
74 mParcel.setDefaultRouters(TEST_ADDRESS_SET); in testSetDefaultRouters()
75 assertEquals(TEST_ADDRESS_SET_PARCELED, asSet(mParcel.defaultRouters)); in testSetDefaultRouters()
80 mParcel.setDnsServers(TEST_ADDRESS_SET); in testSetDnsServers()
81 assertEquals(TEST_ADDRESS_SET_PARCELED, asSet(mParcel.dnsServers)); in testSetDnsServers()
86 mParcel.setExcludedAddrs(TEST_ADDRESS_SET); in testSetExcludedAddrs()
[all …]
/packages/modules/Wifi/framework/tests/src/android/net/wifi/
DParcelUtilTest.java39 private Parcel mParcel; field in ParcelUtilTest
43 mParcel = Parcel.obtain(); in setUp()
48 ParcelUtil.writePrivateKey(mParcel, null); in readWriteNullPrivateKey()
50 mParcel.setDataPosition(0); // Rewind data position back to the beginning for read. in readWriteNullPrivateKey()
51 PrivateKey readKey = ParcelUtil.readPrivateKey(mParcel); in readWriteNullPrivateKey()
58 ParcelUtil.writePrivateKey(mParcel, writeKey); in readWriteValidPrivateKey()
60 mParcel.setDataPosition(0); // Rewind data position back to the beginning for read. in readWriteValidPrivateKey()
61 PrivateKey readKey = ParcelUtil.readPrivateKey(mParcel); in readWriteValidPrivateKey()
69 ParcelUtil.writeCertificate(mParcel, null); in readWriteNullCertificate()
71 mParcel.setDataPosition(0); // Rewind data position back to the beginning for read. in readWriteNullCertificate()
[all …]
/packages/modules/DnsResolver/tests/dns_responder/
Ddns_responder_client_ndk.h67 mParcel.servers = servers; in setDnsServers()
71 mParcel.tlsServers = servers; in setDotServers()
75 mParcel.domains = domains; in setDomains()
79 mParcel.tlsName = provider; in setPrivateDnsProvider()
86 mParcel.sampleValiditySeconds = params[IDnsResolver::RESOLVER_PARAMS_SAMPLE_VALIDITY]; in setParams()
87 mParcel.successThreshold = params[IDnsResolver::RESOLVER_PARAMS_SUCCESS_THRESHOLD]; in setParams()
88 mParcel.minSamples = params[IDnsResolver::RESOLVER_PARAMS_MIN_SAMPLES]; in setParams()
89 mParcel.maxSamples = params[IDnsResolver::RESOLVER_PARAMS_MAX_SAMPLES]; in setParams()
90 mParcel.baseTimeoutMsec = params[IDnsResolver::RESOLVER_PARAMS_BASE_TIMEOUT_MSEC]; in setParams()
91 mParcel.retryCount = params[IDnsResolver::RESOLVER_PARAMS_RETRY_COUNT]; in setParams()
[all …]
Ddns_responder_client_ndk.cpp40 mParcel.netId = TEST_NETID; in Builder()
43 mParcel.sampleValiditySeconds = 300; in Builder()
44 mParcel.successThreshold = 25; in Builder()
45 mParcel.minSamples = 8; in Builder()
46 mParcel.maxSamples = 8; in Builder()
47 mParcel.baseTimeoutMsec = 1000; in Builder()
48 mParcel.retryCount = 2; in Builder()
50 mParcel.servers = {kDefaultServer}; in Builder()
51 mParcel.domains = {kDefaultSearchDomain}; in Builder()
52 mParcel.tlsServers = {kDefaultServer}; in Builder()
[all …]
/packages/services/Car/tests/android_car_api_test/src/android/car/apitest/
DCarPropertyTestBase.java41 private final Parcel mParcel = Parcel.obtain(); field in CarPropertyTestBase
45 mParcel.recycle(); in recycleParcel()
49 mParcel.setDataPosition(0); in readFromParcel()
50 return mParcel.readParcelable(null); in readFromParcel()
54 mParcel.writeParcelable(value, 0); in writeToParcel()
/packages/services/Telecomm/tests/src/com/android/server/telecom/tests/
DCallAttributesTests.java43 @Mock private Parcel mParcel; field in CallAttributesTests
116 callAttributes.writeToParcel(mParcel, 0); in testWriteToParcel()
119 verify(mParcel, times(1)) in testWriteToParcel()
121 verify(mParcel, times(1)).writeCharSequence(isA(CharSequence.class)); in testWriteToParcel()
122 verify(mParcel, times(1)) in testWriteToParcel()
124 verify(mParcel, times(3)).writeInt(isA(Integer.class)); in testWriteToParcel()
DCallExceptionTests.java39 @Mock private Parcel mParcel; field in CallExceptionTests
76 exception.writeToParcel(mParcel, 0); in testWriteToParcel()
79 verify(mParcel, times(1)).writeString8(isA(String.class)); in testWriteToParcel()
80 verify(mParcel, times(1)).writeInt(isA(Integer.class)); in testWriteToParcel()
/packages/services/Car/tests/carservice_unit_test/src/android/car/util/concurrent/
DAndroidFutureTest.java44 private Parcel mParcel = Parcel.obtain(); field in AndroidFutureTest
199 original.writeToParcel(mParcel, /* flags = */0); in testWriteToParcel_completedExceptionally()
201 mParcel.setDataPosition(0); in testWriteToParcel_completedExceptionally()
202 AndroidFuture fromParcel = AndroidFuture.CREATOR.createFromParcel(mParcel); in testWriteToParcel_completedExceptionally()
211 mUncompletedFuture.writeToParcel(mParcel, /* flags= */0); in testWriteToParcel_uncompleted()
213 mParcel.setDataPosition(0); in testWriteToParcel_uncompleted()
214 AndroidFuture fromParcel = AndroidFuture.CREATOR.createFromParcel(mParcel); in testWriteToParcel_uncompleted()
222 mUncompletedFuture.writeToParcel(mParcel, /* flags= */0); in testWriteToParcel_uncompleted_Exception()
224 mParcel.setDataPosition(0); in testWriteToParcel_uncompleted_Exception()
225 AndroidFuture fromParcel = AndroidFuture.CREATOR.createFromParcel(mParcel); in testWriteToParcel_uncompleted_Exception()
/packages/services/Car/tests/carservice_test/src/com/android/car/
DCarPropertyEventTest.java50 private final Parcel mParcel = Parcel.obtain(); field in CarPropertyEventTest
54 mParcel.recycle(); in tearDown()
58 mParcel.setDataPosition(0); in readFromParcel()
59 return mParcel.readParcelable(null); in readFromParcel()
63 mParcel.writeParcelable(value, 0); in writeToParcel()