You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@avalon.apache.org by mc...@apache.org on 2004/06/09 15:08:50 UTC

svn commit: rev 20944 - in avalon/trunk/runtime/meta/test/testc: . src src/main src/main/org src/main/org/apache src/main/org/apache/avalon src/main/org/apache/avalon/test src/main/org/apache/avalon/test/testc

Author: mcconnell
Date: Wed Jun  9 06:08:50 2004
New Revision: 20944

Added:
   avalon/trunk/runtime/meta/test/testc/
   avalon/trunk/runtime/meta/test/testc/build.properties   (contents, props changed)
   avalon/trunk/runtime/meta/test/testc/build.xml   (contents, props changed)
   avalon/trunk/runtime/meta/test/testc/src/
   avalon/trunk/runtime/meta/test/testc/src/main/
   avalon/trunk/runtime/meta/test/testc/src/main/org/
   avalon/trunk/runtime/meta/test/testc/src/main/org/apache/
   avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/
   avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/test/
   avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/test/testc/
   avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/test/testc/C.java   (contents, props changed)
   avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/test/testc/TestC.java   (contents, props changed)
Log:
add the testc package

Added: avalon/trunk/runtime/meta/test/testc/build.properties
==============================================================================
--- (empty file)
+++ avalon/trunk/runtime/meta/test/testc/build.properties	Wed Jun  9 06:08:50 2004
@@ -0,0 +1,2 @@
+project.name = avalon-test-testc
+project.home = ../../../../central/system

Added: avalon/trunk/runtime/meta/test/testc/build.xml
==============================================================================
--- (empty file)
+++ avalon/trunk/runtime/meta/test/testc/build.xml	Wed Jun  9 06:08:50 2004
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<project name="avalon-test-testc" default="dist" basedir="." 
+    xmlns:x="antlib:org.apache.avalon.tools"
+    xmlns:m="plugin:avalon/meta/avalon-meta-tools">
+
+  <property file="build.properties"/>
+  <import file="${project.home}/build/standard.xml"/>
+
+  <target name="build" depends="standard.build">
+    <m:meta destDir="${basedir}/target/classes">
+      <fileset dir="${basedir}/src/main">
+        <include name="**/*.java"/>
+      </fileset>
+    </m:meta>
+  </target>
+
+</project>

Added: avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/test/testc/C.java
==============================================================================
--- (empty file)
+++ avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/test/testc/C.java	Wed Jun  9 06:08:50 2004
@@ -0,0 +1,22 @@
+/* 
+ * Copyright 2004 Apache Software Foundation
+ * Licensed  under the  Apache License,  Version 2.0  (the "License");
+ * you may not use  this file  except in  compliance with the License.
+ * You may obtain a copy of the License at 
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed  under the  License is distributed on an "AS IS" BASIS,
+ * WITHOUT  WARRANTIES OR CONDITIONS  OF ANY KIND, either  express  or
+ * implied.
+ * 
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.avalon.test.testc;
+
+public interface C
+{
+}

Added: avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/test/testc/TestC.java
==============================================================================
--- (empty file)
+++ avalon/trunk/runtime/meta/test/testc/src/main/org/apache/avalon/test/testc/TestC.java	Wed Jun  9 06:08:50 2004
@@ -0,0 +1,56 @@
+/* 
+ * Copyright 2004 Apache Software Foundation
+ * Licensed  under the  Apache License,  Version 2.0  (the "License");
+ * you may not use  this file  except in  compliance with the License.
+ * You may obtain a copy of the License at 
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed  under the  License is distributed on an "AS IS" BASIS,
+ * WITHOUT  WARRANTIES OR CONDITIONS  OF ANY KIND, either  express  or
+ * implied.
+ * 
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.avalon.test.testc;
+
+import org.apache.avalon.framework.activity.Initializable;
+import org.apache.avalon.framework.logger.AbstractLogEnabled;
+import org.apache.avalon.framework.logger.Logger;
+import org.apache.avalon.framework.service.Serviceable;
+import org.apache.avalon.framework.service.ServiceManager;
+import org.apache.avalon.framework.service.ServiceException;
+
+/**
+ * @avalon.component name="test-c" lifestyle="singleton"
+ * @avalon.component type="org.apache.avalon.test.testc.C"
+ */
+public class TestC extends AbstractLogEnabled
+  implements Initializable, Serviceable, C
+{
+    public void initialize() throws Exception
+    {
+        getLogger().info( "hello from C" );
+    }
+
+   /**
+    * @avalon.dependency type"org.apache.avalon.test.testa.A" key="a"
+    * @avalon.dependency type"org.apache.avalon.test.testa.A" key="a2"
+    * @avalon.dependency type"org.apache.avalon.test.testa.B" key="b"
+    */
+    public void service( ServiceManager manager ) throws ServiceException
+    {
+        getLogger().info( "service stage" );
+        Logger logger = getLogger().getChildLogger( "service" );
+        logger.info( "lookup A" );
+        manager.lookup( "a" );
+        logger.info( "lookup A2" );
+        manager.lookup( "a2" );
+        logger.info( "lookup B" );
+        manager.lookup( "b" );
+        logger.info( "ok" );
+    }
+}

---------------------------------------------------------------------
To unsubscribe, e-mail: cvs-unsubscribe@avalon.apache.org
For additional commands, e-mail: cvs-help@avalon.apache.org