posted 20 years ago
Hello fellow ranchers,
The result of the f2.setBar(f1.getBar()); operation is that f1 has a broken link, b2 has a broken link and f2 is linked to b1. The linkages are UNIdirectional, meaning that Foo can access Bar but Bar cannot access Foo. This suggests to me that the operation b2.getFoo() should fail since Bar does not have a link to Foo (see page 391). Similarly b1.getFoo() should fail, even though, in this case, there is a link but it goes in the wrong direction. So I would say A is correct. In the book, it says B is also correct. Can anyone see why?
regards and thanks,
Simon