tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmar...@apache.org
Subject svn commit: r415032 [4/5] - in /incubator/tuscany/sandbox/jboynes/sca: ./ buildtools/src/main/resources/ core2/ core2/src/main/java/org/apache/tuscany/core/bootstrap/ core2/src/main/java/org/apache/tuscany/core/builder/ core2/src/main/java/org/apache/t...
Date Sat, 17 Jun 2006 17:28:14 GMT
Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/RequestScopeInstanceLifecycleTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/RequestScopeInstanceLifecycleTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/RequestScopeInstanceLifecycleTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/RequestScopeInstanceLifecycleTestCase.java Sat Jun 17 10:28:07 2006
@@ -27,23 +27,28 @@
         RequestScopeContainer scope = new RequestScopeContainer(ctx);
         scope.start();
 
-        SystemAtomicComponent initDestroyContext = MockContextFactory.createSystemAtomicContext("InitDestroy", scope, RequestScopeInitDestroyComponent.class);
+        SystemAtomicComponent initDestroyContext = MockContextFactory
+            .createSystemAtomicContext("InitDestroy", scope, RequestScopeInitDestroyComponent.class);
         initDestroyContext.start();
 
-        SystemAtomicComponent initOnlyContext = MockContextFactory.createSystemAtomicContext("InitOnly", scope, RequestScopeInitOnlyComponent.class);
+        SystemAtomicComponent initOnlyContext =
+            MockContextFactory.createSystemAtomicContext("InitOnly", scope, RequestScopeInitOnlyComponent.class);
         initOnlyContext.start();
 
-        SystemAtomicComponent destroyOnlyContext = MockContextFactory.createSystemAtomicContext("DestroyOnly", scope, RequestScopeDestroyOnlyComponent.class);
+        SystemAtomicComponent destroyOnlyContext = MockContextFactory
+            .createSystemAtomicContext("DestroyOnly", scope, RequestScopeDestroyOnlyComponent.class);
         destroyOnlyContext.start();
 
         scope.onEvent(new RequestStart(this));
-        RequestScopeInitDestroyComponent initDestroy = (RequestScopeInitDestroyComponent) scope.getInstance(initDestroyContext);
+        RequestScopeInitDestroyComponent initDestroy =
+            (RequestScopeInitDestroyComponent) scope.getInstance(initDestroyContext);
         Assert.assertNotNull(initDestroy);
 
         RequestScopeInitOnlyComponent initOnly = (RequestScopeInitOnlyComponent) scope.getInstance(initOnlyContext);
         Assert.assertNotNull(initOnly);
 
-        RequestScopeDestroyOnlyComponent destroyOnly = (RequestScopeDestroyOnlyComponent) scope.getInstance(destroyOnlyContext);
+        RequestScopeDestroyOnlyComponent destroyOnly =
+            (RequestScopeDestroyOnlyComponent) scope.getInstance(destroyOnlyContext);
         Assert.assertNotNull(destroyOnly);
 
         Assert.assertTrue(initDestroy.isInitialized());
@@ -65,11 +70,14 @@
         RequestScopeContainer scope = new RequestScopeContainer(ctx);
         scope.start();
 
-        SystemAtomicComponent oneCtx = MockContextFactory.createSystemAtomicContext("one", scope, OrderedInitPojoImpl.class);
+        SystemAtomicComponent oneCtx =
+            MockContextFactory.createSystemAtomicContext("one", scope, OrderedInitPojoImpl.class);
         scope.register(oneCtx);
-        SystemAtomicComponent twoCtx = MockContextFactory.createSystemAtomicContext("two", scope, OrderedInitPojoImpl.class);
+        SystemAtomicComponent twoCtx =
+            MockContextFactory.createSystemAtomicContext("two", scope, OrderedInitPojoImpl.class);
         scope.register(twoCtx);
-        SystemAtomicComponent threeCtx = MockContextFactory.createSystemAtomicContext("three", scope, OrderedInitPojoImpl.class);
+        SystemAtomicComponent threeCtx =
+            MockContextFactory.createSystemAtomicContext("three", scope, OrderedInitPojoImpl.class);
         scope.register(threeCtx);
 
         scope.onEvent(new RequestStart(this));
@@ -99,11 +107,14 @@
         RequestScopeContainer scope = new RequestScopeContainer(ctx);
         scope.start();
 
-        SystemAtomicComponent oneCtx = MockContextFactory.createSystemAtomicContext("one", scope, OrderedEagerInitPojo.class);
+        SystemAtomicComponent oneCtx =
+            MockContextFactory.createSystemAtomicContext("one", scope, OrderedEagerInitPojo.class);
         scope.register(oneCtx);
-        SystemAtomicComponent twoCtx = MockContextFactory.createSystemAtomicContext("two", scope, OrderedEagerInitPojo.class);
+        SystemAtomicComponent twoCtx =
+            MockContextFactory.createSystemAtomicContext("two", scope, OrderedEagerInitPojo.class);
         scope.register(twoCtx);
-        SystemAtomicComponent threeCtx = MockContextFactory.createSystemAtomicContext("three", scope, OrderedEagerInitPojo.class);
+        SystemAtomicComponent threeCtx =
+            MockContextFactory.createSystemAtomicContext("three", scope, OrderedEagerInitPojo.class);
         scope.register(threeCtx);
 
         scope.onEvent(new RequestStart(this));

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/RequestScopeRestartTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/RequestScopeRestartTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/RequestScopeRestartTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/RequestScopeRestartTestCase.java Sat Jun 17 10:28:07 2006
@@ -22,12 +22,14 @@
         WorkContext ctx = new WorkContextImpl();
         RequestScopeContainer scope = new RequestScopeContainer(ctx);
         scope.start();
-        MethodEventInvoker<Object> initInvoker = new MethodEventInvoker<Object>(RequestScopeRestartTestCase.InitDestroyOnce.class.getMethod("init"));
-        MethodEventInvoker<Object> destroyInvoker = new MethodEventInvoker<Object>(RequestScopeRestartTestCase.InitDestroyOnce.class.getMethod("destroy"));
+        MethodEventInvoker<Object> initInvoker =
+            new MethodEventInvoker<Object>(RequestScopeRestartTestCase.InitDestroyOnce.class.getMethod("init"));
+        MethodEventInvoker<Object> destroyInvoker =
+            new MethodEventInvoker<Object>(RequestScopeRestartTestCase.InitDestroyOnce.class.getMethod("destroy"));
         List<Class<?>> interfaces = new ArrayList<Class<?>>();
         interfaces.add(RequestScopeRestartTestCase.InitDestroyOnce.class);
         SystemAtomicComponent context = MockContextFactory.createSystemAtomicContext("InitDestroy", scope, interfaces,
-                RequestScopeRestartTestCase.InitDestroyOnce.class, false, initInvoker, destroyInvoker, null, null);
+            RequestScopeRestartTestCase.InitDestroyOnce.class, false, initInvoker, destroyInvoker, null, null);
         context.start();
 
         Object instance = context.getServiceInstance();

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/WorkContextTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/WorkContextTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/WorkContextTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/component/scope/WorkContextTestCase.java Sat Jun 17 10:28:07 2006
@@ -31,14 +31,14 @@
     public void testIndentifier() throws Exception {
         WorkContext ctx = new WorkContextImpl();
         Object id = new Object();
-        ctx.setIdentifier(this,id);
-        assertEquals(id,ctx.getIdentifier(this));
+        ctx.setIdentifier(this, id);
+        assertEquals(id, ctx.getIdentifier(this));
     }
 
     public void testClearIndentifier() throws Exception {
         WorkContext ctx = new WorkContextImpl();
         Object id = new Object();
-        ctx.setIdentifier(this,id);
+        ctx.setIdentifier(this, id);
         ctx.clearIdentifier(this);
         assertNull(ctx.getIdentifier(this));
     }
