Changes between Version 42 and Version 43 of PRO_LIB_CORE_TUTORIAL
- Timestamp:
- 07/14/09 14:51:53 (16 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
PRO_LIB_CORE_TUTORIAL
v42 v43 717 717 }}} 718 718 * '''This should never happen.''' Every object that is a value of a property or is a value in a list property should either be a ProObject or an Immutable. Having objects like this one will never force an AutoProperty update if this AutoProperty depends on the "badObject()'s" property. Same applied to other properties depending on "badObject()'s" property. If a non-ProObject or non-@Immutable is really needed, use the resource property, where it is created and different things are set to it. 719 720 ==== One "child" owned by two separate parents ==== 721 722 * Suppose we have: 723 {{{ 724 class Child extends BaseProObject { 725 //empty. 726 } 727 728 class Parent extends BaseProObject { 729 730 @Own 731 public RwProp<Child> child() { 732 return getBean().makeValueProp("child", Child.class); 733 } 734 735 } 736 }}} 737 738 * The following should will not work and will throw an AlreadyOwnedException. Despite not working, it worth mentioning. Same applied to have any kind of value or list property that has the @Own annotation. 739 {{{ 740 Child child = new Child(); 741 Parent parent1 = new Parent(); 742 Parent parent2 = new Parent(); 743 parent1.child().set(child); 744 parent2.child().set(child); //throws an exception!!! 745 }}} 746 747 719 748 720 749 == Debugging ProLib ==