Examples of removePolicy()


Examples of org.wso2.carbon.governance.api.policies.PolicyManager.removePolicy()

        });
        assertEquals(1, policies.length);
        assertEquals(newPolicy.getId(), policies[0].getId());

        // deleting the policy
        policyManager.removePolicy(newPolicy.getId());
        Policy deletedPolicy = policyManager.getPolicy(newPolicy.getId());
        assertNull(deletedPolicy);
    }
}
View Full Code Here

Examples of org.wso2.carbon.identity.entitlement.policy.PolicyAdmin.removePolicy()

    public void removePolicy(PolicyDTO policy) throws IdentityException {
        PolicyAdmin policyAdmin;
        EntitlementEngine entitlementEngine = EntitlementEngine
                .getInstance(getGovernanceUserRegistry(), CarbonContext.getCurrentContext().getTenantId());
        policyAdmin = new PolicyAdmin(new PolicyStore(getGovernanceUserRegistry()));
        policyAdmin.removePolicy(policy);
        // Reload the policies to the memory.
        entitlementEngine.getRegistryModule().init(null);
    }

    /**
 
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.