[jboss-cvs] JBossAS SVN: r95840 - in projects/interceptors/api/trunk: src and 4 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Fri Oct 30 11:58:18 EDT 2009


Author: marius.bogoevici
Date: 2009-10-30 11:58:18 -0400 (Fri, 30 Oct 2009)
New Revision: 95840

Added:
   projects/interceptors/api/trunk/pom.xml
   projects/interceptors/api/trunk/src/
   projects/interceptors/api/trunk/src/main/
   projects/interceptors/api/trunk/src/main/java/
   projects/interceptors/api/trunk/src/main/java/javax/
   projects/interceptors/api/trunk/src/main/java/javax/interceptor/
   projects/interceptors/api/trunk/src/main/java/javax/interceptor/AroundInvoke.java
   projects/interceptors/api/trunk/src/main/java/javax/interceptor/ExcludeClassInterceptors.java
   projects/interceptors/api/trunk/src/main/java/javax/interceptor/ExcludeDefaultInterceptors.java
   projects/interceptors/api/trunk/src/main/java/javax/interceptor/Interceptors.java
   projects/interceptors/api/trunk/src/main/java/javax/interceptor/InvocationContext.java
Log:
Version 1.0 of interceptors api added.

Added: projects/interceptors/api/trunk/pom.xml
===================================================================
--- projects/interceptors/api/trunk/pom.xml	                        (rev 0)
+++ projects/interceptors/api/trunk/pom.xml	2009-10-30 15:58:18 UTC (rev 95840)
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+  <parent>
+    <groupId>org.jboss</groupId>
+    <artifactId>jboss-parent</artifactId>
+    <version>4</version>
+  </parent>
+
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.jboss.interceptor</groupId>
+  <artifactId>jboss-interceptor-api</artifactId>
+  <version>1.0-SNAPSHOT</version>
+  <name>EJB Interceptor API</name>
+
+  <scm>
+    <connection>scm:svn:http://anonsvn.jboss.org/repos/jbossas/projects/interceptors/api/trunk/</connection>
+    <developerConnection>scm:svn:https://svn.jboss.org/repos/jbossas/projects/interceptors/api/trunk/</developerConnection>
+    <url>http://viewvc.jboss.org/cgi-bin/viewvc.cgi/jbossas/projects/interceptors/api/trunk/</url>
+  </scm>
+
+  <build>
+    <finalName>${artifactId}</finalName>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <version>2.0.2.SP1</version>
+        <configuration>
+          <source>1.5</source>
+          <target>1.5</target>
+          <showDeprecation>true</showDeprecation>
+          <showWarnings>true</showWarnings>
+          <optimize>true</optimize>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-release-plugin</artifactId>
+        <version>2.0-beta-9</version>
+        <configuration>
+          <generateReleasePoms>false</generateReleasePoms>
+          <tagBase>https://svn.jboss.org/repos/jbossas/projects/interceptors/api/tags</tagBase>
+        </configuration>
+      </plugin>
+    </plugins>
+    <pluginManagement>
+      <plugins>
+        <plugin>
+          <artifactId>maven-idea-plugin</artifactId>
+          <configuration>
+            <downloadSources>true</downloadSources>
+          </configuration>
+        </plugin>
+        <plugin>
+          <!-- Configure javadoc plugin with APIviz -->
+          <groupId>org.apache.maven.plugins</groupId>
+          <artifactId>maven-javadoc-plugin</artifactId>
+          <configuration>
+            <doclet>net.gleamynode.apiviz.APIviz</doclet>
+            <docletArtifact>
+              <groupId>net.gleamynode.apiviz</groupId>
+              <artifactId>apiviz</artifactId>
+              <version>1.1.0</version>
+            </docletArtifact>
+            <encoding>UTF-8</encoding>
+          </configuration>
+        </plugin>
+      </plugins>
+    </pluginManagement>
+  </build>
+</project>
\ No newline at end of file

Added: projects/interceptors/api/trunk/src/main/java/javax/interceptor/AroundInvoke.java
===================================================================
--- projects/interceptors/api/trunk/src/main/java/javax/interceptor/AroundInvoke.java	                        (rev 0)
+++ projects/interceptors/api/trunk/src/main/java/javax/interceptor/AroundInvoke.java	2009-10-30 15:58:18 UTC (rev 95840)
@@ -0,0 +1,38 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* This is free software; you can redistribute it and/or modify it
+* under the terms of the GNU Lesser General Public License as
+* published by the Free Software Foundation; either version 2.1 of
+* the License, or (at your option) any later version.
+*
+* This software is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+* Lesser General Public License for more details.
+*
+* You should have received a copy of the GNU Lesser General Public
+* License along with this software; if not, write to the Free
+* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+*/
+package javax.interceptor;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+import static java.lang.annotation.ElementType.*;
+import static java.lang.annotation.RetentionPolicy.*;
+
+/**
+ * Defines an interceptor method. The method must have the signature:
+ * public Object <METHOD>(InvocationContext) throws Exception
+ * 
+ * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
+ * @version $Revision: 44679 $
+ */
+ at Target({METHOD}) @Retention(RUNTIME)
+public @interface AroundInvoke {
+}

