com.sun.xml.internal.ws.policy.sourcemodel.PolicySourceModel Java Examples

The following examples show how to use com.sun.xml.internal.ws.policy.sourcemodel.PolicySourceModel. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: PolicyWSDLGeneratorExtension.java    From hottub with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Adds a PolicyReference element that points to the policy of the element,
 * if the policy does not have any id or name. Writes policy inside the element otherwise.
 *
 * @param subject
 *      PolicySubject to be referenced or marshalled
 * @param writer
 *      A TXW on to which we shall add the PolicyReference
 */
private void writePolicyOrReferenceIt(final PolicySubject subject, final TypedXmlWriter writer) {
    final Policy policy;
    try {
        policy = subject.getEffectivePolicy(merger);
    } catch (PolicyException e) {
        throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1011_FAILED_TO_RETRIEVE_EFFECTIVE_POLICY_FOR_SUBJECT(subject.toString()), e));
    }
    if (policy != null) {
        if (null == policy.getIdOrName()) {
            final PolicyModelGenerator generator = ModelGenerator.getGenerator();
            try {
                final PolicySourceModel policyInfoset = generator.translate(policy);
                marshaller.marshal(policyInfoset, writer);
            } catch (PolicyException pe) {
                throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1002_UNABLE_TO_MARSHALL_POLICY_OR_POLICY_REFERENCE(), pe));
            }
        } else {
            final TypedXmlWriter policyReference = writer._element(policy.getNamespaceVersion().asQName(XmlToken.PolicyReference), TypedXmlWriter.class);
            policyReference._attribute(XmlToken.Uri.toString(), '#' + policy.getIdOrName());
        }
    }
}
 
Example #2
Source File: PolicyWSDLGeneratorExtension.java    From openjdk-jdk8u with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Adds a PolicyReference element that points to the policy of the element,
 * if the policy does not have any id or name. Writes policy inside the element otherwise.
 *
 * @param subject
 *      PolicySubject to be referenced or marshalled
 * @param writer
 *      A TXW on to which we shall add the PolicyReference
 */
private void writePolicyOrReferenceIt(final PolicySubject subject, final TypedXmlWriter writer) {
    final Policy policy;
    try {
        policy = subject.getEffectivePolicy(merger);
    } catch (PolicyException e) {
        throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1011_FAILED_TO_RETRIEVE_EFFECTIVE_POLICY_FOR_SUBJECT(subject.toString()), e));
    }
    if (policy != null) {
        if (null == policy.getIdOrName()) {
            final PolicyModelGenerator generator = ModelGenerator.getGenerator();
            try {
                final PolicySourceModel policyInfoset = generator.translate(policy);
                marshaller.marshal(policyInfoset, writer);
            } catch (PolicyException pe) {
                throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1002_UNABLE_TO_MARSHALL_POLICY_OR_POLICY_REFERENCE(), pe));
            }
        } else {
            final TypedXmlWriter policyReference = writer._element(policy.getNamespaceVersion().asQName(XmlToken.PolicyReference), TypedXmlWriter.class);
            policyReference._attribute(XmlToken.Uri.toString(), '#' + policy.getIdOrName());
        }
    }
}
 
Example #3
Source File: BuilderHandler.java    From jdk8u60 with GNU General Public License v2.0 6 votes vote down vote up
final Collection<Policy> getPolicies() throws PolicyException {
    if (null == policyURIs) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1004_POLICY_URIS_CAN_NOT_BE_NULL()));
    }
    if (null == policyStore) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1010_NO_POLICIES_DEFINED()));
    }

    final Collection<Policy> result = new ArrayList<Policy>(policyURIs.size());

    for (String policyURI : policyURIs) {
        final PolicySourceModel sourceModel = policyStore.get(policyURI);
        if (sourceModel == null) {
            throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1005_POLICY_REFERENCE_DOES_NOT_EXIST(policyURI)));
        } else {
            result.add(ModelTranslator.getTranslator().translate(sourceModel));
        }
    }

    return result;
}
 
