mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 16:07:47 +00:00
AK: Rename Time to Duration
That's what this class really is; in fact that's what the first line of the comment says it is. This commit does not rename the main files, since those will contain other time-related classes in a little bit.
This commit is contained in:
parent
82ddc813d5
commit
213025f210
140 changed files with 634 additions and 628 deletions
|
@ -29,7 +29,7 @@ class NetworkAdapter;
|
|||
using NetworkByteBuffer = AK::Detail::ByteBuffer<1500>;
|
||||
|
||||
struct PacketWithTimestamp final : public AtomicRefCounted<PacketWithTimestamp> {
|
||||
PacketWithTimestamp(NonnullOwnPtr<KBuffer> buffer, Time timestamp)
|
||||
PacketWithTimestamp(NonnullOwnPtr<KBuffer> buffer, Duration timestamp)
|
||||
: buffer(move(buffer))
|
||||
, timestamp(timestamp)
|
||||
{
|
||||
|
@ -38,7 +38,7 @@ struct PacketWithTimestamp final : public AtomicRefCounted<PacketWithTimestamp>
|
|||
ReadonlyBytes bytes() { return buffer->bytes(); }
|
||||
|
||||
NonnullOwnPtr<KBuffer> buffer;
|
||||
Time timestamp;
|
||||
Duration timestamp;
|
||||
IntrusiveListNode<PacketWithTimestamp, RefPtr<PacketWithTimestamp>> packet_node;
|
||||
};
|
||||
|
||||
|
@ -79,7 +79,7 @@ public:
|
|||
void send(MACAddress const&, ARPPacket const&);
|
||||
void fill_in_ipv4_header(PacketWithTimestamp&, IPv4Address const&, MACAddress const&, IPv4Address const&, IPv4Protocol, size_t, u8 type_of_service, u8 ttl);
|
||||
|
||||
size_t dequeue_packet(u8* buffer, size_t buffer_size, Time& packet_timestamp);
|
||||
size_t dequeue_packet(u8* buffer, size_t buffer_size, Duration& packet_timestamp);
|
||||
|
||||
bool has_queued_packets() const { return !m_packet_queue.is_empty(); }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue