blob: 7e47cc7d59f8975b2ad8ee26c5b115ad02d23625 [file] [log] [blame]
Guillaume Nodet18c56a12009-04-30 09:10:03 +00001<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
3 xmlns:cm="http://www.osgi.org/xmlns/blueprint-cm/v1.0.0"
4 default-availability="optional">
5
6 <type-converters>
7 <bean id="converter1" class="org.apache.geronimo.blueprint.sample.DateTypeConverter">
8 <property name="format" value="yyyy.MM.dd"/>
9 </bean>
10 <bean id="converter2" class="org.apache.geronimo.blueprint.sample.CurrencyTypeConverter"/>
11
12 <cm:property-placeholder id="property-placeholder" persistent-id="blueprint-sample">
13 <cm:default-properties>
14 <cm:property name="key.b" value="-1"/>
15 </cm:default-properties>
16 </cm:property-placeholder>
17 </type-converters>
18
19 <bean id="foo" class="org.apache.geronimo.blueprint.sample.Foo" init-method="init" destroy-method="destroy">
20 <property name="a" value="5" />
21 <property name="b" value="${key.b}" />
22 <property name="bar" ref="bar" />
23 <property name="currency">
24 <value>PLN</value>
25 </property>
26 <property name="date">
27 <value>2009.04.17</value>
28 </property>
29 </bean>
30
31 <bean id="bar" class="org.apache.geronimo.blueprint.sample.Bar">
32 <property name="value"><value>Hello FooBar</value></property>
33 <property name="context" ref="bundleContext"/>
34 <property name="list">
35 <list>
36 <value>a list element</value>
37 <value type = "java.lang.Integer">5</value>
38 </list>
39 </property>
40 </bean>
41
42 <service ref="foo" auto-export="all-classes">
43 <service-properties>
44 <entry key="key" value="value"/>
45 </service-properties>
46 <registration-listener ref="fooRegistrationListener"
47 registration-method="serviceRegistered"
48 unregistration-method="serviceUnregistered"/>
49 </service>
50
51 <bean id="fooRegistrationListener" class="org.apache.geronimo.blueprint.sample.FooRegistrationListener"/>
52
53 <reference id="ref" interface="org.apache.geronimo.blueprint.sample.Foo">
54 </reference>
55
56 <reference id="ref2" interface="org.apache.geronimo.blueprint.sample.InterfaceA" timeout="100">
Guillaume Nodet508a4e12009-06-18 21:11:51 +000057 <reference-listener bind-method="bind" unbind-method="unbind" ref="bindingListener" />
Guillaume Nodet18c56a12009-04-30 09:10:03 +000058 </reference>
59
60 <bean id="bindingListener" class="org.apache.geronimo.blueprint.sample.BindingListener"/>
61
Guillaume Nodet67eeb702009-07-02 07:04:21 +000062 <reference-list id="ref-list" interface="org.apache.geronimo.blueprint.sample.InterfaceA">
Guillaume Nodet508a4e12009-06-18 21:11:51 +000063 <reference-listener bind-method="bind" unbind-method="unbind" ref="listBindingListener" />
Guillaume Nodet67eeb702009-07-02 07:04:21 +000064 </reference-list>
Guillaume Nodet18c56a12009-04-30 09:10:03 +000065
66 <bean id="listBindingListener" class="org.apache.geronimo.blueprint.sample.BindingListener"/>
67
68</blueprint>
69