Updates an existing Xero contact

 Usage :

 contact = xero_gateway.get_contact(some_contact_id)
 contact.email = "a_new_email_ddress"

 xero_gateway.update_contact(contact)
967841
def update_contact(contact)
      raise "contact_id or contact_number is required for updating contacts" if contact.contact_id.nil? and contact.contact_number.nil?
      save_contact(contact)
    end
467716
def update(self):
        
        # Init new stats
        stats = self.get_init_value()

        if self.input_method == 'local' and not import_error_tag:
            # Update stats using the netifaces lib
            try:
                default_gw = netifaces.gateways()['default'][netifaces.AF_INET]
            except (KeyError, AttributeError) as e:
                logger.debug("Cannot grab the default gateway ({})".format(e))
            else:
                try:
                    stats['address'] = netifaces.ifaddresses(default_gw[1])[netifaces.AF_INET][0]['addr']
                    stats['mask'] = netifaces.ifaddresses(default_gw[1])[netifaces.AF_INET][0]['netmask']
                    stats['mask_cidr'] = self.ip_to_cidr(stats['mask'])
                    stats['gateway'] = netifaces.gateways()['default'][netifaces.AF_INET][0]
                    stats['public_address'] = self.public_address
                except (KeyError, AttributeError) as e:
                    logger.debug("Cannot grab IP information: {}".format(e))
        elif self.input_method == 'snmp':
            # Not implemented yet
            pass

        # Update the stats
        self.stats = stats

        return self.stats
650737
public function update( models\Call\ContactUrl $ContactUrl){
        $rest = $this->getService( self::API_URL . $ContactUrl->getId());
        $rest->PUT( $ContactUrl);

        return $rest->getResult( models\Call\ContactUrl::class);
    }
1015492
def update(self, space_no, key_tuple, op_list):
        
        d = self.replyQueue.get()
        packet = RequestUpdate(self.charset, self.errors, d._ipro_request_id, space_no, 0, key_tuple, op_list)
        self.transport.write(bytes(packet))
        return d.addCallback(self.handle_reply, self.charset, self.errors, None)
208054
def getContact(self, user=None, channel=None):
        
        try:
            return self.contacts[(channel, user)]
        except KeyError:
            new_contact = self.contactClass(self, user=user, channel=channel)
            self.contacts[(channel, user)] = new_contact
            new_contact.setServiceParent(self)
            return new_contact
1358040
def get_contact(self, contact_id):
        
        url = self.CONTACTS_ID_URL % contact_id

        connection = Connection(self.token)
        connection.set_url(self.production, url)

        return connection.get_request()
810563
public function update(array $contact_template)
    {
        if(!isset($contact_template['id'])) {
            throw new MonetivoException('$contact["type"] and $contact["id"] are required');
        }

        return $this->merchantApi->call('put', 'contacts_templates/' . $contact_template['id'], [
            'form_params' => $contact_template
        ])->toArray();
    }
577500
def update(data)
      headers = @client.make_request(:post, @client.concat_user_path("#{CALL_PATH}/#{id}"), data)[1]
      if headers[:location]
         Client.get_id_from_location_header(headers[:location])
      end
    end
377404
def get_contact_formatted_email(self, contact):
        
        contact_name = contact.Title()
        contact_email = contact.getEmailAddress()
        return self.get_formatted_email((contact_name, contact_email))
550203
def update(self, new_email_address, name, access_level, password=None):
        """"""
        params = {"email": self.email_address}
        body = {
            "EmailAddress": new_email_address,
            "Name": name,
            "AccessLevel": access_level,
            "Password": password}
        response = self._put("/clients/%s/people.json" % self.client_id,
                             body=json.dumps(body), params=params)
        # Update self.email_address, so this object can continue to be used
        # reliably
        self.email_address = new_email_address
191730
def org_update(object_id, input_params={}, always_retry=True, **kwargs):
    
    return DXHTTPRequest('/%s/update' % object_id, input_params, always_retry=always_retry, **kwargs)
610499
public function updateContact(Contact $contact, array $attributes)
    {
        $attributes = $this->loadContactAttributes($attributes);

        return $contact->fill($attributes)->save();
    }
352097
def refresh(self):
        
        newuser = self.bugzilla.getuser(self.email)
        self.__dict__.update(newuser.__dict__)
1246591
def update(self, request, key):
        """"""

        request.UPDATE = http.QueryDict(request.body)

        email_addr = request.UPDATE.get('email')
        user_id = request.UPDATE.get('user')
        if not email_addr:
            return http.HttpResponseBadRequest()

        try:
            email = EmailAddress.objects.get(address=email_addr,
                                             user_id=user_id)
        except EmailAddress.DoesNotExist:
            raise http.Http404

        email.user.email = email_addr
        email.user.save()
        return http.HttpResponse(status=204)
752511
private function updatePayload()
    {
        if ($this->contactClient) {
            $this->sortPayloadFields();
            $jsonHelper  = new JSONHelper();
            $payloadJSON = $jsonHelper->encode($this->payload, 'Payload');
            $this->contactClient->setAPIPayload($payloadJSON);
        }
    }
1200759
public static base_response update(nitro_service client, dnsaction resource) throws Exception {
		dnsaction updateresource = new dnsaction();
		updateresource.actionname = resource.actionname;
		updateresource.ipaddress = resource.ipaddress;
		updateresource.ttl = resource.ttl;
		updateresource.viewname = resource.viewname;
		updateresource.preferredloclist = resource.preferredloclist;
		return updateresource.update_resource(client);
	}
442
def modifyContacts(self, contactids, paused):
        

        response = self.request("PUT", "notification_contacts", {'contactids': contactids,
                                                    'paused': paused})
        return response.json()['message']