@@ -47,8 +47,8 @@
         WorkContext ctx = new WorkContextImpl();
         Object id = new Object();
         Object id2 = new Object();
-        ctx.setIdentifier(id,id);
-        ctx.setIdentifier(id2,id2);
+        ctx.setIdentifier(id, id);
+        ctx.setIdentifier(id2, id2);
         ctx.clearIdentifiers();
         assertNull(ctx.getIdentifier(id));
         assertNull(ctx.getIdentifier(id2));
@@ -62,9 +62,9 @@
     public void testNullIndentifier() throws Exception {
         WorkContext ctx = new WorkContextImpl();
         Object id = new Object();
-        ctx.setIdentifier(this,id);
+        ctx.setIdentifier(this, id);
         ctx.clearIdentifier(null);
-        assertEquals(id,ctx.getIdentifier(this));
+        assertEquals(id, ctx.getIdentifier(this));
     }
 
     public void testNoIndentifier() throws Exception {

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/JNDIObjectFactoryTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/JNDIObjectFactoryTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/JNDIObjectFactoryTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/JNDIObjectFactoryTestCase.java Sat Jun 17 10:28:07 2006
@@ -6,8 +6,6 @@
 import org.apache.tuscany.spi.ObjectCreationException;
 import org.jmock.Mock;
 import org.jmock.MockObjectTestCase;
-import org.jmock.core.Invocation;
-import org.jmock.core.Stub;
 
 /**
  * @version $Rev$ $Date$

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/MethodEventInvokerTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/MethodEventInvokerTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/MethodEventInvokerTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/MethodEventInvokerTestCase.java Sat Jun 17 10:28:07 2006
@@ -3,8 +3,6 @@
 import java.lang.reflect.Method;
 
 import org.jmock.MockObjectTestCase;
-import org.apache.tuscany.spi.ObjectFactory;
-import org.apache.tuscany.spi.ObjectCreationException;
 
 /**
  * @version $Rev$ $Date$
@@ -45,9 +43,10 @@
         public void foo() {
         }
 
-        private void hidden(){}
+        private void hidden() {
+        }
 
-        public void exception(){
+        public void exception() {
             throw new RuntimeException();
         }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/MethodInjectorTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/MethodInjectorTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/MethodInjectorTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/MethodInjectorTestCase.java Sat Jun 17 10:28:07 2006
@@ -60,9 +60,10 @@
         public void foo(String bar) {
         }
 
-        private void hidden(String bar){}
+        private void hidden(String bar) {
+        }
 
-        public void exception(String bar){
+        public void exception(String bar) {
             throw new RuntimeException();
         }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/SingletonObjectFactoryTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/SingletonObjectFactoryTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/SingletonObjectFactoryTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/injection/SingletonObjectFactoryTestCase.java Sat Jun 17 10:28:07 2006
@@ -7,9 +7,9 @@
  */
 public class SingletonObjectFactoryTestCase extends TestCase {
 
-    public void testSingleton() throws Exception{
+    public void testSingleton() throws Exception {
         Object o = new Object();
         SingletonObjectFactory<Object> factory = new SingletonObjectFactory<Object>(o);
-        assertEquals(o,factory.getInstance());
+        assertEquals(o, factory.getInstance());
     }
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/integration/system/builder/SystemBuildersTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/integration/system/builder/SystemBuildersTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/integration/system/builder/SystemBuildersTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/integration/system/builder/SystemBuildersTestCase.java Sat Jun 17 10:28:07 2006
@@ -48,10 +48,11 @@
         SystemCompositeComponent parent = new SystemCompositeComponentImpl(null, null, null);
 
         ComponentDefinition<SystemImplementation> targetComponentDefinition = MockComponentFactory.createTarget();
-        ComponentDefinition<SystemImplementation> sourceComponentDefinition = MockComponentFactory.createSourceWithTargetReference();
+        ComponentDefinition<SystemImplementation> sourceComponentDefinition =
+            MockComponentFactory.createSourceWithTargetReference();
 
-        AtomicComponent<?> sourceComponent = (AtomicComponent) builder.build(parent, sourceComponentDefinition, deploymentContext);
-        AtomicComponent<?> targetComponent = (AtomicComponent) builder.build(parent, targetComponentDefinition, deploymentContext);
+        AtomicComponent<?> sourceComponent = builder.build(parent, sourceComponentDefinition, deploymentContext);
+        AtomicComponent<?> targetComponent = builder.build(parent, targetComponentDefinition, deploymentContext);
 
         parent.register(sourceComponent);
         parent.register(targetComponent);
@@ -87,13 +88,16 @@
 
         // create a context in the grandparent that the reference will be autowired to
         ComponentDefinition<SystemImplementation> targetComponentDefinition = MockComponentFactory.createTarget();
-        AtomicComponent targetComponentComponent = (AtomicComponent) builder.build(parent, targetComponentDefinition, deploymentContext);
+        AtomicComponent targetComponentComponent =
+            (AtomicComponent) builder.build(parent, targetComponentDefinition, deploymentContext);
         grandParent.register(targetComponentComponent);
 
         BoundReferenceDefinition<SystemBinding> targetReferenceDefinition = MockComponentFactory.createBoundReference();
-        ComponentDefinition<SystemImplementation> sourceComponentDefinition = MockComponentFactory.createSourceWithTargetReference();
+        ComponentDefinition<SystemImplementation> sourceComponentDefinition =
+            MockComponentFactory.createSourceWithTargetReference();
 
-        AtomicComponent<?> sourceComponent = (AtomicComponent) builder.build(parent, sourceComponentDefinition, deploymentContext);
+        AtomicComponent<?> sourceComponent =
+            (AtomicComponent) builder.build(parent, sourceComponentDefinition, deploymentContext);
         Reference reference = (Reference) bindingBuilder.build(parent, targetReferenceDefinition, deploymentContext);
 
         parent.register(sourceComponent);
@@ -132,7 +136,8 @@
         BoundServiceDefinition<SystemBinding> serviceDefinition = MockComponentFactory.createBoundService();
         ComponentDefinition<SystemImplementation> componentDefinition = MockComponentFactory.createTarget();
 
-        AtomicComponent sourceComponent = (AtomicComponent) builder.build(parent, componentDefinition, deploymentContext);
+        AtomicComponent sourceComponent =
+            (AtomicComponent) builder.build(parent, componentDefinition, deploymentContext);
         Service service = (Service) bindingBuilder.build(parent, serviceDefinition, deploymentContext);
 
         connector.connect(service.getInboundWire(), service.getOutboundWire(), true);
@@ -152,51 +157,6 @@
         scope.onEvent(new CompositeStop(this, parent));
         parent.stop();
         scope.stop();
-
-    }
-
-    /**
-     * Validates building a wire from a service context to a reference context
-     */
-    @SuppressWarnings("unchecked")
-    public void testServiceToReferenceWireBuild() throws Exception {
-//        WorkContext work = new WorkContextImpl();
-//        ScopeContainer scope = new ModuleScopeContainer(work);
-//        scope.start();
-//
-//        Connector connector = new ConnectorImpl();
-//        SystemComponentBuilder builder = new SystemComponentBuilder();
-//        SystemBindingBuilder bindingBuilder = new SystemBindingBuilder();
-//
-//        SystemCompositeComponent grandParent = new SystemCompositeComponentImpl("grandparent", null, null);
-//        SystemCompositeComponent parent = new SystemCompositeComponentImpl("parent", grandParent, grandParent);
-//
-//        // create a context in the grandparent that the reference will be autowired to
-//        ComponentDefinition<SystemImplementation> targetComponent = MockComponentFactory.createTarget();
-//        AtomicComponent targetComponentContext = (AtomicComponent) builder.build(parent, targetComponent, deploymentContext);
-//        grandParent.registerContext(targetComponentContext);
-//
-//        BoundReferenceDefinition<SystemBinding> reference = MockComponentFactory.createBoundReference();
-//        BoundServiceDefinition<SystemBinding> service = MockComponentFactory.createBoundService();
-//
-//        Reference referenceContext = (Reference) bindingBuilder.build(parent, reference, deploymentContext);
-//        Service serviceContext = (Service) bindingBuilder.build(parent, service, deploymentContext);
-//
-//        parent.registerContext(referenceContext);
-//        parent.registerContext(serviceContext);
-//
-//        connector.connect(serviceContext.getOutboundWire(), referenceContext.getInboundWire(),true);
-//        grandParent.registerContext(parent);
-//        grandParent.start();
-//        scope.onEvent(new CompositeStart(this, parent));
-//        Target target = (Target) parent.getContext("service").getService();
-//        assertNotNull(target);
-//        Target target2 = (Target) parent.getContext("target").getService();
-//        assertNotNull(target);
-//        assertSame(target, target2);
-//        scope.onEvent(new CompositeStop(this, parent));
-//        parent.stop();
-//        scope.stop();
 
     }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/loader/ServiceLoaderTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/loader/ServiceLoaderTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/loader/ServiceLoaderTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/loader/ServiceLoaderTestCase.java Sat Jun 17 10:28:07 2006
@@ -56,8 +56,10 @@
         };
         mockReader.expects(once()).method("getName").will(returnValue(AssemblyConstants.SERVICE));
         mockReader.expects(once()).method("getAttributeValue").with(NULL, eq("name")).will(returnValue(name));
-        mockReader.expects(atLeastOnce()).method("next").will(onConsecutiveCalls(returnValue(START_ELEMENT), returnValue(END_ELEMENT)));
-        mockRegistry.expects(once()).method("load").with(eq(mockReader.proxy()), eq(deploymentContext)).will(returnValue(sc));
+        mockReader.expects(atLeastOnce()).method("next")
+            .will(onConsecutiveCalls(returnValue(START_ELEMENT), returnValue(END_ELEMENT)));
+        mockRegistry.expects(once()).method("load").with(eq(mockReader.proxy()), eq(deploymentContext))
+            .will(returnValue(sc));
         ServiceDefinition serviceDefinition = loader.load((XMLStreamReader) mockReader.proxy(), deploymentContext);
         assertNotNull(serviceDefinition);
         assertEquals(name, serviceDefinition.getName());

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/loader/StAXLoaderRegistryImplTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/loader/StAXLoaderRegistryImplTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/loader/StAXLoaderRegistryImplTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/loader/StAXLoaderRegistryImplTestCase.java Sat Jun 17 10:28:07 2006
@@ -57,7 +57,8 @@
         mockReader.expects(once()).method("getName").will(returnValue(name));
         mockMonitor.expects(once()).method("registeringLoader").with(eq(name));
         mockMonitor.expects(once()).method("elementLoad").with(eq(name));
-        mockLoader.expects(once()).method("load").with(eq(mockReader.proxy()), eq(deploymentContext)).will(returnValue(modelObject));
+        mockLoader.expects(once()).method("load").with(eq(mockReader.proxy()), eq(deploymentContext))
+            .will(returnValue(modelObject));
 
         registry.registerLoader(name, (StAXElementLoader<ModelObject>) mockLoader.proxy());
         assertSame(modelObject, registry.load((XMLStreamReader) mockReader.proxy(), deploymentContext));

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/AbstractGenericComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/AbstractGenericComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/AbstractGenericComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/AbstractGenericComponent.java Sat Jun 17 10:28:07 2006
@@ -33,20 +33,41 @@
 
     @ComponentName
     protected String name;
+    @Context
+    protected ModuleContext context;
+    Map testMap;
+    List testList;
+    private int[] arrayInt;
+    private float[] arrayFloat;
+    private double[] arrayDouble;
+    private long[] arrayLong;
+    private short[] arrayShort;
+    private boolean[] arrayBoolean;
+    private String[] arrayString;
+    private boolean mBoolean;
+    private short mShort;
+    private int mInt;
+    private long mLong;
+    private double mDouble;
+    private float mFloat;
+    private char mChar;
+    private String mString;
+    private Short mOShort;
+    private Integer mOInteger;
+    private Long mOLong;
+    private Float mOFloat;
+    private Double mODouble;
+    @Property(name = "genericComponent")
+    private GenericComponent mGenericComponent;
 
     public String getName() {
         return name;
     }
 
-    @Context
-    protected ModuleContext context;
-
     public ModuleContext getModuleContext() {
         return context;
     }
 
-    Map testMap;
-
     public Map getTestMap() {
         return testMap;
     }
@@ -55,8 +76,6 @@
         this.testMap = testMap;
     }
 
