Difference between revisions of "Teams Winter 2011/team2/project"

From CDOT Wiki
Jump to: navigation, search
Line 10: Line 10:
  
 
==Steps==
 
==Steps==
# In Eclipse, create a new workspace.  
+
1. In Eclipse, create a new workspace.  
# Create a new Plug-in project following settings, name it consumer.
+
2. Create a new Plug-in project following settings, name it consumer.
[[Image:ecl500-Team2-Project_img01|thumb|widthpx| ]][[Image:ecl500-Team2-Project_img02|thumb|widthpx| ]]
+
[[Image:ecl500-Team2-Project_img01.png]]<br/><br/>
[[Image:ecl500-Team2-Project_img03|thumb|widthpx| ]]
+
[[Image:ecl500-Team2-Project_img02.png]]<br/><br/>
 +
[[Image:ecl500-Team2-Project_img03.png ]]<br/><br/>
 +
3. Likewise create 2 more plug-in projects called interface and provider. Uncheck the 'Generate Activator' option for interface.
 +
4. In the interface bundle, we create a package, ecl.team2.project.weather. We will create classes and interface java files that are used by consumer and provider bundles.
 +
[[Image:ecl500-Team2-Project_img04.png]]<br/><br/>

Revision as of 16:37, 16 April 2011

Tutorial

In this tutorial, we will be elaborating on how to replicate our OSGI project application. We will provide a brief explanation of each plug-in project needed, the packages that corresponds to those projects, and of course the java source files that will be used to create the program.

Project

For this project, we are going to create a weather service program using the osgi framework. This project will contain three bundles: Consumer, Interface and Provider bundles. The Interface bundle will contain a set of interface and classes used by both Consumer and Provider. The Provider bundle will provide a service to return weather information for a selected city. The Consumer bundle will use the service reference to get weather information from the Provider and display in a GUI window based on Java Swing Library.

Prerequisites


Steps

1. In Eclipse, create a new workspace. 2. Create a new Plug-in project following settings, name it consumer. Ecl500-Team2-Project img01.png

Ecl500-Team2-Project img02.png

Ecl500-Team2-Project img03.png

3. Likewise create 2 more plug-in projects called interface and provider. Uncheck the 'Generate Activator' option for interface. 4. In the interface bundle, we create a package, ecl.team2.project.weather. We will create classes and interface java files that are used by consumer and provider bundles. File:Ecl500-Team2-Project img04.png