NetworkInterface.LoopbackInterfaceIndex Propriedade
Definição
Obtém o índice da interface de loopback do IPv4.Gets the index of the IPv4 loopback interface.
public:
static property int LoopbackInterfaceIndex { int get(); };
public static int LoopbackInterfaceIndex { get; }
member this.LoopbackInterfaceIndex : int
Public Shared ReadOnly Property LoopbackInterfaceIndex As Integer
Valor da propriedade
Um Int32 que contém o índice da interface de loopback do IPv4.A Int32 that contains the index for the IPv4 loopback interface.
Exceções
Essa propriedade é inválida em computadores que executam apenas o Ipv6.This property is not valid on computers running only Ipv6.
Comentários
O índice da interface de loopback geralmente é 1, mas você não pode contar com isso.The index of the loopback interface is usually 1, but you cannot rely on this. Use a LoopbackInterfaceIndex propriedade para obter o valor correto.Use the LoopbackInterfaceIndex property to get the correct value.
Uma interface de rede pode ter índices de interface diferentes para a interface de loopback IPv4 e IPv6.A network interface may have different interface indexes for the IPv4 and IPv6 loopback interface. A LoopbackInterfaceIndex propriedade retorna apenas a interface de loopback IPv4.The LoopbackInterfaceIndex property only returns the IPv4 loopback interface.