Returns the device's alias (name).
439835
def alias(self):
        
        try:
            return self._properties.Get('org.bluez.Device1', 'Alias')
        except dbus.exceptions.DBusException as e:
            if e.get_dbus_name() == 'org.freedesktop.DBus.Error.UnknownObject':
                # BlueZ sometimes doesn't provide an alias, we then simply return `None`.
                # Might occur when device was deleted as the following issue points out:
                # https://github.com/blueman-project/blueman/issues/460
                return None
            else:
                raise _error_from_dbus_error(e)
101845
def exists_alias(self, alias_name, index_name=None):
        """"""

        return self._es_conn.indices.exists_alias(index=index_name, name=alias_name)
843039
def aliases(self):
        
        links = list(self.device.device_links)
        links.insert(0, self.node)
        return links
405377
def _get_device_id(self, bus):
        
        _dbus = bus.get(SERVICE_BUS, PATH)
        devices = _dbus.devices()

        if self.device is None and self.device_id is None and len(devices) == 1:
            return devices[0]

        for id in devices:
            self._dev = bus.get(SERVICE_BUS, DEVICE_PATH + "/%s" % id)
            if self.device == self._dev.name:
                return id

        return None
684509
async function getDeviceTagAlias (registrationId) {
  var url = HOST_NAME_SSL + DEVICE_PATH + '/' + registrationId
  return _request(this, url, null, 'GET')
}
271369
def get_alias(self, alias):
        
        aliases = self.get_aliases()
        if alias in aliases.alias:
            settings = self.settings.copy()
            settings.alias = alias
            settings.index = alias
            return Index(read_only=True, kwargs=settings, cluster=self)
        Log.error("Can not find any index with alias {{alias_name}}",  alias_name= alias)
850564
def by_name(name):
    
    devices = discover(all_households=True)
    for device in (devices or []):
        if device.player_name == name:
            return device
    return None
1197611
public Alias getAlias(String aliasName) {
        Alias result = null;
        for (Alias item : getAliasesList()) {
            if (item.getName().equals(aliasName)) {
                result = item;
            }
        }
        return result;
    }
33642
def _get_device_names_in_group(self):
        '''
        '''

        device_names = []
        dg = pollster(self._get_device_group)(self.devices[0])
        members = dg.devices_s.get_collection()
        for member in members:
            member_name = member.name.replace('/%s/' % self.partition, '')
            device_names.append(member_name)
        return device_names
755554
def hostname(self):
        """"""
        try:
            return self.data.get('identity').get('host_name')
        except (KeyError, AttributeError):
            return self.device_status_simple('')
70434
def _onAs( self, name ):
        "  "
        if self.__lastImport.what:
            self.__lastImport.what[ -1 ].alias = name
        else:
            self.__lastImport.alias = name
        return
989187
def map_aliases_to_device_objects(self):
        
        all_devices = self.get_all_devices_in_portal()
        for dev_o in all_devices:
            dev_o['portals_aliases'] = self.get_portal_by_name(
                                                        self.portal_name()
                                                )[2][1]['info']['aliases'][ dev_o['rid'] ]
        return all_devices
734484
def device_info(self):
        """"""
        return {
            'family': self.family,
            'platform': self.platform,
            'os_type': self.os_type,
            'os_version': self.os_version,
            'udi': self.udi,
            # TODO(klstanie): add property to make driver automatically
            'driver_name': self.driver.platform,
            'mode': self.mode,
            'is_console': self.is_console,
            'is_target': self.is_target,
            # 'prompt': self.driver.base_prompt(self.prompt),
            'hostname': self.hostname,
        }
1155070
def _check_device_exists_in_device_group(self, device_name):
        '''
        '''

        dg = self._get_device_group(self.devices[0])
        dg.devices_s.devices.load(name=device_name, partition=self.partition)
361059
public static String getfullNameForDevice(final String deviceName) throws DevFailed {
        if (deviceName == null) {
            throw DevFailedUtils.newDevFailed("cannot retrieve device name", "device name is empty");
        }
        String result;
        final String[] fields = deviceName.split("/");
        final Database db = ApiUtil.get_db_obj();
        if (deviceName.contains(DBASE_NO)) {
            result = deviceName;
        } else if (fields.length == 1) {
            result = db.get_device_from_alias(fields[0]);
        } else {
            result = deviceName;
        }
        return result;
    }
783763
def aliased_slot_name(self, slot: SLOT_OR_SLOTNAME) -> str:
        
        if isinstance(slot, str):
            slot = self.schema.slots[slot]
        return slot.alias if slot.alias else slot.name
328463
def _getdevicetuple(iobtdevice):
    
    addr = _macutil.formatdevaddr(iobtdevice.getAddressString())
    name = iobtdevice.getName()
    cod = iobtdevice.getClassOfDevice()
    return (addr, name, cod)