Author: scabanovich
Date: 2009-12-22 06:45:57 -0500 (Tue, 22 Dec 2009)
New Revision: 19531
Modified:
trunk/esb/plugins/org.jboss.tools.esb.core/resources/meta/esb-actions.meta
trunk/esb/plugins/org.jboss.tools.esb.core/src/org/jboss/tools/esb/core/model/converters/EndpointConverter.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5553
Modified: trunk/esb/plugins/org.jboss.tools.esb.core/resources/meta/esb-actions.meta
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.core/resources/meta/esb-actions.meta 2009-12-22
11:15:20 UTC (rev 19530)
+++ trunk/esb/plugins/org.jboss.tools.esb.core/resources/meta/esb-actions.meta 2009-12-22
11:45:57 UTC (rev 19531)
@@ -1473,7 +1473,7 @@
<Editor name="TreeChooser"/>
</XModelAttribute>
<XModelAttribute PROPERTIES="category=general" name="endpoint
url" xmlname="endpointUrl"/>
- <XModelAttribute PROPERTIES="category=general" name="file"
xmlname="file">
+ <XModelAttribute PROPERTIES="category=general;pre=true"
name="file" xmlname="file">
<Constraint loader="Tree">
<value name="ESBResourceTree"/>
<value name="extensions=properties"/>
@@ -1481,10 +1481,18 @@
</Constraint>
<Editor name="TreeChooser"/>
</XModelAttribute>
- <XModelAttribute PROPERTIES="category=general;pre=true"
default="GET"
- name="method" xmlname="method">
+ <XModelAttribute PROPERTIES="pre=true;category=general"
+ default="Default(true)" name="client credentials required"
xmlname="clientCredentialsRequired">
<Constraint loader="ListString">
- <value name="GET"/>
+ <value name="Default(true)"/>
+ <value name="true"/>
+ <value name="false"/>
+ </Constraint>
+ <Editor name="ListString"/>
+ </XModelAttribute>
+ <XModelAttribute PROPERTIES="category=general;pre=true"
name="method" xmlname="method">
+ <Constraint loader="ListString">
+ <value/>
<value name="POST"/>
</Constraint>
<Editor name="ListString"/>
Modified:
trunk/esb/plugins/org.jboss.tools.esb.core/src/org/jboss/tools/esb/core/model/converters/EndpointConverter.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.core/src/org/jboss/tools/esb/core/model/converters/EndpointConverter.java 2009-12-22
11:15:20 UTC (rev 19530)
+++
trunk/esb/plugins/org.jboss.tools.esb.core/src/org/jboss/tools/esb/core/model/converters/EndpointConverter.java 2009-12-22
11:45:57 UTC (rev 19531)
@@ -37,7 +37,10 @@
p.setAttributeValue(ESBConstants.ATTR_VALUE, endpointURL);
}
String file = specificAction.getAttributeValue(ATTR_FILE);
- if(file != null && file.length() > 0) {
+ if(file != null && file.length() > 0
+ && specificAction.getModelEntity().getAttribute(ATTR_FILE) != null
+ &&
!"true".equals(specificAction.getModelEntity().getAttribute(ATTR_FILE).getProperty("pre"))
+ ) {
empty = false;
XModelObject f = basicAction.getModel().createModelObject(getItemEntityName(), null);
f.setAttributeValue(ESBConstants.ATTR_NAME, ATTR_FILE);
@@ -59,7 +62,10 @@
if(as[i] instanceof AnyElementObjectImpl) {
XModelObject a = fromAnyElement(as[i], getItemEntityName());
if(a != null) {
- if(ATTR_FILE.equals(a.getAttributeValue(ESBConstants.ATTR_NAME))) {
+ if(ATTR_FILE.equals(a.getAttributeValue(ESBConstants.ATTR_NAME))
+ && specificAction.getModelEntity().getAttribute(ATTR_FILE) != null
+ &&
!"true".equals(specificAction.getModelEntity().getAttribute(ATTR_FILE).getProperty("pre"))
+ ) {
specificAction.setAttributeValue(ATTR_FILE,
a.getAttributeValue(ESBConstants.ATTR_VALUE));
} else {
specificAction.addChild(a);