blob: 539209276fed4acdb718b0cb818633222cc14000 [file] [log] [blame]
Clement Escoffier534748b2008-10-24 15:48:18 +00001<?xml version="1.0" encoding="UTF-8"?>
2<ipojo xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Clement Escoffierafaeb3d2008-12-22 17:30:12 +00003 xsi:schemaLocation="org.apache.felix.ipojo http://felix.apache.org/ipojo/schemas/1.1.0-SNAPSHOT/core.xsd
4 org.apache.felix.ipojo.handlers.event http://felix.apache.org/ipojo/schemas/1.1.0-SNAPSHOT/event-admin.xsd"
Clement Escoffier534748b2008-10-24 15:48:18 +00005 xmlns="org.apache.felix.ipojo"
Clement Escoffier0b07ca42008-11-25 14:47:49 +00006 xmlns:ev="org.apache.felix.ipojo.handlers.event">
Clement Escoffier534748b2008-10-24 15:48:18 +00007
8 <!-- The (asynchronous) donut provider -->
9 <component classname="org.apache.felix.ipojo.test.donut.DonutProviderImpl"
10 name="donut-provider">
11 <!-- Expose the donut provider service -->
12 <provides interface="org.apache.felix.ipojo.test.donut.DonutProvider">
13 <property name="name" field="m_name" value="Unknown donut vendor"/>
14 </provides>
15 <!-- Donut publisher -->
16 <ev:publisher name="donut-publisher" field="m_publisher"
17 topics="food/donuts" data-key="food" synchronous="false"/>
18 </component>
19
20 <!-- The synchronous donut provider -->
21 <component classname="org.apache.felix.ipojo.test.donut.DonutProviderImpl"
22 name="synchronous-donut-provider">
23 <!-- Expose the donut provider service -->
24 <provides interface="org.apache.felix.ipojo.test.donut.DonutProvider">
25 <property name="name" field="m_name" value="Unknown donut vendor"/>
26 </provides>
27 <!-- Donut publisher -->
28 <ev:publisher name="donut-publisher" field="m_publisher"
29 topics="food/donuts" data-key="food" synchronous="true"/>
30 </component>
31
32 <!-- The (asynchronous) donut event provider -->
33 <component
34 classname="org.apache.felix.ipojo.test.donut.DonutEventProviderImpl"
35 name="donut-event-provider">
36 <!-- Expose the donut provider service -->
37 <provides interface="org.apache.felix.ipojo.test.donut.DonutProvider">
38 <property name="name" field="m_name" value="Unknown donut vendor"/>
39 </provides>
40 <!-- Raw events publisher -->
41 <ev:publisher name="event-publisher" field="m_publisher"
42 topics="food/donuts" synchronous="false"/>
43 </component>
44
45 <!-- The synchronous donut event provider -->
46 <component
47 classname="org.apache.felix.ipojo.test.donut.DonutEventProviderImpl"
48 name="synchronous-donut-event-provider">
49 <!-- Expose the donut provider service -->
50 <provides interface="org.apache.felix.ipojo.test.donut.DonutProvider">
51 <property name="name" field="m_name" value="Unknown donut vendor"/>
52 </provides>
53 <!-- Raw events publisher -->
54 <ev:publisher name="event-publisher" field="m_publisher"
55 topics="food/donuts" synchronous="true"/>
56 </component>
57
58 <!-- The (asynchronous) event provider -->
59 <component
60 classname="org.apache.felix.ipojo.test.donut.AsyncEventProviderImpl"
61 name="event-provider">
62 <!-- Expose the donut provider service -->
63 <provides interface="org.apache.felix.ipojo.test.donut.DonutProvider">
64 <property name="name" field="m_name" value="Unknown donut vendor"/>
65 </provides>
66 <!-- Direcly interacts with the Event Admin service -->
67 <requires field="m_ea"/>
68 </component>
69
70 <!-- The synchronous event provider -->
71 <component
72 classname="org.apache.felix.ipojo.test.donut.SyncEventProviderImpl"
73 name="synchronous-event-provider">
74 <!-- Expose the donut provider service -->
75 <provides interface="org.apache.felix.ipojo.test.donut.DonutProvider">
76 <property name="name" field="m_name" value="Unknown donut vendor"/>
77 </provides>
78 <!-- Direcly interacts with the Event Admin service -->
79 <requires field="m_ea"/>
80 </component>
81
82 <!-- The donut consumer -->
83 <component classname="org.apache.felix.ipojo.test.donut.DonutConsumerImpl"
84 name="donut-consumer">
85 <!-- Expose the donut consumer service -->
86 <provides interface="org.apache.felix.ipojo.test.donut.DonutConsumer">
87 <property name="name" field="m_name" value="Unknown donut consumer"/>
88 <property name="slow" field="m_isSlow" value="false"/>
89 </provides>
90 <!-- Donut events subscriber -->
91 <ev:subscriber name="donut-subscriber" callback="receiveDonut"
92 topics="food/donuts" data-key="food"
93 data-type="org.apache.felix.ipojo.test.donut.Donut"/>
94 </component>
95
96 <!-- The donut event consumer -->
97 <component classname="org.apache.felix.ipojo.test.donut.DonutConsumerImpl"
98 name="donut-event-consumer">
99 <!-- Expose the donut consumer service -->
100 <provides interface="org.apache.felix.ipojo.test.donut.DonutConsumer">
101 <property name="name" field="m_name" value="Unknown donut consumer"/>
102 <property name="slow" field="m_isSlow" value="false"/>
103 </provides>
104 <!-- Raw events subscriber -->
105 <ev:subscriber name="donut-event-subscriber" callback="receiveEvent"
106 topics="food/donuts"/>
107 </component>
108
109 <!-- The event consumer -->
110 <component classname="org.apache.felix.ipojo.test.donut.EventConsumerImpl"
111 name="event-consumer">
112 <!-- Expose the donut consumer service -->
113 <provides
114 interface="{org.apache.felix.ipojo.test.donut.DonutConsumer,org.osgi.service.event.EventHandler}">
115 <property name="name" field="m_name" value="Unknown event consumer"/>
116 <property name="slow" field="m_isSlow" value="false"/>
117 <property name="event.topics" type="String" value="food/donuts"/>
118 </provides>
119 </component>
120
121 <!-- The event tracker -->
122 <component classname="org.apache.felix.ipojo.test.donut.EventTrackerImpl"
123 name="event-tracker">
124 <!-- Expose the donut consumer service -->
125 <provides
126 interface="{org.apache.felix.ipojo.test.donut.EventTracker,org.osgi.service.event.EventHandler}">
127 <property name="name" field="m_name" value="Unknown event tracker"/>
128 <property name="event.topics" type="String" value="food/donuts"/>
129 </provides>
130 </component>
131
132
133 <!-- Example instances -->
134 <instance component="donut-provider" name="zeifhgbzre">
135 <property name="name" value="Zeifhgbzre donuts"/>
136 </instance>
137 <instance component="donut-consumer" name="zeifhgbzre simpson">
138 <property name="name" value="Zeifhgbzre simpson"/>
139 <property name="slow" value="false"/>
140 </instance>
141
Clement Escoffierdfce6b32008-07-30 18:05:29 +0000142</ipojo>