Example #4
Source File: BuilderHandler.java    From openjdk-8-source with GNU General Public License v2.0 6 votes vote down vote up
final Collection<Policy> getPolicies() throws PolicyException {
    if (null == policyURIs) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1004_POLICY_URIS_CAN_NOT_BE_NULL()));
    }
    if (null == policyStore) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1010_NO_POLICIES_DEFINED()));
    }

    final Collection<Policy> result = new ArrayList<Policy>(policyURIs.size());

    for (String policyURI : policyURIs) {
        final PolicySourceModel sourceModel = policyStore.get(policyURI);
        if (sourceModel == null) {
            throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1005_POLICY_REFERENCE_DOES_NOT_EXIST(policyURI)));
        } else {
            result.add(ModelTranslator.getTranslator().translate(sourceModel));
        }
    }

    return result;
}
 
Example #5
Source File: PolicyWSDLGeneratorExtension.java    From jdk8u60 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Adds a PolicyReference element that points to the policy of the element,
 * if the policy does not have any id or name. Writes policy inside the element otherwise.
 *
 * @param subject
 *      PolicySubject to be referenced or marshalled
 * @param writer
 *      A TXW on to which we shall add the PolicyReference
 */
private void writePolicyOrReferenceIt(final PolicySubject subject, final TypedXmlWriter writer) {
    final Policy policy;
    try {
        policy = subject.getEffectivePolicy(merger);
    } catch (PolicyException e) {
        throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1011_FAILED_TO_RETRIEVE_EFFECTIVE_POLICY_FOR_SUBJECT(subject.toString()), e));
    }
    if (policy != null) {
        if (null == policy.getIdOrName()) {
            final PolicyModelGenerator generator = ModelGenerator.getGenerator();
            try {
                final PolicySourceModel policyInfoset = generator.translate(policy);
                marshaller.marshal(policyInfoset, writer);
            } catch (PolicyException pe) {
                throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1002_UNABLE_TO_MARSHALL_POLICY_OR_POLICY_REFERENCE(), pe));
            }
        } else {
            final TypedXmlWriter policyReference = writer._element(policy.getNamespaceVersion().asQName(XmlToken.PolicyReference), TypedXmlWriter.class);
            policyReference._attribute(XmlToken.Uri.toString(), '#' + policy.getIdOrName());
        }
    }
}
 
Example #6
Source File: BuilderHandler.java    From openjdk-jdk8u with GNU General Public License v2.0 6 votes vote down vote up
final Collection<Policy> getPolicies() throws PolicyException {
    if (null == policyURIs) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1004_POLICY_URIS_CAN_NOT_BE_NULL()));
    }
    if (null == policyStore) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1010_NO_POLICIES_DEFINED()));
    }

    final Collection<Policy> result = new ArrayList<Policy>(policyURIs.size());

    for (String policyURI : policyURIs) {
        final PolicySourceModel sourceModel = policyStore.get(policyURI);
        if (sourceModel == null) {
            throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1005_POLICY_REFERENCE_DOES_NOT_EXIST(policyURI)));
        } else {
            result.add(ModelTranslator.getTranslator().translate(sourceModel));
        }
    }

    return result;
}
 
Example #7
Source File: PolicyWSDLGeneratorExtension.java    From openjdk-8 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Adds a PolicyReference element that points to the policy of the element,
 * if the policy does not have any id or name. Writes policy inside the element otherwise.
 *
 * @param subject
 *      PolicySubject to be referenced or marshalled
 * @param writer
 *      A TXW on to which we shall add the PolicyReference
 */
private void writePolicyOrReferenceIt(final PolicySubject subject, final TypedXmlWriter writer) {
    final Policy policy;
    try {
        policy = subject.getEffectivePolicy(merger);
    } catch (PolicyException e) {
        throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1011_FAILED_TO_RETRIEVE_EFFECTIVE_POLICY_FOR_SUBJECT(subject.toString()), e));
    }
    if (policy != null) {
        if (null == policy.getIdOrName()) {
            final PolicyModelGenerator generator = ModelGenerator.getGenerator();
            try {
                final PolicySourceModel policyInfoset = generator.translate(policy);
                marshaller.marshal(policyInfoset, writer);
            } catch (PolicyException pe) {
                throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1002_UNABLE_TO_MARSHALL_POLICY_OR_POLICY_REFERENCE(), pe));
            }
        } else {
            final TypedXmlWriter policyReference = writer._element(policy.getNamespaceVersion().asQName(XmlToken.PolicyReference), TypedXmlWriter.class);
            policyReference._attribute(XmlToken.Uri.toString(), '#' + policy.getIdOrName());
        }
    }
}
 
