Adds members to the distribution list

        :type distribution_list: zobjects.DistributionList
        :param members:          list of email addresses you want to add
        :type members:           list of str
973205
def add_distribution_list_member(self, distribution_list, members):
        
        members = [{'_content': v} for v in members]
        resp = self.request_single('AddDistributionListMember', {
            'id': self._get_or_fetch_id(distribution_list,
                                        self.get_distribution_list),
            'dlm': members
        })
        return resp
988254
def addSubscribers(self, emails_list):
        

        if not hasattr(emails_list, "__iter__"):
            error_msg = "Input parameter 'emails_list' is not iterable"
            self.log.error(error_msg)
            raise exception.BadValue(error_msg)

        # overall flag
        existed_flags = False

        headers, raw_data = self._perform_subscribe()
        for email in emails_list:
            existed_flag, raw_data = self._add_subscriber(email, raw_data)
            existed_flags = existed_flags and existed_flag

        if existed_flags:
            return

        self._update_subscribe(headers, raw_data)
        self.log.info("Successfully add subscribers: %s for <Workitem %s>",
                      emails_list, self)
1064838
def list_accounts_add(self, id, account_ids):
        
        id = self.__unpack_id(id)
        
        if not isinstance(account_ids, list):
            account_ids = [account_ids]
        account_ids = list(map(lambda x: self.__unpack_id(x), account_ids))
        
        params = self.__generate_params(locals(), ['id'])        
        self.__api_request('POST', '/api/v1/lists/{0}/accounts'.format(id), params)
1291562
def update_membership(self, group_id, users=[]):
        
        data = {
            'groupId': group_id,
            'users': users,
        }
        return _fix_group(self.post('updateMembership', data))
952194
public void addMembership(Membership membership) throws RedmineException {
		final Project project = membership.getProject();
		if (project == null)
			throw new IllegalArgumentException("Project must be set");
		if (membership.getUser() == null)
			throw new IllegalArgumentException("User must be set");
		transport.addChildEntry(Project.class, getProjectKey(project),
				membership);
	}
1211564
def members(self):
        
        if self._members is None:
            self._members = MemberList(
                self._version,
                account_sid=self._solution['account_sid'],
                queue_sid=self._solution['sid'],
            )
        return self._members
579064
public void updateGroupMembers(long logIndex, Collection<Endpoint> members) {
        state.updateGroupMembers(logIndex, members);
        printMemberState();
    }
1142480
def members(self):
        
        if self._members is None:
            self._members = MemberList(
                self._version,
                service_sid=self._solution['service_sid'],
                channel_sid=self._solution['sid'],
            )
        return self._members
844942
def add_member_to_group(self, group_id, member_id):
        
        route_values = {}
        if group_id is not None:
            route_values['groupId'] = self._serialize.url('group_id', group_id, 'str')
        if member_id is not None:
            route_values['memberId'] = self._serialize.url('member_id', member_id, 'str')
        self._send(http_method='PUT',
                   location_id='45a36e53-5286-4518-aa72-2d29f7acc5d8',
                   version='5.0-preview.1',
                   route_values=route_values)
795582
def linkify_contactgroups_contacts(self, contacts):
        
        for contactgroup in self:
            mbrs = contactgroup.get_contacts()

            # The new member list, in id
            new_mbrs = []
            for mbr in mbrs:
                mbr = mbr.strip()  # protect with strip at the beginning so don't care about spaces
                if mbr == '':  # void entry, skip this
                    continue
                member = contacts.find_by_name(mbr)
                # Maybe the contact is missing, if so, must be put in unknown_members
                if member is not None:
                    new_mbrs.append(member.uuid)
                else:
                    contactgroup.add_unknown_members(mbr)

            # Make members uniq
            new_mbrs = list(set(new_mbrs))

            # We find the id, we replace the names
            contactgroup.replace_members(new_mbrs)
260972
def add_member_email(self, email, permissions=None):
        
        data = {'email': email}

        if isinstance(permissions, dict):
            data.update({
                'permissions': permissions
            })

        extra = {
            'resource': self.__class__.__name__,
            'query': {
                'id': self.id,
                'data': data,
            }
        }
        logger.info('Adding member using email', extra=extra)
        response = self._api.post(
            url=self._URL['members_query'].format(id=self.id), data=data)
        member_data = response.json()
        return Member(api=self._api, **member_data)
1302170
def add_list_members(self, screen_name=None, user_id=None, slug=None,
                         list_id=None, owner_id=None, owner_screen_name=None):
        
        return self._add_list_members(list_to_csv(screen_name),
                                      list_to_csv(user_id),
                                      slug, list_id, owner_id,
                                      owner_screen_name)
848667
def add_users_to_organization(self, organization_id, users_list):
        
        log.warning('Adding users...')
        url = 'rest/servicedeskapi/organization/{}/user'.format(organization_id)
        data = {'usernames': users_list}

        return self.post(url, headers=self.experimental_headers, data=data)
979386
def populate_class_members(self, element_cls, prop_name):
        
        super(OneOrMore, self).populate_class_members(
            element_cls, prop_name
        )
        self._add_list_getter()
        self._add_creator()
        self._add_inserter()
        self._add_adder()
        self._add_public_adder()
        delattr(element_cls, prop_name)
1007159
public Membership add(Address new_member) {
        synchronized(members) {
            if(new_member != null && !members.contains(new_member)) {
                members.add(new_member);
            }
        }
        return this;
    }
914757
def add_unknown_members(self, members):
        
        if not isinstance(members, list):
            members = [members]

        if not hasattr(self, 'unknown_members'):
            self.unknown_members = members
        else:
            self.unknown_members.extend(members)
1055427
def p_members(self, p):
        """"""
        if len(p) == 1:
            p[0] = list()
        else:
            p[1].append(p[2])
            p[0] = p[1]