OpenShot Audio Library | OpenShotAudio: juce::MACAddress Class Reference

OpenShot Audio Library | OpenShotAudio 0.3.1

Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
juce::MACAddress Class Referencefinal

`#include <juce_MACAddress.h>`

## Public Member Functions
| MACAddress () noexcept
| MACAddress (const MACAddress &) noexcept
MACAddress & | operator= (const MACAddress &) noexcept
| MACAddress (const uint8 bytes[6]) noexcept
| MACAddress (StringRef address)
const uint8 * | getBytes () const noexcept
String | toString () const
String | toString (StringRef separator) const
int64 | toInt64 () const noexcept
bool | isNull () const noexcept
bool | operator== (const MACAddress &) const noexcept
bool | operator!= (const MACAddress &) const noexcept

## Static Public Member Functions
static Array< MACAddress > | getAllAddresses ()
static void | findAllAddresses (Array< MACAddress > &results)

## Detailed Description

Represents a MAC network card adapter address ID.

Definition at line 32 of file juce_MACAddress.h.

## Constructor & Destructor Documentation

## ◆ MACAddress() [1/4]

juce::MACAddress::MACAddress | ( |  | ) |
| noexcept

Creates a null address (00-00-00-00-00-00).

Definition at line 26 of file juce_MACAddress.cpp.

## ◆ MACAddress() [2/4]

juce::MACAddress::MACAddress | ( | const MACAddress & | other | ) |
| noexcept

Creates a copy of another address.

Definition at line 31 of file juce_MACAddress.cpp.

## ◆ MACAddress() [3/4]

juce::MACAddress::MACAddress | ( | const uint8 | bytes[6] | ) |
| explicitnoexcept

Creates an address from 6 bytes.

Definition at line 42 of file juce_MACAddress.cpp.

## ◆ MACAddress() [4/4]

juce::MACAddress::MACAddress | ( | StringRef | address | ) |
| explicit

Creates an address from a hex string. If the string isn't a 6-byte hex value, this will just default-initialise the object.

Definition at line 47 of file juce_MACAddress.cpp.

## Member Function Documentation

## ◆ findAllAddresses()

static void juce::MACAddress::findAllAddresses | ( | Array< MACAddress > & | results | ) |
| static

Populates a list of the MAC addresses of all the available network cards.

Referenced by getAllAddresses().

## ◆ getAllAddresses()

Array< MACAddress > juce::MACAddress::getAllAddresses | ( |  | ) |
| static

Returns a list of the MAC addresses of all the available network cards.

Definition at line 88 of file juce_MACAddress.cpp.

Referenced by juce::SystemStats::getDeviceIdentifiers().

## ◆ getBytes()

const uint8 * juce::MACAddress::getBytes | ( |  | ) | const
| inlinenoexcept

Returns a pointer to the 6 bytes that make up this address.

Definition at line 62 of file juce_MACAddress.h.

## ◆ isNull()

bool juce::MACAddress::isNull | ( |  | ) | const
| noexcept

Returns true if this address is null (00-00-00-00-00-00).

Definition at line 95 of file juce_MACAddress.cpp.

## ◆ operator!=()

bool juce::MACAddress::operator!= | ( | const MACAddress & | other | ) | const
| noexcept

Definition at line 98 of file juce_MACAddress.cpp.

## ◆ operator=()

MACAddress & juce::MACAddress::operator= | ( | const MACAddress & | other | ) |
| noexcept

Creates a copy of another address.

Definition at line 36 of file juce_MACAddress.cpp.

## ◆ operator==()

bool juce::MACAddress::operator== | ( | const MACAddress & | other | ) | const
| noexcept

Definition at line 97 of file juce_MACAddress.cpp.

## ◆ toInt64()

int64 juce::MACAddress::toInt64 | ( |  | ) | const
| noexcept

Returns the address in the lower 6 bytes of an int64.

This uses a little-endian arrangement, with the first byte of the address being stored in the least-significant byte of the result value.

Definition at line 78 of file juce_MACAddress.cpp.

Referenced by isNull().

## ◆ toString() [1/2]

String juce::MACAddress::toString | ( |  | ) | const

Returns a dash-separated string in the form "11-22-33-44-55-66"

Definition at line 58 of file juce_MACAddress.cpp.

Referenced by toString().

## ◆ toString() [2/2]

String juce::MACAddress::toString | ( | StringRef | separator | ) | const

Returns a hex string of this address, using a custom separator between each byte.

Definition at line 63 of file juce_MACAddress.cpp.

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

- juce_MACAddress.h
- juce_MACAddress.cpp