1:<?xml version="1.0" encoding="UTF-8"?> 2:<componentsDescriptor xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../core/component/xml/components.xsd"> 3: 4: <!-- DEFINITION OF THE COMPONENT TYPES --> 5: <types> 6: <component-type name="RootType"> 7: <provides> 8: <interface name="m" signature="org.objectweb.proactive.examples.components.helloworld.Main"/> 9: </provides> 10: </component-type> 11: 12:<!-- extends is not supported yet --> 13: <component-type name="ClientType"> 14: <provides> 15: <interface name="m" signature="org.objectweb.proactive.examples.components.helloworld.Main"/> 16: </provides> 17: <requires> 18: <interface name="s" signature="org.objectweb.proactive.examples.components.helloworld.Service"/> 19: </requires> 20: </component-type> 21: 22: <component-type name="ServerType"> 23: <provides> 24: <interface name="s" signature="org.objectweb.proactive.examples.components.helloworld.Service"/> 25: </provides> 26: </component-type> 27: 28: </types> 29: 30: <!-- DEFINITION OF THE COMPONENT INSTANCES --> 31: <!-- For conveniency (to avoid multiple files), both configurations (with or without wrappers) are 32: defined here, and therefore instantiated and deployed when parsing the file.--> 33: 34: <components> 35: <!-- standard client server example --> 36: <composite-component name="ClientServer" type="RootType" virtualNode="null"> 37: <components> 38: <primitive-component name="client" type="ClientType" implementation="org.objectweb.proactive.examples.components.helloworld.ClientImpl" virtualNode="VN1"/> 39: <primitive-component name="server" type="ServerType" implementation="org.objectweb.proactive.examples.components.helloworld.ServerImpl" virtualNode="VN2"/> 40: </components> 41: <bindings> 42: <binding client="ClientServer.m" server="client.m"/> 43: <binding client="client.s" server="server.s"/> 44: </bindings> 45: </composite-component> 46: 47: <!-- client server examples with wrapped client and server --> 48: <composite-component name="ClientServerWrapper" type="RootType"> 49: <components> 50: <composite-component name="clientWrapper" type="ClientType"> 51: <components> 52: <primitive-component name="wrapped-client" type="ClientType" implementation="org.objectweb.proactive.examples.components.helloworld.ClientImpl" virtualNode="VN1"/> 53: </components> 54: <bindings> 55: <binding client="clientWrapper.m" server="wrapped-client.m"/> 56: <binding client="wrapped-client.s" server="clientWrapper.s"/> 57: </bindings> 58: </composite-component> 59: <composite-component name="serverWrapper" type="ServerType"> 60: <components> 61: <primitive-component name="wrapped-server" type="ServerType" implementation="org.objectweb.proactive.examples.components.helloworld.ServerImpl" virtualNode="VN2"/> 62: </components> 63: <bindings> 64: <binding client="serverWrapper.s" server="wrapped-server.s"/> 65: </bindings> 66: </composite-component> 67: </components> 68: <bindings> 69: <binding client="ClientServerWrapper.m" server="clientWrapper.m"/> 70: <binding client="clientWrapper.s" server="serverWrapper.s"/> 71: </bindings> 72: </composite-component> 73: </components> 74:</componentsDescriptor>