Remove an address of a domain.
559678
def remove_address(self, fqdn, address):
        " "

        # Get a list of addresses.
        for record in self.list_address(fqdn):
            if record.address == address:
                record.delete()
                break
1204371
def remove_all_matching(self, address=None, name=None):
        
        if self.entries:
            if address and name:
                func = lambda entry: not entry.is_real_entry() or (entry.address != address and name not in entry.names)
            elif address:
                func = lambda entry: not entry.is_real_entry() or entry.address != address
            elif name:
                func = lambda entry: not entry.is_real_entry() or name not in entry.names
            else:
                raise ValueError('No address or name was specified for removal.')
            self.entries = list(filter(func, self.entries))
486141
public static String stripDomain(String hostname)
    {
        String ret = hostname;
        int pos = hostname.indexOf(".");
        if(pos != -1)
            ret = hostname.substring(0,pos);
        return ret;
    }
119705
public function deleteAddress(Address $address)
    {
        if ($this !== $address->addressable()->first())
            return false;

        return $address->delete();
    }
1214179
def delete(gandi, fqdn, name, type, force):
    """"""
    domains = gandi.dns.list()
    domains = [domain['fqdn'] for domain in domains]
    if fqdn not in domains:
        gandi.echo('Sorry domain %s does not exist' % fqdn)
        gandi.echo('Please use one of the following: %s' % ', '.join(domains))
        return

    if not force:
        if not name and not type:
            prompt = ("Are you sure to delete all records for domain %s ?" %
                      fqdn)
        elif name and not type:
            prompt = ("Are you sure to delete all '%s' name records for "
                      "domain %s ?" % (name, fqdn))
        else:
            prompt = ("Are you sure to delete all '%s' records of type %s "
                      "for domain %s ?" % (name, type, fqdn))

        proceed = click.confirm(prompt)

        if not proceed:
            return

    result = gandi.dns.del_record(fqdn, name, type)
    gandi.echo('Delete successful.')
    return result
148658
def removeDomain(self, subnetId, domainId):
        
        subnetDomainIds = []
        for domain in self[subnetId]['domains']:
            subnetDomainIds.append(domain['id'])
        subnetDomainIds.remove(domainId)
        self[subnetId]["domain_ids"] = subnetDomainIds
        return len(self[subnetId]["domains"]) is len(subnetDomainIds)
592215
def unregister_service(self, info):
        """"""
        try:
            del(self.services[info.name.lower()])
        except:
            pass
        now = current_time_millis()
        next_time = now
        i = 0
        while i < 3:
            if now < next_time:
                self.wait(next_time - now)
                now = current_time_millis()
                continue
            out = DNSOutgoing(_FLAGS_QR_RESPONSE | _FLAGS_AA)
            out.add_answer_at_time(
                    DNSPointer(info.type,
                        _TYPE_PTR, _CLASS_IN, 0, info.name), 0)
            out.add_answer_at_time(
                    DNSService(info.name,
                        _TYPE_SRV, _CLASS_IN, 0, info.priority,
                        info.weight, info.port, info.name), 0)
            out.add_answer_at_time(
                    DNSText(info.name, _TYPE_TXT, _CLASS_IN, 0, info.text), 0)
            for k in info.address:
                out.add_answer_at_time(
                        DNSAddress(info.server, _TYPE_A, _CLASS_IN, 0, k), 0)
            self.send(out)
            i += 1
            next_time += _UNREGISTER_TIME
548718
public function removeaddress()
    {
        $member = Security::getCurrentUser();
        $id = $this->getOwner()->request->param("ID");
        $address = ContactLocation::get()->byID($id);

        if ($address && $address->canDelete($member)) {
            $address->delete();
            $this
                ->owner
                ->customise([
                    "Title" => _t(
                        "SilverCommerce\ContactAdmin.AddressRemoved",
                        "Address Removed"
                    ),
                    "MenuTitle" => _t(
                        "SilverCommerce\ContactAdmin.AddressRemoved",
                        "Address Removed"
                    )
                ]);

            $this->getOwner()->extend("updateEditAddress");

            return $this
                ->getOwner()
                ->renderWith([
                    'AccountController_removeaddress',
                    AccountController::class . '_removeaddress',
                    'AccountController',
                    AccountController::class,
                    'Page'
                ]);
        } else {
            return $this->getOwner()->httpError(404);
        }
    }
860279
def remove
      unless domain = shift_argument
        error("Usage: heroku domains:remove DOMAIN\nMust specify DOMAIN to remove.")
      end
      validate_arguments!
      action("Removing #{domain} from #{app}") do
        api.delete_domain(app, domain)
      end
    end
1140533
def user_remove(self, domain, userid):
        
        path = self._get_management_path(domain, userid)
        return self.http_request(path=path,
                                 method='DELETE')
642759
def keys_delete(cls, fqdn, key):
        """"""
        return cls.json_delete('%s/domains/%s/keys/%s' %
                               (cls.api_url, fqdn, key))
861111
def remove_domain_from_fqdn(opts, newid):
    '''
    
    '''
    opt_domain = opts.get('minion_id_remove_domain')
    if opt_domain is True:
        if '.' in newid:
            # Remove any domain
            newid, xdomain = newid.split('.', 1)
            log.debug('Removed any domain (%s) from minion id.', xdomain)
    else:
        # Must be string type
        if newid.upper().endswith('.' + opt_domain.upper()):
            # Remove single domain
            newid = newid[:-len('.' + opt_domain)]
            log.debug('Removed single domain %s from minion id.', opt_domain)
    return newid
413625
def deallocate(self):
        """"""
        if self._domain is not None:
            domain_delete(self._domain, self.logger)
        if self._network is not None:
            self._network_delete()
        if self._storage_pool is not None:
            self._storage_pool_delete()
        if self._hypervisor is not None:
            self._hypervisor_delete()
822868
def unregister_area(self, area_code, index):
        """'
        """
        return self.library.Srv_UnregisterArea(self.pointer, area_code, index)
250487
def del_cached_domain(domains):
    '''
    
    '''
    cache = salt.cache.Cache(__opts__, syspaths.CACHE_DIR)
    if isinstance(domains, six.string_types):
        domains = domains.split(',')
    if not isinstance(domains, list):
        raise CommandExecutionError(
            'You must pass in either a string containing one or more domains '
            'separated by commas, or a list of single domain strings'
        )
    success = []
    failed = []
    for domain in domains:
        try:
            cache.flush('venafi/domains', domain)
            success.append(domain)
        except CommandExecutionError:
            failed.append(domain)
    return {'Succeeded': success, 'Failed': failed}
115561
def release_address(self, address, vpnid):
        """"""
        query = address + "?action=releaseAddress&vpnId=" + vpnid
        request_url = self._build_url(['Lease', query])
        return self._do_request('DELETE', request_url)
1181347
def deactivate(self, address):
        
        log_debug("[#0000]  C: <ROUTING> Deactivating address %r", address)
        # We use `discard` instead of `remove` here since the former
        # will not fail if the address has already been removed.
        self.routing_table.routers.discard(address)
        self.routing_table.readers.discard(address)
        self.routing_table.writers.discard(address)
        log_debug("[#0000]  C: <ROUTING> table=%r", self.routing_table)
        super(RoutingConnectionPool, self).deactivate(address)