Dear Qi4j developers,

I'm trying to add SideEffects to Properties of Composites so that I can
trace getting and setting of property values. In order to get a feeling
for Qi4j in general (I'm a Newbie) and SideEffects in particular, I
copied LogPropertyAccess and LogPropertyChanges from
org.qi4j.runtime.property.PropertyTest together with the Company and Co.
composite to my test application:

public interface Company extends Nameable, TransientComposite {
}

@SideEffects({ LogPropertyAccess.class, LogPropertyChanges.class })
public interface Nameable {
        Property<String> name();
}

Unfortunately, getting/setting property name() did not trigger the
expected SideEffects.

Applying the SideEffects directly to the property method did not work
either:

public interface Nameable {
                @SideEffects({ LogPropertyAccess.class, 
LogPropertyChanges.class })
                Property<String> name();
}

The @Ignore comment on org.qi4j.runtime.property.PropertyTest ("This is
an incorrect satisfiedBy case. [...]") seems to indicate that
SideEffects on Properties might not work right now.?

If this is the case, is there another Qi4j-ish way to get notified about
property value changes? I'm intending to update UI elements whenever the
underlying Composites change state.

P.S. I also tested Concerns for Properties (instead of SideEffects);
this did not work either. But concerns on ordinary (non-property)
methods works find of course.

Many thanks,
Frank

_______________________________________________
qi4j-dev mailing list
[email protected]
http://lists.ops4j.org/mailman/listinfo/qi4j-dev

Reply via email to