Niclas Hedhman wrote:
> On Tue, Nov 4, 2008 at 2:16 AM, Rickard Öberg <[EMAIL PROTECTED]> wrote:
> 
>> I've also changed so that now the property is actually set as mutable
>> during composite builder time. If you ask property.isImmutable() on an
>> immutable property when the source is a CompositeBuilder, the result
>> will be false. This properly ensures that the semantics are correct, and
>> that you can edit a composite in a UI with automatic detection of what
>> can be edited, and what cannot be edited.
> 
> You mean if I pass a "stateFor()" template to an editor?
> 
> That makes sense. But doesn't the client of composite builder
> sometimes need to know if the actual end result will be Immutable?
> 
> Maybe like;
> builder.isImmutable( property ) ???

Well, with the current implementation, if you ask property.isImmutable() 
you will get false, but property.metaInfo(Immutable.class) will return 
the annotation, so you can actually differentiate between the two if you 
really want to.

/Rickard

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

Reply via email to