Example #8
Source File: BuilderHandler.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 6 votes vote down vote up
final Collection<Policy> getPolicies() throws PolicyException {
    if (null == policyURIs) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1004_POLICY_URIS_CAN_NOT_BE_NULL()));
    }
    if (null == policyStore) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1010_NO_POLICIES_DEFINED()));
    }

    final Collection<Policy> result = new ArrayList<Policy>(policyURIs.size());

    for (String policyURI : policyURIs) {
        final PolicySourceModel sourceModel = policyStore.get(policyURI);
        if (sourceModel == null) {
            throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1005_POLICY_REFERENCE_DOES_NOT_EXIST(policyURI)));
        } else {
            result.add(ModelTranslator.getTranslator().translate(sourceModel));
        }
    }

    return result;
}
 
Example #9
Source File: PolicyWSDLParserExtension.java    From TencentKona-8 with GNU General Public License v2.0 6 votes vote down vote up
private Collection<String> getPolicyURIs(
        final Collection<PolicyRecordHandler> handlers, final PolicySourceModelContext modelContext) throws PolicyException{
    final Collection<String> result = new ArrayList<String>(handlers.size());
    String policyUri;
    for (PolicyRecordHandler handler : handlers) {
        policyUri = handler.handler;
        if (HandlerType.AnonymousPolicyId == handler.type) {
            final PolicySourceModel policyModel = getAnonymousPolicyModels().get(policyUri);
            policyModel.expand(modelContext);
            while (getPolicyModels().containsKey(policyUri)) {
                policyUri = AnonymnousPolicyIdPrefix.append(anonymousPoliciesCount++).toString();
            }
            getPolicyModels().put(policyUri,policyModel);
        }
        result.add(policyUri);
    }
    return result;
}
 
Example #10
Source File: PolicyWSDLParserExtension.java    From openjdk-jdk8u with GNU General Public License v2.0 6 votes vote down vote up
private Collection<String> getPolicyURIs(
        final Collection<PolicyRecordHandler> handlers, final PolicySourceModelContext modelContext) throws PolicyException{
    final Collection<String> result = new ArrayList<String>(handlers.size());
    String policyUri;
    for (PolicyRecordHandler handler : handlers) {
        policyUri = handler.handler;
        if (HandlerType.AnonymousPolicyId == handler.type) {
            final PolicySourceModel policyModel = getAnonymousPolicyModels().get(policyUri);
            policyModel.expand(modelContext);
            while (getPolicyModels().containsKey(policyUri)) {
                policyUri = AnonymnousPolicyIdPrefix.append(anonymousPoliciesCount++).toString();
            }
            getPolicyModels().put(policyUri,policyModel);
        }
        result.add(policyUri);
    }
    return result;
}
 
Example #11
Source File: PolicyWSDLParserExtension.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 6 votes vote down vote up
private Collection<String> getPolicyURIs(
        final Collection<PolicyRecordHandler> handlers, final PolicySourceModelContext modelContext) throws PolicyException{
    final Collection<String> result = new ArrayList<String>(handlers.size());
    String policyUri;
    for (PolicyRecordHandler handler : handlers) {
        policyUri = handler.handler;
        if (HandlerType.AnonymousPolicyId == handler.type) {
            final PolicySourceModel policyModel = getAnonymousPolicyModels().get(policyUri);
            policyModel.expand(modelContext);
            while (getPolicyModels().containsKey(policyUri)) {
                policyUri = AnonymnousPolicyIdPrefix.append(anonymousPoliciesCount++).toString();
            }
            getPolicyModels().put(policyUri,policyModel);
        }
        result.add(policyUri);
    }
    return result;
}
 
Example #12
Source File: PolicyWSDLGeneratorExtension.java    From TencentKona-8 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Adds a PolicyReference element that points to the policy of the element,
 * if the policy does not have any id or name. Writes policy inside the element otherwise.
 *
 * @param subject
 *      PolicySubject to be referenced or marshalled
 * @param writer
 *      A TXW on to which we shall add the PolicyReference
 */
