Package org.apache.axis2.context

Examples of org.apache.axis2.context.PropertyDifference


    public void updateProperties(AbstractContext abstractContext) {
        log.debug("Updating props in " + abstractContext);
        if (abstractContext != null) {
            for (Iterator iter = properties.keySet().iterator(); iter.hasNext();) {
                String key = (String) iter.next();
                PropertyDifference propDiff =
                        (PropertyDifference) properties.get(key);
                if (propDiff.isRemoved()) {
                    abstractContext.removePropertyNonReplicable(key);
                } else // it is updated/added
                    abstractContext.setNonReplicableProperty(key, propDiff.getValue());
                    log.debug("Added prop=" + key + ", value=" + propDiff.getValue() +
                              " to context " + abstractContext);
                }
            }
        }
    }
View Full Code Here


                        // Next check whether it matches an excluded pattern
                        if (!isExcluded(key,
                                        context.getClass().getName(),
                                        excludedPropertyPatterns)) {
                            log.debug("sending property =" + key + "-" + prop);
                            PropertyDifference diff = (PropertyDifference) diffs.get(key);
                            diff.setValue(prop);
                            updateCmd.addProperty(diff);
                        }
                    }
                }
            }
        } else {
            synchronized (context) {
                for (Iterator iter = context.getPropertyNames(); iter.hasNext();) {
                    String key = (String) iter.next();
                    Object prop = context.getPropertyNonReplicable(key);
                    if (prop instanceof Serializable) { // First check whether it is serializable

                        // Next check whether it matches an excluded pattern
                        if (!isExcluded(key, context.getClass().getName(), excludedPropertyPatterns))
                        {
                            log.debug("sending property =" + key + "-" + prop);
                            PropertyDifference diff = new PropertyDifference(key, prop, false);
                            updateCmd.addProperty(diff);
                        }
                    }
                }
            }
View Full Code Here

            log.debug("Updating props in " + abstractContext);
        }
        if (abstractContext != null) {
            for (Iterator iter = properties.keySet().iterator(); iter.hasNext();) {
                String key = (String) iter.next();
                PropertyDifference propDiff =
                        (PropertyDifference) properties.get(key);
                if (propDiff.isRemoved()) {
                    abstractContext.removePropertyNonReplicable(key);
                } else // it is updated/added
                    abstractContext.setNonReplicableProperty(key, propDiff.getValue());
                    if (log.isDebugEnabled()) {
                        log.debug("Added prop=" + key + ", value=" + propDiff.getValue() +
                                  " to context " + abstractContext);
                    }
                }
            }
        }
