SatCat5
net_address.cc
1 // Copyright 2023 The Aerospace Corporation.
3 // This file is a part of SatCat5, licensed under CERN-OHL-W v2 or later.
5 
6 #include <satcat5/io_writeable.h>
7 #include <satcat5/net_address.h>
8 
10 
11 bool Address::write_packet(unsigned nbytes, const void* data)
12 {
13  auto wr = open_write(nbytes);
14  if (!wr) return false;
15  wr->write_bytes(nbytes, data);
16  return wr->write_finalize();
17 }
Defines a generic API for sending data to a specific destination, such as a MAC address,...
Definition: net_address.h:30
virtual satcat5::io::Writeable * open_write(unsigned len)=0
Open a new frame to the designated address and type.
"Writeable" I/O interface core definitions
Generic network Address API.