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

Public Member Functions

 MapMessageSerializationCluster (Zone *zone, bool is_canonical, intptr_t cid)
 
 ~MapMessageSerializationCluster ()
 
void Trace (MessageSerializer *s, Object *object)
 
void WriteNodes (MessageSerializer *s)
 
void WriteEdges (MessageSerializer *s)
 
- Public Member Functions inherited from dart::MessageSerializationCluster
 MessageSerializationCluster (const char *name, MessagePhase phase, intptr_t cid, bool is_canonical=false)
 
virtual ~MessageSerializationCluster ()
 
virtual void Trace (MessageSerializer *s, Object *object)=0
 
virtual void WriteNodes (MessageSerializer *s)=0
 
virtual void WriteEdges (MessageSerializer *s)
 
virtual void TraceApi (ApiMessageSerializer *s, Dart_CObject *object)
 
virtual void WriteNodesApi (ApiMessageSerializer *s)
 
virtual void WriteEdgesApi (ApiMessageSerializer *s)
 
const char * name () const
 
MessagePhase phase () const
 
intptr_t cid () 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::MessageSerializationCluster
 DISALLOW_COPY_AND_ASSIGN (MessageSerializationCluster)
 
- Protected Attributes inherited from dart::MessageSerializationCluster
const char *const name_
 
const MessagePhase phase_
 
const intptr_t cid_
 
const bool is_canonical_
 

Detailed Description

Definition at line 2104 of file message_snapshot.cc.

Constructor & Destructor Documentation

◆ MapMessageSerializationCluster()

dart::MapMessageSerializationCluster::MapMessageSerializationCluster ( Zone zone,
bool  is_canonical,
intptr_t  cid 
)
inline

Definition at line 2106 of file message_snapshot.cc.

2111 cid,
2112 is_canonical),
2113 objects_(zone, 0) {}
MessageSerializationCluster(const char *name, MessagePhase phase, intptr_t cid, bool is_canonical=false)

◆ ~MapMessageSerializationCluster()

dart::MapMessageSerializationCluster::~MapMessageSerializationCluster ( )
inline

Definition at line 2114 of file message_snapshot.cc.

2114{}

Member Function Documentation

◆ Trace()

void dart::MapMessageSerializationCluster::Trace ( MessageSerializer s,
Object object 
)
inlinevirtual

Implements dart::MessageSerializationCluster.

Definition at line 2116 of file message_snapshot.cc.

2116 {
2117 Map* map = static_cast<Map*>(object);
2118 objects_.Add(map);
2119
2120 // Compensation for bogus type prefix optimization.
2121 TypeArguments& args =
2122 TypeArguments::Handle(s->zone(), map->untag()->type_arguments());
2123 if (!args.IsNull() && (args.Length() != 2)) {
2124 args = args.TruncatedTo(2);
2125 map->untag()->set_type_arguments(args.ptr());
2126 }
2127
2128 s->Push(map->untag()->type_arguments());
2129 s->Push(map->untag()->data());
2130 s->Push(map->untag()->used_data());
2131 }
static Object & Handle()
Definition: object.h:407
struct MyStruct s
G_BEGIN_DECLS G_MODULE_EXPORT FlValue * args
SI auto map(std::index_sequence< I... >, Fn &&fn, const Args &... args) -> skvx::Vec< sizeof...(I), decltype(fn(args[0]...))>
Definition: SkVx.h:680

◆ WriteEdges()

void dart::MapMessageSerializationCluster::WriteEdges ( MessageSerializer s)
inlinevirtual

Reimplemented from dart::MessageSerializationCluster.

Definition at line 2142 of file message_snapshot.cc.

2142 {
2143 const intptr_t count = objects_.length();
2144 for (intptr_t i = 0; i < count; i++) {
2145 Map* map = objects_[i];
2146 s->WriteRef(map->untag()->type_arguments());
2147 s->WriteRef(map->untag()->data());
2148 s->WriteRef(map->untag()->used_data());
2149 }
2150 }
int count
Definition: FontMgrTest.cpp:50

◆ WriteNodes()

void dart::MapMessageSerializationCluster::WriteNodes ( MessageSerializer s)
inlinevirtual

Implements dart::MessageSerializationCluster.

Definition at line 2133 of file message_snapshot.cc.

2133 {
2134 const intptr_t count = objects_.length();
2135 s->WriteUnsigned(count);
2136 for (intptr_t i = 0; i < count; i++) {
2137 Map* map = objects_[i];
2138 s->AssignRef(map);
2139 }
2140 }

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