private void writePolicyOrReferenceIt(final PolicySubject subject, final TypedXmlWriter writer) {
    final Policy policy;
    try {
        policy = subject.getEffectivePolicy(merger);
    } catch (PolicyException e) {
        throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1011_FAILED_TO_RETRIEVE_EFFECTIVE_POLICY_FOR_SUBJECT(subject.toString()), e));
    }
    if (policy != null) {
        if (null == policy.getIdOrName()) {
            final PolicyModelGenerator generator = ModelGenerator.getGenerator();
            try {
                final PolicySourceModel policyInfoset = generator.translate(policy);
                marshaller.marshal(policyInfoset, writer);
            } catch (PolicyException pe) {
                throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1002_UNABLE_TO_MARSHALL_POLICY_OR_POLICY_REFERENCE(), pe));
            }
        } else {
            final TypedXmlWriter policyReference = writer._element(policy.getNamespaceVersion().asQName(XmlToken.PolicyReference), TypedXmlWriter.class);
            policyReference._attribute(XmlToken.Uri.toString(), '#' + policy.getIdOrName());
        }
    }
}
 
Example #13
Source File: BuilderHandler.java    From TencentKona-8 with GNU General Public License v2.0 6 votes vote down vote up
final Collection<Policy> getPolicies() throws PolicyException {
    if (null == policyURIs) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1004_POLICY_URIS_CAN_NOT_BE_NULL()));
    }
    if (null == policyStore) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1010_NO_POLICIES_DEFINED()));
    }

    final Collection<Policy> result = new ArrayList<Policy>(policyURIs.size());

    for (String policyURI : policyURIs) {
        final PolicySourceModel sourceModel = policyStore.get(policyURI);
        if (sourceModel == null) {
            throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1005_POLICY_REFERENCE_DOES_NOT_EXIST(policyURI)));
        } else {
            result.add(ModelTranslator.getTranslator().translate(sourceModel));
        }
    }

    return result;
}
 
Example #14
Source File: PolicyWSDLParserExtension.java    From jdk8u60 with GNU General Public License v2.0 6 votes vote down vote up
private Collection<String> getPolicyURIs(
        final Collection<PolicyRecordHandler> handlers, final PolicySourceModelContext modelContext) throws PolicyException{
    final Collection<String> result = new ArrayList<String>(handlers.size());
    String policyUri;
    for (PolicyRecordHandler handler : handlers) {
        policyUri = handler.handler;
        if (HandlerType.AnonymousPolicyId == handler.type) {
            final PolicySourceModel policyModel = getAnonymousPolicyModels().get(policyUri);
            policyModel.expand(modelContext);
            while (getPolicyModels().containsKey(policyUri)) {
                policyUri = AnonymnousPolicyIdPrefix.append(anonymousPoliciesCount++).toString();
            }
            getPolicyModels().put(policyUri,policyModel);
        }
        result.add(policyUri);
    }
    return result;
}
 
Example #15
Source File: PolicyWSDLParserExtension.java    From hottub with GNU General Public License v2.0 6 votes vote down vote up
private Collection<String> getPolicyURIs(
        final Collection<PolicyRecordHandler> handlers, final PolicySourceModelContext modelContext) throws PolicyException{
    final Collection<String> result = new ArrayList<String>(handlers.size());
    String policyUri;
    for (PolicyRecordHandler handler : handlers) {
        policyUri = handler.handler;
        if (HandlerType.AnonymousPolicyId == handler.type) {
            final PolicySourceModel policyModel = getAnonymousPolicyModels().get(policyUri);
            policyModel.expand(modelContext);
            while (getPolicyModels().containsKey(policyUri)) {
                policyUri = AnonymnousPolicyIdPrefix.append(anonymousPoliciesCount++).toString();
            }
            getPolicyModels().put(policyUri,policyModel);
        }
        result.add(policyUri);
    }
    return result;
}
 
Example #16
Source File: BuilderHandler.java    From openjdk-jdk9 with GNU General Public License v2.0 6 votes vote down vote up
final Collection<Policy> getPolicies() throws PolicyException {
    if (null == policyURIs) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1004_POLICY_URIS_CAN_NOT_BE_NULL()));
    }
    if (null == policyStore) {
        throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1010_NO_POLICIES_DEFINED()));
    }

    final Collection<Policy> result = new ArrayList<Policy>(policyURIs.size());

    for (String policyURI : policyURIs) {
        final PolicySourceModel sourceModel = policyStore.get(policyURI);
        if (sourceModel == null) {
            throw LOGGER.logSevereException(new PolicyException(PolicyMessages.WSP_1005_POLICY_REFERENCE_DOES_NOT_EXIST(policyURI)));
        } else {
            result.add(ModelTranslator.getTranslator().translate(sourceModel));
        }
    }

    return result;
}
 
