Examples of PolicyBuilder


Examples of com.volantis.mcs.policies.PolicyBuilder

            saveModel(file, iProgressMonitor);
        }
    }

    private void saveModel(IFile targetFile, IProgressMonitor monitor) {
        PolicyBuilder policy =
                (PolicyBuilder) context.getInteractionModel().getModelObject();
        try {
            context.getPolicyFileAccessor().savePolicy(policy, targetFile, monitor);
            context.setDirty(false);
View Full Code Here

Examples of com.volantis.mcs.policies.PolicyBuilder

            throws RepositoryException {

        RemotePolicyBuilderReader reader = createReader();
        PolicyBuilderResponse response = reader.getPolicyBuilder(
                runtimeProjectMock, url);
        PolicyBuilder builder = response.getBuilder();
        assertNull(builder);
    }
View Full Code Here

Examples of com.volantis.mcs.policies.PolicyBuilder

        PolicyBuilders builders = response.getBuilders();
        if (builders != null) {
            Iterator iterator = builders.getPolicyBuilders().iterator();
            while (iterator.hasNext()) {
                PolicyBuilder policyBuilder =
                        (PolicyBuilder) iterator.next();

                // Complete post-load initialization ("activation") for the
                // object. This call will do nothing if there are no
                // activators
View Full Code Here

Examples of com.volantis.mcs.policies.PolicyBuilder

     */
    public PolicyBuilder parsePolicyBuilder(InputStream stream, String url)
            throws ResourceMigrationException, IOException {

        Object object = parseRemoteObject(stream, url);
        PolicyBuilder builder = (PolicyBuilder) object;
        builder.setName(url);
        return builder;
    }
View Full Code Here

Examples of com.volantis.mcs.policies.PolicyBuilder

     *         the owning project.
     */
    public PolicyBuilderResponse getPolicyBuilder(
            Project project, String name) {

        PolicyBuilder builder = null;

        RuntimeProject runtimeProject = (RuntimeProject) project;
        if (!runtimeProject.isRemote()) {
            throw new IllegalStateException("Project is not remote");
        }
View Full Code Here

Examples of org.apache.cxf.ws.policy.PolicyBuilder

                    All all = new All();
                    PolicyAssertion ass = SecureConversationTokenInterceptorProvider
                        .getAddressingPolicy(aim, false);
                    all.addPolicyComponent(ass);
                    ea.addPolicyComponent(all);
                    PolicyBuilder pbuilder = message.getExchange().getBus()
                        .getExtension(PolicyBuilder.class);
                    SymmetricBinding binding = new SymmetricBinding(SP12Constants.INSTANCE, pbuilder);
                    binding.setIncludeTimestamp(true);
                    ProtectionToken token = new ProtectionToken(SP12Constants.INSTANCE, pbuilder);
                    token.setToken(new SecureConversationToken(SP12Constants.INSTANCE));
View Full Code Here

Examples of org.apache.cxf.ws.policy.PolicyBuilder

       
        DomainExpressionBuilderRegistry debr = control.createMock(DomainExpressionBuilderRegistry.class);
        EasyMock.expect(bus.getExtension(DomainExpressionBuilderRegistry.class)).andReturn(debr);
        DomainExpression de = control.createMock(DomainExpression.class);
        EasyMock.expect(debr.build(EasyMock.isA(Element.class))).andReturn(de);
        PolicyBuilder pb = control.createMock(PolicyBuilder.class);
        EasyMock.expect(bus.getExtension(PolicyBuilder.class)).andReturn(pb).anyTimes();
        Policy p = control.createMock(Policy.class);
        EasyMock.expect(pb.getPolicy(EasyMock.isA(Element.class))).andReturn(p);
               
       
        control.replay();
        ExternalAttachmentProvider eap = new ExternalAttachmentProvider(bus);
        URL url = ExternalAttachmentProviderTest.class.getResource("resources/attachments4.xml");
View Full Code Here

Examples of org.apache.cxf.ws.policy.PolicyBuilder

        Policy validatePolicy = new Policy();
        ExactlyOne one = new ExactlyOne();
        validatePolicy.addPolicyComponent(one);
        All all = new All();
        PolicyBuilder pbuilder = bus.getExtension(PolicyBuilder.class);
        SymmetricBinding binding = new SymmetricBinding(pbuilder);
        all.addAssertion(binding);
        one.addPolicyComponent(all);
        all.addAssertion(getAddressingAssertion());
        ProtectionToken ptoken = new ProtectionToken(pbuilder);
View Full Code Here

Examples of org.apache.cxf.ws.policy.PolicyBuilder

        Policy cancelPolicy = new Policy();
        ExactlyOne one = new ExactlyOne();
        cancelPolicy.addPolicyComponent(one);
        All all = new All();
        one.addPolicyComponent(all);
        PolicyBuilder pbuilder = bus.getExtension(PolicyBuilder.class);
        SymmetricBinding binding = new SymmetricBinding(pbuilder);
        all.addAssertion(binding);
        all.addAssertion(getAddressingAssertion());
        ProtectionToken ptoken = new ProtectionToken(pbuilder);
        binding.setProtectionToken(ptoken);
View Full Code Here

Examples of org.apache.cxf.ws.policy.PolicyBuilder

    protected void setPolicyInternal(Element newPolicy) {
        this.setPolicyInternal(bus.getExtension(PolicyBuilder.class).getPolicy(newPolicy));
    }
   
    protected void setPolicyInternal(String policyReference) {
        PolicyBuilder builder = bus.getExtension(PolicyBuilder.class);
        ReferenceResolver resolver = new RemoteReferenceResolver(null, builder);
        PolicyRegistry registry = bus.getExtension(PolicyEngine.class).getRegistry();
        Policy resolved = registry.lookup(policyReference);
        if (null != resolved) {
            this.setPolicyInternal(resolved);
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.