[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [handly-dev] On the way to non-breaking evolution
|
Hi Vlad,
It is not always possible to rely on identity-based lookup for properties in general, because there may be context implementations backed by something like Guice, with different lookup strategies.
There is a simple and well-approved solution to the problem of ensuring unique names - namespacing. Properties that are pre-defined in Handly may use simple names, while properties defined by a plug-in developer should use fully qualified names. Actually, there is nothing new about it - Eclipse extension point and extension ids are an example. So, I wouldn't expect it to be a significant problem in practice.
Having said that, thank you for the discussion; I just thought that I should amend the properties defined in the example model implementations to use fully qualified names. Perhaps we should also use FQNs for the properties pre-defined in Handly, although strictly speaking it is not required as long as they don't conflict with each other. But just to be safe, that would make sense.
Thanks,
Vladimir
Hi!
Yes, I only looked at the current diffs, not the rest of the code, that would have cleared things up.
I still don't feel very comfortable with putting the burden of ensuring unique names for properties on the user - in theory, different plugins from different developers might create properties with the same name and use them on the same model. Maybe that won't be a problem in practice, but you have to decide if it's worth doing something about it. The big problem that I see is that the resulting code would be difficult to debug, with things happening differently depending on which other plugins are installed.
best regards,
Vlad