Example #17
Source File: PolicyWSDLGeneratorExtension.java    From openjdk-jdk9 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Adds a PolicyReference element that points to the policy of the element,
 * if the policy does not have any id or name. Writes policy inside the element otherwise.
 *
 * @param subject
 *      PolicySubject to be referenced or marshalled
 * @param writer
 *      A TXW on to which we shall add the PolicyReference
 */
private void writePolicyOrReferenceIt(final PolicySubject subject, final TypedXmlWriter writer) {
    final Policy policy;
    try {
        policy = subject.getEffectivePolicy(merger);
    } catch (PolicyException e) {
        throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1011_FAILED_TO_RETRIEVE_EFFECTIVE_POLICY_FOR_SUBJECT(subject.toString()), e));
    }
    if (policy != null) {
        if (null == policy.getIdOrName()) {
            final PolicyModelGenerator generator = ModelGenerator.getGenerator();
            try {
                final PolicySourceModel policyInfoset = generator.translate(policy);
                marshaller.marshal(policyInfoset, writer);
            } catch (PolicyException pe) {
                throw LOGGER.logSevereException(new WebServiceException(PolicyMessages.WSP_1002_UNABLE_TO_MARSHALL_POLICY_OR_POLICY_REFERENCE(), pe));
            }
        } else {
            final TypedXmlWriter policyReference = writer._element(policy.getNamespaceVersion().asQName(XmlToken.PolicyReference), TypedXmlWriter.class);
            policyReference._attribute(XmlToken.Uri.toString(), '#' + policy.getIdOrName());
        }
    }
}
 
Example #18
Source File: PolicyWSDLParserExtension.java    From openjdk-jdk9 with GNU General Public License v2.0 6 votes vote down vote up
private Collection<String> getPolicyURIs(
        final Collection<PolicyRecordHandler> handlers, final PolicySourceModelContext modelContext) throws PolicyException{
    final Collection<String> result = new ArrayList<String>(handlers.size());
    String policyUri;
    for (PolicyRecordHandler handler : handlers) {
        policyUri = handler.handler;
        if (HandlerType.AnonymousPolicyId == handler.type) {
            final PolicySourceModel policyModel = getAnonymousPolicyModels().get(policyUri);
            policyModel.expand(modelContext);
            while (getPolicyModels().containsKey(policyUri)) {
                policyUri = AnonymnousPolicyIdPrefix.append(anonymousPoliciesCount++).toString();
            }
            getPolicyModels().put(policyUri,policyModel);
        }
        result.add(policyUri);
    }
    return result;
}
 
Example #19
Source File: ExternalAttachmentsUnmarshaller.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
private void readPolicy(final XMLEventReader reader) throws PolicyException {
    final PolicySourceModel policyModel = POLICY_UNMARSHALLER.unmarshalModel(reader);
    final PolicyModelTranslator translator = PolicyModelTranslator.getTranslator();
    final Policy policy = translator.translate(policyModel);
    if (this.currentUri != null) {
        map.put(this.currentUri, policy);
        this.currentUri = null;
        this.currentPolicy = null;
    }
    else {
        this.currentPolicy = policy;
    }
}
 
Example #20
Source File: BuilderHandlerOperationScope.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
/** Creates a new instance of WSDLServiceScopeBuilderHandler */
BuilderHandlerOperationScope(
        Collection<String> policyURIs
        , Map<String,PolicySourceModel> policyStore
        , Object policySubject
        , QName service, QName port, QName operation) {

    super(policyURIs, policyStore, policySubject);
    this.service = service;
    this.port = port;
    this.operation = operation;
}
 
Example #21
Source File: ExternalAttachmentsUnmarshaller.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
private void readPolicy(final XMLEventReader reader) throws PolicyException {
    final PolicySourceModel policyModel = POLICY_UNMARSHALLER.unmarshalModel(reader);
    final PolicyModelTranslator translator = PolicyModelTranslator.getTranslator();
    final Policy policy = translator.translate(policyModel);
    if (this.currentUri != null) {
        map.put(this.currentUri, policy);
        this.currentUri = null;
        this.currentPolicy = null;
    }
    else {
        this.currentPolicy = policy;
    }
}
 
