1
edit
Changes
no edit summary
=Lab 2=
*[http://zenit.senecac.on.ca/wiki/index.php/Teams_Winter_2011/team4 Teampage]
==Tutorial==
* Like before, enter the name of your package and select ok.
===Use the class Activator to find the service===
*Open the '''Activator ''' class in the consumer plug in project
*Get the servers reference in the '''Activator's''' ''start()'' method, And provide code to start your consumer class. Example code in the picture below.
[[File:T4L2-10.png]]
===Implement a class where one can consume the service===
*Create your consumer class in the consumer project
*Ensure that you create a static field in your consumer: ''static TimeZones tzs''You will need this to use service provided
[[File:T4L2-11.png]]
===Install and run the Service Consumer Bundle===
*Run your consumer project: ''Right click -> Run As -> OSGi Framework''. As with the provider select the 3 bundles in our project
*Click ''Run!''
[[File:T4L2-12.png]]
*A sample of our code running, seamless updating of timezones!