Lines Matching defs:Parcel

17 #define LOG_TAG "Parcel"
36 #include <binder/Parcel.h>
135 LOG_REFS("Parcel %p acquiring reference on local %p", who, obj.cookie);
146 LOG_REFS("Parcel %p acquiring reference on remote %p", who, b.get());
187 LOG_REFS("Parcel %p releasing reference on local %p", who, obj.cookie);
198 LOG_REFS("Parcel %p releasing reference on remote %p", who, b.get());
237 const sp<IBinder>& /*binder*/, const flat_binder_object& flat, Parcel* out)
243 const sp<IBinder>& binder, Parcel* out)
275 const wp<IBinder>& binder, Parcel* out)
325 const Parcel& /*in*/)
331 const Parcel& in, sp<IBinder>* out)
350 const Parcel& in, wp<IBinder>* out)
380 Parcel::Parcel()
382 LOG_ALLOC("Parcel %p: constructing", this);
386 Parcel::~Parcel()
389 LOG_ALLOC("Parcel %p: destroyed", this);
392 size_t Parcel::getGlobalAllocSize() {
399 size_t Parcel::getGlobalAllocCount() {
406 const uint8_t* Parcel::data() const
411 size_t Parcel::dataSize() const
416 size_t Parcel::dataAvail() const
425 size_t Parcel::dataPosition() const
430 size_t Parcel::dataCapacity() const
435 status_t Parcel::setDataSize(size_t size)
452 void Parcel::setDataPosition(size_t pos) const
464 status_t Parcel::setDataCapacity(size_t size)
476 status_t Parcel::setData(const uint8_t* buffer, size_t len)
493 status_t Parcel::appendFrom(const Parcel *parcel, size_t offset, size_t len)
574 // new Parcel now owns its own fd, and can declare that we
589 bool Parcel::allowFds() const
594 bool Parcel::pushAllowFds(bool allowFds)
603 void Parcel::restoreAllowFds(bool lastValue)
608 bool Parcel::hasFileDescriptors() const
617 status_t Parcel::writeInterfaceToken(const String16& interface)
625 bool Parcel::checkInterface(IBinder* binder) const
630 bool Parcel::enforceInterface(const String16& interface,
657 const binder_size_t* Parcel::objects() const
662 size_t Parcel::objectsCount() const
667 status_t Parcel::errorCheck() const
672 void Parcel::setError(status_t err)
677 status_t Parcel::finishWrite(size_t len)
696 status_t Parcel::writeUnpadded(const void* data, size_t len)
721 status_t Parcel::write(const void* data, size_t len)
737 void* Parcel::writeInplace(size_t len)
783 status_t Parcel::writeUtf8AsUtf16(const std::string& str) {
807 status_t Parcel::writeUtf8AsUtf16(const std::unique_ptr<std::string>& str) {
817 status_t writeByteVectorInternal(Parcel* parcel, const std::vector<T>& val)
841 status_t writeByteVectorInternalPtr(Parcel* parcel,
853 status_t Parcel::writeByteVector(const std::vector<int8_t>& val) {
857 status_t Parcel::writeByteVector(const std::unique_ptr<std::vector<int8_t>>& val)
862 status_t Parcel::writeByteVector(const std::vector<uint8_t>& val) {
866 status_t Parcel::writeByteVector(const std::unique_ptr<std::vector<uint8_t>>& val)
871 status_t Parcel::writeInt32Vector(const std::vector<int32_t>& val)
873 return writeTypedVector(val, &Parcel::writeInt32);
876 status_t Parcel::writeInt32Vector(const std::unique_ptr<std::vector<int32_t>>& val)
878 return writeNullableTypedVector(val, &Parcel::writeInt32);
881 status_t Parcel::writeInt64Vector(const std::vector<int64_t>& val)
883 return writeTypedVector(val, &Parcel::writeInt64);
886 status_t Parcel::writeInt64Vector(const std::unique_ptr<std::vector<int64_t>>& val)
888 return writeNullableTypedVector(val, &Parcel::writeInt64);
891 status_t Parcel::writeFloatVector(const std::vector<float>& val)
893 return writeTypedVector(val, &Parcel::writeFloat);
896 status_t Parcel::writeFloatVector(const std::unique_ptr<std::vector<float>>& val)
898 return writeNullableTypedVector(val, &Parcel::writeFloat);
901 status_t Parcel::writeDoubleVector(const std::vector<double>& val)
903 return writeTypedVector(val, &Parcel::writeDouble);
906 status_t Parcel::writeDoubleVector(const std::unique_ptr<std::vector<double>>& val)
908 return writeNullableTypedVector(val, &Parcel::writeDouble);
911 status_t Parcel::writeBoolVector(const std::vector<bool>& val)
913 return writeTypedVector(val, &Parcel::writeBool);
916 status_t Parcel::writeBoolVector(const std::unique_ptr<std::vector<bool>>& val)
918 return writeNullableTypedVector(val, &Parcel::writeBool);
921 status_t Parcel::writeCharVector(const std::vector<char16_t>& val)
923 return writeTypedVector(val, &Parcel::writeChar);
926 status_t Parcel::writeCharVector(const std::unique_ptr<std::vector<char16_t>>& val)
928 return writeNullableTypedVector(val, &Parcel::writeChar);
931 status_t Parcel::writeString16Vector(const std::vector<String16>& val)
933 return writeTypedVector(val, &Parcel::writeString16);
936 status_t Parcel::writeString16Vector(
939 return writeNullableTypedVector(val, &Parcel::writeString16);
942 status_t Parcel::writeUtf8VectorAsUtf16Vector(
944 return writeNullableTypedVector(val, &Parcel::writeUtf8AsUtf16);
947 status_t Parcel::writeUtf8VectorAsUtf16Vector(const std::vector<std::string>& val) {
948 return writeTypedVector(val, &Parcel::writeUtf8AsUtf16);
951 status_t Parcel::writeInt32(int32_t val)
956 status_t Parcel::writeUint32(uint32_t val)
961 status_t Parcel::writeInt32Array(size_t len, const int32_t *val) {
977 status_t Parcel::writeByteArray(size_t len, const uint8_t *val) {
994 status_t Parcel::writeBool(bool val)
999 status_t Parcel::writeChar(char16_t val)
1004 status_t Parcel::writeByte(int8_t val)
1009 status_t Parcel::writeInt64(int64_t val)
1014 status_t Parcel::writeUint64(uint64_t val)
1019 status_t Parcel::writePointer(uintptr_t val)
1024 status_t Parcel::writeFloat(float val)
1031 status_t Parcel::writeDouble(double val)
1043 status_t Parcel::writeDouble(double val)
1050 status_t Parcel::writeCString(const char* str)
1055 status_t Parcel::writeString8(const String8& str)
1067 status_t Parcel::writeString16(const std::unique_ptr<String16>& str)
1076 status_t Parcel::writeString16(const String16& str)
1081 status_t Parcel::writeString16(const char16_t* str, size_t len)
1099 status_t Parcel::writeStrongBinder(const sp<IBinder>& val)
1104 status_t Parcel::writeStrongBinderVector(const std::vector<sp<IBinder>>& val)
1106 return writeTypedVector(val, &Parcel::writeStrongBinder);
1109 status_t Parcel::writeStrongBinderVector(const std::unique_ptr<std::vector<sp<IBinder>>>& val)
1111 return writeNullableTypedVector(val, &Parcel::writeStrongBinder);
1114 status_t Parcel::readStrongBinderVector(std::unique_ptr<std::vector<sp<IBinder>>>* val) const {
1115 return readNullableTypedVector(val, &Parcel::readStrongBinder);
1118 status_t Parcel::readStrongBinderVector(std::vector<sp<IBinder>>* val) const {
1119 return readTypedVector(val, &Parcel::readStrongBinder);
1122 status_t Parcel::writeWeakBinder(const wp<IBinder>& val)
1127 status_t Parcel::writeRawNullableParcelable(const Parcelable* parcelable) {
1135 status_t Parcel::writeParcelable(const Parcelable& parcelable) {
1143 status_t Parcel::writeNativeHandle(const native_handle* handle)
1166 status_t Parcel::writeFileDescriptor(int fd, bool takeOwnership)
1177 status_t Parcel::writeDupFileDescriptor(int fd)
1190 status_t Parcel::writeUniqueFileDescriptor(const ScopedFd& fd) {
1194 status_t Parcel::writeUniqueFileDescriptorVector(const std::vector<ScopedFd>& val) {
1195 return writeTypedVector(val, &Parcel::writeUniqueFileDescriptor);
1198 status_t Parcel::writeUniqueFileDescriptorVector(const std::unique_ptr<std::vector<ScopedFd>>& val) {
1199 return writeNullableTypedVector(val, &Parcel::writeUniqueFileDescriptor);
1202 status_t Parcel::writeBlob(size_t len, bool mutableCopy, WritableBlob* outBlob)
1224 int fd = ashmem_create_region("Parcel Blob", len);
1257 status_t Parcel::writeDupImmutableBlobFileDescriptor(int fd)
1266 status_t Parcel::write(const FlattenableHelperInterface& val)
1312 status_t Parcel::writeObject(const flat_binder_object& val, bool nullMetaData)
1355 status_t Parcel::writeNoException()
1361 void Parcel::remove(size_t /*start*/, size_t /*amt*/)
1363 LOG_ALWAYS_FATAL("Parcel::remove() not yet implemented!");
1366 status_t Parcel::read(void* outData, size_t len) const
1384 const void* Parcel::readInplace(size_t len) const
1403 status_t Parcel::readAligned(T *pArg) const {
1417 T Parcel::readAligned() const {
1427 status_t Parcel::writeAligned(T val) {
1444 status_t readByteVectorInternal(const Parcel* parcel,
1477 const Parcel* parcel,
1502 status_t Parcel::readByteVector(std::vector<int8_t>* val) const {
1506 status_t Parcel::readByteVector(std::vector<uint8_t>* val) const {
1510 status_t Parcel::readByteVector(std::unique_ptr<std::vector<int8_t>>* val) const {
1514 status_t Parcel::readByteVector(std::unique_ptr<std::vector<uint8_t>>* val) const {
1518 status_t Parcel::readInt32Vector(std::unique_ptr<std::vector<int32_t>>* val) const {
1519 return readNullableTypedVector(val, &Parcel::readInt32);
1522 status_t Parcel::readInt32Vector(std::vector<int32_t>* val) const {
1523 return readTypedVector(val, &Parcel::readInt32);
1526 status_t Parcel::readInt64Vector(std::unique_ptr<std::vector<int64_t>>* val) const {
1527 return readNullableTypedVector(val, &Parcel::readInt64);
1530 status_t Parcel::readInt64Vector(std::vector<int64_t>* val) const {
1531 return readTypedVector(val, &Parcel::readInt64);
1534 status_t Parcel::readFloatVector(std::unique_ptr<std::vector<float>>* val) const {
1535 return readNullableTypedVector(val, &Parcel::readFloat);
1538 status_t Parcel::readFloatVector(std::vector<float>* val) const {
1539 return readTypedVector(val, &Parcel::readFloat);
1542 status_t Parcel::readDoubleVector(std::unique_ptr<std::vector<double>>* val) const {
1543 return readNullableTypedVector(val, &Parcel::readDouble);
1546 status_t Parcel::readDoubleVector(std::vector<double>* val) const {
1547 return readTypedVector(val, &Parcel::readDouble);
1550 status_t Parcel::readBoolVector(std::unique_ptr<std::vector<bool>>* val) const {
1572 status_t Parcel::readBoolVector(std::vector<bool>* val) const {
1602 status_t Parcel::readCharVector(std::unique_ptr<std::vector<char16_t>>* val) const {
1603 return readNullableTypedVector(val, &Parcel::readChar);
1606 status_t Parcel::readCharVector(std::vector<char16_t>* val) const {
1607 return readTypedVector(val, &Parcel::readChar);
1610 status_t Parcel::readString16Vector(
1612 return readNullableTypedVector(val, &Parcel::readString16);
1615 status_t Parcel::readString16Vector(std::vector<String16>* val) const {
1616 return readTypedVector(val, &Parcel::readString16);
1619 status_t Parcel::readUtf8VectorFromUtf16Vector(
1621 return readNullableTypedVector(val, &Parcel::readUtf8FromUtf16);
1624 status_t Parcel::readUtf8VectorFromUtf16Vector(std::vector<std::string>* val) const {
1625 return readTypedVector(val, &Parcel::readUtf8FromUtf16);
1628 status_t Parcel::readInt32(int32_t *pArg) const
1633 int32_t Parcel::readInt32() const
1638 status_t Parcel::readUint32(uint32_t *pArg) const
1643 uint32_t Parcel::readUint32() const
1648 status_t Parcel::readInt64(int64_t *pArg) const
1654 int64_t Parcel::readInt64() const
1659 status_t Parcel::readUint64(uint64_t *pArg) const
1664 uint64_t Parcel::readUint64() const
1669 status_t Parcel::readPointer(uintptr_t *pArg) const
1679 uintptr_t Parcel::readPointer() const
1685 status_t Parcel::readFloat(float *pArg) const
1691 float Parcel::readFloat() const
1698 status_t Parcel::readDouble(double *pArg) const
1711 double Parcel::readDouble() const
1723 status_t Parcel::readDouble(double *pArg) const
1728 double Parcel::readDouble() const
1735 status_t Parcel::readIntPtr(intptr_t *pArg) const
1741 intptr_t Parcel::readIntPtr() const
1746 status_t Parcel::readBool(bool *pArg) const
1754 bool Parcel::readBool() const
1759 status_t Parcel::readChar(char16_t *pArg) const
1767 char16_t Parcel::readChar() const
1772 status_t Parcel::readByte(int8_t *pArg) const
1780 int8_t Parcel::readByte() const
1785 status_t Parcel::readUtf8FromUtf16(std::string* str) const {
1810 status_t Parcel::readUtf8FromUtf16(std::unique_ptr<std::string>* str) const {
1825 const char* Parcel::readCString() const
1842 String8 Parcel::readString8() const
1853 String16 Parcel::readString16() const
1862 status_t Parcel::readString16(std::unique_ptr<String16>* pArg) const
1885 status_t Parcel::readString16(String16* pArg) const
1898 const char16_t* Parcel::readString16Inplace(size_t* outLen) const
1913 status_t Parcel::readStrongBinder(sp<IBinder>* val) const
1918 sp<IBinder> Parcel::readStrongBinder() const
1925 wp<IBinder> Parcel::readWeakBinder() const
1932 status_t Parcel::readParcelable(Parcelable* parcelable) const {
1944 int32_t Parcel::readExceptionCode() const
1951 native_handle* Parcel::readNativeHandle() const
1985 int Parcel::readFileDescriptor() const
1996 status_t Parcel::readUniqueFileDescriptor(ScopedFd* val) const
2014 status_t Parcel::readUniqueFileDescriptorVector(std::unique_ptr<std::vector<ScopedFd>>* val) const {
2015 return readNullableTypedVector(val, &Parcel::readUniqueFileDescriptor);
2018 status_t Parcel::readUniqueFileDescriptorVector(std::vector<ScopedFd>* val) const {
2019 return readTypedVector(val, &Parcel::readUniqueFileDescriptor);
2022 status_t Parcel::readBlob(size_t len, ReadableBlob* outBlob) const
2050 status_t Parcel::read(FlattenableHelperInterface& val) const
2081 ALOGE("dup() failed in Parcel::read, i is %zu, fds[i] is %d, fd_count is %zu, error: %s",
2096 const flat_binder_object* Parcel::readObject(bool nullMetaData) const
2117 ALOGV("Parcel %p looking for obj at %zu, hint=%zu",
2131 ALOGV("Parcel %p found obj %zu at index %zu with forward search",
2144 ALOGV("Parcel %p found obj %zu at index %zu with backward search",
2151 ALOGW("Attempt to read object from Parcel %p at offset %zu that is not in the object list",
2157 void Parcel::closeFileDescriptors()
2174 uintptr_t Parcel::ipcData() const
2179 size_t Parcel::ipcDataSize() const
2184 uintptr_t Parcel::ipcObjects() const
2189 size_t Parcel::ipcObjectsCount() const
2194 void Parcel::ipcSetDataReference(const uint8_t* data, size_t dataSize,
2223 void Parcel::print(TextOutput& to, uint32_t /*flags*/) const
2225 to << "Parcel(";
2249 void Parcel::releaseObjects()
2263 void Parcel::acquireObjects()
2277 void Parcel::freeData()
2283 void Parcel::freeDataNoInit()
2286 LOG_ALLOC("Parcel %p: freeing other owner data", this);
2290 LOG_ALLOC("Parcel %p: freeing allocated data", this);
2293 LOG_ALLOC("Parcel %p: freeing with %zu capacity", this, mDataCapacity);
2310 status_t Parcel::growData(size_t len)
2324 status_t Parcel::restartWrite(size_t desired)
2346 LOG_ALLOC("Parcel %p: restart from %zu to %zu capacity", this, mDataCapacity, desired);
2373 status_t Parcel::continueWrite(size_t desired)
2439 LOG_ALLOC("Parcel %p: taking ownership of %zu capacity", this, desired);
2479 LOG_ALLOC("Parcel %p: continue from %zu to %zu capacity", this, mDataCapacity,
2515 LOG_ALLOC("Parcel %p: allocating with %zu capacity", this, desired);
2531 void Parcel::initState()
2533 LOG_ALLOC("Parcel %p: initState", this);
2564 void Parcel::scanForFds() const
2579 size_t Parcel::getBlobAshmemSize() const
2582 // the ashmem currently referenced by this Parcel, which should be equivalent.
2587 size_t Parcel::getOpenAshmemSize() const
2592 // --- Parcel::Blob ---
2594 Parcel::Blob::Blob() :
2598 Parcel::Blob::~Blob() {
2602 void Parcel::Blob::release() {
2609 void Parcel::Blob::init(int fd, void* data, size_t size, bool isMutable) {
2616 void Parcel::Blob::clear() {