Commit cade2958 authored by Christophe Demarey's avatar Christophe Demarey
Browse files

Move calendar code in a separate module.

parent 4470d9c2
<?xml version="1.0" encoding="UTF-8" ?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<name>Home Automation Demonstration Calendar Mock module</name>
<groupId>org.ow2.frascati.demo</groupId>
<artifactId>home-automation-calendar-mock</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>jar</packaging>
<parent>
<groupId>org.ow2.frascati.demo</groupId>
<artifactId>home-automation-parent</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
<!-- ===== -->
<!-- Build -->
<!-- ===== -->
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
</plugin>
</plugins>
</build>
<!-- ============= -->
<!-- Properties -->
<!-- ============= -->
<properties>
</properties>
<!-- ============ -->
<!-- Dependencies -->
<!-- ============ -->
<dependencies>
<dependency>
<groupId>org.ow2.frascati.demo</groupId>
<artifactId>home-automation-core</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
</project>
......@@ -23,7 +23,7 @@
* Contributor(s):
*/
package org.ow2.frascati.demo.homeautomation.lib;
package org.ow2.frascati.demo.homeautomation.calendar;
import java.io.IOException;
import java.sql.Time;
......@@ -48,7 +48,7 @@ import org.ow2.frascati.demo.homeautomation.api.GoogleService;
* @author Mahmoud Ben Hassine
*
*/
public class GoogleServiceMockImpl implements GoogleService {
public class GcalServiceMockImpl implements GoogleService {
@Override
public void addEvent(CalendarEventEntry entry) throws IOException,
......
<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" name="calendar">
<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" name="home-automation">
<component name="calendarComponent">
<property name="login">login</property>
<property name="password">password</property>
<implementation.java class="org.ow2.frascati.demo.homeautomation.lib.GoogleServiceImpl"/>
<service name="calendarService" requires="qos">
<interface.java interface="org.ow2.frascati.demo.homeautomation.api.GoogleService"/>
</service>
</component>
<component name="calendarMockComponent">
<implementation.java class="org.ow2.frascati.demo.homeautomation.lib.GoogleServiceMockImpl"/>
<implementation.java class="org.ow2.frascati.demo.homeautomation.calendar.GcalServiceMockImpl"/>
<service name="calendarMockService" requires="qos">
<interface.java interface="org.ow2.frascati.demo.homeautomation.api.GoogleService"/>
......@@ -23,4 +10,6 @@
</component>
<wire source="Mediator/calendarService" target="calendarMockComponent/calendarMockService"/>
</composite>
This diff is collapsed.
<?xml version="1.0" encoding="UTF-8" ?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<name>Home Automation Demonstration Calendar module</name>
<groupId>org.ow2.frascati.demo</groupId>
<artifactId>home-automation-calendar</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>jar</packaging>
<parent>
<groupId>org.ow2.frascati.demo</groupId>
<artifactId>home-automation-parent</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
<!-- ===== -->
<!-- Build -->
<!-- ===== -->
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
</plugin>
</plugins>
</build>
<!-- ============= -->
<!-- Properties -->
<!-- ============= -->
<properties>
</properties>
<!-- ============ -->
<!-- Dependencies -->
<!-- ============ -->
<dependencies>
<dependency>
<groupId>org.ow2.frascati.demo</groupId>
<artifactId>home-automation-core</artifactId>
<version>${project.version}</version>
</dependency>
<!-- Google -->
<dependency>
<groupId>com.github.dcarter.gdata-java-client</groupId>
<artifactId>gdata-calendar-2.0</artifactId>
</dependency>
<dependency>
<groupId>com.github.dcarter.gdata-java-client</groupId>
<artifactId>gdata-client-1.0</artifactId>
<version>${gdata.java.client.version}</version>
</dependency>
</dependencies>
</project>
......@@ -26,7 +26,7 @@
/**
*
*/
package org.ow2.frascati.demo.homeautomation.lib;
package org.ow2.frascati.demo.homeautomation.calendar;
import java.io.IOException;
import java.net.MalformedURLException;
......@@ -60,7 +60,7 @@ import org.ow2.frascati.demo.homeautomation.api.GoogleService;
* @version 1.0
*
*/
public class GoogleServiceImpl implements GoogleService {
public class GcalServiceImpl implements GoogleService {
private static final String FIRST_MEETING = "07:00:00";
......@@ -95,7 +95,7 @@ public class GoogleServiceImpl implements GoogleService {
this.password = password;
}
public GoogleServiceImpl() {
public GcalServiceImpl() {
}
public void init(){
......
<composite xmlns="http://www.osoa.org/xmlns/sca/1.0" name="home-automation">
<component name="calendarComponent">
<property name="login">christophe.demarey@inria.fr</property>
<property name="password">starburst</property>
<implementation.java class="org.ow2.frascati.demo.homeautomation.calendar.GcalServiceImpl"/>
<service name="calendarService" requires="qos">
<interface.java interface="org.ow2.frascati.demo.homeautomation.api.GoogleService"/>
</service>
</component>
<wire source="Mediator/calendarService" target="calendarComponent/calendarService"/>
</composite>
......@@ -59,9 +59,6 @@
<!-- ============= -->
<properties>
<frascati.version>1.3-SNAPSHOT</frascati.version>
<gdata.java.client.version>1.41.1-SNAPSHOT</gdata.java.client.version>
<cxf.version>2.2.7</cxf.version>
</properties>
<!-- ============= -->
......@@ -125,29 +122,19 @@
<dependencies>
<!-- to run this example with mvn -Prun -->
<dependency>
<groupId>org.ow2.frascati.factory
</groupId>
<artifactId>frascati-factory-tools
</artifactId>
<version>${frascati.version}</version>
</dependency>
<groupId>org.ow2.frascati.factory</groupId>
<artifactId>frascati-factory-tools</artifactId>
</dependency>
<!-- to run this example with mvn -Pexplorer -->
<dependency>
<groupId>org.ow2.frascati</groupId>
<artifactId>frascati-explorer-fscript-plugin</artifactId>
<version>${frascati.version}</version>
</dependency>
<!-- Google -->
<!-- Google calendar -->
<dependency>
<groupId>com.github.dcarter.gdata-java-client</groupId>
<artifactId>gdata-calendar-2.0</artifactId>
<version>${gdata.java.client.version}</version>
</dependency>
<dependency>
<groupId>com.github.dcarter.gdata-java-client</groupId>
<artifactId>gdata-client-1.0</artifactId>
<version>${gdata.java.client.version}</version>
</dependency>
<!-- Knx -->
......
......@@ -3,7 +3,6 @@
<service name="mediatorService" promote="Mediator/mediatorService"/>
<include name="knx"/>
<include name="calendar"/>
<include name="map"/>
<include name="tts"/>
<include name="weather"/>
......@@ -39,7 +38,7 @@
<interface.java interface="org.ow2.frascati.demo.homeautomation.api.CommunicationService"/>
</reference>
<reference name="calendarService" target="calendarMockComponent/calendarMockService">
<reference name="calendarService">
<interface.java interface="org.ow2.frascati.demo.homeautomation.api.GoogleService"/>
</reference>
......
......@@ -26,6 +26,11 @@
<artifactId>home-automation-rfid</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.ow2.frascati.demo</groupId>
<artifactId>home-automation-calendar-mock</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
<!-- ======== -->
......@@ -77,7 +82,7 @@
<argument>-cp</argument>
<classpath />
<argument>org.ow2.frascati.explorer.FrascatiExplorerLauncher</argument>
<argument>orchestration</argument>
<argument>home-automation</argument>
</arguments>
</configuration>
</plugin>
......
......@@ -60,6 +60,28 @@
<dependencyManagement>
<dependencies>
<!-- FraSCAti Runtime -->
<dependency>
<groupId>org.ow2.frascati.factory
</groupId>
<artifactId>frascati-factory-tools
</artifactId>
<version>${frascati.version}</version>
</dependency>
<!-- FraSCAti Explorer -->
<dependency>
<groupId>org.ow2.frascati</groupId>
<artifactId>frascati-explorer-fscript-plugin</artifactId>
<version>${frascati.version}</version>
<exclusions>
<exclusion>
<groupId>com.google.code.google-collections</groupId>
<artifactId>google-collect</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.sun.jna</groupId>
<artifactId>jna</artifactId>
......@@ -71,6 +93,19 @@
<artifactId>nabaztagComApi</artifactId>
<version>1.0</version>
</dependency>
<dependency>
<groupId>com.google.collections</groupId>
<artifactId>google-collections</artifactId>
<version>1.0-rc1</version>
</dependency>
<!-- Google calendar -->
<dependency>
<groupId>com.github.dcarter.gdata-java-client</groupId>
<artifactId>gdata-calendar-2.0</artifactId>
<version>${gdata.java.client.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
......@@ -83,6 +118,8 @@
<module>qos</module>
<module>rfid</module>
<module>rfid-mock</module>
<module>calendar</module>
<module>calendar-mock</module>
</modules>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment