JBoss Tools SVN: r19291 - trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2009-12-15 18:23:19 -0500 (Tue, 15 Dec 2009)
New Revision: 19291
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java
Log:
JBIDE-4931 - added null check
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java 2009-12-15 23:02:56 UTC (rev 19290)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java 2009-12-15 23:23:19 UTC (rev 19291)
@@ -402,7 +402,8 @@
previewTreeViewer.getTree().setEnabled(true);
checkErrors();
}
- main.layout();
+ if( main != null )
+ main.layout();
}
});
}
15 years
JBoss Tools SVN: r19290 - trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2009-12-15 18:02:56 -0500 (Tue, 15 Dec 2009)
New Revision: 19290
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling/JMXPoller.java
Log:
JBIDE-5267 - timeout expire behaviour is to pass
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling/JMXPoller.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling/JMXPoller.java 2009-12-15 21:22:57 UTC (rev 19289)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/polling/JMXPoller.java 2009-12-15 23:02:56 UTC (rev 19290)
@@ -242,7 +242,7 @@
}
public int getTimeoutBehavior() {
- return TIMEOUT_BEHAVIOR_IGNORE;
+ return TIMEOUT_BEHAVIOR_SUCCEED;
}
private void log(IStatus s) {
15 years
JBoss Tools SVN: r19289 - trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2009-12-15 16:22:57 -0500 (Tue, 15 Dec 2009)
New Revision: 19289
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/JBossServer.java
Log:
JBIDE-5468 - change default server id to fix
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/JBossServer.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/JBossServer.java 2009-12-15 17:26:11 UTC (rev 19288)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/JBossServer.java 2009-12-15 21:22:57 UTC (rev 19289)
@@ -13,6 +13,7 @@
import java.io.File;
import java.net.MalformedURLException;
import java.net.URL;
+import java.util.Date;
import java.util.Map;
import org.eclipse.core.runtime.CoreException;
@@ -55,6 +56,7 @@
public void setDefaults(IProgressMonitor monitor) {
super.setDefaults(monitor);
setAttribute("auto-publish-time", 1); //$NON-NLS-1$
+ setAttribute("id", getAttribute("id", (String)"") + new Date().getTime()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
public void saveConfiguration(IProgressMonitor monitor) throws CoreException {
15 years
JBoss Tools SVN: r19288 - trunk/jsf/tests/org.jboss.tools.jsf.ui.bot.test/src/org/jboss/tools/jsf/ui/bot/test/smoke.
by jbosstools-commits@lists.jboss.org
Author: vpakan(a)redhat.com
Date: 2009-12-15 12:26:11 -0500 (Tue, 15 Dec 2009)
New Revision: 19288
Modified:
trunk/jsf/tests/org.jboss.tools.jsf.ui.bot.test/src/org/jboss/tools/jsf/ui/bot/test/smoke/AddRemoveJSFCapabilitiesTest.java
Log:
Do not hide popup menu when removing JSF Capabilities
Modified: trunk/jsf/tests/org.jboss.tools.jsf.ui.bot.test/src/org/jboss/tools/jsf/ui/bot/test/smoke/AddRemoveJSFCapabilitiesTest.java
===================================================================
--- trunk/jsf/tests/org.jboss.tools.jsf.ui.bot.test/src/org/jboss/tools/jsf/ui/bot/test/smoke/AddRemoveJSFCapabilitiesTest.java 2009-12-15 17:24:55 UTC (rev 19287)
+++ trunk/jsf/tests/org.jboss.tools.jsf.ui.bot.test/src/org/jboss/tools/jsf/ui/bot/test/smoke/AddRemoveJSFCapabilitiesTest.java 2009-12-15 17:26:11 UTC (rev 19288)
@@ -259,7 +259,7 @@
}
else{
new SWTBotMenu(ContextMenuHelper.getContextMenu(tree,
- WEB_PROJECT_JBT_JSF_POPUP_MENU, true)).menu(
+ WEB_PROJECT_JBT_JSF_POPUP_MENU, false)).menu(
JBT_REMOVE_JSF_CAPABILITIES_POPUP_MENU).click();
}
@@ -300,6 +300,8 @@
ContextMenuHelper.prepareTreeItemForContextMenu(tree,
tree.getTreeItem(JBT_TEST_PROJECT_NAME));
+ delay();
+
new SWTBotMenu(ContextMenuHelper.getContextMenu(tree,
PACKAGE_EXPLORER_JBT_POPUP_MENU, false)).menu(
ADD_JSF_CAPABILITIES_POPUP_MENU).click();
15 years, 1 month
JBoss Tools SVN: r19287 - trunk/jst/tests/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/types.
by jbosstools-commits@lists.jboss.org
Author: vpakan(a)redhat.com
Date: 2009-12-15 12:24:55 -0500 (Tue, 15 Dec 2009)
New Revision: 19287
Modified:
trunk/jst/tests/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/types/IDELabel.java
Log:
Fixed some labels lost during my unsuccessful commit.
Modified: trunk/jst/tests/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/types/IDELabel.java
===================================================================
--- trunk/jst/tests/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/types/IDELabel.java 2009-12-15 17:23:42 UTC (rev 19286)
+++ trunk/jst/tests/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/types/IDELabel.java 2009-12-15 17:24:55 UTC (rev 19287)
@@ -33,9 +33,9 @@
public static final String CLOSE = "Close";
public static final String OPEN = "Open";
public static final String RENAME = "Rename";
- public static final String JSP_FILE = "JSP...";
+ public static final String JSP_FILE = "JSP File";
public static final String PROPERTIES = "Properties";
- public static final String XHTML_FILE = "XHTML...";
+ public static final String XHTML_FILE = "XHTML File";
public static final String HELP = "Help";
public static final String ABOUT_JBOSS_DEVELOPER_STUDIO = "About JBoss Developer Studio";
public static final String HIBERNATE_CODE_GENERATION = "Hibernate Code Generation...";
@@ -66,9 +66,9 @@
// JBDS
public static final String NEW_HIBERNATE_MAPPING_FILE = "Create Hibernate XML Mapping file (hbm.xml)";
public static final String NEW = "New";
- public static final String SAVE_RESOURCE = "Save";
- public static final String RENAME_RESOURCE = "Rename";
- public static final String NEW_JSP_FILE = "New JSP File";
+ public static final String SAVE_RESOURCE = "Save Resource";
+ public static final String RENAME_RESOURCE = "Rename Resource";
+ public static final String NEW_JSP_FILE = "New File JSP";
public static final String PROPERTIES = "Properties";
public static final String NEW_XHTML_FILE = "New File XHTML";
public static final String IMPORT_JSF_PROJECT = "Import JSF Project";
@@ -164,7 +164,7 @@
public static class RenameResourceDialog {
- public static final String NEW_NAME = "Rename Resource";
+ public static final String NEW_NAME = "New name:";
}
@@ -180,7 +180,7 @@
public static class NewJSPFileDialog {
- public static final String NAME = "New File JSP";
+ public static final String NAME = "Name*";
public static final String TEMPLATE = "Template";
public static final String TEMPLATE_JSF_BASE_PAGE = "JSFBasePage";
@@ -194,7 +194,7 @@
public static final class NewXHTMLFileDialog {
- public static final String NAME = "New XHTML";
+ public static final String NAME = "Name*";
public static final String TEMPLATE = "Template";
public static final String TEMPLATE_FACELET_FORM_XHTML = "FaceletForm.xhtml";
15 years, 1 month
JBoss Tools SVN: r19286 - trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/smoke.
by jbosstools-commits@lists.jboss.org
Author: vpakan(a)redhat.com
Date: 2009-12-15 12:23:42 -0500 (Tue, 15 Dec 2009)
New Revision: 19286
Modified:
trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/smoke/CheckRenaming.java
Log:
Added bot.sleep() after Menu Rename is selected.
Modified: trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/smoke/CheckRenaming.java
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/smoke/CheckRenaming.java 2009-12-15 17:20:24 UTC (rev 19285)
+++ trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/smoke/CheckRenaming.java 2009-12-15 17:23:42 UTC (rev 19286)
@@ -60,6 +60,7 @@
bot.sleep(sleepTime);
// Rename file
new SWTBotMenu(ContextMenuHelper.getContextMenu(tree, IDELabel.Menu.RENAME, true)).click();
+ bot.sleep(sleepTime);
bot.shell(IDELabel.Shell.RENAME_RESOURCE).activate();
bot.textWithLabel(IDELabel.RenameResourceDialog.NEW_NAME)
.setText(newFileName);
15 years, 1 month
JBoss Tools SVN: r19285 - trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2009-12-15 12:20:24 -0500 (Tue, 15 Dec 2009)
New Revision: 19285
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/SessionBean.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-4943
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/SessionBean.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/SessionBean.java 2009-12-15 17:00:07 UTC (rev 19284)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/SessionBean.java 2009-12-15 17:20:24 UTC (rev 19285)
@@ -6,13 +6,12 @@
public class SessionBean extends ClassBean implements ISessionBean {
public IAnnotation getStatefulDeclaration() {
- // TODO Auto-generated method stub
- return null;
+ AnnotationDeclaration stateful = getDefinition().getStatefulAnnotation();
+ return stateful != null ? stateful.getDeclaration() : null;
}
public boolean isStateful() {
- // TODO Auto-generated method stub
- return false;
+ return getDefinition().getStatefulAnnotation() != null;
}
}
15 years, 1 month
JBoss Tools SVN: r19284 - trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/el/refactoring.
by jbosstools-commits@lists.jboss.org
Author: dazarov
Date: 2009-12-15 12:00:07 -0500 (Tue, 15 Dec 2009)
New Revision: 19284
Modified:
trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/el/refactoring/RefactorSearcher.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5289
Modified: trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/el/refactoring/RefactorSearcher.java
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/el/refactoring/RefactorSearcher.java 2009-12-15 16:56:03 UTC (rev 19283)
+++ trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/el/refactoring/RefactorSearcher.java 2009-12-15 17:00:07 UTC (rev 19284)
@@ -10,7 +10,6 @@
******************************************************************************/
package org.jboss.tools.jsf.el.refactoring;
-import java.io.IOException;
import java.util.List;
import java.util.StringTokenizer;
@@ -26,23 +25,8 @@
import org.eclipse.jdt.core.IMethod;
import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.search.IJavaSearchScope;
-import org.eclipse.jdt.internal.ui.text.FastJavaPartitionScanner;
-import org.eclipse.jdt.ui.text.IJavaPartitions;
-import org.eclipse.jface.text.BadLocationException;
-import org.eclipse.jface.text.Document;
-import org.eclipse.jface.text.rules.IToken;
-import org.eclipse.jface.text.rules.Token;
-import org.eclipse.wst.sse.core.StructuredModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IModelManager;
-import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
-import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocumentRegion;
-import org.eclipse.wst.sse.core.internal.provisional.text.ITextRegion;
-import org.eclipse.wst.sse.core.internal.provisional.text.ITextRegionList;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMDocument;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMModel;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMNode;
-import org.eclipse.wst.xml.core.internal.regions.DOMRegionContext;
import org.jboss.tools.common.el.core.ELCorePlugin;
+import org.jboss.tools.common.el.core.ELReference;
import org.jboss.tools.common.el.core.model.ELExpression;
import org.jboss.tools.common.el.core.model.ELInstance;
import org.jboss.tools.common.el.core.model.ELInvocationExpression;
@@ -52,6 +36,7 @@
import org.jboss.tools.common.el.core.parser.ELParser;
import org.jboss.tools.common.el.core.parser.ELParserUtil;
import org.jboss.tools.common.el.core.resolver.ELCompletionEngine;
+import org.jboss.tools.common.el.core.resolver.ELContext;
import org.jboss.tools.common.el.core.resolver.ELResolution;
import org.jboss.tools.common.el.core.resolver.ELResolver;
import org.jboss.tools.common.el.core.resolver.ELResolverFactoryManager;
@@ -61,8 +46,7 @@
import org.jboss.tools.common.el.core.resolver.Var;
import org.jboss.tools.common.model.util.EclipseResourceUtil;
import org.jboss.tools.common.util.FileUtil;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
+import org.jboss.tools.jst.web.kb.PageContextFactory;
public abstract class RefactorSearcher {
protected static final String JAVA_EXT = "java"; //$NON-NLS-1$
@@ -180,19 +164,14 @@
private void scanForJava(IFile file){
if(isFileCorrect(file)) {
- String content = null;
- if(content!= null) {
- String ext = file.getFileExtension();
- if(JAVA_EXT.equalsIgnoreCase(ext)){
- content = getFileContent(file);
- scanJava(file, content);
- } else if(XML_EXT.equalsIgnoreCase(ext)) {
- content = getFileContent(file);
- scanDOM(file, content);
- } else if(PROPERTIES_EXT.equalsIgnoreCase(ext)) {
- content = getFileContent(file);
- scanProperties(file, content);
- }
+ if(PROPERTIES_EXT.equalsIgnoreCase(file.getFileExtension())){
+ String content = getFileContent(file);
+ scanProperties(file, content);
+ } else if (JAVA_EXT.equalsIgnoreCase(file.getFileExtension())
+ || JSP_EXT.equalsIgnoreCase(file.getFileExtension())
+ || XHTML_EXT.equalsIgnoreCase(file.getFileExtension())
+ || XML_EXT.equalsIgnoreCase(file.getFileExtension())) {
+ searchInCach(file);
}
}
}
@@ -203,89 +182,56 @@
if(XML_EXT.equalsIgnoreCase(ext)
|| XHTML_EXT.equalsIgnoreCase(ext)
|| JSP_EXT.equalsIgnoreCase(ext)) {
- String content = getFileContent(file);
- scanDOM(file, content);
+ searchInCach(file);
}
}
}
- private void scanJava(IFile file, String content){
- try {
- FastJavaPartitionScanner scaner = new FastJavaPartitionScanner();
- Document document = new Document(content);
- scaner.setRange(document, 0, document.getLength());
- IToken token = scaner.nextToken();
- while(token!=null && token!=Token.EOF) {
- if(IJavaPartitions.JAVA_STRING.equals(token.getData())) {
- int length = scaner.getTokenLength();
- int offset = scaner.getTokenOffset();
- String value = document.get(offset, length);
- if(value.indexOf('{')>-1) {
- scanString(file, value, offset);
+ private void searchInCach(IFile file){
+ ELContext context = PageContextFactory.createPageContext(file);
+
+ if(context == null)
+ return;
+
+ ELReference[] references = context.getELReferences();
+ ELResolver[] resolvers = context.getElResolvers();
+
+ if(javaElement != null){
+ for(ELReference reference : references){
+ for(ELExpression operand : reference.getEl()){
+ int offset = operand.getStartPosition();
+ for (ELResolver resolver : resolvers) {
+ if (!(resolver instanceof ELCompletionEngine))
+ continue;
+
+ ELResolution resolution = resolver.resolve(context, operand, offset);
+
+ List<ELSegment> segments = resolution.findSegmentsByJavaElement(javaElement);
+
+ for(ELSegment segment : segments){
+ match(file, offset+segment.getSourceReference().getStartPosition(), segment.getSourceReference().getLength());
+ }
}
}
- token = scaner.nextToken();
}
- } catch (BadLocationException e) {
- ELCorePlugin.getDefault().logError(e);
- }
- }
-
-// private void searchInCach(IFile file){
-// //ELResolver[] resolvers = PageContextFactory.createPageContext(file).getElResolvers();
-//
-// }
-
- private void scanDOM(IFile file, String content){
- IModelManager manager = StructuredModelManager.getModelManager();
- if(manager != null) {
- IStructuredModel model = null;
- try {
- model = manager.getModelForRead(file);
- if (model instanceof IDOMModel) {
- IDOMModel domModel = (IDOMModel) model;
- IDOMDocument document = domModel.getDocument();
- scanChildNodes(file, document);
+ }else{
+ for(ELReference reference : references){
+ int offset = reference.getStartPosition();
+ ELExpression[] expressions = reference.getEl();
+ for(ELExpression operand : expressions){
+ if(operand instanceof ELInvocationExpression){
+ ELInvocationExpression expression = findComponentReference((ELInvocationExpression)operand);
+ if(expression != null){
+ checkMatch(file, expression, offset+getOffset(expression), getLength(expression));
+ }
+ }
}
- } catch (CoreException e) {
- ELCorePlugin.getDefault().logError(e);
- } catch (IOException e) {
- ELCorePlugin.getDefault().logError(e);
- } finally {
- if (model != null) {
- model.releaseFromRead();
- }
}
}
+
}
- private void scanChildNodes(IFile file, Node parent) {
- NodeList children = parent.getChildNodes();
- for(int i=0; i<children.getLength(); i++) {
- Node curentValidatedNode = children.item(i);
- if(Node.ELEMENT_NODE == curentValidatedNode.getNodeType()) {
- scanNodeContent(file, ((IDOMNode)curentValidatedNode).getFirstStructuredDocumentRegion(), DOMRegionContext.XML_TAG_ATTRIBUTE_VALUE);
- } else if(Node.TEXT_NODE == curentValidatedNode.getNodeType()) {
- scanNodeContent(file, ((IDOMNode)curentValidatedNode).getFirstStructuredDocumentRegion(), DOMRegionContext.XML_CONTENT);
- }
- scanChildNodes(file, curentValidatedNode);
- }
- }
- private void scanNodeContent(IFile file, IStructuredDocumentRegion node, String regionType) {
- ITextRegionList regions = node.getRegions();
- for(int i=0; i<regions.size(); i++) {
- ITextRegion region = regions.get(i);
- if(region.getType() == regionType) {
- String text = node.getFullText(region);
- if(text.indexOf("{")>-1) { //$NON-NLS-1$
- int offset = node.getStartOffset() + region.getStart();
- scanString(file, text, offset);
- }
- }
- }
- }
-
// looking for component references in EL
private void scanString(IFile file, String string, int offset) {
int startEl = string.indexOf("#{"); //$NON-NLS-1$
15 years, 1 month
JBoss Tools SVN: r19283 - in trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl: definition and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2009-12-15 11:56:03 -0500 (Tue, 15 Dec 2009)
New Revision: 19283
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/InjectionPointMethod.java
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/BeanMember.java
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/InjectionPointField.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/AbstractTypeDefinition.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/BeanMemberDefinition.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/FieldDefinition.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-4943
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/BeanMember.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/BeanMember.java 2009-12-15 16:42:29 UTC (rev 19282)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/BeanMember.java 2009-12-15 16:56:03 UTC (rev 19283)
@@ -58,6 +58,10 @@
this.classBean = classBean;
}
+ public IType getType() {
+ return typeDeclaration == null ? null : typeDeclaration.getType();
+ }
+
public int getLength() {
ISourceRange r = null;
try {
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 2009-12-15 16:42:29 UTC (rev 19282)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/ClassBean.java 2009-12-15 16:56:03 UTC (rev 19283)
@@ -58,6 +58,8 @@
BeanMethod bm = null;
if(m.getProducesAnnotation() != null) {
bm = new ProducerMethod();
+ } else if(m.getInjectAnnotation() != null) {
+ bm = new InjectionPointMethod();
} else {
//add observer case
bm = new BeanMethod();
@@ -159,7 +161,9 @@
}
}
for (BeanMethod m: methods) {
- //get parameters that are injection points
+ if(m instanceof IInjectionPoint) {
+ result.add((IInjectionPoint)m);
+ }
}
return result;
}
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/InjectionPointField.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/InjectionPointField.java 2009-12-15 16:42:29 UTC (rev 19282)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/InjectionPointField.java 2009-12-15 16:56:03 UTC (rev 19283)
@@ -10,7 +10,6 @@
******************************************************************************/
package org.jboss.tools.cdi.internal.core.impl;
-import org.eclipse.jdt.core.IType;
import org.jboss.tools.cdi.core.IAnnotationDeclaration;
import org.jboss.tools.cdi.core.IInjectionPointField;
@@ -27,10 +26,6 @@
return getDefinition().getDelegateAnnotation();
}
- public IType getType() {
- return typeDeclaration == null ? null : typeDeclaration.getType();
- }
-
public boolean isDelegate() {
return getDelegateAnnotation() != null;
}
Added: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/InjectionPointMethod.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/InjectionPointMethod.java (rev 0)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/InjectionPointMethod.java 2009-12-15 16:56:03 UTC (rev 19283)
@@ -0,0 +1,32 @@
+/*******************************************************************************
+ * Copyright (c) 2007 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.internal.core.impl;
+
+import org.jboss.tools.cdi.core.IAnnotationDeclaration;
+import org.jboss.tools.cdi.core.IInjectionPointMethod;
+
+/**
+ *
+ * @author Viacheslav Kabanovich
+ *
+ */
+public class InjectionPointMethod extends BeanMethod implements
+ IInjectionPointMethod {
+
+ public IAnnotationDeclaration getDelegateAnnotation() {
+ return getDefinition().getDelegateAnnotation();
+ }
+
+ public boolean isDelegate() {
+ return getDelegateAnnotation() != null;
+ }
+
+}
Property changes on: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/InjectionPointMethod.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/AbstractTypeDefinition.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/AbstractTypeDefinition.java 2009-12-15 16:42:29 UTC (rev 19282)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/AbstractTypeDefinition.java 2009-12-15 16:56:03 UTC (rev 19283)
@@ -16,6 +16,7 @@
import org.eclipse.core.runtime.CoreException;
import org.eclipse.jdt.core.IType;
import org.jboss.tools.cdi.core.IParametedType;
+import org.jboss.tools.common.el.core.resolver.TypeInfoCollector;
import org.jboss.tools.common.model.util.EclipseJavaUtil;
/**
@@ -50,7 +51,7 @@
String sc = type.getSuperclassTypeSignature();
if(sc != null) {
//TODO process parameter types correctly!!!
- sc = EclipseJavaUtil.resolveType(contextType, sc);
+ sc = EclipseJavaUtil.resolveTypeAsString(contextType, sc);
if(sc != null && sc.length() > 0) {
IType t = EclipseJavaUtil.findType(contextType.getJavaProject(), sc);
//TODO
@@ -59,7 +60,7 @@
}
String[] is = type.getSuperInterfaceTypeSignatures();
if(is != null) for (int i = 0; i < is.length; i++) {
- String c = EclipseJavaUtil.resolveType(contextType, is[i]);
+ String c = EclipseJavaUtil.resolveTypeAsString(contextType, is[i]);
if(c != null && c.length() > 0) {
IType t = EclipseJavaUtil.findType(contextType.getJavaProject(), c);
//TODO
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/BeanMemberDefinition.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/BeanMemberDefinition.java 2009-12-15 16:42:29 UTC (rev 19282)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/BeanMemberDefinition.java 2009-12-15 16:56:03 UTC (rev 19283)
@@ -19,4 +19,8 @@
return annotationsByType.get(CDIConstants.INJECT_ANNOTATION_TYPE_NAME);
}
+ public AnnotationDeclaration getDelegateAnnotation() {
+ return annotationsByType.get(CDIConstants.DELEGATE_STEREOTYPE_TYPE_NAME);
+ }
+
}
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/FieldDefinition.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/FieldDefinition.java 2009-12-15 16:42:29 UTC (rev 19282)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/definition/FieldDefinition.java 2009-12-15 16:56:03 UTC (rev 19283)
@@ -33,8 +33,4 @@
return field;
}
- public AnnotationDeclaration getDelegateAnnotation() {
- return annotationsByType.get(CDIConstants.DELEGATE_STEREOTYPE_TYPE_NAME);
- }
-
}
15 years, 1 month
JBoss Tools SVN: r19282 - trunk/common/plugins/org.jboss.tools.common.ui/src/org/jboss/tools/common/ui/preferences.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2009-12-15 11:42:29 -0500 (Tue, 15 Dec 2009)
New Revision: 19282
Modified:
trunk/common/plugins/org.jboss.tools.common.ui/src/org/jboss/tools/common/ui/preferences/SeverityPreferencesMessages.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-5473
Modified: trunk/common/plugins/org.jboss.tools.common.ui/src/org/jboss/tools/common/ui/preferences/SeverityPreferencesMessages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.ui/src/org/jboss/tools/common/ui/preferences/SeverityPreferencesMessages.java 2009-12-15 16:39:28 UTC (rev 19281)
+++ trunk/common/plugins/org.jboss.tools.common.ui/src/org/jboss/tools/common/ui/preferences/SeverityPreferencesMessages.java 2009-12-15 16:42:29 UTC (rev 19282)
@@ -18,7 +18,7 @@
*/
public class SeverityPreferencesMessages extends NLS {
- private static final String BUNDLE_NAME = "org.jboss.tools.common.model.ui.preferences.SeverityPreferencesMessages"; //$NON-NLS-1$
+ private static final String BUNDLE_NAME = "org.jboss.tools.common.ui.preferences.SeverityPreferencesMessages"; //$NON-NLS-1$
public static String ValidatorConfigurationBlock_needsbuild_title;
public static String ValidatorConfigurationBlock_needsfullbuild_message;
15 years, 1 month