/** * Helper method which obtains a list of targets for a reference * @param reference - Component reference * @return - the list of targets, which will be empty if there are no targets */ private List<ComponentService> getReferenceTargets(ComponentReference reference) { List<ComponentService> theTargets = reference.getTargets(); if (theTargets.isEmpty()) { // Component reference list of targets is empty, try the implementation reference if (reference.getReference() != null) { theTargets = reference.getReference().getTargets(); } // end if } // end if return theTargets; } // end method getReferenceTargets
/** * Helper method which obtains a list of targets for a reference * @param reference - Component reference * @return - the list of targets, which will be empty if there are no targets */ private List<ComponentService> getReferenceTargets(ComponentReference reference) { List<ComponentService> theTargets = reference.getTargets(); if (theTargets.isEmpty()) { // Component reference list of targets is empty, try the implementation reference if (reference.getReference() != null) { theTargets = reference.getReference().getTargets(); } // end if } // end if return theTargets; } // end method getReferenceTargets
/** * Helper method which obtains a list of targets for a reference * @param reference - Component reference * @return - the list of targets, which will be empty if there are no targets */ private List<ComponentService> getReferenceTargets(ComponentReference reference) { List<ComponentService> theTargets = reference.getTargets(); if (theTargets.isEmpty()) { // Component reference list of targets is empty, try the implementation reference if (reference.getReference() != null) { theTargets = reference.getReference().getTargets(); } // end if } // end if return theTargets; } // end method getReferenceTargets
/** * Helper method which obtains a list of targets for a reference * @param reference - Component reference * @return - the list of targets, which will be empty if there are no targets */ private List<ComponentService> getReferenceTargets(ComponentReference reference) { List<ComponentService> theTargets = reference.getTargets(); if (theTargets.isEmpty()) { // Component reference list of targets is empty, try the implementation reference if (reference.getReference() != null) { theTargets = reference.getReference().getTargets(); } // end if } // end if return theTargets; } // end method getReferenceTargets
protected void configure(ComponentReference componentReference, BuilderContext context) { Reference reference = componentReference.getReference(); if (reference != null) { configure(componentReference, reference, null, context); configureBindings(componentReference, reference, context); } }
protected void configure(ComponentReference componentReference, BuilderContext context) { Reference reference = componentReference.getReference(); if (reference != null) { configure(componentReference, reference, null, context); configureBindings(componentReference, reference, context); } }
/** * Follow a reference promotion chain down to the innermost (non composite) * component references. * * @param compositeReference * @param componentReferences * @return */ private void collectPromotedComponentReferences(CompositeReference compositeReference, List<ComponentReference> componentReferences) { for (ComponentReference componentReference : compositeReference.getPromotedReferences()) { Reference reference = componentReference.getReference(); if (reference instanceof CompositeReference) { // Continue to follow the reference promotion chain collectPromotedComponentReferences((CompositeReference)reference, componentReferences); } else if (reference != null) { // Found a non-composite reference componentReferences.add(componentReference); } } }
/** * Follow a reference promotion chain down to the innermost (non composite) * component references. * * @param compositeReference * @param componentReferences * @return */ private void collectPromotedComponentReferences(CompositeReference compositeReference, List<ComponentReference> componentReferences) { for (ComponentReference componentReference : compositeReference.getPromotedReferences()) { Reference reference = componentReference.getReference(); if (reference instanceof CompositeReference) { // Continue to follow the reference promotion chain collectPromotedComponentReferences((CompositeReference)reference, componentReferences); } else if (reference != null) { // Found a non-composite reference componentReferences.add(componentReference); } } }
/** * Follow a reference promotion chain down to the innermost (non composite) * component references. * * @param compositeReference * @param componentReferences * @return */ private void collectPromotedComponentReferences(CompositeReference compositeReference, List<ComponentReference> componentReferences) { for (ComponentReference componentReference : compositeReference.getPromotedReferences()) { // If the user has entered an incorrect promotion string an error will be reported to // tell them but the processing will still reach here so only continue processing // if the promotion chain is well formed if (componentReference != null){ Reference reference = componentReference.getReference(); if (reference instanceof CompositeReference) { // Continue to follow the reference promotion chain collectPromotedComponentReferences((CompositeReference)reference, componentReferences); } else if (reference != null) { // Found a non-composite reference componentReferences.add(componentReference); } } } }
/** * Follow a reference promotion chain down to the innermost (non composite) * component references. * * @param compositeReference * @param componentReferences * @return */ private void collectPromotedComponentReferences(CompositeReference compositeReference, List<ComponentReference> componentReferences) { for (ComponentReference componentReference : compositeReference.getPromotedReferences()) { // If the user has entered an incorrect promotion string an error will be reported to // tell them but the processing will still reach here so only continue processing // if the promotion chain is well formed if (componentReference != null){ Reference reference = componentReference.getReference(); if (reference instanceof CompositeReference) { // Continue to follow the reference promotion chain collectPromotedComponentReferences((CompositeReference)reference, componentReferences); } else if (reference != null) { // Found a non-composite reference componentReferences.add(componentReference); } } } }
/** * Navigate the component/componentType inheritance chain to find the leaf contract * @param contract * @return */ private Contract getLeafContract(Contract contract) { Contract prev = null; Contract current = contract; while (current != null) { prev = current; if (current instanceof ComponentReference) { current = ((ComponentReference)current).getReference(); } else if (current instanceof CompositeReference) { current = ((CompositeReference)current).getPromotedReferences().get(0); } else if (current instanceof ComponentService) { current = ((ComponentService)current).getService(); } else if (current instanceof CompositeService) { current = ((CompositeService)current).getPromotedService(); } else { break; } if (current == null) { return prev; } } return current; }
/** * Navigate the component/componentType inheritence chain to find the leaf contract * @param contract * @return */ private Contract getLeafContract(Contract contract) { Contract prev = null; Contract current = contract; while (current != null) { prev = current; if (current instanceof ComponentReference) { current = ((ComponentReference)current).getReference(); } else if (current instanceof CompositeReference) { current = ((CompositeReference)current).getPromotedReferences().get(0); } else if (current instanceof ComponentService) { current = ((ComponentService)current).getService(); } else if (current instanceof CompositeService) { current = ((CompositeService)current).getPromotedService(); } else { break; } if (current == null) { return prev; } } return current; }
ComponentReference componentReference, Monitor monitor) { Reference reference = componentReference.getReference();
ComponentReference componentReference, Monitor monitor) { Reference reference = componentReference.getReference();
ComponentReference componentReference, Monitor monitor) { Reference reference = componentReference.getReference();
public WireFormatJMSTextReferenceProvider(ExtensionPointRegistry registry, RuntimeEndpointReference endpointReference) { super(); this.registry = registry; this.endpointReference = endpointReference; this.binding = (JMSBinding)endpointReference.getBinding(); // configure the reference based on this wire format // currently maintaining the message processor structure which // contains the details of jms message processing however override // any message processors specified in the SCDL in this case // this wire format doubles up as the execution logic for user defined // message processors so check the processor name is still set to default // before overwriting if ((this.binding.getRequestWireFormat() instanceof WireFormatJMSText) && (this.binding.getRequestMessageProcessorName().equals(JMSBindingConstants.DEFAULT_MP_CLASSNAME))){ this.binding.setRequestMessageProcessorName(JMSBindingConstants.TEXT_MP_CLASSNAME); } if ((this.binding.getResponseWireFormat() instanceof WireFormatJMSText) && (this.binding.getResponseMessageProcessorName().equals(JMSBindingConstants.DEFAULT_MP_CLASSNAME))){ this.binding.setResponseMessageProcessorName(JMSBindingConstants.TEXT_MP_CLASSNAME); } // just point to the reference interface contract so no // databinding transformation takes place interfaceContract = endpointReference.getReference().getReference().getInterfaceContract(); }
List<Operation> opList = reference.getReference().getInterfaceContract().getInterface().getOperations(); interfaceContract = reference.getReference().getInterfaceContract();
public WireFormatJMSBytesReferenceProvider(ExtensionPointRegistry registry, RuntimeEndpointReference endpointReference) { super(); this.registry = registry; this.endpointReference = endpointReference; this.binding = (JMSBinding) endpointReference.getBinding(); // configure the reference based on this wire format // currently maintaining the message processor structure which // contains the details of jms message processing however overried // any message processors specied in the SCDL in this case if (this.binding.getRequestWireFormat() instanceof WireFormatJMSBytes){ this.binding.setRequestMessageProcessorName(JMSBindingConstants.BYTES_MP_CLASSNAME); } if (this.binding.getResponseWireFormat() instanceof WireFormatJMSBytes){ this.binding.setResponseMessageProcessorName(JMSBindingConstants.BYTES_MP_CLASSNAME); } // just point to the reference interface contract so no // databinding transformation takes place interfaceContract = endpointReference.getReference().getReference().getInterfaceContract(); }
if (componentReference.getReference() != null || componentReference.isForCallback()) { continue;
if (componentReference.getReference() != null || componentReference.isForCallback()) { continue;