Flutter Engine
The Flutter Engine
Public Member Functions | Static Public Attributes | List of all members
dart_utils::VMServiceObject Class Reference

#include <vmservice_object.h>

Inheritance diagram for dart_utils::VMServiceObject:

Public Member Functions

void GetContents (LazyEntryVector *out_vector) const override
 
zx_status_t GetFile (Node **out_node, uint64_t id, std::string name) const override
 

Static Public Attributes

static constexpr const char * kDirName = "DartVM"
 
static constexpr const char * kPortDirName = "vmservice-port"
 
static constexpr const char * kPortDir = "/tmp/dart.services"
 

Detailed Description

Definition at line 15 of file vmservice_object.h.

Member Function Documentation

◆ GetContents()

void dart_utils::VMServiceObject::GetContents ( LazyEntryVector *  out_vector) const
override

Definition at line 37 of file vmservice_object.cc.

37 {
38 // List /tmp/dart.services if it exists, and push its contents as
39 // the contents of this directory.
40 std::vector<std::string> files;
41 if (!ReadDirContents(kPortDir, &files)) {
42 FML_LOG(ERROR) << "Failed to read Dart VM service port directory '"
43 << kPortDir << "': " << strerror(errno);
44 return;
45 }
46 for (const auto& file : files) {
47 if ((file == ".") || (file == "..")) {
48 continue;
49 }
50 out_vector->push_back({std::stoul(file) + GetStartingId(), file,
51 fuchsia::io::MODE_TYPE_FILE});
52 }
53}
static constexpr const char * kPortDir
#define FML_LOG(severity)
Definition: logging.h:82
#define ERROR(message)
Definition: elf_loader.cc:260

◆ GetFile()

zx_status_t dart_utils::VMServiceObject::GetFile ( Node **  out_node,
uint64_t  id,
std::string  name 
) const
override

Definition at line 55 of file vmservice_object.cc.

57 {
58 return ZX_ERR_NOT_FOUND;
59}

Member Data Documentation

◆ kDirName

constexpr const char* dart_utils::VMServiceObject::kDirName = "DartVM"
staticconstexpr

Definition at line 17 of file vmservice_object.h.

◆ kPortDir

constexpr const char* dart_utils::VMServiceObject::kPortDir = "/tmp/dart.services"
staticconstexpr

Definition at line 19 of file vmservice_object.h.

◆ kPortDirName

constexpr const char* dart_utils::VMServiceObject::kPortDirName = "vmservice-port"
staticconstexpr

Definition at line 18 of file vmservice_object.h.


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