cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dani...@apache.org
Subject svn commit: r578404 [2/2] - in /cocoon/whiteboard/osgi/core/cocoon-spring-osgi: ./ cocoon-spring-osgi-impl/ cocoon-spring-osgi-impl/src/ cocoon-spring-osgi-impl/src/main/ cocoon-spring-osgi-impl/src/main/java/ cocoon-spring-osgi-impl/src/main/java/org/...
Date Sat, 22 Sep 2007 10:58:23 GMT
Added: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImpl.java
URL: http://svn.apache.org/viewvc/cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImpl.java?rev=578404&view=auto
==============================================================================
--- cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImpl.java
(added)
+++ cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImpl.java
Sat Sep 22 03:58:15 2007
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cocoon.springosgi.simpleservice.impl;
+
+import org.apache.cocoon.springosgi.simpleservice.SimpleService;
+
+/**
+ * @version $Id$
+ */
+public class SimpleServiceImpl implements SimpleService {
+
+    private String message;
+
+    public boolean isABean() {
+        return true;
+    }
+    
+    public void setMessage(String message) {
+        this.message = message;
+    }
+
+    public String stringValue() {
+        return this.message;
+    }
+
+}

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImpl.java
------------------------------------------------------------------------------
    svn:keywords = Id

Added: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context-osgi.xml
URL: http://svn.apache.org/viewvc/cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context-osgi.xml?rev=578404&view=auto
==============================================================================
--- cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context-osgi.xml
(added)
+++ cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context-osgi.xml
Sat Sep 22 03:58:15 2007
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+   http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<!--+
+    | @version $Id$
+    +-->
+<beans xmlns="http://www.springframework.org/schema/beans"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xmlns:osgi="http://www.springframework.org/schema/osgi"
+  xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
+                      http://www.springframework.org/schema/osgi http://www.springframework.org/schema/osgi/spring-osgi.xsd">
+
+  <osgi:service id="simpleServiceOsgi" ref="simpleService" interface="org.apache.cocoon.springosgi.simpleservice.SimpleService"/>
+
+  <osgi:service id="simpleServiceOsgi.A" ref="simpleService.A" interface="org.apache.cocoon.springosgi.simpleservice.SimpleService">
+    <osgi:service-properties>
+      <prop key="simpleService.key">keyA</prop>
+    </osgi:service-properties>
+  </osgi:service>
+
+  <osgi:service id="simpleServiceOsgi.B" ref="simpleService.B" interface="org.apache.cocoon.springosgi.simpleservice.SimpleService">
+    <osgi:service-properties>
+      <prop key="simpleService.key">keyB</prop>
+    </osgi:service-properties>
+  </osgi:service>
+
+  <osgi:service id="simpleServiceOsgi.C" ref="simpleService.C" interface="org.apache.cocoon.springosgi.simpleservice.SimpleService">
+    <osgi:service-properties>
+      <prop key="simpleService.key">keyC</prop>
+    </osgi:service-properties>
+  </osgi:service>
+
+</beans>
\ No newline at end of file

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context-osgi.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context-osgi.xml
------------------------------------------------------------------------------
    svn:keywords = Id

Added: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context.xml
URL: http://svn.apache.org/viewvc/cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context.xml?rev=578404&view=auto
==============================================================================
--- cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context.xml
(added)
+++ cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context.xml
Sat Sep 22 03:58:15 2007
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements.  See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership.  The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License.  You may obtain a copy of the License at
+
+   http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied.  See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<!--+
+    | @version $Id$
+    +-->
+<beans xmlns="http://www.springframework.org/schema/beans"
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+  <bean name="simpleService" class="org.apache.cocoon.springosgi.simpleservice.impl.SimpleServiceImpl">
+  	<property name="message" value="simple service at your service"/>
+  </bean>
+
+  <bean name="simpleService.A" class="org.apache.cocoon.springosgi.simpleservice.impl.SimpleServiceImpl">
+  	<property name="message" value="A"/>
+  </bean>
+
+  <bean name="simpleService.B" class="org.apache.cocoon.springosgi.simpleservice.impl.SimpleServiceImpl">
+  	<property name="message" value="B"/>
+  </bean>
+
+  <bean name="simpleService.C" class="org.apache.cocoon.springosgi.simpleservice.impl.SimpleServiceImpl">
+  	<property name="message" value="C"/>
+  </bean>
+
+</beans>
\ No newline at end of file

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/main/resources/META-INF/spring/bundle-context.xml
------------------------------------------------------------------------------
    svn:keywords = Id

