On 05/18/2011 10:21 AM, Endi Sukma Dewata wrote:
A utility class has been added to store objects which can be accessed both as an ordered list and as a map. This class is used to store various objects including entities, fields, columns, and dialogs. The class needs to be defined in a new file called util.js to avoid circular dependency problem. A test suite for this class has been added as well.

Ticket #1232


_______________________________________________
Freeipa-devel mailing list
Freeipa-devel@redhat.com
https://www.redhat.com/mailman/listinfo/freeipa-devel


Good. The only thing I don't like about it is the Util namespace. I think this should be a JQuery plugin instead. Adding a Util namespace is just ignoring the problem of namespace pollution.

Can you move it to JQuery, and rename the file and class ordered_map?

Put some documentation in the file as to the contract: we explicitly don't hide access to the internals, but if you don't use the manipulator functions, you will corrupt the map etc.

This is where Javascript would really benefit from a macro language.
_______________________________________________
Freeipa-devel mailing list
Freeipa-devel@redhat.com
https://www.redhat.com/mailman/listinfo/freeipa-devel

Reply via email to