Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[higgins-dev] metadata for attribute value components

An issue has arisen while trying to map multi-valued Directory attributes to single-valued Higgins attributes. This is an implementation problem, but is general enough that we may want to come up with a best practice.
 
Assume an attribute called "member" which holds the names of group members. A simple way to model this in Java would be to say the attribute value is an array of String objects.  That leaves nowhere to associate metadata with the individual member values. For example, we would need to store "source" data with each member value.
 
When considering a "joining" context provider, we see that any attribute having multiple values may also have multiple sources, thus this same problem will apply to many attributes.
 
We could solve this by saying the attribute value is an array of IAttribute objects.  This gives us the ability to have multiple values where metadata may be associated with each.  At first, it seems a little heavyweight. For example, the type field of the attributes in the array would likely either not be used, or at least typically always be the same for all attributes in the array. Furthermore, if the type field is required, then one must define two attribute types for every multi-valued attribute (one for the attribute, and one for the individual values).
 
Any other ideas?
 
Jim

Back to the top