There are four typical ways to implement this: a) annotations b) static members holding metadata in the class owning the property, typically using naming conventions to locate c) separate classes accessed by naming convention like BeanInfo's approach d) external config (e.g. XML files)
Depending on the type of tooling, each way could make more sense. Best to wait until a good conversation around tooling happens. -----Original Message----- From: Greg Brown (JIRA) [mailto:[email protected]] Sent: Saturday, August 21, 2010 8:27 AM To: [email protected] Subject: [jira] Commented: (PIVOT-602) Create BeanInfo classes for WTK components [ https://issues.apache.org/jira/browse/PIVOT-602?page=com.atlassian.jira.plug in.system.issuetabpanels:comment-tabpanel&focusedCommentId=12901022#action_1 2901022 ] Greg Brown commented on PIVOT-602: ---------------------------------- FYI, the BeanMonitor class can be used to listen for property change events (it is used by ComponentExplorer and the namespace binding feature in BXMLSerializer). Rather than BeanInfo, how about creating a set of annotations that would contain this information? Annotations didn't exist when BeanInfo was created but serve a similar purpose. PIVOT-559 proposes a similar annotation for styles: https://issues.apache.org/jira/browse/PIVOT-559 Either way, while I like the concept, I would personally prefer to push it to a later release. There aren't currently any actual tools that could take advantage of the annotations, and we don't have a GUI builder planned until Pivot 3.0: https://issues.apache.org/jira/browse/PIVOT-30 I think we should focus on getting the current 2.0 feature set wrapped up and get it out the door. Then we could easily add this in a point release. > Create BeanInfo classes for WTK components > ------------------------------------------ > > Key: PIVOT-602 > URL: https://issues.apache.org/jira/browse/PIVOT-602 > Project: Pivot > Issue Type: New Feature > Components: wtk > Affects Versions: 2.0 > Reporter: Noel Grandin > Priority: Minor > > Create BeanInfo classes for the UI components to add make it easier to build design tools around Pivot. > For example, the BeanInfo classes would tell the design tool which values are valid for certain methods e.g. the methods that take enumerated values also never permit null. > Unfortunately, there will be some limitations - we cannot represent the Pivot listener pattern in the BeanInfo classes. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.
