PcapPlusPlus  Next
pcpp::IPv4TimestampOptionValue Struct Reference

#include <IPv4Layer.h>

Public Types

enum  TimestampType { TimestampOnly = 0 , TimestampAndIP = 1 , TimestampsForPrespecifiedIPs = 2 , Unknown = 3 }
 An enum for IPv4 timestamp option types. More...
 

Public Member Functions

 IPv4TimestampOptionValue ()
 The default constructor.
 
void clear ()
 

Public Attributes

TimestampType type
 The timestamp value type.
 
std::vector< uint32_t > timestamps
 A list of timestamps parsed from the IPv4 timestamp option value.
 
std::vector< IPv4AddressipAddresses
 A list of IPv4 addresses parsed from the IPv4 timestamp option value.
 

Detailed Description

A struct representing a parsed value of the IPv4 timestamp option. This struct is used returned in IPv4OptionData::getTimestampOptionValue() method

Member Enumeration Documentation

◆ TimestampType

An enum for IPv4 timestamp option types.

Enumerator
TimestampOnly 

Value containing only timestamps.

TimestampAndIP 

Value containing both timestamps and IPv4 addresses.

TimestampsForPrespecifiedIPs 

The IPv4 addresses are prespecified.

Unknown 

Invalid or unknown value type.

Member Function Documentation

◆ clear()

void pcpp::IPv4TimestampOptionValue::clear ( )
inline

Clear the structure. Clean the timestamps and IP addresses vectors and set the type as IPv4TimestampOptionValue::Unknown