network

package
v0.0.0-...-8093761 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 3, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MakeNetIfaceInfoString

func MakeNetIfaceInfoString(netIface *NetInterface) string

MakeNetIfaceInfoString 네트워크 인터페이스 정보 문자열 생성

Parameters:

  • netIface: 네트워크 인터페이스 정보 구조체 포인터

Returns:

  • string: 네트워크 인터페이스 정보 문자열

Types

type NetInterface

type NetInterface struct {
	Name         string           // 인터페이스명
	MTU          int              // 전송 가능한 최대 패킷 크기(바이트 단위)
	HardwareAddr net.HardwareAddr // MAC 주소
	Flags        net.Flags        // 인터페이스의 상태를 나타내는 플래그
	IP           []net.IPNet      // 인터페이스에 할당된 IP 주소와 서브넷 정보 리스트
}

func GetNetworkInterfaces

func GetNetworkInterfaces() ([]NetInterface, []error)

GetNetworkInterfaces 시스템 네트워크 인터페이스 정보 획득 함수

Returns:

  • []NetInterface: 네트워크 인터페이스 정보 구조체 슬라이스
  • error: 성공(nil), 실패(error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL