Author: akazakov
Date: 2009-11-16 17:50:05 -0500 (Mon, 16 Nov 2009)
New Revision: 18710
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IAnnotationDeclaration.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBinding.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBindingDeclaration.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScoped.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotypeDeclaration.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/ITypeDeclaration.java
Removed:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInject.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/INamed.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IProduces.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IQualifier.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScope.java
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IBean.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IBeanManager.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInjectionPoint.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotype.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-4943
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IAnnotationDeclaration.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IAnnotationDeclaration.java
(rev 0)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IAnnotationDeclaration.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -0,0 +1,28 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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;
+
+import org.eclipse.jdt.core.IAnnotation;
+
+/**
+ * Represents an annotation declaration. For example a qualifier or a scope
+ * declaration of a bean/injection/produce method.
+ *
+ * @author Alexey Kazakov
+ */
+public interface IAnnotationDeclaration extends ITypeDeclaration {
+
+ /**
+ * Return the annotation declaration.
+ * @return the annotation declaration.
+ */
+ IAnnotation getDeclaration();
+}
\ No newline at end of file
Property changes on:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IAnnotationDeclaration.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IBean.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IBean.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IBean.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -12,7 +12,6 @@
import java.util.Set;
-import org.eclipse.jdt.core.IAnnotation;
import org.eclipse.jdt.core.IType;
import org.jboss.tools.common.text.ITextSourceReference;
@@ -21,41 +20,17 @@
*
* @author Alexey Kazakov
*/
-public interface IBean extends ICDIElement {
+public interface IBean extends IScoped, ICDIElement {
/**
- * Obtains the types of the bean.
+ * Returns the corresponding IType of the managed bean or session bean or of
+ * the bean that declares the producer method or field.
*
- * @return the bean types
+ * @return the bean class
*/
- Set<IType> getTypes();
+ IType getBeanClass();
/**
- * Returns the location of a type declaration of this bean. If the bean
- * doesn't have such declaration then null will be returned.
- *
- * @param type
- * @return the location of the type of this bean.
- */
- ITextSourceReference getTypeLocation(IType type);
-
- /**
- * Obtains the qualifiers of the bean.
- *
- * @return the qualifiers
- */
- Set<IAnnotation> getQualifiers();
-
- /**
- * Returns the location of a qualifier declaration of this bean. If the bean
- * doesn't have such declaration then null will be returned.
- *
- * @param qualifier
- * @return the location of the qualifier declaration of this bean.
- */
- ITextSourceReference getQualifierLocation(IType qualifier);
-
- /**
* Obtains the EL name of the bean, if it has one.
*
* @return the EL name
@@ -64,44 +39,54 @@
/**
* Returns the location of a name declaration of this bean. If the bean
- * doesn't have the name declaration then null will be returned.
+ * doesn't have the name declaration then null will be returned. May be
+ * declared in a stereotype. May be a declaration of @Name annotation or
+ * location of Java class name declaration.
*
* @return the location of a name declaration of this bean.
*/
ITextSourceReference getNameLocation();
/**
- * Obtains the scope of the bean.
+ * Obtains the legal types of the bean class or producer method or field.
*
- * @return the scope
+ * @return the legal types
*/
- IScope getScope();
+ Set<IType> getLegalTypes();
/**
- * Returns the location of a scope declaration of this bean. If the bean
- * doesn't have the scope declaration then null will be returned.
+ * Obtains the all type declarations of the bean class or producer method or
+ * field (legal types as well as illegal ones).
*
- * @return the location of a scope declaration of this bean.
+ * @return the type declarations
*/
- ITextSourceReference getScopeLocation();
+ Set<ITypeDeclaration> getAllTypeDeclarations();
/**
- * Obtains the stereotypes of the bean.
+ * Obtains the type declarations of the bean class or producer method or
+ * field (legal types as well as illegal ones) which are defined by @Typed
+ * annotation.
*
- * @return the set of stereotypes
+ * @return the type declarations
*/
- Set<IStereotype> getStereotypes();
+ Set<ITypeDeclaration> getRestrictedTypeDeclaratios();
/**
- * Returns the location of a stereotype declaration of this bean. If the
- * bean doesn't have such stereotype declaration then null will be returned.
+ * Obtains the qualifiers of the bean class or producer method or field.
*
- * @param qualifier
- * @return the location of the stereotype declaration of this bean.
+ * @return the qualifiers
*/
- ITextSourceReference getStereotypeLocation(IStereotype stereotype);
+ Set<IAnnotationDeclaration> getQualifierDeclarations();
/**
+ * Obtains the stereotype declarations of the bean class or producer method
+ * or field.
+ *
+ * @return the set of stereotype declarations
+ */
+ Set<IStereotypeDeclaration> getStereotypeDeclarations();
+
+ /**
* Determines if the bean is an alternative.
*
* @return <tt>true</tt> if the bean is an alternative, and
<tt>false</tt>
@@ -110,10 +95,17 @@
boolean isAlternative();
/**
+ * Returns the location of @Alternative declaration of this bean. May be
+ * declared in a stereotype.
+ *
+ * @return the location of @Alternative declaration.
+ */
+ IAnnotationDeclaration getAlternativeDeclaration();
+
+ /**
* Obtains the injection points of the bean.
*
* @return the set of injection points of the bean
*/
Set<IInjectionPoint> getInjectionPoints();
-
}
\ No newline at end of file
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IBeanManager.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IBeanManager.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IBeanManager.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -7,12 +7,11 @@
*
* Contributors:
* Red Hat, Inc. - initial API and implementation
- ******************************************************************************/
+ ******************************************************************************/
package org.jboss.tools.cdi.core;
import java.util.Set;
-import org.eclipse.jdt.core.IAnnotation;
import org.eclipse.jdt.core.IType;
/**
@@ -20,23 +19,26 @@
*/
public interface IBeanManager {
- /**
- * Returns the set of beans which match the given EL name
- *
- * @param name the name used to restrict the beans matched
- * @return the matched beans
- */
- public Set<IBean> getBeans(String name);
+ /**
+ * Returns the set of beans which match the given EL name
+ *
+ * @param name
+ * the name used to restrict the beans matched
+ * @return the matched beans
+ */
+ Set<IBean> getBeans(String name);
- /**
- * Returns the set of beans which match the given required type and bindings.
- *
- * @param beanType the type of the beans to be resolved
- * @param bindings the bindings used to restrict the matched beans. If no
- * bindings are passed to getBeans(), the default binding @Current
- * is assumed.
- * @return the matched beans
- */
- public Set<IBean> getBeans(IType beanType, IAnnotation... bindings);
-
+ /**
+ * Returns the set of beans which have the given required type and qualifier type
+ * If no qualifiers are given, the
+ * {@linkplain javax.enterprise.inject.Default default qualifier} is
+ * assumed.
+ *
+ * @param beanType
+ * the required bean type
+ * @param qualifiers
+ * the required qualifiers
+ * @return the resulting set of beans
+ */
+ Set<IBean> getBeans(IType beanType, IType... qualifierTypes);
}
\ No newline at end of file
Deleted:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInject.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInject.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInject.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -1,18 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009 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;
-
-/**
- * @author Alexey Kazakov
- */
-public interface IInject {
-
-}
\ No newline at end of file
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInjectionPoint.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInjectionPoint.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInjectionPoint.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -7,9 +7,13 @@
*
* Contributors:
* Red Hat, Inc. - initial API and implementation
- ******************************************************************************/
+ ******************************************************************************/
package org.jboss.tools.cdi.core;
+import java.util.Set;
+
+import org.eclipse.jdt.core.IAnnotation;
+import org.eclipse.jdt.core.IJavaElement;
import org.jboss.tools.common.text.ITextSourceReference;
/**
@@ -19,4 +23,37 @@
*/
public interface IInjectionPoint extends ICDIElement, ITextSourceReference {
+ /**
+ * Gets the required qualifiers of the injection point.
+ *
+ * @return the required qualifiers
+ */
+ Set<IAnnotation> getQualifiers();
+
+ /**
+ * Gets the object representing the bean that defines the injection point. If
+ * the injection point does not belong to a bean, return a null value.
+ *
+ * @return the object representing bean that defines the injection point, of
+ * null if the injection point does not belong to a bean
+ */
+ IBean getBean();
+
+ /**
+ * Obtains an instance of IMember or ITypeParameter, depending upon whether
+ * the injection point is an injected field or a constructor/method
+ * parameter.
+ *
+ * @return an IMember or ITypeParameter
+ */
+ IJavaElement getSourceElement();
+
+ /**
+ * Determines if the injection point is a decorator delegate injection
+ * point.
+ *
+ * @return <tt>true</tt> if the injection point is a decorator delegate
+ * injection point, and <tt>false</tt> otherwise
+ */
+ boolean isDelegate();
}
\ No newline at end of file
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBinding.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBinding.java
(rev 0)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBinding.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -0,0 +1,18 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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;
+
+/**
+ * @author Alexey Kazakov
+ */
+public interface IInterceptorBinding {
+
+}
\ No newline at end of file
Property changes on:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBinding.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBindingDeclaration.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBindingDeclaration.java
(rev 0)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBindingDeclaration.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -0,0 +1,24 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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;
+
+/**
+ * @author Alexey Kazakov
+ */
+public interface IInterceptorBindingDeclaration extends IAnnotationDeclaration {
+
+ /**
+ * Returns the corresponding interceptor binding.
+ *
+ * @return the corresponding interceptor binding.
+ */
+ IInterceptorBinding getInterceptorBinding();
+}
\ No newline at end of file
Property changes on:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IInterceptorBindingDeclaration.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Deleted:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/INamed.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/INamed.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/INamed.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -1,18 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009 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;
-
-/**
- * @author Alexey Kazakov
- */
-public interface INamed {
-
-}
\ No newline at end of file
Deleted:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IProduces.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IProduces.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IProduces.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -1,18 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009 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;
-
-/**
- * @author Alexey Kazakov
- */
-public interface IProduces {
-
-}
\ No newline at end of file
Deleted:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IQualifier.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IQualifier.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IQualifier.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -1,18 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009 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;
-
-/**
- * @author Alexey Kazakov
- */
-public interface IQualifier {
-
-}
\ No newline at end of file
Deleted:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScope.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScope.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScope.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -1,18 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009 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;
-
-/**
- * @author Alexey Kazakov
- */
-public interface IScope {
-
-}
\ No newline at end of file
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScoped.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScoped.java
(rev 0)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScoped.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -0,0 +1,42 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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;
+
+import java.util.Set;
+
+import org.eclipse.jdt.core.IType;
+
+/**
+ * This interface if common protocol to have access to scoped of bean class or
+ * producer method or field or stereotype.
+ *
+ * @author Alexey Kazakov
+ */
+public interface IScoped {
+
+ /**
+ * Obtains the scope type of the bean class or producer method or filed or
+ * stereotype annotation. The scope may or may not be declared in the
+ * object. It may be default one or come from stereotype of the object.
+ *
+ * @return the scope type
+ */
+ IType getScope();
+
+ /**
+ * Obtains all the scope declarations of the bean class or producer method
+ * or filed or stereotype annotation. This set doesn't contain scope
+ * declarations from stereotypes of this object.
+ *
+ * @return the scope
+ */
+ Set<IAnnotationDeclaration> getScopeDeclarations();
+}
\ No newline at end of file
Property changes on:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IScoped.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotype.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotype.java 2009-11-16
20:32:08 UTC (rev 18709)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotype.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -7,12 +7,62 @@
*
* Contributors:
* Red Hat, Inc. - initial API and implementation
- ******************************************************************************/
+ ******************************************************************************/
package org.jboss.tools.cdi.core;
+import java.util.Set;
+
+import org.eclipse.jdt.core.IAnnotation;
+import org.eclipse.jdt.core.IType;
+
/**
+ * Represents a stereotype.
+ *
* @author Alexey Kazakov
*/
-public interface IStereotype {
+public interface IStereotype extends IScoped, ICDIElement {
+ /**
+ * Returns the corresponding IType of the stereotype.
+ *
+ * @return the corresponding IType
+ */
+ IType getSourceType();
+
+ /**
+ * Returns the location of @Name declaration of this stereotype. If the bean
+ * doesn't have the @Name declaration then null will be returned.
+ *
+ * @return the location of @Name declaration of this bean.
+ */
+ IAnnotation getNameLocation();
+
+ /**
+ * Returns the interceptor binding declarations of the stereotype.
+ *
+ * @return the interceptor binding declarations.
+ */
+ Set<IInterceptorBindingDeclaration> getInterceptorBindingDeclarations();
+
+ /**
+ * Determines if the stereotype is an alternative.
+ *
+ * @return <tt>true</tt> if the stereotype is an alternative, and
+ * <tt>false</tt> otherwise.
+ */
+ boolean isAlternative();
+
+ /**
+ * Returns the location of @Alternative declaration of this stereotype.
+ *
+ * @return the location of @Alternative declaration.
+ */
+ IAnnotationDeclaration getAlternativeDeclaration();
+
+ /**
+ * Obtains the stereotype declarations of the stereotype.
+ *
+ * @return the set of stereotype declarations
+ */
+ Set<IStereotypeDeclaration> getStereotypeDeclarations();
}
\ No newline at end of file
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotypeDeclaration.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotypeDeclaration.java
(rev 0)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotypeDeclaration.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -0,0 +1,26 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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;
+
+/**
+ * Represents a stereotype declaration.
+ *
+ * @author Alexey Kazakov
+ */
+public interface IStereotypeDeclaration extends IAnnotationDeclaration {
+
+ /**
+ * Returns the corresponding stereotype.
+ *
+ * @return the corresponding stereotype.
+ */
+ IStereotype getStereotype();
+}
\ No newline at end of file
Property changes on:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/IStereotypeDeclaration.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/ITypeDeclaration.java
===================================================================
---
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/ITypeDeclaration.java
(rev 0)
+++
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/ITypeDeclaration.java 2009-11-16
22:50:05 UTC (rev 18710)
@@ -0,0 +1,27 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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;
+
+import org.eclipse.jdt.core.IType;
+import org.jboss.tools.common.text.ITextSourceReference;
+
+/**
+ * @author Alexey Kazakov
+ */
+public interface ITypeDeclaration extends ITextSourceReference {
+
+ /**
+ * Returns the corresponding IType of the declaration.
+ *
+ * @return the corresponding IType of the declaration.
+ */
+ IType getType();
+}
\ No newline at end of file
Property changes on:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/ITypeDeclaration.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain