Author: manaRH
Date: 2009-08-05 08:24:08 -0400 (Wed, 05 Aug 2009)
New Revision: 11346
Removed:
branches/enterprise/JBPAPP_5_0/doc/Seam_Reference_Guide/en-US/Guice.xml
branches/enterprise/JBPAPP_5_0/examples/guice/
branches/enterprise/JBPAPP_5_0/src/ioc/org/jboss/seam/ioc/guice/
Modified:
branches/enterprise/JBPAPP_5_0/build.xml
branches/enterprise/JBPAPP_5_0/build/ioc.pom.xml
branches/enterprise/JBPAPP_5_0/build/root.pom.xml
branches/enterprise/JBPAPP_5_0/doc/Seam_Reference_Guide/en-US/master.xml
branches/enterprise/JBPAPP_5_0/examples/build.xml
branches/enterprise/JBPAPP_5_0/seam-gen/ivy/ivy-build.xml
Log:
JBPAPP-2359 - removed guice integration and example from seam
Modified: branches/enterprise/JBPAPP_5_0/build/ioc.pom.xml
===================================================================
--- branches/enterprise/JBPAPP_5_0/build/ioc.pom.xml 2009-08-05 11:20:33 UTC (rev 11345)
+++ branches/enterprise/JBPAPP_5_0/build/ioc.pom.xml 2009-08-05 12:24:08 UTC (rev 11346)
@@ -54,40 +54,6 @@
</dependency>
<dependency>
- <groupId>com.google.code.guice</groupId>
- <artifactId>guice</artifactId>
- <optional>true</optional>
- </dependency>
-
- <!-- Microcontainer stuff isn't done -->
-
- <!-- <dependency>
- <groupId>jboss</groupId>
- <artifactId>jboss-jmx</artifactId>
- <optional>true</optional>
- </dependency>
-
- <dependency>
- <groupId>jboss</groupId>
- <artifactId>jboss-system</artifactId>
- <optional>true</optional>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.microcontainer</groupId>
- <artifactId>jboss-kernel</artifactId>
- <optional>true</optional>
- </dependency>
-
- <dependency>
- <groupId>jboss</groupId>
- <artifactId>jbossxb</artifactId>
- <optional>true</optional>
- </dependency>
-
- -->
-
- <dependency>
<groupId>javax.persistence</groupId>
<artifactId>persistence-api</artifactId>
<optional>true</optional>
Modified: branches/enterprise/JBPAPP_5_0/build/root.pom.xml
===================================================================
--- branches/enterprise/JBPAPP_5_0/build/root.pom.xml 2009-08-05 11:20:33 UTC (rev 11345)
+++ branches/enterprise/JBPAPP_5_0/build/root.pom.xml 2009-08-05 12:24:08 UTC (rev 11346)
@@ -787,12 +787,6 @@
</exclusion>
</exclusions>
</dependency>
-
- <dependency>
- <groupId>com.google.code.guice</groupId>
- <artifactId>guice</artifactId>
- <version>1.0</version>
- </dependency>
<dependency>
<groupId>cglib</groupId>
Modified: branches/enterprise/JBPAPP_5_0/build.xml
===================================================================
--- branches/enterprise/JBPAPP_5_0/build.xml 2009-08-05 11:20:33 UTC (rev 11345)
+++ branches/enterprise/JBPAPP_5_0/build.xml 2009-08-05 12:24:08 UTC (rev 11346)
@@ -365,7 +365,6 @@
<cleanexample name="seamdiscs" />
<cleanexample name="seambay" />
<cleanexample name="nestedbooking" />
- <cleanexample name="guice" />
</target>
<target name="undeployexamples" description="Undeploy all
examples">
@@ -394,7 +393,6 @@
<undeployexample name="seamdiscs" />
<undeployexample name="seambay" />
<undeployexample name="nestedbooking" />
- <undeployexample name="guice" />
</target>
<target name="testexamples" description="Run the example
tests">
@@ -419,7 +417,6 @@
<testexample name="hibernate" />
<testexample name="jpa" />
<testexample name="quartz" />
- <testexample name="guice" />
</target>
<!-- ########################## 'ALL' TARGETS
##########################-->
@@ -456,8 +453,6 @@
<ant dir="examples/seamspace" target="validateConfiguration"
inheritall="false" />
<ant dir="examples/todo" target="validateConfiguration"
inheritall="false" />
<ant dir="examples/ui" target="validateConfiguration"
inheritall="false" />
- <ant dir="examples/guice" target="validateConfiguration"
inheritall="false" />
-
</target>
@@ -551,7 +546,6 @@
<include name="todo/**/*" />
<include name="numberguess/**/*" />
<include name="groovybooking/**/*" />
- <include name="guice/**/*" />
<include name="seamdiscs/**/*" />
<include name="quartz/**/*" />
<include name="drools/**/*" />
Deleted: branches/enterprise/JBPAPP_5_0/doc/Seam_Reference_Guide/en-US/Guice.xml
===================================================================
--- branches/enterprise/JBPAPP_5_0/doc/Seam_Reference_Guide/en-US/Guice.xml 2009-08-05
11:20:33 UTC (rev 11345)
+++ branches/enterprise/JBPAPP_5_0/doc/Seam_Reference_Guide/en-US/Guice.xml 2009-08-05
12:24:08 UTC (rev 11346)
@@ -1,152 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
-
-<chapter id="guice">
-
- <title>Guice integration</title>
-
- <para>
- Google Guice is a library that provides lightweight dependency injection through
type-safe
- resolution. The Guice integration (part of the Seam IoC module) allows use of Guice
injection
- for all Seam components annotated with the <literal>@Guice</literal>
annotation. In addition
- to the regular bijection that Seam performs (which becomes optional), Seam also
delegates
- to known Guice injectors to satisify the dependencies of the component. Guice may
be useful to
- tie non-Seam parts of large or legacy applications together with Seam.
- </para>
-
- <note>
- The Guice integration is bundled in the jboss-seam-ioc library. This dependency is
required
- for all integration techniques covered in this chapter. You will also need the
Guice JAR file
- on the classpath.
- </note>
-
- <section>
- <title>Creating a hybrid Seam-Guice component</title>
-
- <para>
- The goal is to create a hybrid Seam-Guice component. The rule for how to do this
is very
- simple. If you want to use Guice injection in your Seam component, annotate it
with the
- <literal>@Guice</literal> annotation (after importing the type
- <literal>org.jboss.seam.ioc.guice.Guice</literal>).
- </para>
-
- <programlisting role="JAVA">@Name("myGuicyComponent")
-@Guice public class MyGuicyComponent
-{
- @Inject MyObject myObject;
- @Inject @Special MyObject mySpecialObject;
- ...
-}</programlisting>
-
- <para>
- This Guice injection will happen on every method call, just like with
bijection. Guice
- injects based on type and binding. To satisify the dependencies in the previous
example,
- you might have bound the following implementations in a Guice module, where
- <literal>@Special</literal> is an annotation you define in your
application.
- </para>
-
- <programlisting role="JAVA">public class MyGuicyModule implements
Module
-{
- public void configure(Binder binder)
- {
- binder.bind(MyObject.class)
- .toInstance(new MyObject("regular"));
-
- binder.bind(MyObject.class).annotatedWith(Special.class)
- .toInstance(new MyObject("special"));
- }
-}</programlisting>
-
- <para>
- Great, but which Guice injector will be used to inject the dependencies? Well,
you need
- to perform some setup first.
- </para>
-
- </section>
-
- <section>
-
- <title>Configuring an injector</title>
-
- <para>
- You tell Seam which Guice injector to use by hooking it into the injection
property
- of the Guice initization component in the Seam component descriptor
(components.xml):
- </para>
-
- <programlisting role="XML"><![CDATA[<components
xmlns="http://jboss.com/products/seam/components"
-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-
xmlns:guice="http://jboss.org/products/seam/guice"
- xsi:schemaLocation="
-
http://jboss.com/products/seam/guice
-
http://jboss.com/products/seam/guice-2.2.xsd
-
http://jboss.com/products/seam/components
-
http://jboss.com/products/seam/components-2.2.xsd">
-
- <guice:init injector="#{myGuiceInjector}"/>
-
-</components>]]></programlisting>
-
- <para>
- <literal>myGuiceInjector</literal> must resolve to a Seam component
that implements the
- Guice <literal>Injector</literal> interface.
- </para>
-
- <para>
- Having to create an injector is boiler-plate code, though. What you really want
to be able
- to do is simply hook up Seam to your Guice modules. Fortunately, there is a
built-in Seam
- component that implements the <literal>Injector</literal> interface
to do exactly that. You
- can configure it in the Seam component descriptor with this additional stanza.
- </para>
-
- <programlisting role="XML"><![CDATA[<guice:injector
name="myGuiceInjector">
- <guice:modules>
- <value>com.example.guice.GuiceModule1</value>
- <value>com.example.guice.GuiceModule2</value>
- </guice:modules>
-</guice:injector>]]></programlisting>
-
- <para>
- Of course you can also use an injector that is already used in other, possibly
non-Seam
- part of you application. That's one of the main motivations for creating
this integration.
- Since the injector is defined with EL expression, you can obtain it in whatever
way you
- like. For instance, you may use the Seam factory component pattern to provide
injector.
- </para>
-
- <programlisting
role="JAVA">@Name("myGuiceInjectorFactory")
-public InjectorFactory
-{
- @Factory(name = "myGuiceInjector", scope = APPLICATION, create = true)
- public Injector getInjector()
- {
- // Your code that returns injector
- }
-}</programlisting>
-
- </section>
-
- <section>
- <title>Using multiple injectors</title>
-
- <para>
- By default, an injector configured in the Seam component descriptor is used. If
you really
- need to use multiple injectors (AFAIK, you should use multiple modules instead),
you can
- specify different injector for every Seam component in the
<literal>@Guice</literal>
- annotation.
- </para>
-
- <programlisting role="JAVA">@Name("myGuicyComponent")
-@Guice("myGuiceInjector")
-public class MyGuicyComponent
-{
- @Inject MyObject myObject;
- ...
-}</programlisting>
-
- </section>
-
- <para>
- That's all there is to it! Check out the guice example in the Seam distribution
to see the
- Seam Guice integration in action!
- </para>
-
-</chapter>
Modified: branches/enterprise/JBPAPP_5_0/doc/Seam_Reference_Guide/en-US/master.xml
===================================================================
--- branches/enterprise/JBPAPP_5_0/doc/Seam_Reference_Guide/en-US/master.xml 2009-08-05
11:20:33 UTC (rev 11345)
+++ branches/enterprise/JBPAPP_5_0/doc/Seam_Reference_Guide/en-US/master.xml 2009-08-05
12:24:08 UTC (rev 11346)
@@ -29,7 +29,6 @@
<xi:include href="Remoting.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
<xi:include href="Gwt.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
<xi:include href="Spring.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
- <xi:include href="Guice.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
<xi:include href="Hsearch.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
<xi:include href="Configuration.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
<xi:include href="Annotations.xml"
xmlns:xi="http://www.w3.org/2001/XInclude" />
Modified: branches/enterprise/JBPAPP_5_0/examples/build.xml
===================================================================
--- branches/enterprise/JBPAPP_5_0/examples/build.xml 2009-08-05 11:20:33 UTC (rev 11345)
+++ branches/enterprise/JBPAPP_5_0/examples/build.xml 2009-08-05 12:24:08 UTC (rev 11346)
@@ -188,12 +188,6 @@
<include name="jboss-seam-remoting.jar" if="seam.remoting.lib"
/>
</fileset>
- <!-- Seam IoC Guice, with required dependencies -->
- <fileset id="seam.ioc-guice.jar" dir="${lib.dir}">
- <include name="jboss-seam-ioc.jar" if="seam.ioc-guice.lib"
/>
- <include name="guice.jar" if="seam.ioc-guice.lib" />
- </fileset>
-
<!-- jboss-el -->
<fileset id="jboss-el.jar" dir="${lib.dir}">
<include name="jboss-el.jar" />
@@ -680,7 +674,6 @@
<fileset refid="jcaptcha.jar" />
<fileset refid="antlr.jar" />
<fileset refid="seam.remoting.jar" />
- <fileset refid="seam.ioc-guice.jar" />
<fileset refid="el-ri.jar" />
<fileset refid="trinidad-api.jar" />
<fileset refid="metawidget-backend.jar" />
Modified: branches/enterprise/JBPAPP_5_0/seam-gen/ivy/ivy-build.xml
===================================================================
--- branches/enterprise/JBPAPP_5_0/seam-gen/ivy/ivy-build.xml 2009-08-05 11:20:33 UTC (rev
11345)
+++ branches/enterprise/JBPAPP_5_0/seam-gen/ivy/ivy-build.xml 2009-08-05 12:24:08 UTC (rev
11346)
@@ -12,7 +12,7 @@
<property name="seam.version" value="2.1.2"/>
<property name="jsf.version" value="1.2_12"/>
<property name="richfaces.version" value="3.3.1.GA"/>
- <property name="jboss-embedded.version" value="beta3.SP8"/>
+ <property name="jboss-embedded.version" value="beta3.SP9"/>
<target name="init-ivy">
<available property="ivy.installed" value="true"
file="${ivy.jar.file}" type="file"/>