Class MacNetworkIF

java.lang.Object
oshi.hardware.common.AbstractNetworkIF
oshi.hardware.common.platform.mac.MacNetworkIF
All Implemented Interfaces:
NetworkIF

@ThreadSafe public abstract class MacNetworkIF extends AbstractNetworkIF
Base class for macOS NetworkIF implementations. Subclasses provide platform-specific display name resolution and network statistics updates.
  • Constructor Details

  • Method Details

    • getIfType

      public int getIfType()
      Description copied from interface: NetworkIF
      (Windows, macOS) The NDIS Interface Type. NDIS interface types are registered with the Internet Assigned Numbers Authority (IANA), which publishes a list of interface types periodically in the Assigned Numbers RFC, or in a derivative of it that is specific to Internet network management number assignments.

      (Linux) ARP Protocol hardware identifiers defined in include/uapi/linux/if_arp.h

      Returns:
      the ifType
    • setIfType

      protected void setIfType(int ifType)
      Sets the interface type.
      Parameters:
      ifType - the interface type to set