Delete firewall policy

@param firewallPolicy firewall policy
@return OperationFuture wrapper for firewall policy
488857
public OperationFuture<FirewallPolicy> delete(FirewallPolicy firewallPolicy) {
        FirewallPolicyMetadata metadata = findByRef(firewallPolicy);

        firewallPolicyClient.delete(
            metadata.getDataCenterId(),
            metadata.getId()
        );

        return new OperationFuture<>(
            firewallPolicy,
            new NoWaitingJobFuture()
        );
    }
181539
def delete_policy(self, scaling_group, policy):
        
        return self._manager.delete_policy(scaling_group=scaling_group,
                policy=policy)
411371
public Operation deleteAccessConfig(
      String networkInterface, String accessConfig, OperationOption... options) {
    return compute.deleteAccessConfig(getInstanceId(), networkInterface, accessConfig, options);
  }
678507
func (fs *FSObjects) DeleteBucketPolicy(ctx context.Context, bucket string) error {
	return removePolicyConfig(ctx, fs, bucket)
}
1800
def delete_lifecycle(self, policy=None, params=None):
        
        return self.transport.perform_request(
            "DELETE", _make_path("_ilm", "policy", policy), params=params
        )
1257971
def get_fw_policy(self, policy_id):
        
        policy = None
        try:
            policy = self.neutronclient.show_firewall_policy(policy_id)
        except Exception as exc:
            LOG.error("Failed to get firewall plcy for id %(id)s "
                      "Exc %(exc)s",
                      {'id': policy_id, 'exc': str(exc)})
        return policy
1137830
def delete_policy_for_vhost(self, vhost, name):
        
        self._api_delete('/api/policies/{0}/{1}/'.format(
            urllib.parse.quote_plus(vhost),
            urllib.parse.quote_plus(name),
        ))
721151
def _fw_rule_delete(self, drvr_name, data):
        
        rule_id = data.get('firewall_rule_id')
        tenant_id = self.tenant_db.get_rule_tenant(rule_id)

        if tenant_id not in self.fwid_attr:
            LOG.error("Invalid tenant id for FW delete %s", tenant_id)
            return
        tenant_obj = self.fwid_attr[tenant_id]
        # Guess actual FW/policy need not be deleted if this is the active
        # rule, Openstack does not allow it to be deleted
        tenant_obj.delete_rule(rule_id)
        self.tenant_db.del_rule_tenant(rule_id)
1373868
def slas_policy_delete(self, id, **kwargs):
        ""
        api_path = "/api/v2/slas/policies/{id}"
        api_path = api_path.format(id=id)
        return self.call(api_path, method="DELETE", **kwargs)
1305435
public void delete() {
        URL url = STORAGE_POLICY_ASSIGNMENT_WITH_ID_URL_TEMPLATE.build(this.getAPI().getBaseURL(), this.getID());
        BoxAPIRequest request = new BoxAPIRequest(this.getAPI(), url, HttpMethod.DELETE);

        request.send();
    }
137847
func (c *CloudAPI) DeleteFirewallRule(fwRuleID string) error {
	if err := c.ProcessFunctionHook(c, fwRuleID); err != nil {
		return err
	}

	for i, r := range c.firewallRules {
		if strings.EqualFold(r.Id, fwRuleID) {
			c.firewallRules = append(c.firewallRules[:i], c.firewallRules[i+1:]...)
			return nil
		}
	}

	return fmt.Errorf("Firewall rule %s not found", fwRuleID)
}
171580
@Override
    public void removePolicy(String sec, String ptype, List<String> rule) {
        throw new Error("not implemented");
    }
635723
@Override
    public boolean deletePolicy(String name) throws PolicyIndexException {
        log.debug("Deleting document: " + name);

        DbXmlManager.writeLock.lock();
        try {
            m_dbXmlManager.container.deleteDocument(name, m_dbXmlManager.updateContext);
            setLastUpdate(System.currentTimeMillis());
        } catch (XmlException xe) {
            // safe delete - only warn if not found
            if (xe.getDbError() == XmlException.DOCUMENT_NOT_FOUND){
                log.warn("Error deleting document: " + name + " - document does not exist");
            } else {
                throw new PolicyIndexException("Error deleting document: " + name + xe.getMessage(), xe);
            }
        } finally {
            DbXmlManager.writeLock.unlock();
        }
        return true;
    }
51947
def create_firewall_policy(kwargs=None, call=None):
    '''
    
    '''
    if call == 'action':
        raise SaltCloudSystemExit(
            'The create_firewall_policy function must be called with '
            '-f or --function'
        )

    conn = get_conn()

    # Assemble the composite FirewallPolicy and FirewallPolicyRule[] objects.
    getFwpResult = _get_firewall_policy(kwargs)

    data = conn.create_firewall_policy(
        firewall_policy=getFwpResult['firewall_policy'],
        firewall_policy_rules=getFwpResult['firewall_policy_rules']
    )

    return {'FirewallPolicy': data}
471172
public OperationFuture<AntiAffinityPolicy> delete(AntiAffinityPolicy policyRef) {
        client.deleteAntiAffinityPolicy(findByRef(policyRef).getId());

        return new OperationFuture<>(
            policyRef,
            new NoWaitingJobFuture()
        );
    }
535126
public OperationFuture<List<FirewallPolicy>> update(
            List<FirewallPolicy> firewallPolicyList,
            FirewallPolicyConfig config
    ) {
        firewallPolicyList.forEach(firewallPolicy -> update(firewallPolicy, config));

        return new OperationFuture<>(
            firewallPolicyList,
            new NoWaitingJobFuture()
        );
    }
239981
public RetryInterceptorBuilder<T> backOffPolicy(BackOffPolicy policy) {
		Assert.isNull(this.retryOperations,
				"cannot set the back off policy when a custom retryOperations has been set");
		Assert.isTrue(!this.backOffOptionsSet,
				"cannot set the back off policy when the back off policy options have been set");
		this.retryTemplate.setBackOffPolicy(policy);
		this.templateAltered = true;
		this.backOffPolicySet = true;
		return this;
	}