Functionality
This component is aimed at demonstrating the dynamic generation of ports based on the configuration made. By default, there are no input and output ports for this sample component. In the component's custom property sheet (CPS), a property called "Number of Ports" can be seen; input and output ports will be generated based on the value of this property.
Default Behavior
By default, the component sends the message received on a particular input port to all the output ports.
Changes required to use a different CPS
Add the following lines in etc\ServiceDescriptor.xml under "execution" element after "separate-process" element,
AddUnder "servicerefs" element, make the following service reference changes:
AddRemoveAdd 'cpsClass' and 'cpsMandatory' (if the configuration is mandatory) attributes in service-export ant task (present in the target "deploy")
in common.xml as shown below:Add class DynamicPortsPM.
Provide default constructor and a parameterized constructor (taking "CPSHelper" as the parameter)
Add the following methods:
private void generateInports(int val)
private void generateOutports(int val)
Also follow steps 2-4 in ..\PortProperties\readme.txt