View Full Code Here

        if (!includeAllProperties) {
            synchronized (context) {
                Map diffs = context.getPropertyDifferences();
                for (Object o : diffs.keySet()) {
                    String key = (String) o;
                    PropertyDifference diff = (PropertyDifference) diffs.get(key);
                    Object value = diff.getValue();

                    if (value instanceof Serializable) {

                        // Next check whether it matches an excluded pattern
                        if (!isExcluded(key,
                                        context.getClass().getName(),
                                        excludedPropertyPatterns)) {
                            if (log.isDebugEnabled()) {
                                log.debug("sending property =" + key + "-" + value);
                            }
                            updateCmd.addProperty(diff);
                        }
                    }
                }
            }
        } else {
            synchronized (context) {
                for (Iterator iter = context.getPropertyNames(); iter.hasNext();) {
                    String key = (String) iter.next();
                    Object value = context.getPropertyNonReplicable(key);
                    if (value instanceof Serializable) {

                        // Next check whether it matches an excluded pattern
                        if (!isExcluded(key, context.getClass().getName(), excludedPropertyPatterns)) {
                            if (log.isDebugEnabled()) {
                                log.debug("sending property =" + key + "-" + value);
                            }
                            PropertyDifference diff = new PropertyDifference(key, value, false);
                            updateCmd.addProperty(diff);
                        }
                    }
                }
            }
View Full Code Here

            // First check whether it is serializable
            if (prop instanceof Serializable) {
                if (log.isDebugEnabled()) {
                    log.debug("sending property =" + key + "-" + prop);
                }
                PropertyDifference diff = (PropertyDifference) diffs.get(key);
                if (diff != null) {
                    diff.setValue(prop);
                    updateCmd.addProperty(diff);

                    // Remove the diff?
                    diffs.remove(key);
                }
View Full Code Here

        if (!includeAllProperties) {
            synchronized (context) {
                Map diffs = context.getPropertyDifferences();
                for (Object o : diffs.keySet()) {
                    String key = (String) o;
                    PropertyDifference diff = (PropertyDifference) diffs.get(key);
                    Object value = diff.getValue();
                    if (isSerializable(value)) {

                        // Next check whether it matches an excluded pattern
                        if (!isExcluded(key,
                                        context.getClass().getName(),
                                        excludedPropertyPatterns)) {
                            if (log.isDebugEnabled()) {
                                log.debug("sending property =" + key + "-" + value);
                            }
                            updateCmd.addProperty(diff);
                        }
                    }
                }
            }
        } else {
            synchronized (context) {
                for (Iterator iter = context.getPropertyNames(); iter.hasNext();) {
                    String key = (String) iter.next();
                    Object value = context.getPropertyNonReplicable(key);
                    if (isSerializable(value)) {

                        // Next check whether it matches an excluded pattern
                        if (!isExcluded(key, context.getClass().getName(), excludedPropertyPatterns)) {
                            if (log.isDebugEnabled()) {
                                log.debug("sending property =" + key + "-" + value);
                            }
                            PropertyDifference diff = new PropertyDifference(key, value, false);
                            updateCmd.addProperty(diff);
                        }
                    }
                }
            }
View Full Code Here

            // First check whether it is serializable
            if (isSerializable(prop)) {
                if (log.isDebugEnabled()) {
                    log.debug("sending property =" + key + "-" + prop);
                }
                PropertyDifference diff = (PropertyDifference) diffs.get(key);
                if (diff != null) {
                    diff.setValue(prop);
                    updateCmd.addProperty(diff);

                    // Remove the diff?
                    diffs.remove(key);
                }
View Full Code Here

            log.debug("Updating props in " + abstractContext);
        }
        if (abstractContext != null) {
            for (Iterator iter = properties.keySet().iterator(); iter.hasNext();) {
                String key = (String) iter.next();
                PropertyDifference propDiff =
                        (PropertyDifference) properties.get(key);
                if (propDiff.isRemoved()) {
                    abstractContext.removePropertyNonReplicable(key);
                } else // it is updated/added
                    abstractContext.setNonReplicableProperty(key, propDiff.getValue());
                    if (log.isDebugEnabled()) {
                        log.debug("Added prop=" + key + ", value=" + propDiff.getValue() +
                                  " to context " + abstractContext);
                    }
                }
            }
        }
View Full Code Here

        // mark the anon services created to be used in the client side of synapse as hidden
        // from the server side of synapse point of view
        anoymousService.getParent().addParameter(SynapseConstants.HIDDEN_SERVICE_PARAM, "true");
        ServiceGroupContext sgc = new ServiceGroupContext(
            axisCfgCtx, (AxisServiceGroup) anoymousService.getParent());
        ServiceContext serviceCtx = sgc.getServiceContext(anoymousService);

        boolean outOnlyMessage = "true".equals(synapseOutMessageContext.getProperty(
                SynapseConstants.OUT_ONLY)) || WSDL2Constants.MEP_URI_IN_ONLY.equals(
                originalInMsgCtx.getOperationContext()
                        .getAxisOperation().getMessageExchangePattern());
View Full Code Here

            AnonymousServiceFactory.getAnonymousService(synapseOutMessageContext.getConfiguration(),
            axisCfg, wsAddressingEnabled, wsRMEnabled, wsSecurityEnabled);
        // mark the anon services created to be used in the client side of synapse as hidden
        // from the server side of synapse point of view
        anoymousService.getParent().addParameter(SynapseConstants.HIDDEN_SERVICE_PARAM, "true");
        ServiceGroupContext sgc = new ServiceGroupContext(
            axisCfgCtx, (AxisServiceGroup) anoymousService.getParent());
        ServiceContext serviceCtx = sgc.getServiceContext(anoymousService);

        boolean outOnlyMessage = "true".equals(synapseOutMessageContext.getProperty(
                SynapseConstants.OUT_ONLY)) || WSDL2Constants.MEP_URI_IN_ONLY.equals(
                originalInMsgCtx.getOperationContext()
                        .getAxisOperation().getMessageExchangePattern());
View Full Code Here

TOP

Related Classes of org.apache.axis2.context.PropertyDifference

Copyright © 2018 www.massapicom. 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.