wise SVN: r578 - core/trunk/core/src/main/java/org/jboss/wise/core/utils.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 18:01:47 -0400 (Wed, 03 Jul 2013)
New Revision: 578
Modified:
core/trunk/core/src/main/java/org/jboss/wise/core/utils/JavaUtils.java
core/trunk/core/src/main/java/org/jboss/wise/core/utils/ReflectionUtils.java
Log:
Few minor optimizations/cleanup
Modified: core/trunk/core/src/main/java/org/jboss/wise/core/utils/JavaUtils.java
===================================================================
--- core/trunk/core/src/main/java/org/jboss/wise/core/utils/JavaUtils.java 2013-07-03 21:45:50 UTC (rev 577)
+++ core/trunk/core/src/main/java/org/jboss/wise/core/utils/JavaUtils.java 2013-07-03 22:01:47 UTC (rev 578)
@@ -31,7 +31,7 @@
*/
public class JavaUtils {
- private static HashMap<String, Class<?>> primitiveNames = new HashMap<String, Class<?>>(8);
+ private static HashMap<String, Class<?>> primitiveNames = new HashMap<String, Class<?>>(12);
static {
primitiveNames.put("int", int.class);
Modified: core/trunk/core/src/main/java/org/jboss/wise/core/utils/ReflectionUtils.java
===================================================================
--- core/trunk/core/src/main/java/org/jboss/wise/core/utils/ReflectionUtils.java 2013-07-03 21:45:50 UTC (rev 577)
+++ core/trunk/core/src/main/java/org/jboss/wise/core/utils/ReflectionUtils.java 2013-07-03 22:01:47 UTC (rev 578)
@@ -24,7 +24,6 @@
import java.lang.reflect.Field;
import java.util.LinkedList;
import java.util.List;
-import javax.xml.bind.annotation.XmlElement;
/**
* Provides some utility methods useful to deal with classes through reflection.
@@ -63,15 +62,11 @@
*/
public static String setterMethodName( String fieldName,
boolean isBoolean ) {
- String setter = "set" + JavaUtils.capitalize(fieldName);
- if (isBoolean) {
- if (fieldName.startsWith("is")) {
- setter = "set" + fieldName.substring(2);
- } else {
- setter = "set" + JavaUtils.capitalize(fieldName);
- }
+ if (!isBoolean) {
+ return "set" + JavaUtils.capitalize(fieldName);
+ } else {
+ return "set" + (fieldName.startsWith("is") ? fieldName.substring(2) : JavaUtils.capitalize(fieldName));
}
- return setter;
}
/**
@@ -83,15 +78,11 @@
*/
public static String getterMethodName( String fieldName,
boolean isBoolean ) {
- String getter = "get" + JavaUtils.capitalize(fieldName);
- if (isBoolean) {
- if (fieldName.startsWith("is")) {
- getter = fieldName;
- } else {
- getter = "is" + JavaUtils.capitalize(fieldName);
- }
- }
- return getter;
+ if (!isBoolean) {
+ return "get" + JavaUtils.capitalize(fieldName);
+ } else {
+ return fieldName.startsWith("is") ? fieldName : "is" + JavaUtils.capitalize(fieldName);
+ }
}
/**
@@ -104,13 +95,8 @@
Class cl = field.getType();
if (cl.isPrimitive()) {
cl = JavaUtils.getWrapperType(cl);
-
}
String cap = JavaUtils.capitalize(field.getName());
- if (cl.getName().equalsIgnoreCase("java.lang.Boolean")) {
- return "is" + cap;
- } else {
- return "get" + cap;
- }
+ return cl.getName().equalsIgnoreCase("java.lang.Boolean") ? "is" + cap : "get" + cap;
}
}
11 years, 6 months
wise SVN: r577 - core/trunk/core/src/main/java/org/jboss/wise/core/utils.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 17:45:50 -0400 (Wed, 03 Jul 2013)
New Revision: 577
Modified:
core/trunk/core/src/main/java/org/jboss/wise/core/utils/ReflectionUtils.java
Log:
[WISE-206] Fixing ReflectionUtils.getGetter()
Modified: core/trunk/core/src/main/java/org/jboss/wise/core/utils/ReflectionUtils.java
===================================================================
--- core/trunk/core/src/main/java/org/jboss/wise/core/utils/ReflectionUtils.java 2013-07-03 21:41:31 UTC (rev 576)
+++ core/trunk/core/src/main/java/org/jboss/wise/core/utils/ReflectionUtils.java 2013-07-03 21:45:50 UTC (rev 577)
@@ -101,18 +101,12 @@
* @return String
*/
public static String getGetter( Field field ) {
- XmlElement ann = field.getAnnotation(XmlElement.class);
Class cl = field.getType();
if (cl.isPrimitive()) {
cl = JavaUtils.getWrapperType(cl);
}
- String cap;
- if (ann == null || ann.name() == null || ann.name().startsWith("##")) {
- cap = JavaUtils.capitalize(field.getName());
- } else {
- cap = JavaUtils.capitalize(ann.name());
- }
+ String cap = JavaUtils.capitalize(field.getName());
if (cl.getName().equalsIgnoreCase("java.lang.Boolean")) {
return "is" + cap;
} else {
11 years, 6 months
wise SVN: r576 - webgui/trunk/src/main/java/org/jboss/wise/gui.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 17:41:31 -0400 (Wed, 03 Jul 2013)
New Revision: 576
Modified:
webgui/trunk/src/main/java/org/jboss/wise/gui/ResponseLogHandler.java
Log:
Turn ResponseLogHandler into LogicalHandler instead of SOAPHandler
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/ResponseLogHandler.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/ResponseLogHandler.java 2013-07-03 21:40:54 UTC (rev 575)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/ResponseLogHandler.java 2013-07-03 21:41:31 UTC (rev 576)
@@ -32,16 +32,16 @@
import javax.xml.transform.Transformer;
import javax.xml.transform.TransformerFactory;
import javax.xml.transform.stream.StreamResult;
+import javax.xml.ws.handler.LogicalHandler;
+import javax.xml.ws.handler.LogicalMessageContext;
import javax.xml.ws.handler.MessageContext;
-import javax.xml.ws.handler.soap.SOAPHandler;
-import javax.xml.ws.handler.soap.SOAPMessageContext;
/**
* Logs the client inbound response message
*
* @author alessio.soldano(a)jboss.com
*/
-public class ResponseLogHandler implements SOAPHandler<SOAPMessageContext> {
+public class ResponseLogHandler implements LogicalHandler<LogicalMessageContext> {
private final OutputStream outputStream;
@@ -53,12 +53,12 @@
return new HashSet<QName>(); // empty set
}
- public boolean handleMessage(SOAPMessageContext smc) {
+ public boolean handleMessage(LogicalMessageContext smc) {
doLog(smc);
return true;
}
- public boolean handleFault(SOAPMessageContext smc) {
+ public boolean handleFault(LogicalMessageContext smc) {
doLog(smc);
return true;
}
@@ -67,7 +67,7 @@
public void close(MessageContext messageContext) {
}
- private void doLog(SOAPMessageContext smc) {
+ private void doLog(LogicalMessageContext smc) {
if (!(Boolean) smc.get(MessageContext.MESSAGE_OUTBOUND_PROPERTY)) {
try {
TransformerFactory tff = TransformerFactory.newInstance();
@@ -75,7 +75,7 @@
tf.setOutputProperty(OutputKeys.INDENT, "yes");
tf.setOutputProperty("{http://xml.apache.org/xslt}indent-amount", "2");
- Source sc = smc.getMessage().getSOAPPart().getContent();
+ Source sc = smc.getMessage().getPayload();
StreamResult result = new StreamResult(outputStream);
tf.transform(sc, result);
@@ -87,5 +87,4 @@
}
}
}
-
}
11 years, 6 months
wise SVN: r575 - webgui/trunk/src/main/java/org/jboss/wise/gui.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 17:40:54 -0400 (Wed, 03 Jul 2013)
New Revision: 575
Modified:
webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java
Log:
[WISE-203] Cleanup error message when going back in the flow
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java 2013-07-03 17:28:48 UTC (rev 574)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java 2013-07-03 21:40:54 UTC (rev 575)
@@ -100,7 +100,7 @@
}
});
} catch (Exception e) {
- error = "Could not read WSDL from specified URL. Please check logs for further information.";
+ error = "Could not read WSDL from specified URL. Please check credentials and see logs for further information.";
logException(e);
}
if (client != null) {
@@ -209,11 +209,19 @@
} else if (oldName.endsWith("step2")) {
if (newName.endsWith("step3")) {
parseOperationParameters();
+ } else if (newName.endsWith("step1")) {
+ this.error = null;
}
} else if (oldName.endsWith("step3")) {
if (newName.endsWith("step4")) {
performInvocation();
+ } else if (newName.endsWith("step2")) {
+ this.error = null;
}
+ } else if (oldName.endsWith("step4")) {
+ if (newName.endsWith("step3")) {
+ this.error = null;
+ }
}
}
}
11 years, 6 months
wise SVN: r574 - webgui/trunk/src/main/webapp/WEB-INF.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 13:28:48 -0400 (Wed, 03 Jul 2013)
New Revision: 574
Modified:
webgui/trunk/src/main/webapp/WEB-INF/web.xml
Log:
[WISE-205] Further perf tuning
Modified: webgui/trunk/src/main/webapp/WEB-INF/web.xml
===================================================================
--- webgui/trunk/src/main/webapp/WEB-INF/web.xml 2013-07-03 16:51:11 UTC (rev 573)
+++ webgui/trunk/src/main/webapp/WEB-INF/web.xml 2013-07-03 17:28:48 UTC (rev 574)
@@ -20,6 +20,14 @@
<param-name>org.richfaces.resourceOptimization.enabled</param-name>
<param-value>true</param-value>
</context-param>
+ <context-param>
+ <param-name>javax.faces.FACELETS_SKIP_COMMENTS</param-name>
+ <param-value>true</param-value>
+ </context-param>
+ <context-param>
+ <param-name>javax.faces.FACELETS_REFRESH_PERIOD</param-name>
+ <param-value>-1</param-value>
+ </context-param>
<!-- Set the PROJECT_STAGE to 'Development' to receive constructive error messages during development.
Change the PROJECT_STAGE to 'Production' when putting the application into production -->
<context-param>
11 years, 6 months
wise SVN: r573 - in webgui/trunk/src/main: webapp and 1 other directory.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 12:51:11 -0400 (Wed, 03 Jul 2013)
New Revision: 573
Added:
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/IDGenerator.java
Modified:
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ComplexWiseTreeElement.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/GroupWiseTreeElement.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/LazyLoadWiseTreeElement.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ParameterizedWiseTreeElement.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/SimpleWiseTreeElement.java
webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/WiseTreeElementBuilder.java
webgui/trunk/src/main/webapp/step3.xhtml
Log:
[WISE-205] Reducing ajax messages size by using shorter ids for gui elements and shorter labels
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ComplexWiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ComplexWiseTreeElement.java 2013-07-03 12:36:16 UTC (rev 572)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ComplexWiseTreeElement.java 2013-07-03 16:51:11 UTC (rev 573)
@@ -27,7 +27,6 @@
import javax.xml.datatype.XMLGregorianCalendar;
import org.jboss.wise.core.exception.WiseRuntimeException;
-import org.jboss.wise.core.utils.IDGenerator;
import org.jboss.wise.core.utils.ReflectionUtils;
/**
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/GroupWiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/GroupWiseTreeElement.java 2013-07-03 12:36:16 UTC (rev 572)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/GroupWiseTreeElement.java 2013-07-03 16:51:11 UTC (rev 573)
@@ -21,8 +21,6 @@
import java.util.Iterator;
import java.util.LinkedList;
-import org.jboss.wise.core.utils.IDGenerator;
-
/**
* This tree element is for arrays and collections of elements
*
Added: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/IDGenerator.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/IDGenerator.java (rev 0)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/IDGenerator.java 2013-07-03 16:51:11 UTC (rev 573)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2012, Red Hat, Inc. and/or its affiliates, and individual
+ * contributors by the @authors tag. See the copyright.txt in the
+ * distribution for a full listing of individual contributors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.jboss.wise.gui.treeElement;
+
+import java.util.concurrent.atomic.AtomicInteger;
+
+/**
+ * An ID generator returning short values (unique on the same VM).
+ * This backed by an atomic integer.
+ *
+ * @author alessio.soldano(a)jboss.com
+ *
+ */
+public class IDGenerator {
+
+ private static AtomicInteger idCounter = new AtomicInteger();
+
+ public static final String nextVal() {
+ return String.valueOf(idCounter.getAndIncrement());
+ }
+}
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/LazyLoadWiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/LazyLoadWiseTreeElement.java 2013-07-03 12:36:16 UTC (rev 572)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/LazyLoadWiseTreeElement.java 2013-07-03 16:51:11 UTC (rev 573)
@@ -20,8 +20,6 @@
import java.util.Iterator;
import java.util.Map;
-import org.jboss.wise.core.utils.IDGenerator;
-
/**
* This tree element is for storing lazy load references to other elements;
* required because in some uncommon scenario, the parameter trees might
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ParameterizedWiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ParameterizedWiseTreeElement.java 2013-07-03 12:36:16 UTC (rev 572)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/ParameterizedWiseTreeElement.java 2013-07-03 16:51:11 UTC (rev 573)
@@ -27,8 +27,6 @@
import org.jboss.wise.core.client.WSDynamicClient;
import org.jboss.wise.core.exception.WiseRuntimeException;
-import org.jboss.wise.core.utils.IDGenerator;
-
/**
* A tree element to handle JAXBElement<T>.
*
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/SimpleWiseTreeElement.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/SimpleWiseTreeElement.java 2013-07-03 12:36:16 UTC (rev 572)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/SimpleWiseTreeElement.java 2013-07-03 16:51:11 UTC (rev 573)
@@ -22,7 +22,6 @@
import java.net.URLEncoder;
import org.jboss.wise.core.exception.WiseRuntimeException;
-import org.jboss.wise.core.utils.IDGenerator;
import org.jboss.wise.core.utils.JavaUtils;
import sun.misc.BASE64Encoder;
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/WiseTreeElementBuilder.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/WiseTreeElementBuilder.java 2013-07-03 12:36:16 UTC (rev 572)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/treeElement/WiseTreeElementBuilder.java 2013-07-03 16:51:11 UTC (rev 573)
@@ -34,7 +34,6 @@
import org.jboss.logging.Logger;
import org.jboss.wise.core.client.WSDynamicClient;
import org.jboss.wise.core.exception.WiseRuntimeException;
-import org.jboss.wise.core.utils.IDGenerator;
import org.jboss.wise.core.utils.ReflectionUtils;
/**
Modified: webgui/trunk/src/main/webapp/step3.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step3.xhtml 2013-07-03 12:36:16 UTC (rev 572)
+++ webgui/trunk/src/main/webapp/step3.xhtml 2013-07-03 16:51:11 UTC (rev 573)
@@ -12,44 +12,34 @@
<div>
<i>#{clientConversationBean.currentOperationFullName}</i>
</div>
- <a4j:outputPanel id="parInputPanel" ajaxRendered="true"> <!-- The tree must live within a ajaxRendered outputPanel in order for properly refreshing! -->
- <rich:tree id="richTree" var="node" value="#{clientConversationBean.inputTree}" nodeType="#{node.kind}" binding="#{clientConversationBean.inTree}">
+ <a4j:outputPanel id="parInputPanel">
+ <rich:tree id="rt" var="node" value="#{clientConversationBean.inputTree}" nodeType="#{node.kind}" binding="#{clientConversationBean.inTree}">
<rich:treeNode type="simple">
<h:outputText value="#{node.type} : #{node.name} " />
- <h:selectBooleanCheckbox id="foo-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <h:selectBooleanCheckbox id="n_cb" value="#{node.notNil}" disabled="#{node.notNillable}" >
<f:ajax />
</h:selectBooleanCheckbox>
- <h:inputText value="#{node.value}" id="foo" label="" rendered="#{node.type!='boolean' and node.type!='Boolean'}" columns="10" >
- <f:ajax event="valueChange" render="foo-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ <h:inputText value="#{node.value}" id="n" label="" rendered="#{node.type!='boolean' and node.type!='Boolean'}" columns="10" >
+ <f:ajax event="valueChange" render="n_cb" listener="#{clientConversationBean.onInputFocus(node)}" />
</h:inputText>
<h:selectOneMenu value="#{node.value}" rendered="#{node.type=='boolean' or node.type=='Boolean'}">
<f:selectItem itemValue="true" itemLabel="true" />
<f:selectItem itemValue="false" itemLabel="false" />
</h:selectOneMenu>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
<rich:treeNode type="group" expanded="#{node.expanded}">
<h:outputText value="[#{node.type}]" styleClass="tipoCampo" />
<h:selectBooleanCheckbox value="#{node.notNil}" disabled="true" />
<h:outputText value=" " />
- <a4j:commandLink name="Add" action="#{clientConversationBean.addChild(node)}" reRender="richTree">
- Add
- </a4j:commandLink>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink name="Add" action="#{clientConversationBean.addChild(node)}" render="rt">Add</a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
<rich:treeNode type="lazy">
<h:outputText value="#{node.type} ..." />
<h:outputText value=" " />
- <a4j:commandLink name="Load" action="#{clientConversationBean.lazyLoadChild(node)}" reRender="richTree" rendered="#{not node.resolved}">
- Load
- </a4j:commandLink>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink name="Load" action="#{clientConversationBean.lazyLoadChild(node)}" render="rt" rendered="#{not node.resolved}">Load</a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
<rich:treeNode type="complex" expanded="#{node.expanded}">
<h:outputText value="#{node.type} : #{node.name} " />
@@ -57,79 +47,67 @@
<f:ajax />
</h:selectBooleanCheckbox>
<h:outputText value=" " />
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
<rich:treeNode type="Parameterized" expanded="#{node.expanded}">
<h:outputText value="{#{node.namespace}} " />
<h:selectBooleanCheckbox value="#{node.notNil}" disabled="true" />
</rich:treeNode>
<rich:treeNode type="XMLGregorianCalendar">
- <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
- <h:selectBooleanCheckbox id="foo2-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
+ <h:selectBooleanCheckbox id="n2_cb" value="#{node.notNil}" disabled="#{node.notNillable}" >
<f:ajax />
</h:selectBooleanCheckbox>
- <rich:calendar id="foo2" value="#{node.valueDate}" popup="true" showInput="true" enableManualInput="false" >
- <f:ajax event="change" render="foo2-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ <rich:calendar id="n2" value="#{node.valueDate}" popup="true" showInput="true" enableManualInput="false" >
+ <f:ajax event="change" render="n2_cb" listener="#{clientConversationBean.onInputFocus(node)}" />
</rich:calendar>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
<rich:treeNode type="Duration">
<h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
- <h:selectBooleanCheckbox id="foo3-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <h:selectBooleanCheckbox id="n3_cb" value="#{node.notNil}" disabled="#{node.notNillable}" >
<f:ajax />
</h:selectBooleanCheckbox>
- <h:inputText id="foo3" value="#{node.value}">
- <f:ajax event="valueChange" render="foo3-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ <h:inputText id="n3" value="#{node.value}">
+ <f:ajax event="valueChange" render="n3_cb" listener="#{clientConversationBean.onInputFocus(node)}" />
</h:inputText>
<h:outputText value="(MilliSeconds)" target="_blank" />
<h:outputText value=" " />
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
<rich:treeNode type="qname">
<h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
- <h:selectBooleanCheckbox id="foo4-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <h:selectBooleanCheckbox id="n4_cb" value="#{node.notNil}" disabled="#{node.notNillable}" >
<f:ajax />
</h:selectBooleanCheckbox>
- <h:inputText id="foo4" value="#{node.nameSpace}">
- <f:ajax event="valueChange" render="foo4-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ <h:inputText id="n4" value="#{node.nameSpace}">
+ <f:ajax event="valueChange" render="n4_cb" listener="#{clientConversationBean.onInputFocus(node)}" />
</h:inputText>
<h:outputText value=" : " />
<h:inputText value="#{node.localPart}" />
<h:outputText value=" " />
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
<rich:treeNode type="Enumeration">
<h:outputText value="#{node.type} : #{node.name} " styleClass="tipoCampo" />
- <h:selectBooleanCheckbox id="foo5-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <h:selectBooleanCheckbox id="n5_cb" value="#{node.notNil}" disabled="#{node.notNillable}" >
<f:ajax />
</h:selectBooleanCheckbox>
- <h:selectOneMenu id="foo5" value="#{node.value}" onfocus="document.getElementById(this.id + '-chk').checked=true">
+ <h:selectOneMenu id="n5" value="#{node.value}" onfocus="document.getElementById(this.id + '_cb').checked=true">
<f:selectItems value="#{node.validValue}" />
</h:selectOneMenu>
<h:outputText value=" " />
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
<rich:treeNode type="byteArray">
<h:outputText value="#{node.type} : #{node.name} " />
- <h:selectBooleanCheckbox id="foo6-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
+ <h:selectBooleanCheckbox id="n6_cb" value="#{node.notNil}" disabled="#{node.notNillable}" >
<f:ajax />
</h:selectBooleanCheckbox>
- <h:inputText value="#{node.value}" id="foo6" >
- <f:ajax event="valueChange" render="foo6-chk" listener="#{clientConversationBean.onInputFocus(node)}" />
+ <h:inputText value="#{node.value}" id="n6" >
+ <f:ajax event="valueChange" render="n6_cb" listener="#{clientConversationBean.onInputFocus(node)}" />
</h:inputText>
- <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" rerender="richTree" rendered="#{node.removable}">
- Remove
- </a4j:commandLink>
+ <a4j:commandLink action="#{clientConversationBean.removeChild(node)}" render="rt" rendered="#{node.removable}">Remove</a4j:commandLink>
</rich:treeNode>
</rich:tree>
</a4j:outputPanel>
11 years, 6 months
wise SVN: r572 - webgui/trunk/src/main/webapp.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 08:36:16 -0400 (Wed, 03 Jul 2013)
New Revision: 572
Modified:
webgui/trunk/src/main/webapp/step4.xhtml
Log:
[WSIE-205] Fix
Modified: webgui/trunk/src/main/webapp/step4.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step4.xhtml 2013-07-03 12:34:50 UTC (rev 571)
+++ webgui/trunk/src/main/webapp/step4.xhtml 2013-07-03 12:36:16 UTC (rev 572)
@@ -8,7 +8,7 @@
xmlns:c="http://java.sun.com/jsp/jstl/core"
xmlns:rich="http://richfaces.org/rich">
- <rich:panel header="Response3" rendered="#{clientConversationBean.responseAvailable}">
+ <rich:panel header="Response" rendered="#{clientConversationBean.responseAvailable}">
<div>
<i>#{clientConversationBean.currentOperationFullName}</i>
</div>
11 years, 6 months
wise SVN: r571 - in webgui/trunk/src/main/webapp: WEB-INF and 1 other directory.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 08:34:50 -0400 (Wed, 03 Jul 2013)
New Revision: 571
Modified:
webgui/trunk/src/main/webapp/WEB-INF/web.xml
webgui/trunk/src/main/webapp/step3.xhtml
webgui/trunk/src/main/webapp/step4.xhtml
Log:
[WISE-205] Set javax.faces.PROJECT_STAGE = Production, reduce some ajax message payload by tuning a4j regions
Modified: webgui/trunk/src/main/webapp/WEB-INF/web.xml
===================================================================
--- webgui/trunk/src/main/webapp/WEB-INF/web.xml 2013-07-03 08:42:49 UTC (rev 570)
+++ webgui/trunk/src/main/webapp/WEB-INF/web.xml 2013-07-03 12:34:50 UTC (rev 571)
@@ -12,11 +12,19 @@
<web-app version="3.0" xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
+ <context-param>
+ <param-name>org.richfaces.queue.enabled</param-name>
+ <param-value>true</param-value>
+ </context-param>
+ <context-param>
+ <param-name>org.richfaces.resourceOptimization.enabled</param-name>
+ <param-value>true</param-value>
+ </context-param>
<!-- Set the PROJECT_STAGE to 'Development' to receive constructive error messages during development.
Change the PROJECT_STAGE to 'Production' when putting the application into production -->
<context-param>
<param-name>javax.faces.PROJECT_STAGE</param-name>
- <param-value>Development</param-value>
+ <param-value>Production</param-value>
</context-param>
<!-- add a welcome-file-list entry to allow JSF pages to be used as welcome files -->
Modified: webgui/trunk/src/main/webapp/step3.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step3.xhtml 2013-07-03 08:42:49 UTC (rev 570)
+++ webgui/trunk/src/main/webapp/step3.xhtml 2013-07-03 12:34:50 UTC (rev 571)
@@ -9,12 +9,11 @@
xmlns:rich="http://richfaces.org/rich">
<rich:panel header="Request">
- <a4j:outputPanel id="parInputPanel" ajaxRendered="true"> <!-- The tree must live within a ajaxRendered outputPanel in order for properly refreshing! -->
- <div>
- <i>#{clientConversationBean.currentOperationFullName}</i>
- </div>
- <rich:tree id="richTree" var="node" value="#{clientConversationBean.inputTree}" nodeType="#{node.kind}"
- switchType="ajax" binding="#{clientConversationBean.inTree}">
+ <div>
+ <i>#{clientConversationBean.currentOperationFullName}</i>
+ </div>
+ <a4j:outputPanel id="parInputPanel" ajaxRendered="true"> <!-- The tree must live within a ajaxRendered outputPanel in order for properly refreshing! -->
+ <rich:tree id="richTree" var="node" value="#{clientConversationBean.inputTree}" nodeType="#{node.kind}" binding="#{clientConversationBean.inTree}">
<rich:treeNode type="simple">
<h:outputText value="#{node.type} : #{node.name} " />
<h:selectBooleanCheckbox id="foo-chk" value="#{node.notNil}" disabled="#{node.notNillable}" >
@@ -133,32 +132,30 @@
</a4j:commandLink>
</rich:treeNode>
</rich:tree>
- <br />
- <rich:panel>
- <h:panelGrid columns="2">
- <h:outputLabel value="Override target address:" for="invUrlInput"/>
- <h:inputText id="invUrlInput" value="#{clientConversationBean.invocationUrl}" />
- <h:outputLabel value="User:" for="invUser"/>
- <h:inputText id="invUser" value="#{clientConversationBean.invocationUser}" />
- <h:outputLabel value="Password:" for="invPwd"/>
- <h:inputSecret id="invPwd" value="#{clientConversationBean.invocationPwd}" redisplay="true" />
- </h:panelGrid>
- </rich:panel>
-
- <rich:popupPanel id="popupPreview" modal="true" resizeable="true" onmaskclick="#{rich:component('popupPreview')}.hide()" minWidth="550" minHeight="450">
- <f:facet name="header">
- <h:outputText value="SOAP request message preview" />
- </f:facet>
- <f:facet name="controls">
- <h:outputLink value="#" onclick="#{rich:component('popupPreview')}.hide(); return false;">X</h:outputLink>
- </f:facet>
- <p>Below is a preview of the SOAP message that will be generated upon invocation. The actual message going on the wire might be different
- depending on the selected service policy (security, addressing, reliable-messaging, etc.), if any.</p>
- <div align="center"><h:inputTextarea value="#{clientConversationBean.requestPreview}" cols="80" rows="20" readonly="true" styleClass="preformatted"/></div>
- </rich:popupPanel>
+ </a4j:outputPanel>
+ <br />
+ <rich:panel>
+ <h:panelGrid columns="2">
+ <h:outputLabel value="Override target address:" for="invUrlInput"/>
+ <h:inputText id="invUrlInput" value="#{clientConversationBean.invocationUrl}" />
+ <h:outputLabel value="User:" for="invUser"/>
+ <h:inputText id="invUser" value="#{clientConversationBean.invocationUser}" />
+ <h:outputLabel value="Password:" for="invPwd"/>
+ <h:inputSecret id="invPwd" value="#{clientConversationBean.invocationPwd}" redisplay="true" />
+ </h:panelGrid>
+ </rich:panel>
+ <rich:popupPanel id="popupPreview" modal="true" resizeable="true" onmaskclick="#{rich:component('popupPreview')}.hide()" minWidth="550" minHeight="450">
+ <f:facet name="header">
+ <h:outputText value="SOAP request message preview" />
+ </f:facet>
+ <f:facet name="controls">
+ <h:outputLink value="#" onclick="#{rich:component('popupPreview')}.hide(); return false;">X</h:outputLink>
+ </f:facet>
+ <p>Below is a preview of the SOAP message that will be generated upon invocation. The actual message going on the wire might be different
+ depending on the selected service policy (security, addressing, reliable-messaging, etc.), if any.</p>
+ <div align="center"><h:inputTextarea value="#{clientConversationBean.requestPreview}" cols="80" rows="20" readonly="true" styleClass="preformatted"/></div>
+ </rich:popupPanel>
- </a4j:outputPanel>
-
</rich:panel>
<rich:panel header="Error" rendered="#{not empty clientConversationBean.error}">
<h:outputText value="#{clientConversationBean.error}" />
Modified: webgui/trunk/src/main/webapp/step4.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step4.xhtml 2013-07-03 08:42:49 UTC (rev 570)
+++ webgui/trunk/src/main/webapp/step4.xhtml 2013-07-03 12:34:50 UTC (rev 571)
@@ -8,12 +8,11 @@
xmlns:c="http://java.sun.com/jsp/jstl/core"
xmlns:rich="http://richfaces.org/rich">
- <rich:panel header="Response" rendered="#{clientConversationBean.responseAvailable}">
- <a4j:outputPanel id="parOutputPanel" ajaxRendered="true"> <!-- The tree must live within a ajaxRendered outputPanel in order for properly refreshing! -->
- <div>
- <i>#{clientConversationBean.currentOperationFullName}</i>
- </div>
- <rich:tree id="richResTree" var="node" value="#{clientConversationBean.outputTree}" nodeType="#{node.kind}" switchType="ajax">
+ <rich:panel header="Response3" rendered="#{clientConversationBean.responseAvailable}">
+ <div>
+ <i>#{clientConversationBean.currentOperationFullName}</i>
+ </div>
+ <rich:tree id="richResTree" var="node" value="#{clientConversationBean.outputTree}" nodeType="#{node.kind}" selectionType="client" toggleType="client">
<rich:treeNode type="simple">
<h:outputText value="#{node.type} : #{node.name} = #{node.shortValue}"
rendered="#{node.notNil}" />
@@ -53,7 +52,8 @@
rendered="#{node.notNil}" />
<h:outputText value="#{node.type} : #{node.name} = ***NIL***" rendered="#{node.nil}" />
</rich:treeNode>
- </rich:tree>
+ </rich:tree>
+ <a4j:region>
<rich:popupPanel id="popupView" modal="true" resizeable="true" onmaskclick="#{rich:component('popupView')}.hide()" minWidth="550" minHeight="450">
<f:facet name="header">
<h:outputText value="SOAP response message" />
@@ -64,7 +64,7 @@
<p>Below is the captured SOAP response message:</p>
<div align="center"><h:inputTextarea value="#{clientConversationBean.responseMessage}" cols="80" rows="20" readonly="true" styleClass="preformatted"/></div>
</rich:popupPanel>
- </a4j:outputPanel>
+ </a4j:region>
</rich:panel>
<rich:panel header="Error" rendered="#{not empty clientConversationBean.error}">
<h:outputText value="#{clientConversationBean.error}" />
11 years, 6 months
wise SVN: r570 - webgui/trunk/src/main/webapp.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 04:42:49 -0400 (Wed, 03 Jul 2013)
New Revision: 570
Modified:
webgui/trunk/src/main/webapp/step3.xhtml
webgui/trunk/src/main/webapp/step4.xhtml
Log:
[WISE-203] Add wait status panel on request message preview and response message view
Modified: webgui/trunk/src/main/webapp/step3.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step3.xhtml 2013-07-03 07:57:36 UTC (rev 569)
+++ webgui/trunk/src/main/webapp/step3.xhtml 2013-07-03 08:42:49 UTC (rev 570)
@@ -171,7 +171,7 @@
<rich:toggleControl targetItem="@next" event="click" />
</a4j:commandButton>
<a4j:commandButton value="Preview message" render="popupPreview" rendered="#{empty clientConversationBean.error}" action="#{clientConversationBean.generateRequestPreview}" style="float:right"
- id="previewButton" oncomplete="#{rich:component('popupPreview')}.show();">
+ id="previewButton" oncomplete="#{rich:component('popupPreview')}.show();" status="waitStatus">
</a4j:commandButton>
</div>
Modified: webgui/trunk/src/main/webapp/step4.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step4.xhtml 2013-07-03 07:57:36 UTC (rev 569)
+++ webgui/trunk/src/main/webapp/step4.xhtml 2013-07-03 08:42:49 UTC (rev 570)
@@ -75,7 +75,7 @@
<rich:toggleControl targetItem="@prev" event="click" />
</a4j:commandButton>
<a4j:commandButton value="View message" render="popupView" style="float:right" rendered="#{clientConversationBean.responseAvailable}"
- id="viewMessageButton" oncomplete="#{rich:component('popupView')}.show();">
+ id="viewMessageButton" oncomplete="#{rich:component('popupView')}.show();" status="waitStatus">
</a4j:commandButton>
</div>
11 years, 6 months
wise SVN: r569 - in webgui/trunk/src/main: webapp and 1 other directory.
by wise-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2013-07-03 03:57:36 -0400 (Wed, 03 Jul 2013)
New Revision: 569
Modified:
webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java
webgui/trunk/src/main/java/org/jboss/wise/gui/ClientHelper.java
webgui/trunk/src/main/webapp/step2.xhtml
webgui/trunk/src/main/webapp/step3.xhtml
Log:
[WSIE-203] Further improvements
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java 2013-07-02 14:31:07 UTC (rev 568)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/ClientConversationBean.java 2013-07-03 07:57:36 UTC (rev 569)
@@ -119,6 +119,7 @@
responseMessage = null;
error = null;
try {
+ currentOperationFullName = ClientHelper.getOperationFullName(currentOperation, services);
inputTree = ClientHelper.convertOperationParametersToGui(ClientHelper.getWSMethod(currentOperation, client), client);
} catch (Exception e) {
error = ClientHelper.toErrorMessage(e);
@@ -335,7 +336,6 @@
public void setCurrentOperation(String currentOperation) {
this.currentOperation = currentOperation;
- this.currentOperationFullName = ClientHelper.getOperationFullName(currentOperation, services);
}
public UITree getInTree() {
Modified: webgui/trunk/src/main/java/org/jboss/wise/gui/ClientHelper.java
===================================================================
--- webgui/trunk/src/main/java/org/jboss/wise/gui/ClientHelper.java 2013-07-02 14:31:07 UTC (rev 568)
+++ webgui/trunk/src/main/java/org/jboss/wise/gui/ClientHelper.java 2013-07-03 07:57:36 UTC (rev 569)
@@ -137,27 +137,23 @@
}
public static String getFirstGuiOperation(List<Service> services) {
- if (services == null || services.isEmpty()) {
+ if (services == null) {
return null;
}
- Service s = services.iterator().next();
- List<Port> ports = s.getPorts();
- if (ports == null || ports.isEmpty()) {
- return null;
+ for (Service s : services) {
+ for (Port p : s.getPorts()) {
+ for (Operation o : p.getOperations()) {
+ StringBuilder sb = new StringBuilder();
+ sb.append(s.getName());
+ sb.append(";");
+ sb.append(p.getName());
+ sb.append(";");
+ sb.append(o.getName());
+ return sb.toString();
+ }
+ }
}
- Port p = ports.iterator().next();
- List<Operation> operations = p.getOperations();
- if (operations == null || operations.isEmpty()) {
- return null;
- }
- Operation o = operations.iterator().next();
- StringBuilder sb = new StringBuilder();
- sb.append(s.getName());
- sb.append(";");
- sb.append(p.getName());
- sb.append(";");
- sb.append(o.getName());
- return sb.toString();
+ return null;
}
public static String getOperationFullName(String currentGuiOperation, List<Service> services) {
Modified: webgui/trunk/src/main/webapp/step2.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step2.xhtml 2013-07-02 14:31:07 UTC (rev 568)
+++ webgui/trunk/src/main/webapp/step2.xhtml 2013-07-03 07:57:36 UTC (rev 569)
@@ -25,11 +25,14 @@
</c:forEach>
</rich:panelMenu>
</rich:panel>
+ <rich:panel header="Error" rendered="#{not empty clientConversationBean.error}">
+ <h:outputText value="#{clientConversationBean.error}" />
+ </rich:panel>
<div class="navPanel" style="width: 100%;">
<a4j:commandButton value="<< Back" style="float:left">
<rich:toggleControl targetItem="@prev" event="click" />
</a4j:commandButton>
- <a4j:commandButton value="Select >>" style="float:right" rendered="#{not empty clientConversationBean.currentOperation}">
+ <a4j:commandButton value="Select >>" style="float:right" rendered="#{empty clientConversationBean.error}">
<rich:toggleControl targetItem="@next" event="click" />
</a4j:commandButton>
</div>
Modified: webgui/trunk/src/main/webapp/step3.xhtml
===================================================================
--- webgui/trunk/src/main/webapp/step3.xhtml 2013-07-02 14:31:07 UTC (rev 568)
+++ webgui/trunk/src/main/webapp/step3.xhtml 2013-07-03 07:57:36 UTC (rev 569)
@@ -160,14 +160,17 @@
</a4j:outputPanel>
</rich:panel>
+ <rich:panel header="Error" rendered="#{not empty clientConversationBean.error}">
+ <h:outputText value="#{clientConversationBean.error}" />
+ </rich:panel>
<div class="navPanel" style="width: 100%;">
<a4j:commandButton value="<< Back" style="float:left">
<rich:toggleControl targetItem="@prev" event="click" />
</a4j:commandButton>
- <a4j:commandButton value="Invoke >>" style="float:right">
+ <a4j:commandButton value="Invoke >>" style="float:right" rendered="#{empty clientConversationBean.error}">
<rich:toggleControl targetItem="@next" event="click" />
</a4j:commandButton>
- <a4j:commandButton value="Preview message" render="popupPreview" action="#{clientConversationBean.generateRequestPreview}" style="float:right"
+ <a4j:commandButton value="Preview message" render="popupPreview" rendered="#{empty clientConversationBean.error}" action="#{clientConversationBean.generateRequestPreview}" style="float:right"
id="previewButton" oncomplete="#{rich:component('popupPreview')}.show();">
</a4j:commandButton>
</div>
11 years, 6 months