vfs::PseudoFile

Summary

Inheritance

Inherits from: vfs::internal::File

Constructors and Destructors

PseudoFile(size_t max_file_size, ReadHandler read_handler, WriteHandler write_handler)
~PseudoFile()

Public types

ReadHandler using
fit::function< zx_status_t(std::vector< uint8_t > *output, size_t max_bytes)>
WriteHandler using
fit::function< zx_status_t(std::vector< uint8_t > input)>

Public functions

GetAttr(fuchsia::io::NodeAttributes *out_attributes) const override
zx_status_t

Protected functions

CreateConnection(fuchsia::io::OpenFlags flags, std::unique_ptr< vfs::internal::Connection > *connection) override
zx_status_t
GetAllowedFlags() const override
fuchsia::io::OpenFlags

Public types

ReadHandler

fit::function< zx_status_t(std::vector< uint8_t > *output, size_t max_bytes)> ReadHandler

WriteHandler

fit::function< zx_status_t(std::vector< uint8_t > input)> WriteHandler

Public functions

GetAttr

zx_status_t GetAttr(
  fuchsia::io::NodeAttributes *out_attributes
) const override

PseudoFile

 PseudoFile(
  size_t max_file_size,
  ReadHandler read_handler,
  WriteHandler write_handler
)

~PseudoFile

 ~PseudoFile() override

Protected functions

CreateConnection

zx_status_t CreateConnection(
  fuchsia::io::OpenFlags flags,
  std::unique_ptr< vfs::internal::Connection > *connection
) override

GetAllowedFlags

fuchsia::io::OpenFlags GetAllowedFlags() const override