The underlaying ``pyudev.Device`` instance can be accessed by using the
        ``device`` property. This propety is cached, so only one lookup is
        performed to obtain the device object. This cache is invalidated by
        :py:meth:`~refresh` method.

def device(self):
        """
        The underlaying ``pyudev.Device`` instance can be accessed by using the
        ``device`` property. This propety is cached, so only one lookup is
        performed to obtain the device object. This cache is invalidated by
        :py:meth:`~refresh` method.
        """
        # We always create a new context and look up the devices because they
        # may disappear or change their state between lookups.
        if not self._device:
            ctx = pyudev.Context()
            devs = ctx.list_devices(sys_name=self.name)
            try:
                self._device = list(devs)[0]
            except IndexError:
                raise ValueError(
                    'Device {} no longer present in context'.format(self.name))
        return self._device