summaryrefslogtreecommitdiffstats
path: root/java
diff options
context:
space:
mode:
Diffstat (limited to 'java')
-rw-r--r--java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java7
-rw-r--r--java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/impl/BaseBuilderImpl.java4
2 files changed, 10 insertions, 1 deletions
diff --git a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java
index b4fe17770c..0f3eb8ea30 100644
--- a/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java
+++ b/java/sca/modules/assembly-xml/src/main/java/org/apache/tuscany/sca/assembly/xml/BaseAssemblyProcessor.java
@@ -581,6 +581,13 @@ abstract class BaseAssemblyProcessor extends BaseStAXArtifactProcessor {
break;
}
isTextForProperty = false;
+
+ // CONFORMANCE: ASM50033
+ // A property <value/> subelement MUST NOT be used when the @value attribute is used
+ // to specify the value for that property.
+ if (valueAttr != null) {
+ error("ASM50033: value attribute exists for the property element", name, name);
+ }
// Read <value>
if (VALUE_QNAME.equals(name)) {
loadElement(reader, root);
diff --git a/java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/impl/BaseBuilderImpl.java b/java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/impl/BaseBuilderImpl.java
index 09b19dd7b3..161cf73b17 100644
--- a/java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/impl/BaseBuilderImpl.java
+++ b/java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/impl/BaseBuilderImpl.java
@@ -379,7 +379,9 @@ public abstract class BaseBuilderImpl implements CompositeBuilder {
if (!componentProperties.containsKey(property.getName())) {
ComponentProperty componentProperty = assemblyFactory.createComponentProperty();
componentProperty.setName(property.getName());
+ componentProperty.setValue(property.getValue());
componentProperty.setMany(property.isMany());
+ componentProperty.setMustSupply(property.isMustSupply());
componentProperty.setXSDElement(property.getXSDElement());
componentProperty.setXSDType(property.getXSDType());
componentProperty.setProperty(property);
@@ -419,7 +421,7 @@ public abstract class BaseBuilderImpl implements CompositeBuilder {
// Check that a value is supplied
if (componentProperty.getValue() == null && property.isMustSupply()) {
- warning(monitor, "PropertyMustSupplyNull", component, component.getName(), componentProperty
+ error(monitor, "PropertyMustSupplyNull", component, component.getName(), componentProperty
.getName());
}