FELIX-1010 : Add annotations to the build, change version and make the retention policy to be source (we don't want the annotations in the compiled classes)
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@760530 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/pom.xml b/pom.xml
index 1e65dc6..71d9e60 100644
--- a/pom.xml
+++ b/pom.xml
@@ -66,6 +66,7 @@
<modules>
<module>maven-obr-plugin</module>
<module>bundleplugin</module>
+ <module>scrplugin-annotations</module>
<module>scrplugin</module>
<module>tools/maven2/maven-osgi-plugin</module>
<!-- <module>tools/maven2/maven-felix-plugin</module> -->
diff --git a/scrplugin-annotations/pom.xml b/scrplugin-annotations/pom.xml
index e8417cc..0deb634 100644
--- a/scrplugin-annotations/pom.xml
+++ b/scrplugin-annotations/pom.xml
@@ -23,12 +23,13 @@
<artifactId>felix</artifactId>
<groupId>org.apache.felix</groupId>
<version>1.0.4</version>
+ <relativePath>../pom/pom.xml</relativePath>
</parent>
<groupId>org.apache.felix</groupId>
<artifactId>maven-scr-plugin-annotations</artifactId>
- <version>1.0.11-SNAPSHOT</version>
+ <version>0.9.0-SNAPSHOT</version>
<packaging>jar</packaging>
<name>Annotations for Maven SCR Plugin</name>
diff --git a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Component.java b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Component.java
index ce4625d..0bfc58b 100644
--- a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Component.java
+++ b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Component.java
@@ -18,10 +18,7 @@
*/
package org.apache.felix.scrplugin.annotations;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
/**
* The <code>Component</code> annotation is the only required annotation. If
@@ -37,7 +34,7 @@
* </p>
*/
@Target(ElementType.TYPE)
-@Retention(RetentionPolicy.RUNTIME)
+@Retention(RetentionPolicy.SOURCE)
public @interface Component {
/**
diff --git a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Properties.java b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Properties.java
index 0c72e30..faac843 100644
--- a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Properties.java
+++ b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Properties.java
@@ -18,17 +18,13 @@
*/
package org.apache.felix.scrplugin.annotations;
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
/**
* Allows to define multiple {@link Property} annotations for one type.
*/
@Target(ElementType.TYPE)
-@Retention(RetentionPolicy.RUNTIME)
+@Retention(RetentionPolicy.SOURCE)
@Documented
public @interface Properties {
diff --git a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Property.java b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Property.java
index ab6a4cc..4b90e6b 100644
--- a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Property.java
+++ b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Property.java
@@ -18,11 +18,7 @@
*/
package org.apache.felix.scrplugin.annotations;
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
/**
* The <code>Property</code> annotation defines properties which are made
@@ -37,7 +33,7 @@
* OSGi Service Platform Service Compendium Specification for more information.
*/
@Target(ElementType.TYPE)
-@Retention(RetentionPolicy.RUNTIME)
+@Retention(RetentionPolicy.SOURCE)
@Documented
public @interface Property {
diff --git a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/PropertyOption.java b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/PropertyOption.java
index 07b5b26..2d4b4a1 100644
--- a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/PropertyOption.java
+++ b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/PropertyOption.java
@@ -18,17 +18,13 @@
*/
package org.apache.felix.scrplugin.annotations;
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
/**
* Defines a {@link Property} option.
*/
@Target(ElementType.ANNOTATION_TYPE)
-@Retention(RetentionPolicy.RUNTIME)
+@Retention(RetentionPolicy.SOURCE)
@Documented
public @interface PropertyOption {
diff --git a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Reference.java b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Reference.java
index e0daac0..9d1ec6e 100644
--- a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Reference.java
+++ b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Reference.java
@@ -18,11 +18,7 @@
*/
package org.apache.felix.scrplugin.annotations;
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
/**
* The <code>Reference</code> annotation defines references to other services
@@ -37,7 +33,7 @@
* Service Platform Service Compendium Specification for more information.
*/
@Target( { ElementType.TYPE, ElementType.FIELD })
-@Retention(RetentionPolicy.RUNTIME)
+@Retention(RetentionPolicy.SOURCE)
@Documented
public @interface Reference {
diff --git a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/References.java b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/References.java
index 6706935..e2d3079 100644
--- a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/References.java
+++ b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/References.java
@@ -18,17 +18,13 @@
*/
package org.apache.felix.scrplugin.annotations;
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
/**
* Allows to define multiple {@link Reference} annotations for one type.
*/
@Target(ElementType.TYPE)
-@Retention(RetentionPolicy.RUNTIME)
+@Retention(RetentionPolicy.SOURCE)
@Documented
public @interface References {
diff --git a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Service.java b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Service.java
index 94e13be..226c64e 100644
--- a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Service.java
+++ b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Service.java
@@ -18,11 +18,7 @@
*/
package org.apache.felix.scrplugin.annotations;
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
/**
* The <code>Service</code> annotation defines whether and which service
@@ -34,7 +30,7 @@
* information.
*/
@Target(ElementType.TYPE)
-@Retention(RetentionPolicy.RUNTIME)
+@Retention(RetentionPolicy.SOURCE)
@Documented
public @interface Service {
diff --git a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Services.java b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Services.java
index 5acf325..e00f689 100644
--- a/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Services.java
+++ b/scrplugin-annotations/src/main/java/org/apache/felix/scrplugin/annotations/Services.java
@@ -18,17 +18,13 @@
*/
package org.apache.felix.scrplugin.annotations;
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
+import java.lang.annotation.*;
/**
* Allows to define multiple {@link Service} annotations for one type.
*/
@Target(ElementType.TYPE)
-@Retention(RetentionPolicy.RUNTIME)
+@Retention(RetentionPolicy.SOURCE)
@Documented
public @interface Services {
diff --git a/scrplugin/pom.xml b/scrplugin/pom.xml
index a704547..5810d8c 100644
--- a/scrplugin/pom.xml
+++ b/scrplugin/pom.xml
@@ -23,12 +23,13 @@
<artifactId>felix</artifactId>
<groupId>org.apache.felix</groupId>
<version>1.0.4</version>
+ <relativePath>../pom/pom.xml</relativePath>
</parent>
<groupId>org.apache.felix</groupId>
<artifactId>maven-scr-plugin</artifactId>
- <version>1.0.11-SNAPSHOT</version>
+ <version>1.1.0-SNAPSHOT</version>
<packaging>maven-plugin</packaging>
<name>Maven SCR Plugin</name>
@@ -101,7 +102,7 @@
<dependency>
<groupId>org.apache.felix</groupId>
<artifactId>maven-scr-plugin-annotations</artifactId>
- <version>1.0.11-SNAPSHOT</version>
+ <version>0.9.0-SNAPSHOT</version>
</dependency>
</dependencies>