-    List testList;
-
     public List getTestList() {
         return testList;
     }
@@ -65,8 +84,6 @@
         this.testList = testList;
     }
 
-    private int[] arrayInt;
-
     public int[] getArrayInt() {
         return arrayInt;
     }
@@ -75,8 +92,6 @@
         this.arrayInt = arrayInt;
     }
 
-    private float[] arrayFloat;
-
     public float[] getArrayFloat() {
         return arrayFloat;
     }
@@ -85,8 +100,6 @@
         arrayFloat = pArrayFloat;
     }
 
-    private double[] arrayDouble;
-
     public double[] getArrayDouble() {
         return arrayDouble;
     }
@@ -95,8 +108,6 @@
         arrayDouble = pArrayDouble;
     }
 
-    private long[] arrayLong;
-
     public long[] getArrayLong() {
         return arrayLong;
     }
@@ -105,8 +116,6 @@
         this.arrayLong = arrayLong;
     }
 
-    private short[] arrayShort;
-
     public short[] getArrayShort() {
         return arrayShort;
     }
@@ -115,8 +124,6 @@
         this.arrayShort = arrayShort;
     }
 
-    private boolean[] arrayBoolean;
-
     public boolean[] getArrayBoolean() {
         return arrayBoolean;
     }
@@ -125,8 +132,6 @@
         this.arrayBoolean = arrayBoolean;
     }
 
-    private String[] arrayString;
-
     public String[] getArrayString() {
         return arrayString;
     }
@@ -135,8 +140,6 @@
         this.arrayString = arrayString;
     }
 
-    private boolean mBoolean;
-
     public boolean getBoolean() {
         return mBoolean;
     }
@@ -145,8 +148,6 @@
         mBoolean = pBoolean;
     }
 
-    private short mShort;
-
     public short getShort() {
         return mShort;
     }
@@ -155,8 +156,6 @@
         mShort = pShort;
     }
 
-    private int mInt;
-
     public int getInt() {
         return mInt;
     }
@@ -165,8 +164,6 @@
         mInt = pInt;
     }
 
-    private long mLong;
-
     public long getLong() {
         return mLong;
     }
@@ -175,8 +172,6 @@
         mLong = pLong;
     }
 
-    private double mDouble;
-
     public double getDouble() {
         return mDouble;
     }
@@ -185,8 +180,6 @@
         mDouble = pDouble;
     }
 
-    private float mFloat;
-
     public float getFloat() {
         return mFloat;
     }
@@ -195,8 +188,6 @@
         mFloat = pFloat;
     }
 
-    private char mChar;
-
     public char getChar() {
         return mChar;
     }
@@ -205,8 +196,6 @@
         mChar = pChar;
     }
 
-    private String mString;
-
     public String getString() {
         return mString;
     }
@@ -215,8 +204,6 @@
         mString = pString;
     }
 
-    private Short mOShort;
-
     public Short getOShort() {
         return mOShort;
     }
@@ -225,8 +212,6 @@
         mOShort = pOShort;
     }
 
-    private Integer mOInteger;
-
     public Integer getOInteger() {
         return mOInteger;
     }
@@ -235,8 +220,6 @@
         mOInteger = pOInteger;
     }
 
-    private Long mOLong;
-
     public Long getOLong() {
         return mOLong;
     }
