From 4c8a8203b7de51b337d472685fa30ba2b2faf14a Mon Sep 17 00:00:00 2001 From: antelder Date: Tue, 5 Oct 2010 14:05:13 +0000 Subject: Updates for selectedOperation attribute change git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@1004647 13f79535-47bb-0310-9956-ffa450edef68 --- .../tuscany/sca/binding/jms/JMSBindingProcessor.java | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'sca-java-2.x/trunk/modules') diff --git a/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java b/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java index fb2f168645..c86f9a7f18 100644 --- a/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java +++ b/sca-java-2.x/trunk/modules/binding-jms/src/main/java/org/apache/tuscany/sca/binding/jms/JMSBindingProcessor.java @@ -34,6 +34,7 @@ import javax.xml.stream.XMLStreamException; import javax.xml.stream.XMLStreamReader; import javax.xml.stream.XMLStreamWriter; +import org.apache.tuscany.sca.assembly.Base; import org.apache.tuscany.sca.assembly.ConfiguredOperation; import org.apache.tuscany.sca.assembly.OperationSelector; import org.apache.tuscany.sca.assembly.OperationsConfigurator; @@ -46,6 +47,7 @@ import org.apache.tuscany.sca.binding.jms.wireformat.WireFormatJMSDefault; import org.apache.tuscany.sca.binding.jms.wireformat.WireFormatJMSObject; import org.apache.tuscany.sca.binding.jms.wireformat.WireFormatJMSText; import org.apache.tuscany.sca.binding.jms.wireformat.WireFormatJMSTextXML; +import org.apache.tuscany.sca.common.xml.stax.StAXHelper; import org.apache.tuscany.sca.contribution.processor.BaseStAXArtifactProcessor; import org.apache.tuscany.sca.contribution.processor.ContributionReadException; import org.apache.tuscany.sca.contribution.processor.ContributionResolveException; @@ -113,7 +115,7 @@ import org.apache.tuscany.sca.policy.PolicyFactory; * * * ? * - * + * * * * 0) { - if (JMSBindingConstants.VALID_CORRELATION_SCHEMES.contains(correlationScheme.toLowerCase())) { - jmsBinding.setCorrelationScheme(correlationScheme); + QName correlationScheme = StAXHelper.getAttributeAsQName(reader, "correlationScheme"); + if (correlationScheme != null) { + if (Base.SCA11_NS.equals(correlationScheme.getNamespaceURI()) && JMSBindingConstants.VALID_CORRELATION_SCHEMES.contains(correlationScheme.getLocalPart())) { + jmsBinding.setCorrelationScheme(correlationScheme.getLocalPart()); } else { error(monitor, "InvalidCorrelationScheme", reader, correlationScheme); } @@ -754,7 +756,7 @@ public class JMSBindingProcessor extends BaseStAXArtifactProcessor implements St } /** - * + * * * * 0) { jmsBinding.setNativeOperationName(opName, nativeOpName); } @@ -1259,7 +1261,7 @@ public class JMSBindingProcessor extends BaseStAXArtifactProcessor implements St /** * Writes operation properties if there are any. * - * + * * * * 0) { if ( !nativeOperation.equals( opName )) { - writer.writeAttribute("nativeOperation", nativeOperation); + writer.writeAttribute("selectedOperation", nativeOperation); } } -- cgit v1.2.3