Example #22
Source File: ExternalAttachmentsUnmarshaller.java    From openjdk-8-source with GNU General Public License v2.0 5 votes vote down vote up
private void readPolicy(final XMLEventReader reader) throws PolicyException {
    final PolicySourceModel policyModel = POLICY_UNMARSHALLER.unmarshalModel(reader);
    final PolicyModelTranslator translator = PolicyModelTranslator.getTranslator();
    final Policy policy = translator.translate(policyModel);
    if (this.currentUri != null) {
        map.put(this.currentUri, policy);
        this.currentUri = null;
        this.currentPolicy = null;
    }
    else {
        this.currentPolicy = policy;
    }
}
 
Example #23
Source File: BuilderHandlerOperationScope.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
/** Creates a new instance of WSDLServiceScopeBuilderHandler */
BuilderHandlerOperationScope(
        Collection<String> policyURIs
        , Map<String,PolicySourceModel> policyStore
        , Object policySubject
        , QName service, QName port, QName operation) {

    super(policyURIs, policyStore, policySubject);
    this.service = service;
    this.port = port;
    this.operation = operation;
}
 
Example #24
Source File: BuilderHandlerEndpointScope.java    From openjdk-8 with GNU General Public License v2.0 5 votes vote down vote up
/** Creates a new instance of WSDLServiceScopeBuilderHandler */
BuilderHandlerEndpointScope(Collection<String> policyURIs, Map<String,PolicySourceModel> policyStore, Object policySubject, QName service, QName port) {

    super(policyURIs, policyStore, policySubject);
    this.service = service;
    this.port = port;
}
 
Example #25
Source File: BuilderHandlerEndpointScope.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
/** Creates a new instance of WSDLServiceScopeBuilderHandler */
BuilderHandlerEndpointScope(Collection<String> policyURIs, Map<String,PolicySourceModel> policyStore, Object policySubject, QName service, QName port) {

    super(policyURIs, policyStore, policySubject);
    this.service = service;
    this.port = port;
}
 
Example #26
Source File: BuilderHandlerMessageScope.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
/** Creates a new instance of WSDLServiceScopeBuilderHandler */
BuilderHandlerMessageScope(
        Collection<String> policyURIs
        , Map<String,PolicySourceModel> policyStore
        , Object policySubject
        , Scope scope
        , QName service, QName port, QName operation, QName message) {

    super(policyURIs, policyStore, policySubject);
    this.service = service;
    this.port = port;
    this.operation = operation;
    this.scope = scope;
    this.message = message;
}
 
Example #27
Source File: BuilderHandlerServiceScope.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Creates a new instance of BuilderHandlerServiceScope
 */
BuilderHandlerServiceScope(
        Collection<String> policyURIs, Map<String,PolicySourceModel> policyStore, Object policySubject, QName service) {

    super(policyURIs, policyStore, policySubject);
    this.service = service;
}
 
Example #28
Source File: BuilderHandlerServiceScope.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Creates a new instance of BuilderHandlerServiceScope
 */
BuilderHandlerServiceScope(
        Collection<String> policyURIs, Map<String,PolicySourceModel> policyStore, Object policySubject, QName service) {

    super(policyURIs, policyStore, policySubject);
    this.service = service;
}
 
Example #29
Source File: BuilderHandlerEndpointScope.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
/** Creates a new instance of WSDLServiceScopeBuilderHandler */
BuilderHandlerEndpointScope(Collection<String> policyURIs, Map<String,PolicySourceModel> policyStore, Object policySubject, QName service, QName port) {

    super(policyURIs, policyStore, policySubject);
    this.service = service;
    this.port = port;
}
 
Example #30
Source File: ExternalAttachmentsUnmarshaller.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
private void readPolicy(final XMLEventReader reader) throws PolicyException {
    final PolicySourceModel policyModel = POLICY_UNMARSHALLER.unmarshalModel(reader);
    final PolicyModelTranslator translator = PolicyModelTranslator.getTranslator();
    final Policy policy = translator.translate(policyModel);
    if (this.currentUri != null) {
        map.put(this.currentUri, policy);
        this.currentUri = null;
        this.currentPolicy = null;
    }
    else {
        this.currentPolicy = policy;
    }
}