System.Net.Socket.TNetEndpoint.Create
Delphi
class function Create(const Name, Service: string; SocketType: TSocketType = TSocketType.TCP): TNetEndpoint; overload; static;
class function Create(const Address: Cardinal; const Port: Word): TNetEndpoint; overload; static;
class function Create(const B1, B2, B3, B4: Byte; const Port: Word): TNetEndpoint; overload; static;
class function Create(const Address: TIPAddress; const Service: string; SocketType: TSocketType = TSocketType.TCP): TNetEndpoint; overload; static;
class function Create(const Address: TIPAddress; const Port: Word): TNetEndpoint; overload; static;
class function Create(const Family: Word; const Name, Service: string; SocketType: TSocketType = TSocketType.TCP): TNetEndpoint; overload; static;
class function Create(const Family: Word; const Address: Cardinal; const Port: Word): TNetEndpoint; overload; static;
class function Create(const Family: Word; const B1, B2, B3, B4: Byte; const Port: Word): TNetEndpoint; overload; static;
class function Create(const Family: Word; const Address: TIPAddress; const Service: string; SocketType: TSocketType = TSocketType.TCP): TNetEndpoint; overload; static;
class function Create(const Family: Word; const Address: TIPAddress; const Port: Word): TNetEndpoint; overload; static;
class function Create(const Endpoint: sockaddr_in): TNetEndpoint; overload; inline; static;
C++
static TNetEndpoint __fastcall Create(const System::UnicodeString Name, const System::UnicodeString Service, TSocketType SocketType = (TSocketType)(0x0))/* overload */;
static TNetEndpoint __fastcall Create(const unsigned Address, const System::Word Port)/* overload */;
static TNetEndpoint __fastcall Create(const System::Byte B1, const System::Byte B2, const System::Byte B3, const System::Byte B4, const System::Word Port)/* overload */;
static TNetEndpoint __fastcall Create(const TIPAddress Address, const System::UnicodeString Service, TSocketType SocketType = (TSocketType)(0x0))/* overload */;
static TNetEndpoint __fastcall Create(const TIPAddress Address, const System::Word Port)/* overload */;
static TNetEndpoint __fastcall Create(const System::Word Family, const System::UnicodeString Name, const System::UnicodeString Service, TSocketType SocketType = (TSocketType)(0x0))/* overload */;
static TNetEndpoint __fastcall Create(const System::Word Family, const unsigned Address, const System::Word Port)/* overload */;
static TNetEndpoint __fastcall Create(const System::Word Family, const System::Byte B1, const System::Byte B2, const System::Byte B3, const System::Byte B4, const System::Word Port)/* overload */;
static TNetEndpoint __fastcall Create(const System::Word Family, const TIPAddress Address, const System::UnicodeString Service, TSocketType SocketType = (TSocketType)(0x0))/* overload */;
static TNetEndpoint __fastcall Create(const System::Word Family, const TIPAddress Address, const System::Word Port)/* overload */;
static TNetEndpoint __fastcall Create(const sockaddr_in &Endpoint)/* overload */;
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
function | public | System.Net.Socket.pas System.Net.Socket.hpp |
System.Net.Socket | TNetEndpoint |
Description
Creates an instance of TNetEndpoint.
The accepted combinations of parameters are:
Family
(optional).Address
orName
orB1, B2, B3, B4
.Service
orPort
.SocketType
(optional, you can specify it only if the previous parameter isService
. Default is TSocketType.TCP).
Where:
Family
is the address family of the IP address.Address
is the IP address, either as an instance of TIPAddress or as a Cardinal.Name
is a domain name.B1, B2, B3, B4
are the individual octets of an IPv4 address.Service
is a service name.Port
is a port number.SocketType
is the type of the socket.