Flutter Engine
The Flutter Engine
Public Member Functions | List of all members
dart::SmiMessageDeserializationCluster Class Reference
Inheritance diagram for dart::SmiMessageDeserializationCluster:
dart::MessageDeserializationCluster dart::ZoneAllocated

Public Member Functions

 SmiMessageDeserializationCluster ()
 
 ~SmiMessageDeserializationCluster ()
 
void ReadNodes (MessageDeserializer *d)
 
void ReadNodesApi (ApiMessageDeserializer *d)
 
- Public Member Functions inherited from dart::MessageDeserializationCluster
 MessageDeserializationCluster (const char *name, bool is_canonical=false)
 
virtual ~MessageDeserializationCluster ()
 
virtual void ReadNodes (MessageDeserializer *d)=0
 
virtual void ReadEdges (MessageDeserializer *d)
 
virtual ObjectPtr PostLoad (MessageDeserializer *d)
 
virtual void ReadNodesApi (ApiMessageDeserializer *d)
 
virtual void ReadEdgesApi (ApiMessageDeserializer *d)
 
virtual void PostLoadApi (ApiMessageDeserializer *d)
 
void ReadNodesWrapped (MessageDeserializer *d)
 
void ReadNodesWrappedApi (ApiMessageDeserializer *d)
 
const char * name () const
 
bool is_canonical () const
 
- Public Member Functions inherited from dart::ZoneAllocated
 ZoneAllocated ()
 
void * operator new (size_t size)
 
void * operator new (size_t size, Zone *zone)
 
void operator delete (void *pointer)
 

Additional Inherited Members

- Protected Member Functions inherited from dart::MessageDeserializationCluster
ObjectPtr PostLoadAbstractType (MessageDeserializer *d)
 
ObjectPtr PostLoadLinkedHash (MessageDeserializer *d)
 
 DISALLOW_COPY_AND_ASSIGN (MessageDeserializationCluster)
 
- Protected Attributes inherited from dart::MessageDeserializationCluster
const char *const name_
 
const bool is_canonical_
 
intptr_t start_index_
 
intptr_t stop_index_
 

Detailed Description

Definition at line 844 of file message_snapshot.cc.

Constructor & Destructor Documentation

◆ SmiMessageDeserializationCluster()

dart::SmiMessageDeserializationCluster::SmiMessageDeserializationCluster ( )
inline

Definition at line 846 of file message_snapshot.cc.

847 : MessageDeserializationCluster("Smi", true) {}
MessageDeserializationCluster(const char *name, bool is_canonical=false)

◆ ~SmiMessageDeserializationCluster()

dart::SmiMessageDeserializationCluster::~SmiMessageDeserializationCluster ( )
inline

Definition at line 848 of file message_snapshot.cc.

848{}

Member Function Documentation

◆ ReadNodes()

void dart::SmiMessageDeserializationCluster::ReadNodes ( MessageDeserializer d)
inlinevirtual

Implements dart::MessageDeserializationCluster.

Definition at line 850 of file message_snapshot.cc.

850 {
851 const intptr_t count = d->ReadUnsigned();
852 for (intptr_t i = 0; i < count; i++) {
853 d->AssignRef(Smi::New(d->Read<intptr_t>()));
854 }
855 }
int count
Definition: FontMgrTest.cpp:50
static SmiPtr New(intptr_t value)
Definition: object.h:10006
VULKAN_HPP_DEFAULT_DISPATCH_LOADER_DYNAMIC_STORAGE auto & d
Definition: main.cc:19

◆ ReadNodesApi()

void dart::SmiMessageDeserializationCluster::ReadNodesApi ( ApiMessageDeserializer d)
inlinevirtual

Reimplemented from dart::MessageDeserializationCluster.

Definition at line 857 of file message_snapshot.cc.

857 {
858 intptr_t count = d->ReadUnsigned();
859 for (intptr_t i = 0; i < count; i++) {
860 intptr_t value = d->Read<intptr_t>();
861 Dart_CObject* smi;
862 if ((kMinInt32 <= value) && (value <= kMaxInt32)) {
863 smi = d->Allocate(Dart_CObject_kInt32);
864 smi->value.as_int32 = value;
865 } else {
866 smi = d->Allocate(Dart_CObject_kInt64);
867 smi->value.as_int64 = value;
868 }
869 d->AssignRef(smi);
870 }
871 }
@ Dart_CObject_kInt64
@ Dart_CObject_kInt32
uint8_t value
constexpr int32_t kMinInt32
Definition: globals.h:482
constexpr int32_t kMaxInt32
Definition: globals.h:483

The documentation for this class was generated from the following file: