# Path: roscraco/helper/validator.py
# WEP_CONSTRAINTS_MAP = {
#     64: {'ascii': 5, 'hex': 10},
#     128: {'ascii': 13, 'hex': 26},
#     152: {'ascii': 16, 'hex': 32}
# }
# def is_valid_mac_address(mac):
# def is_valid_mac_address_normalized(mac):
# def is_valid_ip_address(ip):
# def _is_hex_string(string):
# def is_valid_wpa_psk_password(password):
# def is_valid_wep_password(password, bit_length):
# def is_wep_password_in_hex(password, bit_length):
# def is_valid_ssid(ssid):
# def is_ip_in_range(ip, ip_range_start, ip_range_end):
# 
# Path: roscraco/helper/converter.py
# def ip2long(ip_addr):
# def long2ip(ip):
# def normalize_mac(mac):
# 
# Path: roscraco/exception.py
# class RouterSettingsError(RouterError):
#     pass


from roscraco.helper import validator, converter
from roscraco.exception import RouterSettingsError
    def __ne__(self, other):
        return not self == other

    def __hash__(self):
        return id(self)

    def export(self):
        """Exports the most important settings attributes,
        omitting any internal attributes.
        """
        export = {}
        for i, item in enumerate(self):
            export['entry_%d' % i] = item.export()
        return export


class DHCPReservationListItem(object):
    """Represents a single entry in the DHCP address reservation table."""

    #: Properties to export()
    PROPERTIES = (
        'mac', 'ip'
    )

    def __init__(self):
        self._mac_address = None
        self._ip_address = None
        self._is_enabled = True

    def set_mac(self, value):

# Path: roscraco/helper/validator.py
# WEP_CONSTRAINTS_MAP = {
#     64: {'ascii': 5, 'hex': 10},
#     128: {'ascii': 13, 'hex': 26},
#     152: {'ascii': 16, 'hex': 32}
# }
# def is_valid_mac_address(mac):
# def is_valid_mac_address_normalized(mac):
# def is_valid_ip_address(ip):
# def _is_hex_string(string):
# def is_valid_wpa_psk_password(password):
# def is_valid_wep_password(password, bit_length):
# def is_wep_password_in_hex(password, bit_length):
# def is_valid_ssid(ssid):
# def is_ip_in_range(ip, ip_range_start, ip_range_end):
# 
# Path: roscraco/helper/converter.py
# def ip2long(ip_addr):
# def long2ip(ip):
# def normalize_mac(mac):
# 
# Path: roscraco/exception.py
# class RouterSettingsError(RouterError):
#     pass


# Path: roscraco/response/dhcp.py
from roscraco.helper import validator, converter
from roscraco.exception import RouterSettingsError

    def __ne__(self, other):
        return not self == other

    def __hash__(self):
        return id(self)

    def export(self):
        """Exports the most important settings attributes,
        omitting any internal attributes.
        """
        export = {}
        for i, item in enumerate(self):
            export['entry_%d' % i] = item.export()
        return export


class DHCPReservationListItem(object):
    """Represents a single entry in the DHCP address reservation table."""

    #: Properties to export()
    PROPERTIES = (
        'mac', 'ip'
    )

    def __init__(self):
        self._mac_address = None
        self._ip_address = None
        self._is_enabled = True

    def set_mac(self, value):

        self._mac_address = converter.normalize_mac(value)