UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FInternetAddr Class Referenceabstract

#include <IPAddress.h>

+ Inheritance diagram for FInternetAddr:

Public Member Functions

virtual ~FInternetAddr ()
 
virtual bool CompareEndpoints (const FInternetAddr &InAddr) const
 
virtual void SetIp (uint32 InAddr)=0
 
virtual void SetIp (const TCHAR *InAddr, bool &bIsValid)=0
 
virtual void GetIp (uint32 &OutAddr) const =0
 
virtual void SetPort (int32 InPort)=0
 
virtual bool IsPortValid (int32 InPort) const
 
virtual void GetPort (int32 &OutPort) const
 
virtual int32 GetPort () const =0
 
virtual void SetPlatformPort (int32 InPort)
 
virtual int32 GetPlatformPort () const
 
virtual void SetRawIp (const TArray< uint8 > &RawAddr)=0
 
virtual TArray< uint8GetRawIp () const =0
 
virtual void SetAnyAddress ()=0
 
virtual void SetBroadcastAddress ()=0
 
virtual void SetLoopbackAddress ()=0
 
virtual FString ToString (bool bAppendPort) const =0
 
virtual bool operator== (const FInternetAddr &Other) const
 
virtual uint32 GetTypeHash () const =0
 
virtual bool IsValid () const =0
 
virtual TSharedRef< FInternetAddrClone () const =0
 
virtual FName GetProtocolType () const
 
virtual SOCKETS_API void DumpAddrData () const
 

Protected Member Functions

 FInternetAddr ()
 

Friends

uint32 GetTypeHash (const FInternetAddr &InAddr)
 

Detailed Description

Represents an internet address. All data is in network byte order

Constructor & Destructor Documentation

◆ FInternetAddr()

FInternetAddr::FInternetAddr ( )
inlineprotected

Hidden on purpose

◆ ~FInternetAddr()

virtual FInternetAddr::~FInternetAddr ( )
inlinevirtual

Member Function Documentation

◆ Clone()

virtual TSharedRef< FInternetAddr > FInternetAddr::Clone ( ) const
pure virtual

Creates a new structure with the same data as this structure

Returns
The new structure

Implemented in FInternetAddrDemo.

◆ CompareEndpoints()

virtual bool FInternetAddr::CompareEndpoints ( const FInternetAddr InAddr) const
inlinevirtual

Compares FInternetAddrs together, comparing the logical net addresses (endpoints) of the data stored, rather than doing a memory comparison like the equality operator does. If it is not explicitly implemented, this falls back to just doing the same behavior of the comparison operator.

@Param InAddr The address to compare with.

Returns
true if the endpoint stored in this FInternetAddr is the same as the input.

◆ DumpAddrData()

void FInternetAddr::DumpAddrData ( ) const
virtual

◆ GetIp()

virtual void FInternetAddr::GetIp ( uint32 OutAddr) const
pure virtual

Copies the network byte order ip address to a host byte order dword

Parameters
OutAddrthe out param receiving the ip address

Implemented in FInternetAddrDemo.

◆ GetPlatformPort()

virtual int32 FInternetAddr::GetPlatformPort ( ) const
inlinevirtual

Get platform specific port data.

◆ GetPort() [1/2]

virtual int32 FInternetAddr::GetPort ( ) const
pure virtual

Returns the port number from this address in host byte order

Implemented in FInternetAddrDemo.

◆ GetPort() [2/2]

virtual void FInternetAddr::GetPort ( int32 OutPort) const
inlinevirtual

Copies the port number from this address and places it into a host byte order int

Parameters
OutPortthe host byte order int that receives the port

Reimplemented in FInternetAddrDemo.

◆ GetProtocolType()

virtual FName FInternetAddr::GetProtocolType ( ) const
inlinevirtual

Returns the protocol type name of the address data currently stored in this struct

Returns
The type of the address. If it's not known or overridden in a derived class, the return is None.

◆ GetRawIp()

virtual TArray< uint8 > FInternetAddr::GetRawIp ( ) const
pure virtual

Gets the ip address in a raw array stored in network byte order.

Returns
The raw address stored in an array

Implemented in FInternetAddrDemo.

◆ GetTypeHash()

virtual uint32 FInternetAddr::GetTypeHash ( ) const
pure virtual

Hash function for use with TMap's - exposed through FInternetAddrMapRef

Returns
The value to use for the hash

Implemented in FInternetAddrDemo.

◆ IsPortValid()

virtual bool FInternetAddr::IsPortValid ( int32  InPort) const
inlinevirtual

Report whether the port is in a valid range for SetPort.

◆ IsValid()

virtual bool FInternetAddr::IsValid ( ) const
pure virtual

Is this a well formed internet address

Returns
true if a valid IP, false otherwise

Implemented in FInternetAddrDemo.

◆ operator==()

virtual bool FInternetAddr::operator== ( const FInternetAddr Other) const
inlinevirtual

Compares two internet ip addresses for equality

Parameters
Otherthe address to compare against

Reimplemented in FInternetAddrDemo.

◆ SetAnyAddress()

virtual void FInternetAddr::SetAnyAddress ( )
pure virtual

Sets the address to be any address

Implemented in FInternetAddrDemo.

◆ SetBroadcastAddress()

virtual void FInternetAddr::SetBroadcastAddress ( )
pure virtual

Sets the address to broadcast

Implemented in FInternetAddrDemo.

◆ SetIp() [1/2]

virtual void FInternetAddr::SetIp ( const TCHAR InAddr,
bool bIsValid 
)
pure virtual

Sets the ip address from a string ("A.B.C.D")

Parameters
InAddrthe string containing the new ip address to use

Implemented in FInternetAddrDemo.

◆ SetIp() [2/2]

virtual void FInternetAddr::SetIp ( uint32  InAddr)
pure virtual

Sets the ip address from a host byte order uint32

Parameters
InAddrthe new address to use (must convert to network byte order)

Implemented in FInternetAddrDemo.

◆ SetLoopbackAddress()

virtual void FInternetAddr::SetLoopbackAddress ( )
pure virtual

Sets the address to loopback

Implemented in FInternetAddrDemo.

◆ SetPlatformPort()

virtual void FInternetAddr::SetPlatformPort ( int32  InPort)
inlinevirtual

Set Platform specific port data

◆ SetPort()

virtual void FInternetAddr::SetPort ( int32  InPort)
pure virtual

Sets the port number from a host byte order int

Parameters
InPortthe new port to use (must convert to network byte order)

Implemented in FInternetAddrDemo.

◆ SetRawIp()

virtual void FInternetAddr::SetRawIp ( const TArray< uint8 > &  RawAddr)
pure virtual

Sets the ip address from a raw network byte order array.

Parameters
RawAddrthe new address to use (must be converted to network byte order)

Implemented in FInternetAddrDemo.

◆ ToString()

virtual FString FInternetAddr::ToString ( bool  bAppendPort) const
pure virtual

Converts this internet ip address to string form

Parameters
bAppendPortwhether to append the port information or not

Implemented in FInternetAddrDemo.

Friends And Related Symbol Documentation

◆ GetTypeHash

uint32 GetTypeHash ( const FInternetAddr InAddr)
friend

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