Added: projects/interceptors/api/trunk/src/main/java/javax/interceptor/ExcludeClassInterceptors.java
===================================================================
--- projects/interceptors/api/trunk/src/main/java/javax/interceptor/ExcludeClassInterceptors.java	                        (rev 0)
+++ projects/interceptors/api/trunk/src/main/java/javax/interceptor/ExcludeClassInterceptors.java	2009-10-30 15:58:18 UTC (rev 95840)
@@ -0,0 +1,23 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ * 
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package javax.interceptor;
+
+import static java.lang.annotation.ElementType.METHOD;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 44679 $
+ */
+ at Target({METHOD}) @Retention(RUNTIME)
+public @interface ExcludeClassInterceptors {
+
+}

Added: projects/interceptors/api/trunk/src/main/java/javax/interceptor/ExcludeDefaultInterceptors.java
===================================================================
--- projects/interceptors/api/trunk/src/main/java/javax/interceptor/ExcludeDefaultInterceptors.java	                        (rev 0)
+++ projects/interceptors/api/trunk/src/main/java/javax/interceptor/ExcludeDefaultInterceptors.java	2009-10-30 15:58:18 UTC (rev 95840)
@@ -0,0 +1,24 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ * 
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package javax.interceptor;
+
+import static java.lang.annotation.ElementType.METHOD;
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 57282 $
+ */
+ at Target({TYPE, METHOD}) @Retention(RUNTIME)
+public @interface ExcludeDefaultInterceptors {
+
+}

Added: projects/interceptors/api/trunk/src/main/java/javax/interceptor/Interceptors.java
===================================================================
--- projects/interceptors/api/trunk/src/main/java/javax/interceptor/Interceptors.java	                        (rev 0)
+++ projects/interceptors/api/trunk/src/main/java/javax/interceptor/Interceptors.java	2009-10-30 15:58:18 UTC (rev 95840)
@@ -0,0 +1,41 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* This is free software; you can redistribute it and/or modify it
+* under the terms of the GNU Lesser General Public License as
+* published by the Free Software Foundation; either version 2.1 of
+* the License, or (at your option) any later version.
+*
+* This software is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+* Lesser General Public License for more details.
+*
+* You should have received a copy of the GNU Lesser General Public
+* License along with this software; if not, write to the Free
+* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+*/
+package javax.interceptor;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+import static java.lang.annotation.ElementType.*;
+import static java.lang.annotation.RetentionPolicy.*;
+
+/**
+ * An interceptor class is denoted using the Interceptor annotation on the bean
+ * class with which it is associated. In the case of multiple interceptor
+ * classes, the Interceptors annotation is used.
+ * 
+ * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
+ * @version $Revision: 44679 $
+ */
+ at Target({TYPE, METHOD}) @Retention(RUNTIME)
+   public @interface Interceptors
+{
+   Class[] value();
+}

Added: projects/interceptors/api/trunk/src/main/java/javax/interceptor/InvocationContext.java
===================================================================
--- projects/interceptors/api/trunk/src/main/java/javax/interceptor/InvocationContext.java	                        (rev 0)
+++ projects/interceptors/api/trunk/src/main/java/javax/interceptor/InvocationContext.java	2009-10-30 15:58:18 UTC (rev 95840)
@@ -0,0 +1,49 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* This is free software; you can redistribute it and/or modify it
+* under the terms of the GNU Lesser General Public License as
+* published by the Free Software Foundation; either version 2.1 of
+* the License, or (at your option) any later version.
+*
+* This software is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+* Lesser General Public License for more details.
+*
+* You should have received a copy of the GNU Lesser General Public
+* License along with this software; if not, write to the Free
+* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+*/
+package javax.interceptor;
+
+import java.lang.reflect.Method;
+
+/**
+ * The InvocationContext object provides the metadata that is required for
+ * AroundInvoke interceptor methods.
+ * 
+ * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
+ * @version $Revision: 57282 $
+ */
+public interface InvocationContext
+{
+   public Object getTarget();
+
+   public Method getMethod();
+
+   public Object[] getParameters();
+
+   public void setParameters(Object[] params);
+
+   /**
+    * Returns the context data associated with this invocation or lifecycle callback. If there is no context data, an empty Map object will be returned.
+    */
+   public java.util.Map<String, Object> getContextData();
+
+   public Object proceed() throws Exception;
+}
\ No newline at end of file




More information about the jboss-cvs-commits mailing list