You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tapestry.apache.org by hl...@apache.org on 2011/07/22 02:22:38 UTC

svn commit: r1149415 - /tapestry/tapestry5/trunk/tapestry-hibernate/src/test/java/org/example/app0/services/AppModule.java

Author: hlship
Date: Fri Jul 22 00:22:38 2011
New Revision: 1149415

URL: http://svn.apache.org/viewvc?rev=1149415&view=rev
Log:
Add @SubModule annotations to force modules to be loaded when developing inside IDE

Modified:
    tapestry/tapestry5/trunk/tapestry-hibernate/src/test/java/org/example/app0/services/AppModule.java

Modified: tapestry/tapestry5/trunk/tapestry-hibernate/src/test/java/org/example/app0/services/AppModule.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-hibernate/src/test/java/org/example/app0/services/AppModule.java?rev=1149415&r1=1149414&r2=1149415&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-hibernate/src/test/java/org/example/app0/services/AppModule.java (original)
+++ tapestry/tapestry5/trunk/tapestry-hibernate/src/test/java/org/example/app0/services/AppModule.java Fri Jul 22 00:22:38 2011
@@ -1,4 +1,4 @@
-// Copyright 2007, 2008 The Apache Software Foundation
+// Copyright 2007, 2008, 2011 The Apache Software Foundation
 //
 // Licensed under the Apache License, Version 2.0 (the "License");
 // you may not use this file except in compliance with the License.
@@ -15,6 +15,7 @@
 package org.example.app0.services;
 
 import org.apache.tapestry5.SymbolConstants;
+import org.apache.tapestry5.hibernate.HibernateCoreModule;
 import org.apache.tapestry5.hibernate.HibernateModule;
 import org.apache.tapestry5.hibernate.HibernateSymbols;
 import org.apache.tapestry5.hibernate.HibernateTransactionDecorator;
@@ -24,7 +25,8 @@ import org.apache.tapestry5.ioc.ServiceR
 import org.apache.tapestry5.ioc.annotations.Match;
 import org.apache.tapestry5.ioc.annotations.SubModule;
 
-@SubModule(HibernateModule.class)
+// @SubModule just needed for developers running these tests within the IDE
+@SubModule({HibernateModule.class, HibernateCoreModule.class})
 public class AppModule
 {
     public static void bind(ServiceBinder binder)
@@ -40,7 +42,7 @@ public class AppModule
 
     @Match("*DAO")
     public static <T> T decorateTransactionally(HibernateTransactionDecorator decorator, Class<T> serviceInterface,
-            T delegate, ServiceResources resources)
+                                                T delegate, ServiceResources resources)
     {
         return decorator.build(serviceInterface, delegate, resources.getServiceId());
     }