polygene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From soelvs...@apache.org
Subject zest-java git commit: ZEST-135 minor error fix
Date Thu, 17 Dec 2015 22:18:20 GMT
Repository: zest-java
Updated Branches:
  refs/heads/ZEST-132 9c0995de4 -> 4190b401d


ZEST-135 minor error fix


Project: http://git-wip-us.apache.org/repos/asf/zest-java/repo
Commit: http://git-wip-us.apache.org/repos/asf/zest-java/commit/4190b401
Tree: http://git-wip-us.apache.org/repos/asf/zest-java/tree/4190b401
Diff: http://git-wip-us.apache.org/repos/asf/zest-java/diff/4190b401

Branch: refs/heads/ZEST-132
Commit: 4190b401d36ac470cc15edc2363203803f4bdfc3
Parents: 9c0995d
Author: Kent Sølvsten <soelvsten@apache.org>
Authored: Thu Dec 17 23:18:18 2015 +0100
Committer: Kent Sølvsten <soelvsten@apache.org>
Committed: Thu Dec 17 23:18:18 2015 +0100

----------------------------------------------------------------------
 .../apache/zest/bootstrap/handler/ModuleAssembledEvent.java  | 2 +-
 .../zest/runtime/bootstrap/ApplicationModelFactoryImpl.java  | 4 ++--
 .../main/java/org/apache/zest/test/AbstractZestBaseTest.java | 8 +++-----
 3 files changed, 6 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/zest-java/blob/4190b401/core/bootstrap/src/main/java/org/apache/zest/bootstrap/handler/ModuleAssembledEvent.java
----------------------------------------------------------------------
diff --git a/core/bootstrap/src/main/java/org/apache/zest/bootstrap/handler/ModuleAssembledEvent.java
b/core/bootstrap/src/main/java/org/apache/zest/bootstrap/handler/ModuleAssembledEvent.java
index a7b63e3..9d9ea77 100755
--- a/core/bootstrap/src/main/java/org/apache/zest/bootstrap/handler/ModuleAssembledEvent.java
+++ b/core/bootstrap/src/main/java/org/apache/zest/bootstrap/handler/ModuleAssembledEvent.java
@@ -24,7 +24,7 @@ import org.apache.zest.bootstrap.ModuleAssembly;
 
 public class ModuleAssembledEvent extends ZestAssemblyEvent<ModuleAssembledEvent.Handler>
 {
-    private static final Type<Handler> TYPE = new Type();
+    public static final Type<Handler> TYPE = new Type();
 
     private final ModuleAssembly module;
 

http://git-wip-us.apache.org/repos/asf/zest-java/blob/4190b401/core/runtime/src/main/java/org/apache/zest/runtime/bootstrap/ApplicationModelFactoryImpl.java
----------------------------------------------------------------------
diff --git a/core/runtime/src/main/java/org/apache/zest/runtime/bootstrap/ApplicationModelFactoryImpl.java
b/core/runtime/src/main/java/org/apache/zest/runtime/bootstrap/ApplicationModelFactoryImpl.java
index 6f1bc79..567d721 100755
--- a/core/runtime/src/main/java/org/apache/zest/runtime/bootstrap/ApplicationModelFactoryImpl.java
+++ b/core/runtime/src/main/java/org/apache/zest/runtime/bootstrap/ApplicationModelFactoryImpl.java
@@ -29,11 +29,11 @@ import org.apache.zest.bootstrap.ApplicationModelFactory;
 import org.apache.zest.bootstrap.AssemblyException;
 import org.apache.zest.bootstrap.BindingException;
 import org.apache.zest.bootstrap.LayerAssembly;
-import org.apache.zest.bootstrap.handler.ModuleAssembledEvent;
 import org.apache.zest.functional.HierarchicalVisitor;
 import org.apache.zest.runtime.activation.ActivatorsModel;
 import org.apache.zest.runtime.composite.CompositeMethodModel;
 import org.apache.zest.runtime.event.EventBus;
+import org.apache.zest.runtime.event.ModuleAssembledRuntimeEvent;
 import org.apache.zest.runtime.injection.InjectedFieldModel;
 import org.apache.zest.runtime.model.Binder;
 import org.apache.zest.runtime.model.Resolution;
@@ -92,7 +92,7 @@ public final class ApplicationModelFactoryImpl
 
             for( ModuleAssemblyImpl moduleAssembly : layerAssembly.moduleAssemblies() )
             {
-                eventBus.emit( new ModuleAssembledEvent( moduleAssembly ) );
+                eventBus.emit( new ModuleAssembledRuntimeEvent( moduleAssembly ) );
                 moduleModels.add( moduleAssembly.assembleModule( helper ) );
             }
             mapAssemblyModel.put( layerAssembly, layerModel );

http://git-wip-us.apache.org/repos/asf/zest-java/blob/4190b401/core/testsupport/src/main/java/org/apache/zest/test/AbstractZestBaseTest.java
----------------------------------------------------------------------
diff --git a/core/testsupport/src/main/java/org/apache/zest/test/AbstractZestBaseTest.java
b/core/testsupport/src/main/java/org/apache/zest/test/AbstractZestBaseTest.java
index ec1ca26..0d8f66f 100755
--- a/core/testsupport/src/main/java/org/apache/zest/test/AbstractZestBaseTest.java
+++ b/core/testsupport/src/main/java/org/apache/zest/test/AbstractZestBaseTest.java
@@ -19,8 +19,6 @@
 package org.apache.zest.test;
 
 import org.apache.zest.api.ZestAPI;
-import org.apache.zest.api.event.ZestEvent;
-import org.apache.zest.api.event.ZestUserEventHandler;
 import org.apache.zest.api.structure.Application;
 import org.apache.zest.api.structure.ApplicationDescriptor;
 import org.apache.zest.bootstrap.ApplicationAssembler;
@@ -46,6 +44,7 @@ public abstract class AbstractZestBaseTest
         throws Exception
     {
         zest = new Energy4Java();
+        addUserEventHandlers( zest.applicationAssemblyFactory() );
         applicationModel = newApplication();
         if( applicationModel == null )
         {
@@ -58,9 +57,8 @@ public abstract class AbstractZestBaseTest
         application.activate();
     }
 
-    <H extends ZestUserEventHandler> void addUserEventHandler( ZestEvent.Type<H>
type, H handler ) {
-        zest.applicationAssemblyFactory().addUserEventHandler( type, handler );
-    };
+    protected void addUserEventHandlers( ApplicationAssemblyFactory assemblyFactory ) {
+    }
 
     /** Called by the superclass for the test to define the entire application, every layer,
every module and all
      * the contents of each module.


Mime
View raw message