@@ -245,8 +228,6 @@
         mOLong = pOLong;
     }
 
-    private Float mOFloat;
-
     public Float getOFloat() {
         return mOFloat;
     }
@@ -255,8 +236,6 @@
         mOFloat = pOFloat;
     }
 
-    private Double mODouble;
-
     public Double getODouble() {
         return mODouble;
     }
@@ -264,9 +243,6 @@
     public void setODouble(Double pODouble) {
         mODouble = pODouble;
     }
-
-    @Property(name = "genericComponent")
-    private GenericComponent mGenericComponent;
 
     public GenericComponent getGenericComponent() {
         return mGenericComponent;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/BasicInterfaceImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/BasicInterfaceImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/BasicInterfaceImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/BasicInterfaceImpl.java Sat Jun 17 10:28:07 2006
@@ -20,21 +20,18 @@
  * @version $Rev$ $Date$
  */
 public class BasicInterfaceImpl implements BasicInterface {
-    protected String protectedProperty;
 
     public String publicProperty;
-
+    public BasicInterface publicReference;
+    protected String protectedProperty;
+    protected BasicInterface protectedReference;
     private String privateProperty;
+    private BasicInterface privateReference;
 
     public void setPrivateProperty(String privateProperty) {
         this.privateProperty = privateProperty;
     }
 
-    protected BasicInterface protectedReference;
-
-    public BasicInterface publicReference;
-
-    private BasicInterface privateReference;
 
     public void setPrivateReference(BasicInterface privateReference) {
         this.privateReference = privateReference;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/DataObject.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/DataObject.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/DataObject.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/DataObject.java Sat Jun 17 10:28:07 2006
@@ -25,9 +25,8 @@
  */
 @SuppressWarnings({"SerializableHasSerializationMethods"})
 public class DataObject implements Serializable {
-
-    private String stringValue;
     private static final long serialVersionUID = 5168705836784756017L;
+    private String stringValue;
 
     public String getStringValue() {
         return stringValue;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/GenericComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/GenericComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/GenericComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/GenericComponent.java Sat Jun 17 10:28:07 2006
@@ -26,117 +26,101 @@
  *
  * @version $Rev$ $Date$
  */
-public interface GenericComponent {
+interface GenericComponent {
 
-    public String getName();
+    String getName();
 
-    public ModuleContext getModuleContext();
+    ModuleContext getModuleContext();
 
-    // ----------------------------------
-    // Collections
-    // ----------------------------------
+    Map getTestMap();
 
-    public Map getTestMap();
+    void setTestMap(Map pTestMap);
 
-    public void setTestMap(Map pTestMap);
+    List getTestList();
 
-    public List getTestList();
+    void setTestList(List pTestList);
 
-    public void setTestList(List pTestList);
+    int[] getArrayInt();
 
-    // ----------------------------------
-    // Arrays
-    // ----------------------------------
+    void setArrayInt(int[] pArrayInt);
 
-    public int[] getArrayInt();
+    float[] getArrayFloat();
 
-    public void setArrayInt(int[] pArrayInt);
+    void setArrayFloat(float[] pArrayFloat);
 
-    public float[] getArrayFloat();
+    double[] getArrayDouble();
 
-    public void setArrayFloat(float[] pArrayFloat);
+    void setArrayDouble(double[] pArrayDouble);
 
-    public double[] getArrayDouble();
+    long[] getArrayLong();
 
-    public void setArrayDouble(double[] pArrayDouble);
+    void setArrayLong(long[] pArrayLong);
 
-    public long[] getArrayLong();
+    short[] getArrayShort();
 
-    public void setArrayLong(long[] pArrayLong);
+    void setArrayShort(short[] pArrayShort);
 
-    public short[] getArrayShort();
+    boolean[] getArrayBoolean();
 
-    public void setArrayShort(short[] pArrayShort);
+    void setArrayBoolean(boolean[] pArrayBoolean);
 
-    public boolean[] getArrayBoolean();
+    String[] getArrayString();
 
-    public void setArrayBoolean(boolean[] pArrayBoolean);
+    void setArrayString(String[] pArrayString);
 
-    public String[] getArrayString();
+    boolean getBoolean();
 
-    public void setArrayString(String[] pArrayString);
+    void setBoolean(boolean pBoolean);
 
-    // ----------------------------------
-    // Primitives
-    // ----------------------------------
+    short getShort();
 
-    public boolean getBoolean();
+    void setShort(short pShort);
 
-    public void setBoolean(boolean pBoolean);
+    int getInt();
 
-    public short getShort();
+    void setInt(int pInt);
 
-    public void setShort(short pShort);
+    long getLong();
 
-    public int getInt();
+    void setLong(long pLong);
 
-    public void setInt(int pInt);
+    double getDouble();
 
-    public long getLong();
+    void setDouble(double pDouble);
 
-    public void setLong(long pLong);
+    float getFloat();
 
-    public double getDouble();
+    void setFloat(float pFloat);
 
-    public void setDouble(double pDouble);
+    char getChar();
 
-    public float getFloat();
+    void setChar(char pChar);
 
-    public void setFloat(float pFloat);
+    String getString();
 
-    public char getChar();
+    void setString(String pString);
 
-    public void setChar(char pChar);
+    Short getOShort();
 
-    // ----------------------------------
-    // Object types
-    // ----------------------------------
+    void setOShort(Short pOShort);
 
-    public String getString();
+    Integer getOInteger();
 
-    public void setString(String pString);
+    void setOInteger(Integer pOInteger);
 
-    public Short getOShort();
+    Long getOLong();
 
-    public void setOShort(Short pOShort);
+    void setOLong(Long pOLong);
 
-    public Integer getOInteger();
+    Float getOFloat();
 
-    public void setOInteger(Integer pOInteger);
+    void setOFloat(Float pOFloat);
 
-    public Long getOLong();
+    Double getODouble();
 
-    public void setOLong(Long pOLong);
+    void setODouble(Double pODouble);
 
-    public Float getOFloat();
+    GenericComponent getGenericComponent();
 
-    public void setOFloat(Float pOFloat);
-
-    public Double getODouble();
-
-    public void setODouble(Double pODouble);
-
-    public GenericComponent getGenericComponent();
-
-    public void setGenericComponent(GenericComponent pGenericComponent);
+    void setGenericComponent(GenericComponent pGenericComponent);
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/HelloWorldClient.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/HelloWorldClient.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/HelloWorldClient.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/HelloWorldClient.java Sat Jun 17 10:28:07 2006
@@ -19,11 +19,10 @@
 public class HelloWorldClient implements HelloWorldService {
 
     private int count;
+    private HelloWorldService service;
 
     public HelloWorldClient() {
     }
-
-    private HelloWorldService service;
 
     public void setHelloWorldService(HelloWorldService service) {
         this.service = service;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/HelloWorldService.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/HelloWorldService.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/HelloWorldService.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/HelloWorldService.java Sat Jun 17 10:28:07 2006
@@ -6,6 +6,6 @@
 public interface HelloWorldService {
     String hello(String name);
 
-    public int count();
+    int count();
 
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/LocalComponentImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/LocalComponentImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/LocalComponentImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/LocalComponentImpl.java Sat Jun 17 10:28:07 2006
@@ -32,21 +32,25 @@
 
     @ComponentName
     protected String name;
+    @Context
+    protected ModuleContext moduleCtx;
+    boolean mSetByMethod;
+    @Property(name = "fieldSetter", required = true)
+    private String mfieldSetter;
+    private String mMethodSetter;
+    @Reference(name = "requiredDataObject", required = true)
+    private DataObject mRequiredDataObject;
+    @Reference(name = "optionalDataObject")
+    private DataObject mOptionalDataObject;
 
     public String getName() {
         return name;
     }
 
-    @Context
-    protected ModuleContext moduleCtx;
-
     public ModuleContext getModuleContext() {
         return moduleCtx;
     }
 
-    @Property(name = "fieldSetter", required = true)
-    private String mfieldSetter;
-
     public String getfieldSetter() {
         return mfieldSetter;
     }
@@ -55,9 +59,6 @@
         throw new Exception("Set method instead of field");
     }
 
-    private String mMethodSetter;
-    boolean mSetByMethod;
-
     public String getMethodSetter() throws Exception {
         if (mSetByMethod) {
             return mMethodSetter;
@@ -72,9 +73,6 @@
         mMethodSetter = pMethodSetter;
     }
 
-    @Reference(name = "requiredDataObject", required = true)
-    private DataObject mRequiredDataObject;
-
     public DataObject getRequiredDataObject() {
         return mRequiredDataObject;
     }
@@ -82,9 +80,6 @@
     public void setRequiredDataObject(DataObject pRequiredDataObject) {
         mRequiredDataObject = pRequiredDataObject;
     }
-
-    @Reference(name = "optionalDataObject")
-    private DataObject mOptionalDataObject;
 
     public DataObject getOptionalDataObject() {
         return mOptionalDataObject;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeComponentImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeComponentImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeComponentImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeComponentImpl.java Sat Jun 17 10:28:07 2006
@@ -24,7 +24,7 @@
  */
 @Scope("MODULE")
 public class ModuleScopeComponentImpl extends AbstractGenericComponent implements
-        ModuleScopeComponent {
+    ModuleScopeComponent {
 
     private String foo;
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeDestroyOnlyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeDestroyOnlyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeDestroyOnlyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeDestroyOnlyComponent.java Sat Jun 17 10:28:07 2006
@@ -20,7 +20,7 @@
 
 public class ModuleScopeDestroyOnlyComponent extends ModuleScopeComponentImpl {
 
-    boolean destroyed = false;
+    boolean destroyed;
 
     public boolean isDestroyed() {
         return destroyed;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeEagerInitComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeEagerInitComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeEagerInitComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeEagerInitComponent.java Sat Jun 17 10:28:07 2006
@@ -20,16 +20,15 @@
 
 public class ModuleScopeEagerInitComponent extends ModuleScopeComponentImpl {
 
-    boolean initialized = false;
-
-    public boolean isInitialized() {
-        return initialized;
-    }
-
+    boolean initialized;
     // this value tests to ensure introspection can find the init() method even
     // if a field is named the same. Ultimately, this should be in the
     // introspection tests
     private boolean init;
+
+    public boolean isInitialized() {
+        return initialized;
+    }
 
     @Init(eager = true)
     public void init() {

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeEagerInitDestroyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeEagerInitDestroyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeEagerInitDestroyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeEagerInitDestroyComponent.java Sat Jun 17 10:28:07 2006
@@ -20,7 +20,7 @@
 
 public class ModuleScopeEagerInitDestroyComponent extends ModuleScopeEagerInitComponent {
 
-    boolean destroyed = false;
+    boolean destroyed;
 
     public boolean isDestroyed() {
         return destroyed;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeInitDestroyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeInitDestroyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeInitDestroyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeInitDestroyComponent.java Sat Jun 17 10:28:07 2006
@@ -20,7 +20,7 @@
 
 public class ModuleScopeInitDestroyComponent extends ModuleScopeInitOnlyComponent {
 
-    boolean destroyed = false;
+    boolean destroyed;
 
     public boolean isDestroyed() {
         return destroyed;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeInitOnlyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeInitOnlyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeInitOnlyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/ModuleScopeInitOnlyComponent.java Sat Jun 17 10:28:07 2006
@@ -20,15 +20,14 @@
 
 public class ModuleScopeInitOnlyComponent extends ModuleScopeComponentImpl {
 
-    boolean initialized = false;
+    private boolean initialized;
+    // this value tests to ensure introspection can find the init() method even
+    // if a field is named the same. Ultimately, this should be in the introspection tests
+    private boolean init;
 
     public boolean isInitialized() {
         return initialized;
     }
-
-    // this value tests to ensure introspection can find the init() method even
-    // if a field is named the same. Ultimately, this should be in the introspection tests
-    private boolean init;
 
     @Init
     public void init() {

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OrderedEagerInitPojo.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OrderedEagerInitPojo.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OrderedEagerInitPojo.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OrderedEagerInitPojo.java Sat Jun 17 10:28:07 2006
@@ -23,13 +23,13 @@
 @Scope("MODULE")
 public class OrderedEagerInitPojo {
 
-    private static final Object lock = new Object();
+    private static final Object LOCK = new Object();
     private static int numberInstantied;
     private int initOrder;
 
     @Init(eager = true)
     public void init() {
-        synchronized (lock) {
+        synchronized (LOCK) {
             ++numberInstantied;
             initOrder = numberInstantied;
         }
@@ -37,7 +37,7 @@
 
     @Destroy
     public void destroy() throws OrderException {
-        synchronized (lock) {
+        synchronized (LOCK) {
             if (initOrder != numberInstantied) {
                 throw new OrderException("Instance shutdown done out of order");
             }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OrderedInitPojoImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OrderedInitPojoImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OrderedInitPojoImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OrderedInitPojoImpl.java Sat Jun 17 10:28:07 2006
@@ -23,13 +23,13 @@
 @Scope("MODULE")
 public class OrderedInitPojoImpl implements OrderedInitPojo {
 
-    private static final Object lock = new Object();
+    private static final Object LOCK = new Object();
     private static int numberInstantied;
     private int initOrder;
 
     @Init
     public void init() {
-        synchronized (lock) {
+        synchronized (LOCK) {
             ++numberInstantied;
             initOrder = numberInstantied;
         }
@@ -37,7 +37,7 @@
 
     @Destroy
     public void destroy() throws OrderException {
-        synchronized (lock) {
+        synchronized (LOCK) {
             if (initOrder != numberInstantied) {
                 throw new OrderException("Instance shutdown done out of order");
             }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OtherTarget.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OtherTarget.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OtherTarget.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/OtherTarget.java Sat Jun 17 10:28:07 2006
@@ -20,8 +20,8 @@
  */
 public interface OtherTarget {
 
-    public String getString();
+    String getString();
 
-    public void setString(String val);
+    void setString(String val);
 }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RemotableService.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RemotableService.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RemotableService.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RemotableService.java Sat Jun 17 10:28:07 2006
@@ -27,14 +27,14 @@
 @Remotable
 public interface RemotableService {
 
-    public void syncOneWay(String msg);
+    void syncOneWay(String msg);
 
-    public String syncTwoWay(String msg);
+    String syncTwoWay(String msg);
 
-    public DataObject syncTwoWayCustomType(DataObject val);
+    DataObject syncTwoWayCustomType(DataObject val);
 
-    public String getString();
+    String getString();
 
-    public void setString(String string);
+    void setString(String string);
 
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RemotableServiceImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RemotableServiceImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RemotableServiceImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RemotableServiceImpl.java Sat Jun 17 10:28:07 2006
@@ -16,8 +16,9 @@
  */
 package org.apache.tuscany.core.mock.component;
 
-import junit.framework.Assert;
 import org.osoa.sca.annotations.Property;
+
+import junit.framework.Assert;
 
 
 /**

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeComponentImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeComponentImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeComponentImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeComponentImpl.java Sat Jun 17 10:28:07 2006
@@ -21,6 +21,6 @@
  * @version $Rev$ $Date$
  */
 public class RequestScopeComponentImpl extends AbstractGenericComponent implements
-        RequestScopeComponent {
+    RequestScopeComponent {
 
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeDestroyOnlyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeDestroyOnlyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeDestroyOnlyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeDestroyOnlyComponent.java Sat Jun 17 10:28:07 2006
@@ -6,7 +6,7 @@
 @Scope("REQUEST")
 public class RequestScopeDestroyOnlyComponent extends SessionScopeComponentImpl {
 
-    boolean destroyed = false;
+    boolean destroyed;
 
     public boolean isDestroyed() {
         return destroyed;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeInitDestroyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeInitDestroyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeInitDestroyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeInitDestroyComponent.java Sat Jun 17 10:28:07 2006
@@ -6,7 +6,7 @@
 @Scope("REQUEST")
 public class RequestScopeInitDestroyComponent extends SessionScopeInitOnlyComponent {
 
-    boolean destroyed = false;
+    boolean destroyed;
 
     public boolean isDestroyed() {
         return destroyed;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeInitOnlyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeInitOnlyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeInitOnlyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopeInitOnlyComponent.java Sat Jun 17 10:28:07 2006
@@ -6,7 +6,7 @@
 @Scope("REQUEST")
 public class RequestScopeInitOnlyComponent extends SessionScopeComponentImpl {
 
-    boolean initialized = false;
+    private boolean initialized;
 
     public boolean isInitialized() {
         return initialized;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopedOrderedInitPojo.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopedOrderedInitPojo.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopedOrderedInitPojo.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/RequestScopedOrderedInitPojo.java Sat Jun 17 10:28:07 2006
@@ -7,13 +7,13 @@
 @Scope("REQUEST")
 public class RequestScopedOrderedInitPojo {
 
-    private static final Object lock = new Object();
+    private static final Object LOCK = new Object();
     private static int numberInstantied;
     private int initOrder;
 
     @Init
     public void init() {
-        synchronized (lock) {
+        synchronized (LOCK) {
             ++RequestScopedOrderedInitPojo.numberInstantied;
             initOrder = RequestScopedOrderedInitPojo.numberInstantied;
         }
@@ -21,7 +21,7 @@
 
     @Destroy
     public void destroy() throws OrderException {
-        synchronized (lock) {
+        synchronized (LOCK) {
             if (initOrder != RequestScopedOrderedInitPojo.numberInstantied) {
                 throw new OrderException("Instance shutdown done out of order");
             }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeComponentImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeComponentImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeComponentImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeComponentImpl.java Sat Jun 17 10:28:07 2006
@@ -23,6 +23,6 @@
  */
 @Scope("SESSION")
 public class SessionScopeComponentImpl extends AbstractGenericComponent implements
-        SessionScopeComponent {
+    SessionScopeComponent {
 
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeDestroyOnlyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeDestroyOnlyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeDestroyOnlyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeDestroyOnlyComponent.java Sat Jun 17 10:28:07 2006
@@ -20,7 +20,7 @@
 
 public class SessionScopeDestroyOnlyComponent extends SessionScopeComponentImpl {
 
-    boolean destroyed = false;
+    private boolean destroyed;
 
     public boolean isDestroyed() {
         return destroyed;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeInitDestroyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeInitDestroyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeInitDestroyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeInitDestroyComponent.java Sat Jun 17 10:28:07 2006
@@ -20,7 +20,7 @@
 
 public class SessionScopeInitDestroyComponent extends SessionScopeInitOnlyComponent {
 
-    boolean destroyed = false;
+    private boolean destroyed;
 
     public boolean isDestroyed() {
         return destroyed;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeInitOnlyComponent.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeInitOnlyComponent.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeInitOnlyComponent.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopeInitOnlyComponent.java Sat Jun 17 10:28:07 2006
@@ -20,7 +20,7 @@
 
 public class SessionScopeInitOnlyComponent extends SessionScopeComponentImpl {
 
-    boolean initialized = false;
+    private boolean initialized;
 
     public boolean isInitialized() {
         return initialized;

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopedOrderedInitPojo.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopedOrderedInitPojo.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopedOrderedInitPojo.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SessionScopedOrderedInitPojo.java Sat Jun 17 10:28:07 2006
@@ -7,13 +7,13 @@
 @Scope("SESSION")
 public class SessionScopedOrderedInitPojo {
 
-    private static final Object lock = new Object();
+    private static final Object LOCK = new Object();
     private static int numberInstantied;
     private int initOrder;
 
     @Init
     public void init() {
-        synchronized (lock) {
+        synchronized (LOCK) {
             ++SessionScopedOrderedInitPojo.numberInstantied;
             initOrder = SessionScopedOrderedInitPojo.numberInstantied;
         }
@@ -21,7 +21,7 @@
 
     @Destroy
     public void destroy() throws OrderException {
-        synchronized (lock) {
+        synchronized (LOCK) {
             if (initOrder != SessionScopedOrderedInitPojo.numberInstantied) {
                 throw new OrderException("Instance shutdown done out of order");
             }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SimpleSource.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SimpleSource.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SimpleSource.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SimpleSource.java Sat Jun 17 10:28:07 2006
@@ -18,10 +18,10 @@
 
 public interface SimpleSource {
 
-    public void invokeHello() throws Exception;
+    void invokeHello() throws Exception;
 
-    public void invokeGoodbye() throws Exception;
+    void invokeGoodbye() throws Exception;
 
-    public SimpleTarget getTarget();
+    SimpleTarget getTarget();
 }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SimpleTarget.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SimpleTarget.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SimpleTarget.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SimpleTarget.java Sat Jun 17 10:28:07 2006
@@ -18,11 +18,11 @@
 
 public interface SimpleTarget {
 
-    public String hello(String message) throws Exception;
+    String hello(String message) throws Exception;
 
-    public String goodbye(String message) throws Exception;
+    String goodbye(String message) throws Exception;
 
-    public String echo(String message) throws Exception;
+    String echo(String message) throws Exception;
 
 }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/Source.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/Source.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/Source.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/Source.java Sat Jun 17 10:28:07 2006
@@ -22,11 +22,11 @@
  */
 public interface Source {
 
-    public Target getTarget();
+    Target getTarget();
 
-    public List<Target> getTargets();
+    List<Target> getTargets();
 
-    public List<Target> getTargetsThroughField();
+    List<Target> getTargetsThroughField();
 
 }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SourceImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SourceImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SourceImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/SourceImpl.java Sat Jun 17 10:28:07 2006
@@ -23,10 +23,9 @@
 public class SourceImpl implements Source {
 
     private Target target;
-
     private List<Target> targets;
-
     private List<Target> targetsThroughField;
+    private Target[] targetsArray;
 
     public void setTarget(Target target) {
         this.target = target;
@@ -48,9 +47,6 @@
         return targetsThroughField;
     }
 
-
-    private Target[] targetsArray;
-
     public Target[] getArrayOfTargets() {
         return targetsArray;
     }
@@ -58,6 +54,5 @@
     public void setArrayOfTargets(Target[] targets) {
         targetsArray = targets;
     }
-
 
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/StatelessComponentImpl.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/StatelessComponentImpl.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/StatelessComponentImpl.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/StatelessComponentImpl.java Sat Jun 17 10:28:07 2006
@@ -20,6 +20,6 @@
  * @version $Rev$ $Date$
  */
 public class StatelessComponentImpl extends AbstractGenericComponent implements
-        StatelessComponent {
+    StatelessComponent {
 
 }

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/Target.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/Target.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/Target.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/component/Target.java Sat Jun 17 10:28:07 2006
@@ -20,8 +20,8 @@
  */
 public interface Target {
 
-    public String getString();
+    String getString();
 
-    public void setString(String val);
+    void setString(String val);
 }
 

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/factories/MockComponentFactory.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/factories/MockComponentFactory.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/factories/MockComponentFactory.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/factories/MockComponentFactory.java Sat Jun 17 10:28:07 2006
@@ -22,7 +22,10 @@
 /**
  * @version $$Rev$$ $$Date$$
  */
-public class MockComponentFactory {
+public final class MockComponentFactory {
+
+    private MockComponentFactory() {
+    }
 
     /**
      * Creates a component named "source" with a reference to target/Target
@@ -44,7 +47,8 @@
         }
         impl.setComponentType(componentType);
         impl.setImplementationClass(SourceImpl.class);
-        ComponentDefinition<SystemImplementation> sourceComponentDefinition = new ComponentDefinition<SystemImplementation>(impl);
+        ComponentDefinition<SystemImplementation> sourceComponentDefinition =
+            new ComponentDefinition<SystemImplementation>(impl);
         sourceComponentDefinition.setName("source");
 
         ReferenceTarget referenceTarget = new ReferenceTarget();
@@ -80,7 +84,8 @@
         }
         impl.setComponentType(componentType);
         impl.setImplementationClass(SourceImpl.class);
-        ComponentDefinition<SystemImplementation> sourceComponentDefinition = new ComponentDefinition<SystemImplementation>(impl);
+        ComponentDefinition<SystemImplementation> sourceComponentDefinition =
+            new ComponentDefinition<SystemImplementation>(impl);
         sourceComponentDefinition.setName("source");
 
         ReferenceTarget referenceTarget = new ReferenceTarget();
@@ -105,7 +110,8 @@
         componentType.add(targetServiceDefinition);
         impl.setComponentType(componentType);
         impl.setImplementationClass(TargetImpl.class);
-        ComponentDefinition<SystemImplementation> targetComponentDefinition = new ComponentDefinition<SystemImplementation>(impl);
+        ComponentDefinition<SystemImplementation> targetComponentDefinition =
+            new ComponentDefinition<SystemImplementation>(impl);
         targetComponentDefinition.setName("target");
         return targetComponentDefinition;
     }
@@ -123,8 +129,7 @@
     }
 
     /**
-     * Creates a bound service with the name "service" that is configured to be wired to a target named
-     * "target/Target"
+     * Creates a bound service with the name "service" that is configured to be wired to a target named "target/Target"
      */
     public static BoundServiceDefinition<SystemBinding> createBoundService() {
         SystemBinding binding = new SystemBinding();

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/factories/MockContextFactory.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/factories/MockContextFactory.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/factories/MockContextFactory.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/factories/MockContextFactory.java Sat Jun 17 10:28:07 2006
@@ -8,6 +8,9 @@
 import java.util.List;
 import java.util.Map;
 
+import org.osoa.sca.annotations.Destroy;
+import org.osoa.sca.annotations.Init;
+
 import org.apache.tuscany.core.injection.EventInvoker;
 import org.apache.tuscany.core.injection.Injector;
 import org.apache.tuscany.core.injection.MethodEventInvoker;
@@ -27,28 +30,30 @@
 import org.apache.tuscany.spi.component.ScopeContainer;
 import org.apache.tuscany.spi.wire.InboundInvocationChain;
 import org.apache.tuscany.spi.wire.InboundWire;
-import org.osoa.sca.annotations.Destroy;
-import org.osoa.sca.annotations.Init;
 
 /**
  * @version $$Rev$$ $$Date$$
  */
-public class MockContextFactory {
+public final class MockContextFactory {
 
     private MockContextFactory() {
     }
 
-    public static Map<String, AtomicComponent> createWiredContexts(String source, Class<?> sourceClass, ScopeContainer sourceScopeCtx,
-                                                                   String target, Class<?> targetClass, ScopeContainer targetScopeCtx) throws NoSuchMethodException {
+    public static Map<String, AtomicComponent> createWiredContexts(String source, Class<?> sourceClass,
+                                                                   ScopeContainer sourceScopeCtx,
+                                                                   String target, Class<?> targetClass,
+                                                                   ScopeContainer targetScopeCtx)
+        throws NoSuchMethodException {
         List<Class<?>> sourceClasses = new ArrayList<Class<?>>();
         sourceClasses.add(sourceClass);
-        return createWiredContexts(source, sourceClasses, sourceClass, sourceScopeCtx, target, targetClass, targetScopeCtx);
+        return createWiredContexts(source, sourceClasses, sourceClass, sourceScopeCtx, target, targetClass,
+            targetScopeCtx);
     }
 
     /**
-     * Creates source and target {@link AtomicComponent}s whose instances are wired together. The wiring
-     * algorithm searches for the first method on the source with a single parameter type matching an
-     * interface implemented by the target.
+     * Creates source and target {@link AtomicComponent}s whose instances are wired together. The wiring algorithm
+     * searches for the first method on the source with a single parameter type matching an interface implemented by the
+     * target.
      *
      * @throws NoSuchMethodException
      */
@@ -58,10 +63,12 @@
                                                                    ScopeContainer sourceScopeCtx,
                                                                    String target,
                                                                    Class<?> targetClass,
-                                                                   ScopeContainer targetScopeCtx) throws NoSuchMethodException {
+                                                                   ScopeContainer targetScopeCtx)
+        throws NoSuchMethodException {
 
         Map<String, AtomicComponent> contexts = new HashMap<String, AtomicComponent>();
-        SystemAtomicComponent targetCtx = createSystemAtomicContext(target, targetScopeCtx, targetClass);//, targetEager, targetInitInvoker, targetDestroyInvoker, null);
+        SystemAtomicComponent targetCtx = createSystemAtomicContext(target, targetScopeCtx,
+            targetClass);
 
         //create target wire
         Method[] sourceMethods = sourceClass.getMethods();
@@ -86,7 +93,8 @@
 
         Map<String, Member> members = new HashMap<String, Member>();
         members.put(setter.getName(), setter);
-        SystemAtomicComponent sourceCtx = createSystemAtomicContext(source, sourceScopeCtx, sourceInterfaces, sourceClass, null, members);//, sourceEager, sourceInitInvoker, sourceDestroyInvoker, injectors);
+        SystemAtomicComponent sourceCtx = createSystemAtomicContext(source, sourceScopeCtx, sourceInterfaces,
+            sourceClass, null, members);
         QualifiedName targetName = new QualifiedName(target);
         SystemOutboundWire wire = new SystemOutboundWireImpl(setter.getName(), targetName, targetClass);
         InboundWire inboundWire = new SystemInboundWireImpl(targetName.getPortName(), targetClass, targetCtx);
@@ -98,13 +106,16 @@
         return contexts;
     }
 
-    public static SystemAtomicComponent createSystemAtomicContext(String name, ScopeContainer scopeContainer, Class<?> clazz) throws NoSuchMethodException {
+    public static SystemAtomicComponent createSystemAtomicContext(String name, ScopeContainer scopeContainer,
+                                                                  Class<?> clazz) throws NoSuchMethodException {
         List<Class<?>> serviceInterfaces = new ArrayList<Class<?>>();
         serviceInterfaces.add(clazz);
         return createSystemAtomicContext(name, scopeContainer, serviceInterfaces, clazz);
     }
 
-    public static SystemAtomicComponent createSystemAtomicContext(String name, ScopeContainer scopeContainer, List<Class<?>> interfaces, Class<?> clazz) throws NoSuchMethodException {
+    public static SystemAtomicComponent createSystemAtomicContext(String name, ScopeContainer scopeContainer,
+                                                                  List<Class<?>> interfaces, Class<?> clazz)
+        throws NoSuchMethodException {
         return createSystemAtomicContext(name, scopeContainer, interfaces, clazz, null, null);
     }
 
@@ -113,7 +124,8 @@
                                                                   List<Class<?>> serviceInterfaces,
                                                                   Class<?> clazz,
                                                                   List<Injector> injectors,
-                                                                  Map<String, Member> members) throws NoSuchMethodException {
+                                                                  Map<String, Member> members)
+        throws NoSuchMethodException {
         Method[] methods = clazz.getMethods();
         EventInvoker<Object> initInvoker = null;
         EventInvoker<Object> destroyInvoker = null;
@@ -128,7 +140,8 @@
                 destroyInvoker = new MethodEventInvoker<Object>(method);
             }
         }
-        return createSystemAtomicContext(name, scopeContainer, serviceInterfaces, clazz, eager, initInvoker, destroyInvoker, injectors, members);
+        return createSystemAtomicContext(name, scopeContainer, serviceInterfaces, clazz, eager, initInvoker,
+            destroyInvoker, injectors, members);
     }
 
     /**
@@ -150,8 +163,10 @@
                                                                       EventInvoker<Object> initInvoker,
                                                                       EventInvoker<Object> destroyInvoker,
                                                                       List<Injector> injectors,
-                                                                      Map<String, Member> members) throws NoSuchMethodException {
-        return new SystemAtomicComponentImpl(name, null, scopeContainer, serviceInterfaces, createObjectFactory(clazz), eagerInit, initInvoker, destroyInvoker, injectors, members);
+                                                                      Map<String, Member> members)
+        throws NoSuchMethodException {
+        return new SystemAtomicComponentImpl(name, null, scopeContainer, serviceInterfaces, createObjectFactory(clazz),
+            eagerInit, initInvoker, destroyInvoker, injectors, members);
     }
 
     public static <T> InboundWire<T> createTargetWireFactory(String serviceName, Class<T> interfaze) {

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/wire/MockHandler.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/wire/MockHandler.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/wire/MockHandler.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/wire/MockHandler.java Sat Jun 17 10:28:07 2006
@@ -11,7 +11,7 @@
  */
 public class MockHandler implements MessageHandler {
 
-    private int count = 0;
+    private int count;
 
     public boolean processMessage(Message message) {
         //System.out.println("Invoking handler");

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/wire/MockStaticInvoker.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/wire/MockStaticInvoker.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/wire/MockStaticInvoker.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/mock/wire/MockStaticInvoker.java Sat Jun 17 10:28:07 2006
@@ -9,8 +9,8 @@
 import org.apache.tuscany.spi.wire.TargetInvoker;
 
 /**
- * Caches component instances that do not need to be resolved for every wire, e.g. an wire originating from a
- * lesser scope intended for a target with a wider scope
+ * Caches component instances that do not need to be resolved for every wire, e.g. an wire originating from a lesser
+ * scope intended for a target with a wider scope
  *
  * @version $Rev$ $Date$
  */

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/monitor/JavaLoggingTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/monitor/JavaLoggingTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/monitor/JavaLoggingTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/monitor/JavaLoggingTestCase.java Sat Jun 17 10:28:07 2006
@@ -34,17 +34,17 @@
  * @version $Rev$ $Date$
  */
 public class JavaLoggingTestCase extends TestCase {
-    private static final Logger logger = Logger.getLogger(Monitor.class.getName());
-    private static final MockHandler handler = new MockHandler();
+    private static final Logger LOGGER = Logger.getLogger(Monitor.class.getName());
+    private static final MockHandler HANDLER = new MockHandler();
 
     private MonitorFactory factory;
 
     /**
-     * Smoke test to ensure the logger is working.
+     * Smoke test to ensure the LOGGER is working.
      */
     public void testLogger() {
-        logger.info("test");
-        assertEquals(1, handler.logs.size());
+        LOGGER.info("test");
+        assertEquals(1, HANDLER.logs.size());
     }
 
     /**
@@ -53,7 +53,7 @@
     public void testUnloggedEvent() {
         Monitor mon = factory.getMonitor(Monitor.class);
         mon.eventNotToLog();
-        assertEquals(0, handler.logs.size());
+        assertEquals(0, HANDLER.logs.size());
     }
 
     /**
@@ -62,10 +62,10 @@
     public void testEventWithNoArgs() {
         Monitor mon = factory.getMonitor(Monitor.class);
         mon.eventWithNoArgs();
-        assertEquals(1, handler.logs.size());
-        LogRecord record = handler.logs.get(0);
+        assertEquals(1, HANDLER.logs.size());
+        LogRecord record = HANDLER.logs.get(0);
         assertEquals(Level.INFO, record.getLevel());
-        assertEquals(logger.getName(), record.getLoggerName());
+        assertEquals(LOGGER.getName(), record.getLoggerName());
         assertEquals(Monitor.class.getName() + "#eventWithNoArgs", record.getMessage());
     }
 
@@ -75,10 +75,10 @@
     public void testEventWithAnnotation() {
         Monitor mon = factory.getMonitor(Monitor.class);
         mon.eventWithAnnotation();
-        assertEquals(1, handler.logs.size());
-        LogRecord record = handler.logs.get(0);
+        assertEquals(1, HANDLER.logs.size());
+        LogRecord record = HANDLER.logs.get(0);
         assertEquals(Level.INFO, record.getLevel());
-        assertEquals(logger.getName(), record.getLoggerName());
+        assertEquals(LOGGER.getName(), record.getLoggerName());
         assertEquals(Monitor.class.getName() + "#eventWithAnnotation", record.getMessage());
     }
 
@@ -89,10 +89,10 @@
         Exception e = new Exception();
         Monitor mon = factory.getMonitor(Monitor.class);
         mon.eventWithThrowable(e);
-        assertEquals(1, handler.logs.size());
-        LogRecord record = handler.logs.get(0);
+        assertEquals(1, HANDLER.logs.size());
+        LogRecord record = HANDLER.logs.get(0);
         assertEquals(Level.WARNING, record.getLevel());
-        assertEquals(logger.getName(), record.getLoggerName());
+        assertEquals(LOGGER.getName(), record.getLoggerName());
         assertEquals(Monitor.class.getName() + "#eventWithThrowable", record.getMessage());
         assertSame(e, record.getThrown());
     }
@@ -103,16 +103,16 @@
     public void testEventWithOneArg() {
         Monitor mon = factory.getMonitor(Monitor.class);
         mon.eventWithOneArg("ARG");
-        assertEquals(1, handler.logs.size());
-        LogRecord record = handler.logs.get(0);
+        assertEquals(1, HANDLER.logs.size());
+        LogRecord record = HANDLER.logs.get(0);
         assertEquals(Monitor.class.getName() + "#eventWithOneArg", record.getMessage());
     }
 
     protected void setUp() throws Exception {
         super.setUp();
-        logger.setUseParentHandlers(false);
-        logger.addHandler(handler);
-        handler.flush();
+        LOGGER.setUseParentHandlers(false);
+        LOGGER.addHandler(HANDLER);
+        HANDLER.flush();
 
         String sourceClass = Monitor.class.getName();
         Properties levels = new Properties();
@@ -123,13 +123,13 @@
     }
 
     protected void tearDown() throws Exception {
-        logger.removeHandler(handler);
-        handler.flush();
+        LOGGER.removeHandler(HANDLER);
+        HANDLER.flush();
         super.tearDown();
     }
 
     /**
-     * Mock log handler to capture records.
+     * Mock log HANDLER to capture records.
      */
     public static class MockHandler extends Handler {
         List<LogRecord> logs = new ArrayList<LogRecord>();

Modified: incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/policy/async/AsyncInterceptorTestCase.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/policy/async/AsyncInterceptorTestCase.java?rev=415032&r1=415031&r2=415032&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/policy/async/AsyncInterceptorTestCase.java (original)
+++ incubator/tuscany/sandbox/jboynes/sca/core2/src/test/java/org/apache/tuscany/core/policy/async/AsyncInterceptorTestCase.java Sat Jun 17 10:28:07 2006
@@ -24,7 +24,8 @@
 
     @SuppressWarnings("unchecked")
     public void testInvocation() throws Exception {
-        AsyncInterceptor asyncInterceptor = new AsyncInterceptor(workManager, new NullMonitorFactory().getMonitor(AsyncMonitor.class));
+        AsyncInterceptor asyncInterceptor =
+            new AsyncInterceptor(workManager, new NullMonitorFactory().getMonitor(AsyncMonitor.class));
         Message msg = new MessageImpl();
         msg.setBody("foo");
         final CountDownLatch startSignal = new CountDownLatch(1);



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org


Mime
View raw message