Added: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImplTest.java
URL: http://svn.apache.org/viewvc/cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImplTest.java?rev=578404&view=auto
==============================================================================
--- cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImplTest.java
(added)
+++ cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImplTest.java
Sat Sep 22 03:58:15 2007
@@ -0,0 +1,33 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cocoon.springosgi.simpleservice.impl;
+
+import junit.framework.TestCase;
+
+import org.apache.cocoon.springosgi.simpleservice.SimpleService;
+
+/**
+ * @version $Id$
+ */
+public class SimpleServiceImplTest extends TestCase {
+
+    public void testBeanIsABean() {
+	SimpleService aBean = new SimpleServiceImpl();
+        assertTrue(aBean.isABean());
+    }
+
+}
\ No newline at end of file

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImplTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceImplTest.java
------------------------------------------------------------------------------
    svn:keywords = Id

Added: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceIntegrationTest.java
URL: http://svn.apache.org/viewvc/cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceIntegrationTest.java?rev=578404&view=auto
==============================================================================
--- cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceIntegrationTest.java
(added)
+++ cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceIntegrationTest.java
Sat Sep 22 03:58:15 2007
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cocoon.springosgi.simpleservice.impl;
+
+import org.apache.cocoon.springosgi.simpleservice.SimpleService;
+import org.springframework.test.AbstractDependencyInjectionSpringContextTests;
+
+/**
+ * Integration test the bundle locally (outside of OSGi).
+ * Use AbstractOsgiTests and a separate integration test project
+ * for testing inside of OSGi.
+ * 
+ * @version $Id$
+ */
+public class SimpleServiceIntegrationTest extends AbstractDependencyInjectionSpringContextTests
{
+
+	protected String[] getConfigLocations() {
+	    return new String[] {"META-INF/spring/bundle-context.xml"};
+	}
+	
+	public void testBeanIsABean() {
+	    SimpleService simpleService = (SimpleService) this.applicationContext.getBean("simpleService");
+	    assertNotNull(simpleService);
+	    assertTrue(simpleService.isABean());
+	}
+
+}

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceIntegrationTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/java/org/apache/cocoon/springosgi/simpleservice/impl/SimpleServiceIntegrationTest.java
------------------------------------------------------------------------------
    svn:keywords = Id

Added: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/resources/readme.txt
URL: http://svn.apache.org/viewvc/cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/resources/readme.txt?rev=578404&view=auto
==============================================================================
--- cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/resources/readme.txt
(added)
+++ cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/resources/readme.txt
Sat Sep 22 03:58:15 2007
@@ -0,0 +1,4 @@
+This file is only here because maven archetypes cannot create empty directories.Without this
directory present, eclipse will indicate a classpath error 
+because src/test/resources is on the project's classpath.
+
+You can safely delete this file.

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/resources/readme.txt
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/cocoon-spring-osgi-simple-service/src/test/resources/readme.txt
------------------------------------------------------------------------------
    svn:keywords = Id

Added: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/pom.xml
URL: http://svn.apache.org/viewvc/cocoon/whiteboard/osgi/core/cocoon-spring-osgi/pom.xml?rev=578404&view=auto
==============================================================================
--- cocoon/whiteboard/osgi/core/cocoon-spring-osgi/pom.xml (added)
+++ cocoon/whiteboard/osgi/core/cocoon-spring-osgi/pom.xml Sat Sep 22 03:58:15 2007
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you under the Apache License, Version 2.0 (the
+    "License"); you may not use this file except in compliance
+    with the License.  You may obtain a copy of the License at
+    
+    http://www.apache.org/licenses/LICENSE-2.0
+    
+    Unless required by applicable law or agreed to in writing,
+    software distributed under the License is distributed on an
+    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+    KIND, either express or implied.  See the License for the
+    specific language governing permissions and limitations
+    under the License. 
+-->
+<project>
+  <parent>
+    <groupId>org.apache.cocoon</groupId>
+    <artifactId>cocoon-osgi-modules</artifactId>
+    <version>1-SNAPSHOT</version>
+  </parent>
+  <modelVersion>4.0.0</modelVersion>
+  <artifactId>cocoon-spring-osgi-modules</artifactId>
+  <name>Cocoon utilities for Spring OSGi</name>
+  <packaging>pom</packaging>
+  <modules>
+    <module>cocoon-spring-osgi-impl</module>
+    <module>cocoon-spring-osgi-simple-service</module>
+    <module>cocoon-spring-osgi-integration-test</module>
+  </modules>
+</project>

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cocoon/whiteboard/osgi/core/cocoon-spring-osgi/pom.xml
------------------------------------------------------------------------------
    svn:keywords = Id



Mime
View raw message