You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Simon Laws (JIRA)" <tu...@ws.apache.org> on 2007/10/01 21:47:50 UTC
[jira] Resolved: (TUSCANY-1825) SCA Java User Guide: Building The
Calculator Sample In Java code snippet missing @Reference annontation
[ https://issues.apache.org/jira/browse/TUSCANY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Simon Laws resolved TUSCANY-1825.
---------------------------------
Resolution: Fixed
Thank you Bruce. Have just been in and fixed that.
Simon
> SCA Java User Guide: Building The Calculator Sample In Java code snippet missing @Reference annontation
> -------------------------------------------------------------------------------------------------------
>
> Key: TUSCANY-1825
> URL: https://issues.apache.org/jira/browse/TUSCANY-1825
> Project: Tuscany
> Issue Type: Bug
> Components: Website
> Reporter: Bruce Gallegos
> Assignee: Simon Laws
>
> I was following along trying to implement the Sample in the Users guide and was getting the following errors:
> Oct 1, 2007 12:25:22 PM org.apache.tuscany.sca.assembly.builder.impl.CompositeBuilderImpl$1 problem
> WARNING: [WARNING] Reference not found for component reference: CalculatorServiceComponent/addService null
> so I compared my source to the source provided I realized that the *@Reference* annotation was missing from the setters methods in my source. Once I added the annotation everything worked perfectly.
> At any rate, I was thinking it might be worth adding the annotation in the wiki example source.
> {code}
> public class CalculatorServiceImpl implements CalculatorService {
> private AddService addService;
> private SubtractService subtractService;
> private MultiplyService multiplyService;
> private DivideService divideService;
> @Reference
> public void setAddService(AddService addService) {
> this.addService = addService;
> }
> ...set methods for the other attributes would go here
> public double add(double n1, double n2) {
> return addService.add(n1, n2);
> }
> ...implementations of the other methods would go here
> }
> {code}
> Thanks,
> Bruce
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org