Package netaddr :: Package eui :: Class OUI
[hide private]
[frames] | no frames]

Class OUI

object --+
         |
        OUI

An individual IEEE OUI (Organisationally Unique Identifier).

For online details see - http://standards.ieee.org/regauth/oui/

Instance Methods [hide private]
 
__init__(self, oui)
Constructor
 
_parse_data(self, data, offset, size)
Returns a dict record from raw OUI record data
 
__int__(self)
Returns: integer representation of this OUI
 
__hex__(self)
Returns: hexadecimal string representation of this OUI (in network byte order).
 
registration(self, index=0)
The IEEE registration details for this OUI.
 
__str__(self)
Returns: string representation of this OUI
 
__repr__(self)
Returns: executable Python string to recreate equivalent object.

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__

Properties [hide private]
  reg_count
Number of registered organisations with this OUI

Inherited from object: __class__

Method Details [hide private]

__init__(self, oui)
(Constructor)

 

Constructor

Parameters:
  • oui - an OUI string XX-XX-XX or an unsigned integer. Also accepts and parses full MAC/EUI-48 address strings (but not MAC/EUI-48 integers)!
Overrides: object.__init__

__int__(self)

 
Returns:
integer representation of this OUI

__hex__(self)

 
Returns:
hexadecimal string representation of this OUI (in network byte order).

registration(self, index=0)

 

The IEEE registration details for this OUI.

Parameters:
  • index - the index of record (may contain multiple registrations) (Default: 0 - first registration)
Returns:
Objectified Python data structure containing registration details.

__str__(self)
(Informal representation operator)

 

str(x)

Returns:
string representation of this OUI
Overrides: object.__str__

__repr__(self)
(Representation operator)

 

repr(x)

Returns:
executable Python string to recreate equivalent object.
Overrides: object.__repr__

Property Details [hide private]

reg_count

Number of registered organisations with this OUI

Get Method:
unreachable.reg_count(self) - Number of registered organisations with this OUI