You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by ge...@apache.org on 2010/04/22 11:12:46 UTC

svn commit: r936669 [1/2] - in /geronimo/sandbox/shawn/owb_geronimo_example: ./ guess-tomcat/ guess-tomcat/src/ guess-tomcat/src/main/ guess-tomcat/src/main/history/ guess-tomcat/src/main/plan/ guess/ guess/src/ guess/src/main/ guess/src/main/java/ gue...

Author: genspring
Date: Thu Apr 22 09:12:45 2010
New Revision: 936669

URL: http://svn.apache.org/viewvc?rev=936669&view=rev
Log:
Geronimo owb app plugin sample based on owb guess sample. Used to test owb geronimo integration code.

Added:
    geronimo/sandbox/shawn/owb_geronimo_example/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/
    geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/
    geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/pom.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/
    geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/
    geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/history/
    geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/history/dependencies.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/plan/
    geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/plan/plan.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/pom.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LoginBean.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LogoutBean.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/JmsBinding.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/LoggedInUser.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/conversation/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/conversation/ShoppingCardBean.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/dependent/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/dependent/LoginCheck.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/event/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/event/LoggedInEvent.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/Highest.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/JSFNumberGuess.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NextNumber.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NumberProducer.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/User.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/conversation/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/conversation/ConversationModel.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/observer/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/observer/LoggedInObserver.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/util/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/util/FacesMessageUtil.java   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/beans.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/openwebbeans/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/openwebbeans/openwebbeans.properties   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/beans.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/faces-config.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/web.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/conversation.xhtml
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/home.xhtml
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/index.html   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/login.xhtml
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/redirect.xhtml
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/site/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/site/apt/
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/site/apt/index.apt   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/guess/src/site/site.xml   (with props)
    geronimo/sandbox/shawn/owb_geronimo_example/pom.xml   (with props)

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/pom.xml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/pom.xml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/pom.xml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,128 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.
+-->
+
+<!-- $Rev: 901686 $ $Date: 2010-01-21 20:53:52 +0800 (Thu, 21 Jan 2010) $ -->
+
+<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/maven-v4_0_0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.geronimo.plugins</groupId>
+        <artifactId>plugins</artifactId>
+        <version>3.0-SNAPSHOT</version>
+    </parent>
+
+    <groupId>org.apache.geronimo.samples</groupId>
+    <artifactId>guess-tomcat</artifactId>
+    <name>Geronimo Samples :: owb guess war :: plugin for tomcat</name>
+    <packaging>car</packaging>
+
+    <description>The Servlet examples originally developed for Tomcat. Can be found via HTTP at /servlet-examples/ after installation. These examples give a basic introduction to Servlet development along with sample code.</description>
+
+    <dependencies>
+        
+        <dependency>
+            <groupId>org.apache.openwebbeans.samples</groupId>
+            <artifactId>guess</artifactId>
+            <version>1.0.0-SNAPSHOT</version>
+            <type>war</type>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>tomcat7-deployer</artifactId>
+            <version>${geronimoVersion}</version>
+            <type>car</type>
+            <scope>provided</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>tomcat7</artifactId>
+            <version>${geronimoVersion}</version>
+            <type>car</type>
+            <scope>provided</scope>            
+        </dependency>
+        
+          <dependency>      
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>openwebbeans-deployer</artifactId>
+            <version>${geronimoVersion}</version>
+            <type>car</type>
+            <scope>provided</scope>            
+        </dependency>
+        
+        <dependency>      
+            <groupId>org.apache.geronimo.configs</groupId>
+            <artifactId>openwebbeans</artifactId>
+            <version>${geronimoVersion}</version>
+            <type>car</type>
+            <scope>provided</scope>            
+        </dependency>
+        
+    </dependencies>
+
+    <build>
+
+        <plugins>
+            <plugin>
+                <groupId>org.apache.geronimo.buildsupport</groupId>
+                <artifactId>car-maven-plugin</artifactId>
+                <configuration>
+                    <deploymentConfigs>
+                        <deploymentConfig>${gbeanDeployer}</deploymentConfig>
+                        <deploymentConfig>${j2eeDeployer}</deploymentConfig>
+                        <deploymentConfig>${tomcatDeployer}</deploymentConfig>
+                        <deploymentConfig>${myfacesDeployer}</deploymentConfig>
+                        <deploymentConfig>${openwebbeansDeployer}</deploymentConfig>                        
+                    </deploymentConfigs>
+                    <module>
+                        <groupId>org.apache.openwebbeans.samples</groupId>
+                        <artifactId>guess</artifactId>
+                        <version>1.0.0-SNAPSHOT</version>
+                        <type>war</type>
+                    </module>
+                    <useMavenDependencies>
+                        <value>true</value>
+                        <includeVersion>true</includeVersion>
+                    </useMavenDependencies>
+                    <category>Sample</category>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+    <profiles>
+        <profile>
+            <id>it</id>
+            <!--<properties>-->
+            <!--<it-server>tomcat-minimal</it-server>-->
+            <!--</properties>-->
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.apache.geronimo.buildsupport</groupId>
+                        <artifactId>geronimo-maven-plugin</artifactId>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
+    </profiles>
+</project>

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/history/dependencies.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/history/dependencies.xml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/history/dependencies.xml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/history/dependencies.xml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<plugin-artifact xmlns:ns2="http://geronimo.apache.org/xml/ns/attributes-1.2" xmlns="http://geronimo.apache.org/xml/ns/plugins-1.3">
+    <module-id>
+        <groupId>org.apache.geronimo.samples</groupId>
+        <artifactId>guess-tomcat</artifactId>
+        <version>3.0-SNAPSHOT</version>
+        <type>car</type>
+    </module-id>
+    <dependency>
+        <groupId>org.apache.geronimo.configs</groupId>
+        <artifactId>openwebbeans</artifactId>
+        <type>car</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.configs</groupId>
+        <artifactId>openwebbeans-deployer</artifactId>
+        <type>car</type>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.geronimo.configs</groupId>
+        <artifactId>tomcat7</artifactId>
+        <type>car</type>
+    </dependency>
+</plugin-artifact>

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/history/dependencies.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/plan/plan.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/plan/plan.xml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/plan/plan.xml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/plan/plan.xml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You under the Apache License, Version 2.0
+    (the "License"); you may not use this file except in compliance with
+    the License.  You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+    Unless required by applicable law or agreed to in writing, software
+    distributed under the License is distributed on an "AS IS" BASIS,
+    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+    See the License for the specific language governing permissions and
+    limitations under the License.-->
+<!--$Rev: 664120 $ $Date: 2008-06-07 04:53:24 +0800 (Sat, 07 Jun 2008) $-->
+<web-app xmlns="http://geronimo.apache.org/xml/ns/j2ee/web/tomcat-1.2">
+    <context-root>/guess</context-root>
+    <security-realm-name>geronimo-admin</security-realm-name>
+    <security>
+        <role-mappings>
+            <role role-name="tomcat">
+                <principal name="admin" class="org.apache.geronimo.security.realm.providers.GeronimoGroupPrincipal"/>
+            </role>
+        </role-mappings>
+    </security>
+</web-app>
\ No newline at end of file

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess-tomcat/src/main/plan/plan.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/pom.xml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/pom.xml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/pom.xml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,131 @@
+<?xml version="1.0" encoding="UTF-8"?>
+    <!--
+
+        Licensed to the Apache Software Foundation (ASF) under one or more
+        contributor license agreements. See the NOTICE file distributed with
+        this work for additional information regarding copyright ownership.
+        The ASF licenses this file to You under the Apache License, Version
+        2.0 (the "License"); you may not use this file except in compliance
+        with the License. You may obtain a copy of the License at
+
+        http://www.apache.org/licenses/LICENSE-2.0 Unless required by
+        applicable law or agreed to in writing, software distributed under the
+        License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
+        CONDITIONS OF ANY KIND, either express or implied. See the License for
+        the specific language governing permissions and limitations under the
+        License.
+    -->
+<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/maven-v4_0_0.xsd">
+    <parent>
+        <artifactId>samples</artifactId>
+        <groupId>org.apache.openwebbeans</groupId>
+        <version>1.0.0-SNAPSHOT</version>
+    </parent>
+    <modelVersion>4.0.0</modelVersion>
+    <groupId>org.apache.openwebbeans.samples</groupId>
+    <artifactId>guess</artifactId>
+    <packaging>war</packaging>
+    <name>Apache OpenWebBeans :: Sample Guess Application</name>
+    <description>Simple login application, copied from openwebbeans project for sample to develop the owb-geronimo integration code.</description>
+
+    <build>
+        <finalName>guess</finalName>
+        <plugins>
+            <plugin>
+                <groupId>org.mortbay.jetty</groupId>
+                <artifactId>maven-jetty-plugin</artifactId>
+                <version>6.1.18</version>
+                <configuration>
+                    <scanIntervalSeconds>10</scanIntervalSeconds>
+                </configuration>
+            </plugin>
+        </plugins>        
+    </build>
+        
+    <dependencies>
+
+        <!-- JSF Facelet -->
+        <dependency>
+            <groupId>com.sun.facelets</groupId>
+            <artifactId>jsf-facelets</artifactId>
+            <version>1.1.14</version>
+            <scope>provided</scope>            
+        </dependency>
+                                
+        <!-- MyFaces API -->
+        <dependency>
+            <groupId>org.apache.myfaces.core</groupId>
+            <artifactId>myfaces-api</artifactId>
+            <version>1.2.8</version>
+            <scope>provided</scope>            
+        </dependency>
+                        
+        <!-- JSF Plugin -->
+        <dependency>
+            <groupId>org.apache.openwebbeans</groupId>
+            <artifactId>openwebbeans-jsf</artifactId>
+            <version>${project.version}</version>
+            <scope>provided</scope>            
+        </dependency>
+                
+        <!-- Servlet API -->
+        <dependency>
+            <groupId>org.apache.geronimo.specs</groupId>
+            <artifactId>geronimo-servlet_2.5_spec</artifactId>
+            <scope>provided</scope>
+        </dependency>
+
+         <!-- JSR-299 implementation per application -->
+         <dependency>
+                 <groupId>org.apache.openwebbeans</groupId>
+                 <artifactId>openwebbeans-impl</artifactId>
+                 <scope>provided</scope>                 
+         </dependency>
+         
+         <!-- Web Plugin -->
+         <dependency>
+             <groupId>org.apache.openwebbeans</groupId>
+             <artifactId>openwebbeans-web</artifactId>
+             <version>${project.version}</version>
+            <scope>provided</scope>            
+         </dependency>
+        
+        <!-- JSR-299 API -->
+        <dependency>
+            <groupId>org.apache.geronimo.specs</groupId>
+            <artifactId>geronimo-jcdi_1.0_spec</artifactId>
+            <scope>provided</scope>            
+        </dependency>
+        
+        <!-- JSR-330 API -->
+        <dependency>
+                <groupId>org.apache.geronimo.specs</groupId>
+                <artifactId>geronimo-atinject_1.0_spec</artifactId>
+                <scope>provided</scope>                
+        </dependency>
+        
+        <!-- SPI API -->
+        <dependency>
+            <groupId>org.apache.openwebbeans</groupId>
+            <artifactId>openwebbeans-spi</artifactId>
+            <scope>provided</scope>            
+        </dependency>        
+
+        <!-- Interceptor API -->    
+        <dependency>
+            <groupId>org.apache.geronimo.specs</groupId>
+            <artifactId>geronimo-interceptor_1.1_spec</artifactId>
+            <scope>provided</scope>            
+        </dependency>
+
+        <!-- MyFaces IMPL -->
+        <dependency>
+            <groupId>org.apache.myfaces.core</groupId>
+            <artifactId>myfaces-impl</artifactId>
+            <version>1.2.8</version>
+            <scope>provided</scope>
+        </dependency>
+
+                
+    </dependencies>
+</project>

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LoginBean.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LoginBean.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LoginBean.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LoginBean.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,122 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.bean;
+
+
+import javax.enterprise.context.RequestScoped;
+import javax.enterprise.context.SessionScoped;
+import javax.enterprise.event.Event;
+import javax.enterprise.event.Observes;
+import javax.enterprise.inject.Any;
+import javax.enterprise.inject.Default;
+import javax.inject.Inject;
+import javax.inject.Named;
+import javax.enterprise.inject.Produces;
+import javax.faces.application.FacesMessage;
+
+import org.apache.webbeans.sample.bindings.LoggedInUser;
+import org.apache.webbeans.sample.dependent.LoginCheck;
+import org.apache.webbeans.sample.event.LoggedInEvent;
+import org.apache.webbeans.sample.model.User;
+import org.apache.webbeans.sample.util.FacesMessageUtil;
+
+@RequestScoped
+@Named
+public class LoginBean
+{
+	private User user = null;
+	
+	private String userName;
+	
+	private String password;
+	
+	private @Inject @Default LoginCheck loginCheck;
+	
+	private @Inject @Default FacesMessageUtil messageUtil;
+	
+	private @Inject @Any Event<LoggedInEvent> event;
+	
+	public LoginBean()
+	{
+		
+	}
+	
+	public String login()
+	{
+		if(loginCheck.checkLogin(this.userName, this.password))
+		{
+			user = new User();
+			user.setUserName(this.userName);
+			user.setPassword(this.password);
+			
+			event.fire(new LoggedInEvent(this.user));
+			
+			return "loginSuccess";
+		}
+		else
+		{
+			messageUtil.addMessage(FacesMessage.SEVERITY_ERROR, "Login Failed", "Login failed");
+			return null;
+		}
+	}
+	
+	public void afterLoggedIn(@Observes LoggedInEvent event)
+	{
+		messageUtil.addMessage(FacesMessage.SEVERITY_INFO, "Login Successfull", "Login Successfull");
+	}
+	
+	
+	@Produces @SessionScoped @LoggedInUser @Named(value="currentUser")
+	public User getLoggedInUser()
+	{
+		return this.user;
+	}
+
+	/**
+	 * @return the userName
+	 */
+	public String getUserName()
+	{
+		return userName;
+	}
+
+	/**
+	 * @param userName the userName to set
+	 */
+	public void setUserName(String userName)
+	{
+		this.userName = userName;
+	}
+
+	/**
+	 * @return the password
+	 */
+	public String getPassword()
+	{
+		return password;
+	}
+
+	/**
+	 * @param password the password to set
+	 */
+	public void setPassword(String password)
+	{
+		this.password = password;
+	}
+	
+	
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LoginBean.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LogoutBean.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LogoutBean.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LogoutBean.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LogoutBean.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,46 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.bean;
+
+import javax.inject.Inject;
+import javax.inject.Named;
+import javax.faces.context.FacesContext;
+import javax.servlet.http.HttpSession;
+
+import org.apache.webbeans.sample.bindings.LoggedInUser;
+import org.apache.webbeans.sample.model.User;
+
+@Named
+public class LogoutBean
+{
+	private @Inject @LoggedInUser User user;
+
+	public LogoutBean()
+	{
+		
+	}
+	
+	public String logout()
+	{
+		System.out.println("Logged out User : " + user.getUserName());
+		
+		HttpSession session = (HttpSession) FacesContext.getCurrentInstance().getExternalContext().getSession(true);
+		session.invalidate();
+		
+		return "login";
+	}
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bean/LogoutBean.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/JmsBinding.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/JmsBinding.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/JmsBinding.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/JmsBinding.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,33 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.bindings;
+
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+import javax.inject.Qualifier;
+
+
+@Qualifier
+@Retention(RetentionPolicy.RUNTIME)
+@Target({ElementType.FIELD,ElementType.METHOD, ElementType.TYPE, ElementType.PARAMETER})
+public @interface JmsBinding
+{
+
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/JmsBinding.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/LoggedInUser.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/LoggedInUser.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/LoggedInUser.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/LoggedInUser.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,33 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.bindings;
+
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+import javax.inject.Qualifier;
+
+
+@Qualifier
+@Retention(RetentionPolicy.RUNTIME)
+@Target({ElementType.FIELD,ElementType.METHOD, ElementType.TYPE, ElementType.PARAMETER})
+public @interface LoggedInUser
+{
+
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/bindings/LoggedInUser.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/conversation/ShoppingCardBean.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/conversation/ShoppingCardBean.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/conversation/ShoppingCardBean.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/conversation/ShoppingCardBean.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,110 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.conversation;
+
+import java.io.Serializable;
+
+import javax.enterprise.context.Conversation;
+import javax.enterprise.context.RequestScoped;
+import javax.enterprise.inject.Default;
+import javax.inject.Inject;
+import javax.inject.Named;
+import javax.faces.application.FacesMessage;
+
+import org.apache.webbeans.sample.model.conversation.ConversationModel;
+import org.apache.webbeans.sample.util.FacesMessageUtil;
+
+@RequestScoped
+@Named
+public class ShoppingCardBean implements Serializable
+{
+    private static final long serialVersionUID = 7914095399647910625L;
+
+    private @Inject @Default Conversation conversation;
+    
+    private @Inject @Default ConversationModel model;
+    
+    private @Inject @Default FacesMessageUtil messageUtil;
+    
+    private String book;
+    
+    public String startConversation()
+    {
+        conversation.begin();
+        
+        messageUtil.addMessage(FacesMessage.SEVERITY_INFO, "Conversation with id : " + conversation.getId() + " is started", null);
+        
+        return null;
+    }
+    
+    public String addNewBook()
+    {
+        model.getList().add(this.book);
+        
+        StringBuffer buffer = new StringBuffer("Your shopping card contents : [");
+        
+        for(String b : model.getList())
+        {
+            buffer.append("," + b);
+        }
+        
+        messageUtil.addMessage(FacesMessage.SEVERITY_INFO, buffer.toString() + "]", null);
+        
+        
+        return null;
+    }
+    
+    public String getBooks()
+    {
+        StringBuffer buffer = new StringBuffer("Your shopping card contents : [");
+        
+        for(String b : model.getList())
+        {
+            buffer.append("," + b);
+        }
+        
+        return buffer.toString();
+        
+    }
+    
+    public String endConversation()
+    {
+        messageUtil.addMessage(FacesMessage.SEVERITY_INFO, "Conversation with id : " + conversation.getId() + " is ended", null);
+        
+        conversation.end();        
+        
+        return null;
+    }
+
+    /**
+     * @return the book
+     */
+    public String getBook()
+    {
+        return book;
+    }
+
+    /**
+     * @param book the book to set
+     */
+    public void setBook(String book)
+    {
+        this.book = book;
+    }
+
+    
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/conversation/ShoppingCardBean.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/dependent/LoginCheck.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/dependent/LoginCheck.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/dependent/LoginCheck.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/dependent/LoginCheck.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,35 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.dependent;
+
+import javax.enterprise.context.Dependent;
+
+
+@Dependent
+public class LoginCheck
+{
+	
+	public boolean checkLogin(String userName, String password)
+	{
+		if(userName.equals("admin") && password.equals("admin"))
+		{
+			return true;
+		}
+		
+		return false;
+	}
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/dependent/LoginCheck.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/event/LoggedInEvent.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/event/LoggedInEvent.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/event/LoggedInEvent.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/event/LoggedInEvent.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,35 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.event;
+
+import org.apache.webbeans.sample.model.User;
+
+public class LoggedInEvent
+{
+	private User user;
+	
+	public LoggedInEvent(User user)
+	{
+		this.user = user;
+	}
+	
+	public User getUser()
+	{
+		return this.user;
+	}
+
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/event/LoggedInEvent.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/Highest.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/Highest.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/Highest.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/Highest.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,40 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.guess;
+
+
+import static java.lang.annotation.ElementType.FIELD;
+import static java.lang.annotation.ElementType.METHOD;
+import static java.lang.annotation.ElementType.PARAMETER;
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+import javax.inject.Qualifier;
+
+
+@Qualifier
+@Target( { TYPE, METHOD, PARAMETER, FIELD })
+@Retention(RUNTIME)
+@Documented
+public @interface Highest
+{
+
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/Highest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/JSFNumberGuess.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/JSFNumberGuess.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/JSFNumberGuess.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/JSFNumberGuess.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,237 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with this
+ * work for additional information regarding copyright ownership. The ASF
+ * licenses this file to You under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law
+ * or agreed to in writing, software distributed under the License is
+ * distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the specific language
+ * governing permissions and limitations under the License.
+ */
+package org.apache.webbeans.sample.guess;
+
+import java.io.Serializable;
+import java.lang.annotation.Annotation;
+import java.util.Set;
+
+import javax.enterprise.context.SessionScoped;
+import javax.enterprise.inject.Default;
+import javax.inject.Named;
+import javax.enterprise.inject.spi.Bean;
+import javax.enterprise.inject.spi.BeanManager;
+import javax.enterprise.util.AnnotationLiteral;
+import javax.faces.application.FacesMessage;
+import javax.faces.context.FacesContext;
+import javax.inject.Inject;
+
+@Named(value = "game")
+@SessionScoped
+public class JSFNumberGuess implements Serializable
+{
+    private static final long serialVersionUID = 2264057893898002872L;
+
+    private int no;
+    private boolean correct = false;
+    private int guess = 1;
+    private int smallRange;
+    private int maxRange;
+    private int remainder;
+    private @Inject @Default BeanManager manager;
+
+    public JSFNumberGuess()
+    {
+
+    }
+
+    @Inject
+    public JSFNumberGuess(@NextNumber Integer number, @Highest Integer maxNumber)
+    {
+        this.no = number;
+        this.smallRange = 1;
+        this.maxRange = maxNumber;
+        this.remainder = 10;
+    }
+
+    public String clear()
+    {
+        Annotation[] anns = new Annotation[1];
+        anns[0] = new AnnotationLiteral<NextNumber>()
+        {
+        };
+
+        Annotation[] anns2 = new Annotation[1];
+        anns2[0] = new AnnotationLiteral<Highest>()
+        {
+        };
+
+        Set<Bean<?>> beans = manager.getBeans(Integer.class, anns);
+        Bean<?> bean = beans.iterator().next();
+        this.no = (Integer)manager.getReference(bean, null, manager.createCreationalContext(bean));
+        //this.no = manager.getInstanceByType(Integer.class, anns);
+        setSmallRange(1);
+        beans = manager.getBeans(Integer.class, anns2);
+        bean = beans.iterator().next();
+        setMaxRange((Integer)manager.getReference(bean, null, manager.createCreationalContext(bean)));
+        //setMaxRange(manager.getInstanceByType(Integer.class, anns2));
+        setRemainder(10);
+        setGuess(1);
+        setCorrect(false);
+
+        return null;
+    }
+
+    public String checkNumber()
+    {
+        if (correct)
+        {
+            FacesContext.getCurrentInstance().addMessage(null, new FacesMessage("Game is over! Please restart the game..."));
+            return null;
+        }
+
+        if (guess > no)
+        {
+            maxRange = guess - 1;
+        }
+        if (guess < no)
+        {
+            smallRange = guess + 1;
+        }
+        if (guess == no)
+        {
+            correct = true;
+            FacesContext.getCurrentInstance().addMessage(null, new FacesMessage("Correct! Please restart the game..."));
+
+            return null;
+        }
+
+        if (remainder == 0)
+        {
+            FacesContext.getCurrentInstance().addMessage(null, new FacesMessage("Game is over! Please restart the game..."));
+            this.correct = false;
+
+            return null;
+        }
+        else
+        {
+            remainder-=1;
+        }
+
+        return null;
+    }
+
+    /**
+     * @return the no
+     */
+    public int getNo()
+    {
+        return no;
+    }
+
+    /**
+     * @param no the no to set
+     */
+    public void setNo(int no)
+    {
+        this.no = no;
+    }
+
+    /**
+     * @return the correct
+     */
+    public boolean isCorrect()
+    {
+        return correct;
+    }
+
+    /**
+     * @param correct the correct to set
+     */
+    public void setCorrect(boolean correct)
+    {
+        this.correct = correct;
+    }
+
+    /**
+     * @return the guess
+     */
+    public int getGuess()
+    {
+        return guess;
+    }
+
+    /**
+     * @param guess the guess to set
+     */
+    public void setGuess(int guess)
+    {
+        this.guess = guess;
+    }
+
+    /**
+     * @return the smallRange
+     */
+    public int getSmallRange()
+    {
+        return smallRange;
+    }
+
+    /**
+     * @param smallRange the smallRange to set
+     */
+    public void setSmallRange(int smallRange)
+    {
+        this.smallRange = smallRange;
+    }
+
+    /**
+     * @return the maxRange
+     */
+    public int getMaxRange()
+    {
+        return maxRange;
+    }
+
+    /**
+     * @param maxRange the maxRange to set
+     */
+    public void setMaxRange(int maxRange)
+    {
+        this.maxRange = maxRange;
+    }
+
+    /**
+     * @return the remainder
+     */
+    public int getRemainder()
+    {
+        return remainder;
+    }
+
+    /**
+     * @param remainder the remainder to set
+     */
+    public void setRemainder(int remainder)
+    {
+        this.remainder = remainder;
+    }
+
+    /**
+     * @return the manager
+     */
+    public BeanManager getManager()
+    {
+        return manager;
+    }
+
+    /**
+     * @param manager the manager to set
+     */
+    public void setManager(BeanManager manager)
+    {
+        this.manager = manager;
+    }
+
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/JSFNumberGuess.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NextNumber.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NextNumber.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NextNumber.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NextNumber.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,40 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.guess;
+
+
+import static java.lang.annotation.ElementType.FIELD;
+import static java.lang.annotation.ElementType.METHOD;
+import static java.lang.annotation.ElementType.PARAMETER;
+import static java.lang.annotation.ElementType.TYPE;
+import static java.lang.annotation.RetentionPolicy.RUNTIME;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.Retention;
+import java.lang.annotation.Target;
+
+import javax.inject.Qualifier;
+
+
+@Qualifier
+@Target( { TYPE, METHOD, PARAMETER, FIELD })
+@Retention(RUNTIME)
+@Documented
+public @interface NextNumber
+{
+
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NextNumber.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NumberProducer.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NumberProducer.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NumberProducer.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NumberProducer.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,51 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.guess;
+
+
+import java.io.Serializable;
+
+import javax.enterprise.context.SessionScoped;
+import javax.inject.Named;
+import javax.enterprise.inject.Produces;
+
+@SessionScoped
+@Named
+public class NumberProducer implements Serializable
+{
+    private static final long serialVersionUID = 2504578502938734869L;
+    private int number = 100;
+    
+    public NumberProducer()
+    {
+        
+    }
+      
+   @Produces    
+   @NextNumber
+   public Integer next() { 
+      return new Integer(new java.util.Random().nextInt(101)); 
+   }
+   
+   @Produces 
+   @Highest
+   public Integer getNumber()
+   {
+      return number;
+   }   
+   
+} 
\ No newline at end of file

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/guess/NumberProducer.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/User.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/User.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/User.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/User.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,76 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.model;
+
+import java.io.Serializable;
+
+import javax.enterprise.inject.Model;
+
+/**
+ * Simple model object for loginned users.
+ */
+@Model
+public class User implements Serializable
+{
+    private static final long serialVersionUID = 4953743986412127075L;
+
+    /**User name*/
+	private String userName;
+	
+	/**Password*/
+	private String password;
+	
+	public User()
+	{
+		
+	}
+
+	/**
+	 * @return the userName
+	 */
+	public String getUserName()
+	{
+		return userName;
+	}
+
+	/**
+	 * @param userName the userName to set
+	 */
+	public void setUserName(String userName)
+	{
+		this.userName = userName;
+	}
+
+	/**
+	 * @return the password
+	 */
+	public String getPassword()
+	{
+		return password;
+	}
+
+	/**
+	 * @param password the password to set
+	 */
+	public void setPassword(String password)
+	{
+		this.password = password;
+	}
+	
+	
+
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/User.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/conversation/ConversationModel.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/conversation/ConversationModel.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/conversation/ConversationModel.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/conversation/ConversationModel.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,43 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.model.conversation;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.enterprise.context.ConversationScoped;
+import javax.inject.Named;
+
+@ConversationScoped
+@Named
+public class ConversationModel implements Serializable
+{
+    private static final long serialVersionUID = -5042442586067259214L;
+
+    private List<String> list = new ArrayList<String>();
+    
+    public void addNewBook(String name)
+    {
+        list.add(name);
+    }
+
+    public List<String> getList()
+    {
+        return this.list;
+    }
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/model/conversation/ConversationModel.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/observer/LoggedInObserver.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/observer/LoggedInObserver.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/observer/LoggedInObserver.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/observer/LoggedInObserver.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,38 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.observer;
+
+
+import javax.enterprise.event.Observes;
+
+import org.apache.webbeans.sample.event.LoggedInEvent;
+import org.apache.webbeans.sample.model.User;
+
+
+
+public class LoggedInObserver
+{
+
+	public void afterLogin(@Observes LoggedInEvent event)
+	{
+		User user = event.getUser();
+		System.out.println("User with user name : " + user.getUserName());
+		System.out.println("User with password : " + user.getPassword());
+		
+	}
+
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/observer/LoggedInObserver.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/util/FacesMessageUtil.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/util/FacesMessageUtil.java?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/util/FacesMessageUtil.java (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/util/FacesMessageUtil.java Thu Apr 22 09:12:45 2010
@@ -0,0 +1,40 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one or more
+ *  contributor license agreements.  See the NOTICE file distributed with
+ *  this work for additional information regarding copyright ownership.
+ *  The ASF licenses this file to You under the Apache License, Version 2.0
+ *  (the "License"); you may not use this file except in compliance with
+ *  the License.  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.apache.webbeans.sample.util;
+
+import javax.enterprise.context.Dependent;
+import javax.inject.Named;
+import javax.faces.application.FacesMessage;
+import javax.faces.application.FacesMessage.Severity;
+import javax.faces.context.FacesContext;
+
+@Named(value="facesMessage")
+@Dependent
+public class FacesMessageUtil
+{
+
+	public FacesMessageUtil()
+	{
+		
+	}
+	
+	public void addMessage(Severity severity,String summary, String detail)
+	{
+		FacesMessage message = new FacesMessage(severity,summary,detail);
+		FacesContext.getCurrentInstance().addMessage(null, message);
+	}
+}

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/java/org/apache/webbeans/sample/util/FacesMessageUtil.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/beans.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/beans.xml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/beans.xml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/beans.xml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<WebBeans 	xmlns="urn:java:ee"
+ 			xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+			xsi:schemaLocation="urn:java:ee http://java.sun.com/jee/beans-1.0.xsd">	
+</WebBeans>
\ No newline at end of file

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/beans.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/openwebbeans/openwebbeans.properties
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/openwebbeans/openwebbeans.properties?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/openwebbeans/openwebbeans.properties (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/openwebbeans/openwebbeans.properties Thu Apr 22 09:12:45 2010
@@ -0,0 +1,30 @@
+#Licensed to the Apache Software Foundation (ASF) under one
+#or more contributor license agreements.  See the NOTICE file
+#distributed with this work for additional information
+#regarding copyright ownership.  The ASF licenses this file
+#to you under the Apache License, Version 2.0 (the
+#"License"); you may not use this file except in compliance
+#with the License.  You may obtain a copy of the License at
+#
+#  http://www.apache.org/licenses/LICENSE-2.0
+#
+#Unless required by applicable law or agreed to in writing,
+#software distributed under the License is distributed on an
+#"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+#KIND, either express or implied.  See the License for the
+#specific language governing permissions and limitations
+#under the License.
+#---------------------------------------------------------------
+# The default configuration for OpenWebBeans
+#
+# The default configuration is intended for a JDK and a simple ServletContainer
+# like jetty, resin or tomcat.
+# 
+#---------------------------------------------------------------
+
+#general configuration section
+
+#use OWB Specific XML Configuration
+org.apache.webbeans.useOwbSpecificXmlConfig=true
+
+org.apache.webbeans.application.useJSF2Extensions=false
\ No newline at end of file

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/resources/META-INF/openwebbeans/openwebbeans.properties
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/beans.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/beans.xml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/beans.xml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/beans.xml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<WebBeans 	xmlns="urn:java:ee"
+			xmlns:myapp="urn:java:org.apache.webbeans.sample.bindings"
+ 			xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+			xsi:schemaLocation="urn:java:ee http://java.sun.com/jee/beans-1.0.xsd">
+	
+	<Deploy>
+		<Standard/>
+		<Production/>
+	</Deploy>
+		
+</WebBeans>
\ No newline at end of file

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/beans.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/faces-config.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/faces-config.xml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/faces-config.xml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/faces-config.xml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<faces-config version="1.2" xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xi="http://www.w3.org/2001/XInclude"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd">
+
+ 	
+    <navigation-rule>
+    	<from-view-id>/home.xhtml</from-view-id>
+    	<navigation-case>
+    		<from-outcome>login</from-outcome>
+    		<to-view-id>/login.xhtml</to-view-id>
+    	</navigation-case>
+    </navigation-rule>
+	
+   <navigation-rule>
+    	<from-view-id>/login.xhtml</from-view-id>
+    	<navigation-case>
+    		<from-outcome>loginSuccess</from-outcome>
+    		<to-view-id>/home.xhtml</to-view-id>
+    	</navigation-case>
+    </navigation-rule>
+
+   <navigation-rule>
+    	<from-view-id>/conversation.xhtml</from-view-id>
+    	<navigation-case>
+    		<from-outcome>toRedirect</from-outcome>
+    		<to-view-id>/redirect.jsf?book=alis</to-view-id>
+    		<redirect/>
+    	</navigation-case>
+    </navigation-rule>
+	
+	 <application>
+  <view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
+ </application>
+
+	
+</faces-config>

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/faces-config.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/web.xml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/web.xml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/web.xml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
+  <display-name>guess</display-name>
+  
+  <welcome-file-list>
+  	<welcome-file>index.html</welcome-file>
+  </welcome-file-list>
+  
+  <servlet>
+    <servlet-name>Faces Servlet</servlet-name>
+    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
+    <load-on-startup>1</load-on-startup>
+  </servlet>
+  <servlet-mapping>
+    <servlet-name>Faces Servlet</servlet-name>
+    <url-pattern>*.jsf</url-pattern>
+  </servlet-mapping>
+	
+	<context-param>
+      <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
+      <param-value>.xhtml</param-value>
+   </context-param>
+	  
+</web-app>
\ No newline at end of file

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/WEB-INF/web.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/conversation.xhtml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/conversation.xhtml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/conversation.xhtml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/conversation.xhtml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,59 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+	
+	Licensed to the Apache Software Foundation (ASF) under one or more
+	contributor license agreements. See the NOTICE file distributed with
+	this work for additional information regarding copyright ownership.
+	The ASF licenses this file to You under the Apache License, Version
+	2.0 (the "License"); you may not use this file except in compliance
+	with the License. You may obtain a copy of the License at
+	
+	http://www.apache.org/licenses/LICENSE-2.0 Unless required by
+	applicable law or agreed to in writing, software distributed under the
+	License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
+	CONDITIONS OF ANY KIND, either express or implied. See the License for
+	the specific language governing permissions and limitations under the
+	License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml"
+    xmlns:f="http://java.sun.com/jsf/core"
+    xmlns:h="http://java.sun.com/jsf/html"
+    xmlns:ui="http://java.sun.com/jsf/facelets">
+
+<head>
+  <title>OpenWebBeans :: Examples :: Conversation</title>
+</head>
+
+<body>
+  
+  <div id="container">
+    <div id="content">
+		<h:messages globalOnly="false" showSummary="true" infoStyle="font-weight:bold;"></h:messages>
+		
+		<h:form>
+						
+			<div style="border:1px solid black;margin: 25px 75px;">
+			
+				<h:panelGrid columns="2">
+					
+					<h:outputLabel for="book">
+						<h:outputText value="Book Name : "></h:outputText>
+					</h:outputLabel>
+					<h:inputText id="book" value="#{shoppingCardBean.book}" required="true" requiredMessage="Please give a book name!"></h:inputText>
+					
+					<h:panelGroup>					
+						<h:commandButton action="#{shoppingCardBean.startConversation}" immediate="true" value="Start Conversation"></h:commandButton>
+						<h:commandButton action="#{shoppingCardBean.endConversation}" immediate="true" value="End Conversation"></h:commandButton>
+						<h:commandButton action="toRedirect" immediate="true" value="Redirect"></h:commandButton>
+					</h:panelGroup>
+					
+					<h:commandButton action="#{shoppingCardBean.addNewBook}" value="Add New Book"></h:commandButton>
+					
+				</h:panelGrid>
+			</div>
+		</h:form>
+	    </div>
+    
+  </div>
+</body>
+</html>
\ No newline at end of file

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/home.xhtml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/home.xhtml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/home.xhtml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/home.xhtml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,69 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+	
+	Licensed to the Apache Software Foundation (ASF) under one or more
+	contributor license agreements. See the NOTICE file distributed with
+	this work for additional information regarding copyright ownership.
+	The ASF licenses this file to You under the Apache License, Version
+	2.0 (the "License"); you may not use this file except in compliance
+	with the License. You may obtain a copy of the License at
+	
+	http://www.apache.org/licenses/LICENSE-2.0 Unless required by
+	applicable law or agreed to in writing, software distributed under the
+	License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
+	CONDITIONS OF ANY KIND, either express or implied. See the License for
+	the specific language governing permissions and limitations under the
+	License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml"
+    xmlns:f="http://java.sun.com/jsf/core"
+    xmlns:h="http://java.sun.com/jsf/html"
+    xmlns:ui="http://java.sun.com/jsf/facelets">
+
+<head>
+  <title>OpenWebBeans :: Examples</title>
+</head>
+
+<body>
+  
+  <div id="container">
+    <div id="content">
+        <h:form>			       
+
+	   	<div align="right">
+			<h:commandLink value="Logout" action="#{logoutBean.logout}" immediate="true"></h:commandLink>
+		</div>
+   
+	   	<h2>
+			<h:outputText value="Hello #{currentUser.userName} #{currentUser.password}"></h:outputText>
+		</h2>
+		
+      <h1>Please guess a number...</h1>
+   
+          <div style="color: red">
+             <h:messages id="messages" globalOnly="true"/>
+             <h:outputText id="higher" value="Higher..." rendered="#{game.no gt game.guess}"/>
+             <h:outputText id="lower" value="Lower..." rendered="#{game.no lt game.guess}"/>
+          </div>
+   
+          <div>
+             Please guess a number between #{game.smallRange} and #{game.maxRange}. Your remaining guesses : #{game.remainder}.
+          </div>
+     
+          <div>
+             Your guessed number: 
+             <h:inputText id="inputGuess" value="#{game.guess}" required="true" size="3">
+                <f:validateLongRange maximum="#{game.maxRange}" minimum="#{game.smallRange}"/>
+             </h:inputText>
+            <h:commandButton id="GuessButton" value="Guess Number" action="#{game.checkNumber}"/>
+            <h:commandButton id="Restart" value="Restart" action="#{game.clear}" immediate="true"/>
+          </div>
+   
+          <div>
+             <h:message id="message" for="inputGuess" style="color: red"/>
+          </div>
+        </h:form>
+    </div>    
+  </div>
+</body>
+</html>
\ No newline at end of file

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/index.html
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/index.html?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/index.html (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/index.html Thu Apr 22 09:12:45 2010
@@ -0,0 +1,21 @@
+<html>
+<!--
+	
+	Licensed to the Apache Software Foundation (ASF) under one or more
+	contributor license agreements. See the NOTICE file distributed with
+	this work for additional information regarding copyright ownership.
+	The ASF licenses this file to You under the Apache License, Version
+	2.0 (the "License"); you may not use this file except in compliance
+	with the License. You may obtain a copy of the License at
+	
+	http://www.apache.org/licenses/LICENSE-2.0 Unless required by
+	applicable law or agreed to in writing, software distributed under the
+	License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
+	CONDITIONS OF ANY KIND, either express or implied. See the License for
+	the specific language governing permissions and limitations under the
+	License.
+-->
+<head>
+  <meta http-equiv="Refresh" content="0; URL=login.jsf">
+</head>
+</html>
\ No newline at end of file

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/index.html
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/index.html
------------------------------------------------------------------------------
    svn:mime-type = text/html

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/login.xhtml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/login.xhtml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/login.xhtml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/login.xhtml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,64 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+	
+	Licensed to the Apache Software Foundation (ASF) under one or more
+	contributor license agreements. See the NOTICE file distributed with
+	this work for additional information regarding copyright ownership.
+	The ASF licenses this file to You under the Apache License, Version
+	2.0 (the "License"); you may not use this file except in compliance
+	with the License. You may obtain a copy of the License at
+	
+	http://www.apache.org/licenses/LICENSE-2.0 Unless required by
+	applicable law or agreed to in writing, software distributed under the
+	License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
+	CONDITIONS OF ANY KIND, either express or implied. See the License for
+	the specific language governing permissions and limitations under the
+	License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml"
+    xmlns:f="http://java.sun.com/jsf/core"
+    xmlns:h="http://java.sun.com/jsf/html"
+    xmlns:ui="http://java.sun.com/jsf/facelets">
+
+<head>
+  <title>OpenWebBeans :: Examples</title>
+</head>
+
+<body>
+  
+  <div id="container">
+    <div id="content">
+		<h:messages globalOnly="false" showSummary="true"></h:messages>
+		
+		<h:form id="form">
+			
+			<div align="center">
+				<h3>OpenWebBeans Examples</h3>
+				<span style="color:red;">User name : admin, Password : admin</span>
+			</div>
+			
+			<div align="center" style="border:1px solid black;">
+			
+				<h:panelGrid columns="2">
+					
+					<h:outputLabel for="userName">
+						<h:outputText value="User Name : "></h:outputText>
+					</h:outputLabel>
+					<h:inputText id="userName" value="#{loginBean.userName}"></h:inputText>
+
+					<h:outputLabel for="password">
+						<h:outputText value="Password : "></h:outputText>
+					</h:outputLabel>
+					<h:inputSecret id="password" value="#{loginBean.password}"></h:inputSecret>
+					
+					<h:commandButton action="#{loginBean.login}" value="Login"></h:commandButton>
+					<h:commandButton onclick="document.getElementById('form').reset(); return false;" value="Reset"></h:commandButton>
+					
+				</h:panelGrid>
+			</div>
+		</h:form>
+	    </div>
+    
+  </div>
+</body>
+</html>
\ No newline at end of file

Added: geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/redirect.xhtml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/redirect.xhtml?rev=936669&view=auto
==============================================================================
--- geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/redirect.xhtml (added)
+++ geronimo/sandbox/shawn/owb_geronimo_example/guess/src/main/webapp/redirect.xhtml Thu Apr 22 09:12:45 2010
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+	
+	Licensed to the Apache Software Foundation (ASF) under one or more
+	contributor license agreements. See the NOTICE file distributed with
+	this work for additional information regarding copyright ownership.
+	The ASF licenses this file to You under the Apache License, Version
+	2.0 (the "License"); you may not use this file except in compliance
+	with the License. You may obtain a copy of the License at
+	
+	http://www.apache.org/licenses/LICENSE-2.0 Unless required by
+	applicable law or agreed to in writing, software distributed under the
+	License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
+	CONDITIONS OF ANY KIND, either express or implied. See the License for
+	the specific language governing permissions and limitations under the
+	License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml"
+    xmlns:f="http://java.sun.com/jsf/core"
+    xmlns:h="http://java.sun.com/jsf/html"
+    xmlns:ui="http://java.sun.com/jsf/facelets">
+
+<head>
+  <title>OpenWebBeans :: Examples :: Conversation</title>
+</head>
+
+<body>
+  
+  <div id="container">
+    <div id="content">
+		<h:messages globalOnly="false" showSummary="true" infoStyle="font-weight:bold;"></h:messages>
+		
+		<h:form id="form">
+			
+			<div style="border:1px solid black;margin: 25px 75px;">
+			
+				<h:panelGrid columns="2">
+					
+					<h:outputLabel>
+						<h:outputText value="Redirected Books : "></h:outputText>
+					</h:outputLabel>
+					<h:outputText value="#{shoppingCardBean.books}" />					
+					
+				</h:panelGrid>
+			</div>
+		</h:form>
+	    </div>
+    
+  </div>
+</body>
+</html>
\ No newline at end of file