On 2010-01-13 03.32, Niclas Hedhman wrote:
Fair observation. This field will cause (Stuart, please correct me if
I'm wrong), 16 bytes 'waste'. 160kB for 10,000 property instances...
Is that a lot?

Oh, that was not all that bad. I think that's reasonably ok actually.

Likewise;
  private ConstraintsCheck constraints;

is per PropertyInstance. Why don't we collapsed into PropertyInfo, as
I don't think it can be a "per instance" choice.

We tried that before, but it gets a bit complicated unfortunately...

Since the PropertyInfo is reasonably easily accessible from the various
descriptors, I'm considering whether we should change this, so that Property
does not extend PropertyInfo. It will then only have the get/set methods.
This will minimize the memory footprint, and also make it easier to do the
ComputedPropertyInstance, since no PropertyInfo needs to be provided.

Yes, ComputedProperty is a pain due to this.... and IMHO a bigger
reason to fix this.

Considering the above, yeah.

The main question is: is it ok if clients have to go through the
metadescriptors rather than ask a property for the metainfo?

Could we possibly consider another option?

public interface Name extends Property<String>
{
     @Structure PropertyInfo propertyInfo();
}

But how would that be implemented?

As a counter-argument, I noticed in my own code that I actually have a few places where I only have the properties AND use the metaInfo, and no access to the metaInfo of the composite. So I would have to change that. But that's doable.

/Rickard

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

Reply via email to