'return initiator names.'

def _find_initiator_names(self, connector):

    initiatornamelist = []
    if ((self.protocol == 'fc') and connector['wwpns']):
        LOG.debug('_find_initiator_names,    wwpns:    %s.', connector['wwpns'])
        initiatornamelist = connector['wwpns']
    elif ((self.protocol == 'iSCSI') and connector['initiator']):
        LOG.debug('_find_initiator_names,    initiator:    %s.', connector['initiator'])
        initiatornamelist.append(connector['initiator'])
    if (not initiatornamelist):
        msg = (_('_find_initiator_names,    connector:    %(connector)s,    initiator    not    found.') % {'connector': connector})
        LOG.error(msg)
        raise exception.VolumeBackendAPIException(data=msg)
    LOG.debug('_find_initiator_names,    initiator    list:    %(initiator)s.', {'initiator': initiatornamelist})
    return initiatornamelist
