JBoss Tools SVN: r35179 - in trunk/ws/docs: soap_reference/en-US and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: irooskov(a)redhat.com
Date: 2011-09-29 17:52:55 -0400 (Thu, 29 Sep 2011)
New Revision: 35179
Modified:
trunk/ws/docs/restful_reference/en-US/proc-jbt-web_service_test_view.xml
trunk/ws/docs/soap_reference/en-US/proc-jbt-web_service_test_view.xml
Log:
updated with new changes
Modified: trunk/ws/docs/restful_reference/en-US/proc-jbt-web_service_test_view.xml
===================================================================
--- trunk/ws/docs/restful_reference/en-US/proc-jbt-web_service_test_view.xml 2011-09-29 21:39:28 UTC (rev 35178)
+++ trunk/ws/docs/restful_reference/en-US/proc-jbt-web_service_test_view.xml 2011-09-29 21:52:55 UTC (rev 35179)
@@ -80,7 +80,7 @@
</row>
<row>
<entry>Combo box</entry>
- <entry>Select the type of service to test. The options are <guilabel>JAX-WS</guilabel> or any other option to test a <guilabel>JAX-RS</guilabel> service using HTTP request methods (<methodname>PUT</methodname>, <methodname>GET</methodname>, <methodname>POST</methodname>, <methodname>DELETE</methodname> or <methodname>OPTIONS</methodname>).For RESTful web services use the <guilabel>JAX-RS</guilabel> service option.</entry>
+ <entry>Select the type of service to test. The options are <guilabel>JAX-WS</guilabel> or any other option to test a <guilabel>JAX-RS</guilabel> service using HTTP request methods (<methodname>PUT</methodname>, <methodname>GET</methodname>, <methodname>POST</methodname>, <methodname>DELETE</methodname> or <methodname>OPTIONS</methodname>).</entry>
</row>
<row>
<entry>Toolbar button - Get From WSDL</entry>
@@ -90,7 +90,7 @@
</row>
<row>
<entry>Toolbar button - Invoke</entry>
- <entry>Once the WSDL file has been selected, the service can be invoked by clicking this button. Reponse details will be displayed in the <guilabel>Response Details</guilabel> panel.</entry>
+ <entry>Once the WSDL file has been selected, the service can be invoked by clicking this button. Response details will be displayed in the <guilabel>Response Details</guilabel> panel.</entry>
</row>
</tbody>
</tgroup>
@@ -122,7 +122,7 @@
</row>
<row>
<entry>Body</entry>
- <entry>Enter the input for the JAX-RS service invocations into this text box.</entry>
+ <entry>Enter the JAX-WS SOAP request messages or input for JAX-RS service invocations in this text box.</entry>
</row>
</tbody>
</tgroup>
@@ -146,7 +146,7 @@
</row>
<row>
<entry>Response body</entry>
- <entry>The JAX-RS response bodies will be displayed in this box. The raw text returned form the web service invocation can be displayed by clicking the <guibutton>Show Raw</guibutton> button. The output will be embedded in a html browser by clicking the <guibutton>Show in Browser</guibutton> button. The output can alternatively be displayed in the Eclipse editor as xml or raw text (depending on the response content type) by clicking the <guibutton>Show in Editor</guibutton> button.</entry>
+ <entry>The JAX-WS and JAX-RS response bodies will be displayed in this box. The raw text returned from the web service invocation can be displayed by clicking the <guibutton>Show Raw</guibutton> button. The output will be embedded in a html browser by clicking the <guibutton>Show in Browser</guibutton> button. The output can alternatively be displayed in the Eclipse editor as xml or raw text (depending on the response content type) by clicking the <guibutton>Show in Editor</guibutton> button.</entry>
</row>
<row>
<entry>Parameters</entry>
@@ -154,7 +154,7 @@
</row>
<row>
<entry>Body</entry>
- <entry>Enter the input for the JAX-RS service invocations into this text box.</entry>
+ <entry>Enter JAX-WS SOAP request messages and input for JAX-RS service invocations in this text box.</entry>
</row>
</tbody>
</tgroup>
Modified: trunk/ws/docs/soap_reference/en-US/proc-jbt-web_service_test_view.xml
===================================================================
--- trunk/ws/docs/soap_reference/en-US/proc-jbt-web_service_test_view.xml 2011-09-29 21:39:28 UTC (rev 35178)
+++ trunk/ws/docs/soap_reference/en-US/proc-jbt-web_service_test_view.xml 2011-09-29 21:52:55 UTC (rev 35179)
@@ -90,7 +90,7 @@
</row>
<row>
<entry>Toolbar button - Invoke</entry>
- <entry>Once the WSDL file has been selected, the service can be invoked by clicking this button. Reponse details will be displayed in the <guilabel>Response Details</guilabel> panel.</entry>
+ <entry>Once the WSDL file has been selected, the service can be invoked by clicking this button. Response details will be displayed in the <guilabel>Response Details</guilabel> panel.</entry>
</row>
</tbody>
</tgroup>
@@ -146,7 +146,7 @@
</row>
<row>
<entry>Response body</entry>
- <entry>The JAX-WS and JAX-RS response bodies will be displayed in this box. The raw text returned form the web service invocation can be displayed by clicking the <guibutton>Show Raw</guibutton> button. The output will be embedded in a html browser by clicking the <guibutton>Show in Browser</guibutton> button. The output can alternatively be displayed in the Eclipse editor as xml or raw text (depending on the response content type) by clicking the <guibutton>Show in Editor</guibutton> button.</entry>
+ <entry>The JAX-WS and JAX-RS response bodies will be displayed in this box. The raw text returned from the web service invocation can be displayed by clicking the <guibutton>Show Raw</guibutton> button. The output will be embedded in a html browser by clicking the <guibutton>Show in Browser</guibutton> button. The output can alternatively be displayed in the Eclipse editor as xml or raw text (depending on the response content type) by clicking the <guibutton>Show in Editor</guibutton> button.</entry>
</row>
<row>
<entry>Parameters</entry>
12 years, 7 months
JBoss Tools SVN: r35178 - trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-09-29 17:39:28 -0400 (Thu, 29 Sep 2011)
New Revision: 35178
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard/OpenCDINamedBeanDialog.java
Log:
JBIDE-9800
https://issues.jboss.org/browse/JBIDE-9800
Implemented equals and hashCode for CDINamedBeanWrapper so that each item would appear only once.
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard/OpenCDINamedBeanDialog.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard/OpenCDINamedBeanDialog.java 2011-09-29 21:33:13 UTC (rev 35177)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard/OpenCDINamedBeanDialog.java 2011-09-29 21:39:28 UTC (rev 35178)
@@ -459,6 +459,19 @@
}
return bean;
}
+
+ public boolean equals(Object obj) {
+ if(!(obj instanceof CDINamedBeanWrapper)) {
+ return false;
+ }
+ String s1 = new CDINamedBeanLabelProvider().getText(this);
+ String s2 = new CDINamedBeanLabelProvider().getText(obj);
+ return s1.equals(s2);
+ }
+
+ public int hashCode() {
+ return new CDINamedBeanLabelProvider().getText(this).hashCode();
+ }
}
public static void validateHistory(ICDIProject cdiProject) {
12 years, 7 months
JBoss Tools SVN: r35177 - trunk/cdi/tests/org.jboss.tools.cdi.seam.core.test.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2011-09-29 17:33:13 -0400 (Thu, 29 Sep 2011)
New Revision: 35177
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.seam.core.test/pom.xml
Log:
fix for test coverage report in org.jboss.tools.cdi.seam.core.test, bundles to instrument are configured now
Modified: trunk/cdi/tests/org.jboss.tools.cdi.seam.core.test/pom.xml
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.seam.core.test/pom.xml 2011-09-29 21:24:44 UTC (rev 35176)
+++ trunk/cdi/tests/org.jboss.tools.cdi.seam.core.test/pom.xml 2011-09-29 21:33:13 UTC (rev 35177)
@@ -9,7 +9,9 @@
<groupId>org.jboss.tools.cdi.tests</groupId>
<artifactId>org.jboss.tools.cdi.seam.core.test</artifactId>
<packaging>eclipse-test-plugin</packaging>
-
+ <properties>
+ <emma.instrument.bundles>org.jboss.tools.cdi.seam.core,org.jboss.tools.cdi.core,org.jboss.tools.cdi.xml</emma.instrument.bundles>
+ </properties>
<build>
<plugins>
<plugin>
12 years, 7 months
JBoss Tools SVN: r35176 - trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-09-29 17:24:44 -0400 (Thu, 29 Sep 2011)
New Revision: 35176
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard/OpenCDINamedBeanDialog.java
Log:
JBIDE-9800
https://issues.jboss.org/browse/JBIDE-9800
Created util method for string presentation of IBean
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard/OpenCDINamedBeanDialog.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard/OpenCDINamedBeanDialog.java 2011-09-29 21:23:50 UTC (rev 35175)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/wizard/OpenCDINamedBeanDialog.java 2011-09-29 21:24:44 UTC (rev 35176)
@@ -49,6 +49,7 @@
import org.jboss.tools.cdi.core.CDIImages;
import org.jboss.tools.cdi.core.IBean;
import org.jboss.tools.cdi.core.ICDIProject;
+import org.jboss.tools.cdi.core.util.BeanPresentationUtil;
import org.jboss.tools.cdi.internal.core.event.CDIProjectChangeEvent;
import org.jboss.tools.cdi.internal.core.event.ICDIProjectChangeListener;
import org.jboss.tools.cdi.ui.CDIUIMessages;
@@ -67,8 +68,6 @@
private static final String PROJECT_NAME = "ProjectName"; //$NON-NLS-1$
private static final String BEAN_NAME = "BeanName"; //$NON-NLS-1$
private static final String DELETED = "Deleted"; //$NON-NLS-1$
- private static final String SEPARATOR = " - "; //$NON-NLS-1$
- private static final String DOT = "."; //$NON-NLS-1$
private static final String YES = "yes"; //$NON-NLS-1$
private static final String NO = "no"; //$NON-NLS-1$
@@ -389,40 +388,17 @@
}
public StyledString getStyledText(Object element) {
- StyledString styledString = new StyledString();
-
+ StyledString styledString = new StyledString();
if (element instanceof CDINamedBeanWrapper) {
CDINamedBeanWrapper beanWrapper = (CDINamedBeanWrapper) element;
-
+ //1. bean name
styledString.append(beanWrapper.getBeanName(), NAME_STYLE);
-
+ //2. bean location
IBean b = beanWrapper.getBean();
- if (b == null)
- return styledString;
-
- IType t = b.getBeanClass();
-
- IPath beanPath = t.getPackageFragment().getParent().getPath();//beanWrapper.getBean().getBeanClass().getPackageFragment().getParent().getPath()
- IPath beanProjectPath = b.getCDIProject().getNature().getProject().getFullPath();
- if (beanProjectPath != null && beanPath != null && beanProjectPath.isPrefixOf(beanPath)) {
- beanPath = beanPath.makeRelative();
+ if (b != null) {
+ String beanLocation = BeanPresentationUtil.getBeanLocation(b, true);
+ styledString.append(beanLocation, BEAN_PATH_STYLE);
}
-
- String elementName = b.getElementName();
- String packageName = t.getPackageFragment().getElementName();
-
- if (elementName != null) {
- styledString.append(SEPARATOR, QUALIFIED_NAME_STYLE);
- if (packageName != null && packageName.length() > 0) {
- styledString.append(packageName, QUALIFIED_NAME_STYLE);
- styledString.append(DOT, QUALIFIED_NAME_STYLE);
- }
- styledString.append(elementName, QUALIFIED_NAME_STYLE);
- }
- if (beanPath != null) {
- styledString.append(SEPARATOR, BEAN_PATH_STYLE);
- styledString.append(beanPath.toString(), BEAN_PATH_STYLE);
- }
}
return styledString;
}
12 years, 7 months
JBoss Tools SVN: r35175 - in trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext: hyperlink and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-09-29 17:23:50 -0400 (Thu, 29 Sep 2011)
New Revision: 35175
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/CDIExtensionsMessages.java
trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/hyperlink/AssignableBeansDialog.java
trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/hyperlink/InjectedPointHyperlink.java
trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/messages.properties
Log:
JBIDE-9800
https://issues.jboss.org/browse/JBIDE-9800
Created util method for string presentation of IBean
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/CDIExtensionsMessages.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/CDIExtensionsMessages.java 2011-09-29 21:21:32 UTC (rev 35174)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/CDIExtensionsMessages.java 2011-09-29 21:23:50 UTC (rev 35175)
@@ -21,13 +21,7 @@
public static String CDI_EXT_PLUGIN_NO_MESSAGE;
public static String CDI_INJECTED_POINT_HYPERLINK_OPEN_BEAN;
- public static String CDI_INJECTED_POINT_HYPERLINK_OPEN_DECORATOR;
- public static String CDI_INJECTED_POINT_HYPERLINK_OPEN_INTERCEPTOR;
- public static String CDI_INJECTED_POINT_HYPERLINK_OPEN_INJECTED_BEAN;
public static String CDI_INJECTED_POINT_HYPERLINK_OPEN_INJECT_BEAN;
- public static String CDI_INJECTED_POINT_HYPERLINK_OPEN_SELECTED_ALTERNATIVE;
- public static String CDI_INJECTED_POINT_HYPERLINK_OPEN_ALTERNATIVE;
- public static String CDI_INJECTED_POINT_HYPERLINK_OPEN_PRODUCER;
public static String CDI_INJECTED_POINT_HYPERLINK_SHOW_ALTERNATIVES;
public static String CDI_SHOW_ALL_ELIGIBLE_BEANS_TITLE;
public static String CDI_INJECTED_POINT_HYPERLINK_SHOW_ASSIGNABLE;
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/hyperlink/AssignableBeansDialog.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/hyperlink/AssignableBeansDialog.java 2011-09-29 21:21:32 UTC (rev 35174)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/hyperlink/AssignableBeansDialog.java 2011-09-29 21:23:50 UTC (rev 35175)
@@ -78,6 +78,7 @@
import org.jboss.tools.cdi.core.IProducerField;
import org.jboss.tools.cdi.core.IProducerMethod;
import org.jboss.tools.cdi.core.IQualifierDeclaration;
+import org.jboss.tools.cdi.core.util.BeanPresentationUtil;
import org.jboss.tools.cdi.internal.core.impl.AbstractBeanElement;
import org.jboss.tools.cdi.text.ext.CDIExtensionsPlugin;
import org.jboss.tools.cdi.text.ext.hyperlink.AssignableBeanFilters.Checkbox;
@@ -569,47 +570,18 @@
IBean b = (IBean)element;
Styler nameStyler = eligibleBeans.contains(b) ? ELIGIBLE_NAME : DISABLED;
StyledString sb = new StyledString();
- if(b.isAlternative()) {
- sb.append("@Alternative ", nameStyler);
+
+ //1.bean kind
+ String kind = BeanPresentationUtil.getBeanKind(b);
+ if(kind != null) {
+ sb.append(kind, nameStyler).append(' ');
}
- if(b.isAnnotationPresent(CDIConstants.DECORATOR_STEREOTYPE_TYPE_NAME)) {
- sb.append("@Decorator ", nameStyler);
- }
- if(b.isAnnotationPresent(CDIConstants.INTERCEPTOR_ANNOTATION_TYPE_NAME)) {
- sb.append("@Interceptor ", nameStyler);
- }
- if(b instanceof IProducer) {
- sb.append("@Produces ", nameStyler);
- sb.append(b.getBeanClass().getElementName(), nameStyler).append(".", nameStyler);
- if(b instanceof IProducerField) {
- sb.append(((IProducerField)b).getField().getElementName(), nameStyler);
- } else {
- sb.append(((IProducerMethod)b).getMethod().getElementName(), nameStyler)
- .append("()", nameStyler);
- }
- } else {
- String name = b.getBeanClass().getElementName();
- if(name.length() == 0) {
- name = b.getBeanClass().getFullyQualifiedName();
- }
- sb.append(name, nameStyler);
- }
+ //2. bean element name
+ sb.append(b.getElementName(), nameStyler);
+ //3. bean location
Styler qualifierStyler = eligibleBeans.contains(b) ? ELIGIBLE_QUALIFIER : DISABLED;
-
- AbstractBeanElement e = (AbstractBeanElement)b;
- ITextSourceReference origin = e.getDefinition().getOriginalDefinition();
- if(origin != null) {
- //If toString() is not enough, another interface should be introduced.
- sb.append(" - ", qualifierStyler).append(origin.toString(), qualifierStyler);
- } else {
- String pkg = b.getBeanClass().getPackageFragment().getElementName();
- sb.append(" - ", qualifierStyler).append(pkg, qualifierStyler).append(" - ", qualifierStyler);
- IPath path = b.getBeanClass().getPackageFragment().getParent().getPath();
- if(path != null) {
- sb.append(path.toString(), qualifierStyler);
- }
- }
+ sb.append(BeanPresentationUtil.getBeanLocation(b, false),qualifierStyler);
return sb;
}
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/hyperlink/InjectedPointHyperlink.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/hyperlink/InjectedPointHyperlink.java 2011-09-29 21:21:32 UTC (rev 35174)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/hyperlink/InjectedPointHyperlink.java 2011-09-29 21:23:50 UTC (rev 35175)
@@ -27,6 +27,7 @@
import org.jboss.tools.cdi.core.IInterceptor;
import org.jboss.tools.cdi.core.IProducerField;
import org.jboss.tools.cdi.core.IProducerMethod;
+import org.jboss.tools.cdi.core.util.BeanPresentationUtil;
import org.jboss.tools.cdi.text.ext.CDIExtensionsMessages;
import org.jboss.tools.cdi.text.ext.CDIExtensionsPlugin;
import org.jboss.tools.common.text.ext.hyperlink.AbstractHyperlink;
@@ -76,23 +77,19 @@
@Override
public String getHyperlinkText() {
- String text="";
+ String text = "";
if(bean != null){
if(first){
- text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_INJECT_BEAN+" ";
+ text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_INJECT_BEAN + " ";
}else{
- if(bean.isSelectedAlternative())
- text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_SELECTED_ALTERNATIVE+" ";
- else if(bean.isAlternative())
- text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_ALTERNATIVE+" ";
- else if(bean instanceof IProducerField || bean instanceof IProducerMethod)
- text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_PRODUCER+" ";
- else if(bean instanceof IDecorator)
- text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_DECORATOR+" ";
- else if(bean instanceof IInterceptor)
- text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_INTERCEPTOR+" ";
- else
- text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_BEAN+" ";
+ text = CDIExtensionsMessages.CDI_INJECTED_POINT_HYPERLINK_OPEN_BEAN + " ";
+ String kind = BeanPresentationUtil.getBeanKind(bean);
+ if(kind != null) {
+ if(bean.isSelectedAlternative()) {
+ text += "*";
+ }
+ text += kind + " ";
+ }
}
text += bean.getElementName();
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/messages.properties
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/messages.properties 2011-09-29 21:21:32 UTC (rev 35174)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.text.ext/src/org/jboss/tools/cdi/text/ext/messages.properties 2011-09-29 21:23:50 UTC (rev 35175)
@@ -1,12 +1,6 @@
CDI_EXT_PLUGIN_NO_MESSAGE=No message
CDI_INJECTED_POINT_HYPERLINK_OPEN_BEAN=Open
-CDI_INJECTED_POINT_HYPERLINK_OPEN_DECORATOR=Open @Decorator
-CDI_INJECTED_POINT_HYPERLINK_OPEN_INTERCEPTOR=Open @Interceptor
-CDI_INJECTED_POINT_HYPERLINK_OPEN_INJECTED_BEAN=Open Injected Bean
CDI_INJECTED_POINT_HYPERLINK_OPEN_INJECT_BEAN=Open @Inject Bean
-CDI_INJECTED_POINT_HYPERLINK_OPEN_SELECTED_ALTERNATIVE=Open *@Alternative
-CDI_INJECTED_POINT_HYPERLINK_OPEN_ALTERNATIVE=Open @Alternative
-CDI_INJECTED_POINT_HYPERLINK_OPEN_PRODUCER=Open @Produces
CDI_INJECTED_POINT_HYPERLINK_SHOW_ALTERNATIVES=Show All Eligible Beans...
CDI_SHOW_ALL_ELIGIBLE_BEANS_TITLE=All Eligible Beans
CDI_INJECTED_POINT_HYPERLINK_SHOW_ASSIGNABLE=Show All Assignable Beans...
12 years, 7 months
JBoss Tools SVN: r35174 - in trunk/cdi/plugins/org.jboss.tools.cdi.core: src/org/jboss/tools/cdi/core and 2 other directories.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-09-29 17:21:32 -0400 (Thu, 29 Sep 2011)
New Revision: 35174
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/util/
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/util/BeanPresentationUtil.java
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/META-INF/MANIFEST.MF
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/ClassBean.java
Log:
JBIDE-9800
https://issues.jboss.org/browse/JBIDE-9800
Created util method for string presentation of IBean
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/META-INF/MANIFEST.MF
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/META-INF/MANIFEST.MF 2011-09-29 20:02:51 UTC (rev 35173)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/META-INF/MANIFEST.MF 2011-09-29 21:21:32 UTC (rev 35174)
@@ -45,4 +45,5 @@
org.jboss.tools.cdi.internal.core.refactoring,
org.jboss.tools.cdi.internal.core.scanner,
org.jboss.tools.cdi.internal.core.scanner.lib,
+ org.jboss.tools.cdi.core.util,
org.jboss.tools.cdi.internal.core.validation
Added: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/util/BeanPresentationUtil.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/util/BeanPresentationUtil.java (rev 0)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/util/BeanPresentationUtil.java 2011-09-29 21:21:32 UTC (rev 35174)
@@ -0,0 +1,79 @@
+/*******************************************************************************
+ * Copyright (c) 2011 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.cdi.core.util;
+
+import org.eclipse.core.runtime.IPath;
+import org.jboss.tools.cdi.core.CDIConstants;
+import org.jboss.tools.cdi.core.IBean;
+import org.jboss.tools.cdi.core.IProducer;
+import org.jboss.tools.cdi.internal.core.impl.AbstractBeanElement;
+import org.jboss.tools.common.text.ITextSourceReference;
+
+/**
+ *
+ * @author Viacheslav Kabanovich
+ *
+ */
+public class BeanPresentationUtil {
+ public static final String SEPARATOR = " - "; //$NON-NLS-1$
+ public static final String DOT = "."; //$NON-NLS-1$
+
+ /**
+ * Returns "@Alternative", "@Decorator", "@Interceptor", "@Produces",
+ * or null, if nothing is relevant.
+ *
+ * @param bean
+ * @return
+ */
+ public static String getBeanKind(IBean bean) {
+ if(bean.isAlternative()) {
+ return "@Alternative";
+ }
+ if(bean.isAnnotationPresent(CDIConstants.DECORATOR_STEREOTYPE_TYPE_NAME)) {
+ return "@Decorator";
+ }
+ if(bean.isAnnotationPresent(CDIConstants.INTERCEPTOR_ANNOTATION_TYPE_NAME)) {
+ return "@Interceptor";
+ }
+ if(bean instanceof IProducer) {
+ return "@Produces";
+ }
+ return null;
+ }
+
+ public static String getBeanLocation(IBean bean, boolean includeElementName) {
+ StringBuilder sb = new StringBuilder();
+ sb.append(SEPARATOR);
+ AbstractBeanElement e = (AbstractBeanElement)bean;
+ ITextSourceReference origin = e.getDefinition().getOriginalDefinition();
+ if(origin != null) {
+ //If toString() is not enough, another interface should be introduced.
+ sb.append(origin.toString());
+ } else {
+ String pkg = bean.getBeanClass().getPackageFragment().getElementName();
+ if(pkg.length() > 0) {
+ sb.append(pkg);
+ }
+ if(includeElementName) {
+ if(pkg.length() > 0) {
+ sb.append(DOT);
+ }
+ sb.append(bean.getElementName());
+ }
+ sb.append(SEPARATOR);
+ IPath path = bean.getBeanClass().getPackageFragment().getParent().getPath();
+ sb.append(path.toString());
+ }
+
+ return sb.toString();
+ }
+
+}
Property changes on: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/util/BeanPresentationUtil.java
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/ClassBean.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/ClassBean.java 2011-09-29 20:02:51 UTC (rev 35173)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/ClassBean.java 2011-09-29 21:21:32 UTC (rev 35174)
@@ -591,7 +591,11 @@
*/
@Override
public String getElementName() {
- return this.getBeanClass().getElementName();
+ String result = getBeanClass().getElementName();
+ if(result.length() == 0) {
+ result = getBeanClass().getFullyQualifiedName();
+ }
+ return result;
}
/*
12 years, 7 months
JBoss Tools SVN: r35173 - workspace/Denny/esb-example-soa-p5.0.
by jbosstools-commits@lists.jboss.org
Author: bfitzpat
Date: 2011-09-29 16:02:51 -0400 (Thu, 29 Sep 2011)
New Revision: 35173
Modified:
workspace/Denny/esb-example-soa-p5.0/webservice_producer.zip
workspace/Denny/esb-example-soa-p5.0/webservice_producer_all.zip
workspace/Denny/esb-example-soa-p5.0/webservice_producer_client.zip
Log:
JBIDE-9771 - attempt #2 - updates to webservice_producer project example to make it work better on SOA-P 5.1 and 5.2
Modified: workspace/Denny/esb-example-soa-p5.0/webservice_producer.zip
===================================================================
(Binary files differ)
Modified: workspace/Denny/esb-example-soa-p5.0/webservice_producer_all.zip
===================================================================
(Binary files differ)
Modified: workspace/Denny/esb-example-soa-p5.0/webservice_producer_client.zip
===================================================================
(Binary files differ)
12 years, 7 months
JBoss Tools SVN: r35172 - workspace/Denny/esb-example-soa-p5.0.
by jbosstools-commits@lists.jboss.org
Author: bfitzpat
Date: 2011-09-29 15:48:32 -0400 (Thu, 29 Sep 2011)
New Revision: 35172
Modified:
workspace/Denny/esb-example-soa-p5.0/webservice_producer.zip
workspace/Denny/esb-example-soa-p5.0/webservice_producer_all.zip
workspace/Denny/esb-example-soa-p5.0/webservice_producer_client.zip
Log:
JBIDE-9771 - updates to webservice_producer project example to make it work better on SOA-P 5.1 and 5.2
Modified: workspace/Denny/esb-example-soa-p5.0/webservice_producer.zip
===================================================================
(Binary files differ)
Modified: workspace/Denny/esb-example-soa-p5.0/webservice_producer_all.zip
===================================================================
(Binary files differ)
Modified: workspace/Denny/esb-example-soa-p5.0/webservice_producer_client.zip
===================================================================
(Binary files differ)
12 years, 7 months
JBoss Tools SVN: r35171 - trunk/cdi/tests.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2011-09-29 15:21:13 -0400 (Thu, 29 Sep 2011)
New Revision: 35171
Modified:
trunk/cdi/tests/pom.xml
Log:
https://issues.jboss.org/browse/JBIDE-9798 new *-tests profiles in trunk/build/pom.xml are breaking Hudson jobs
moved profiles to cdi/tests/pom.xml
Modified: trunk/cdi/tests/pom.xml
===================================================================
--- trunk/cdi/tests/pom.xml 2011-09-29 19:16:19 UTC (rev 35170)
+++ trunk/cdi/tests/pom.xml 2011-09-29 19:21:13 UTC (rev 35171)
@@ -13,17 +13,52 @@
<emma.filter>org.jboss.tools.cdi*</emma.filter>
</properties>
<packaging>pom</packaging>
- <modules>
- <module>org.jboss.tools.cdi.bot.test</module>
- <module>org.jboss.tools.cdi.core.test</module>
- <module>org.jboss.tools.cdi.seam.config.core.test</module>
- <module>org.jboss.tools.cdi.seam.config.ui.test</module>
- <module>org.jboss.tools.cdi.seam.core.test</module>
- <module>org.jboss.tools.cdi.seam.faces.core.test</module>
- <module>org.jboss.tools.cdi.seam.solder.core.test</module>
- <module>org.jboss.tools.cdi.seam.text.ext.test</module>
- <module>org.jboss.tools.cdi.text.ext.test</module>
- <module>org.jboss.tools.cdi.ui.test</module>
- </modules>
+ <profiles>
+ <profile>
+ <id>cdi-tests-libs</id>
+ <activation>
+ <property>
+ <name>coverage</name>
+ </property>
+ </activation>
+ <modules>
+ <module>../../build/libs</module>
+ </modules>
+ </profile>
+
+ <profile>
+ <id>cdi-tests-deafult</id>
+ <activation>
+ <activeByDefault>true</activeByDefault>
+ <property>
+ <name>coverage</name>
+ </property>
+ </activation>
+ <modules>
+ <module>org.jboss.tools.cdi.bot.test</module>
+ <module>org.jboss.tools.cdi.core.test</module>
+ <module>org.jboss.tools.cdi.seam.config.core.test</module>
+ <module>org.jboss.tools.cdi.seam.config.ui.test</module>
+ <module>org.jboss.tools.cdi.seam.core.test</module>
+ <module>org.jboss.tools.cdi.seam.faces.core.test</module>
+ <module>org.jboss.tools.cdi.seam.solder.core.test</module>
+ <module>org.jboss.tools.cdi.seam.text.ext.test</module>
+ <module>org.jboss.tools.cdi.text.ext.test</module>
+ <module>org.jboss.tools.cdi.ui.test</module>
+ </modules>
+ </profile>
+
+ <profile>
+ <id>cdi-tests-coverage-report</id>
+ <activation>
+ <property>
+ <name>coverage</name>
+ </property>
+ </activation>
+ <modules>
+ <module>../../build/reports/emma-coverage</module>
+ </modules>
+ </profile>
+ </profiles>
</project>
12 years, 7 months
JBoss Tools SVN: r35170 - trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/handlers.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-09-29 15:16:19 -0400 (Thu, 29 Sep 2011)
New Revision: 35170
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/handlers/OpenCDINamedBeanHandler.java
Log:
JBIDE-9799
https://issues.jboss.org/browse/JBIDE-9799
Stwitched opening bean to IBean.open()
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/handlers/OpenCDINamedBeanHandler.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/handlers/OpenCDINamedBeanHandler.java 2011-09-29 18:17:32 UTC (rev 35169)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.ui/src/org/jboss/tools/cdi/ui/handlers/OpenCDINamedBeanHandler.java 2011-09-29 19:16:19 UTC (rev 35170)
@@ -13,38 +13,19 @@
import org.eclipse.core.commands.AbstractHandler;
import org.eclipse.core.commands.ExecutionEvent;
import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.resources.IFile;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility;
-import org.eclipse.jdt.internal.ui.javaeditor.JavaEditor;
import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.text.Region;
import org.eclipse.swt.widgets.Shell;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.PartInitException;
import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.dialogs.SelectionDialog;
-import org.eclipse.ui.ide.IDE;
-import org.jboss.tools.cdi.core.CDICorePlugin;
-import org.jboss.tools.cdi.core.IBean;
-import org.jboss.tools.cdi.internal.core.el.CdiElResolver;
import org.jboss.tools.cdi.ui.CDIUIMessages;
import org.jboss.tools.cdi.ui.wizard.OpenCDINamedBeanDialog;
import org.jboss.tools.cdi.ui.wizard.OpenCDINamedBeanDialog.CDINamedBeanWrapper;
-import org.jboss.tools.common.el.core.resolver.ELContextImpl;
-import org.jboss.tools.common.el.core.resolver.ELResolution;
-import org.jboss.tools.common.el.core.resolver.ELSegment;
-import org.jboss.tools.common.el.core.resolver.IOpenableReference;
-import org.jboss.tools.common.text.ITextSourceReference;
-import org.jboss.tools.common.text.ext.util.StructuredSelectionHelper;
/**
* Open CDI Named Bean Dialog Handler
*
* @author Victor V. Rubezhny
*/
-@SuppressWarnings("restriction")
public class OpenCDINamedBeanHandler extends AbstractHandler {
public Object execute(ExecutionEvent event) throws ExecutionException {
@@ -62,46 +43,7 @@
Object[] resultObjects = dialog.getResult();
for (Object resultObject : resultObjects) {
- CDINamedBeanWrapper wrapper= (CDINamedBeanWrapper) resultObject;
- IBean bean = wrapper.getBean();
- IProject project = bean.getCDIProject().getNature().getProject();
- ELContextImpl elContext = new ELContextImpl();
- elContext.setResource(project.getFile(".project"));
-
- CdiElResolver resolver = new CdiElResolver();
- ELResolution resolution = resolver.resolve(elContext, resolver.parseOperand("${" + bean.getName() + "}"), 0);
- if (resolution.isResolved() && resolution.getNumberOfResolvedSegments() == 1) {
- ELSegment segment = resolution.getLastSegment();
- if (segment.isResolved()) {
- IOpenableReference[] openables = segment.getOpenable();
-
- if(openables.length == 0 || !openables[0].open()) {
- ITextSourceReference ref = segment.getSourceReference();
- if (ref.getResource() instanceof IFile) {
- try {
- IWorkbenchPage page = PlatformUI.getWorkbench()
- .getActiveWorkbenchWindow().getActivePage();
- IEditorPart part = IDE.openEditor(page, (IFile)ref.getResource(), true);
- if (ref.getStartPosition() >=0 && ref.getLength() > 0) {
- if (part instanceof JavaEditor) {
- EditorUtility.revealInEditor(part,
- ref.getStartPosition(), ref.getLength());
- } else if (part != null) {
- // We have not to pass null argument here, because the following call will
- // perform select and reveal on active editor which is wrong in part == null
- //
- StructuredSelectionHelper.setSelectionAndRevealInActiveEditor(
- new Region(ref.getStartPosition(), ref.getLength()));
- }
- }
-
- } catch (PartInitException pie) {
- CDICorePlugin.getDefault().logError(pie);
- }
- }
- }
- }
- }
+ ((CDINamedBeanWrapper) resultObject).getBean().open();
}
return null;
12 years, 7 months