I am working on adding some common functionality to a potentially large set of diverse custom controls.
To surface my configuration-driven functionality, I was thinking an elegant way could be to add custom members to the "metadata" section of a control's definition.
For example, something like this:
sap.ui.core.Control.extend("myCompany.foo.FooControl", {
metadata: {
// normal stuff, properties, aggregation, etc...
properties: {
},
...
// my custom stuff
custom: {
}
}
});
Is there a best practice way of adding custom content to the metadata object? Or, is there a way to get a hold of this object literal at runtime so I could at least parse it for my custom attributes?