You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beehive.apache.org by cs...@apache.org on 2006/07/06 18:45:24 UTC

svn commit: r419614 [6/6] - in /beehive/trunk/controls/test: ./ src/controls/org/apache/beehive/controls/test/controls/assembly/ src/controls/org/apache/beehive/controls/test/controls/beaninfo/ src/controls/org/apache/beehive/controls/test/controls/gen...

Added: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/inherit/Intf2Bean.beaninfo
URL: http://svn.apache.org/viewvc/beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/inherit/Intf2Bean.beaninfo?rev=419614&view=auto
==============================================================================
--- beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/inherit/Intf2Bean.beaninfo (added)
+++ beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/inherit/Intf2Bean.beaninfo Thu Jul  6 09:45:19 2006
@@ -0,0 +1,629 @@
+<bean-info name="org.apache.beehive.controls.test.controls.inherit.Intf2Bean">
+    <bean-descriptor name="Intf2Bean">
+        <feature-descriptor name="Intf2Bean"
+            full-name="Intf2Bean"
+            is-expert=false
+            is-hidden=false
+            is-preferred=false>
+            <short-description>
+                Intf2Bean
+            </short-description>
+            <attributes>
+                <attribute name="persistenceDelegate" value="org.apache.beehive.controls.runtime.bean.BeanPersistenceDelegate@">
+            </attributes>
+        </feature-descriptor>
+        <bean-class>
+            org.apache.beehive.controls.test.controls.inherit.Intf2Bean
+        </bean-class>
+    </bean-descriptor>
+    <method-descriptors>
+        <method-descriptor name="addInOperation1"
+            <method>
+                public abstract void org.apache.beehive.controls.test.controls.inherit.AddIn.addInOperation1()
+            </method>
+            <param-descriptors/>
+            <feature-descriptor name="addInOperation1"
+                full-name="addInOperation1"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    addInOperation1
+                </short-description>
+            </feature-descriptor>
+        </method-descriptor>
+        <method-descriptor name="addInOperation2"
+            <method>
+                public abstract void org.apache.beehive.controls.test.controls.inherit.AddIn.addInOperation2()
+            </method>
+            <param-descriptors/>
+            <feature-descriptor name="addInOperation2"
+                full-name="addInOperation2"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    addInOperation2
+                </short-description>
+            </feature-descriptor>
+        </method-descriptor>
+        <method-descriptor name="intf1Operation1"
+            <method>
+                public abstract int org.apache.beehive.controls.test.controls.inherit.Intf1.intf1Operation1()
+            </method>
+            <param-descriptors/>
+            <feature-descriptor name="intf1Operation1"
+                full-name="intf1Operation1"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf1Operation1
+                </short-description>
+            </feature-descriptor>
+        </method-descriptor>
+        <method-descriptor name="intf1Operation2"
+            <method>
+                public abstract int org.apache.beehive.controls.test.controls.inherit.Intf1.intf1Operation2()
+            </method>
+            <param-descriptors/>
+            <feature-descriptor name="intf1Operation2"
+                full-name="intf1Operation2"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf1Operation2
+                </short-description>
+            </feature-descriptor>
+        </method-descriptor>
+        <method-descriptor name="intf2Operation1"
+            <method>
+                public abstract int org.apache.beehive.controls.test.controls.inherit.Intf2.intf2Operation1()
+            </method>
+            <param-descriptors/>
+            <feature-descriptor name="intf2Operation1"
+                full-name="intf2Operation1"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf2Operation1
+                </short-description>
+            </feature-descriptor>
+        </method-descriptor>
+        <method-descriptor name="intf2Operation2"
+            <method>
+                public abstract int org.apache.beehive.controls.test.controls.inherit.Intf2.intf2Operation2()
+            </method>
+            <param-descriptors/>
+            <feature-descriptor name="intf2Operation2"
+                full-name="intf2Operation2"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf2Operation2
+                </short-description>
+            </feature-descriptor>
+        </method-descriptor>
+        <method-descriptor name="rootOperation1"
+            <method>
+                public abstract void org.apache.beehive.controls.test.controls.inherit.Root.rootOperation1()
+            </method>
+            <param-descriptors/>
+            <feature-descriptor name="rootOperation1"
+                full-name="rootOperation1"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    rootOperation1
+                </short-description>
+            </feature-descriptor>
+        </method-descriptor>
+        <method-descriptor name="rootOperation2"
+            <method>
+                public abstract void org.apache.beehive.controls.test.controls.inherit.Root.rootOperation2()
+            </method>
+            <param-descriptors/>
+            <feature-descriptor name="rootOperation2"
+                full-name="rootOperation2"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    rootOperation2
+                </short-description>
+            </feature-descriptor>
+        </method-descriptor>
+    </method-descriptors>
+    <property-descriptors default-index=-1>
+        <property-descriptor name="controlImplementation">
+            type="java.lang.String"
+            isBound=false
+            isConstrained=false
+            isDefault=false>
+            <read-method>
+                public java.lang.String org.apache.beehive.controls.test.controls.inherit.Intf1Bean.getControlImplementation()
+            </read-method>
+            <write-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf1Bean.setControlImplementation(java.lang.String)
+            </write-method>
+            <feature-descriptor name="controlImplementation"
+                full-name="controlImplementation"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    controlImplementation
+                </short-description>
+            </feature-descriptor>
+        </property-descriptor>
+        <property-descriptor name="intf1Prop1">
+            type="int"
+            isBound=false
+            isConstrained=false
+            isDefault=false>
+            <read-method>
+                public int org.apache.beehive.controls.test.controls.inherit.Intf1Bean.getIntf1Prop1()
+            </read-method>
+            <write-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf1Bean.setIntf1Prop1(int)
+            </write-method>
+            <feature-descriptor name="intf1Prop1"
+                full-name="intf1Prop1"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf1Prop1
+                </short-description>
+            </feature-descriptor>
+        </property-descriptor>
+        <property-descriptor name="intf1Prop2">
+            type="int"
+            isBound=false
+            isConstrained=false
+            isDefault=false>
+            <read-method>
+                public int org.apache.beehive.controls.test.controls.inherit.Intf1Bean.getIntf1Prop2()
+            </read-method>
+            <write-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf1Bean.setIntf1Prop2(int)
+            </write-method>
+            <feature-descriptor name="intf1Prop2"
+                full-name="intf1Prop2"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf1Prop2
+                </short-description>
+            </feature-descriptor>
+        </property-descriptor>
+        <property-descriptor name="intf2Prop1">
+            type="int"
+            isBound=false
+            isConstrained=false
+            isDefault=false>
+            <read-method>
+                public int org.apache.beehive.controls.test.controls.inherit.Intf2Bean.getIntf2Prop1()
+            </read-method>
+            <write-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf2Bean.setIntf2Prop1(int)
+            </write-method>
+            <feature-descriptor name="intf2Prop1"
+                full-name="intf2Prop1"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf2Prop1
+                </short-description>
+            </feature-descriptor>
+        </property-descriptor>
+        <property-descriptor name="intf2Prop2">
+            type="int"
+            isBound=false
+            isConstrained=false
+            isDefault=false>
+            <read-method>
+                public int org.apache.beehive.controls.test.controls.inherit.Intf2Bean.getIntf2Prop2()
+            </read-method>
+            <write-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf2Bean.setIntf2Prop2(int)
+            </write-method>
+            <feature-descriptor name="intf2Prop2"
+                full-name="intf2Prop2"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf2Prop2
+                </short-description>
+            </feature-descriptor>
+        </property-descriptor>
+    </property-descriptors>
+    <event-set-descriptors default-index=-1>
+        <event-descriptor name="intf2NewEvents"
+            is-unicast=true
+            is-in-default=true
+            is-default=false>
+            <listener-type>
+                org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2NewEvents
+            </listener-type>
+            <add-listener-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf2Bean.addIntf2NewEventsListener(org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2NewEvents) throws java.util.TooManyListenersException
+            </add-listener-method>
+            <remove-listener-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf2Bean.removeIntf2NewEventsListener(org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2NewEvents)
+            </remove-listener-method>
+            <get-listener-method>
+                public synchronized org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2NewEvents[] org.apache.beehive.controls.test.controls.inherit.Intf2Bean.getIntf2NewEventsListeners()
+            </get-listener-method>
+            <listener-method-descriptors>
+                <method-descriptor name="addInEvent1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.AddIn$AddInEvents.addInEvent1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="addInEvent1"
+                        full-name="addInEvent1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            addInEvent1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="addInEvent2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.AddIn$AddInEvents.addInEvent2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="addInEvent2"
+                        full-name="addInEvent2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            addInEvent2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="intf2NewEvent1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2NewEvents.intf2NewEvent1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf2NewEvent1"
+                        full-name="intf2NewEvent1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf2NewEvent1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="intf2NewEvent2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2NewEvents.intf2NewEvent2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf2NewEvent2"
+                        full-name="intf2NewEvent2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf2NewEvent2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+            </listener-method-descriptors>
+            <feature-descriptor name="intf2NewEvents"
+                full-name="intf2NewEvents"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf2NewEvents
+                </short-description>
+            </feature-descriptor>
+        <event-descriptor name="intf1Events"
+            is-unicast=false
+            is-in-default=true
+            is-default=false>
+            <listener-type>
+                org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1Events
+            </listener-type>
+            <add-listener-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf1Bean.addIntf1EventsListener(org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1Events)
+            </add-listener-method>
+            <remove-listener-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf1Bean.removeIntf1EventsListener(org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1Events)
+            </remove-listener-method>
+            <get-listener-method>
+                public synchronized org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1Events[] org.apache.beehive.controls.test.controls.inherit.Intf1Bean.getIntf1EventsListeners()
+            </get-listener-method>
+            <listener-method-descriptors>
+                <method-descriptor name="intf1Event1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1Events.intf1Event1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf1Event1"
+                        full-name="intf1Event1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf1Event1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="intf1Event2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1Events.intf1Event2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf1Event2"
+                        full-name="intf1Event2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf1Event2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="rootEvent1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Root$RootEvents.rootEvent1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="rootEvent1"
+                        full-name="rootEvent1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            rootEvent1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="rootEvent2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Root$RootEvents.rootEvent2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="rootEvent2"
+                        full-name="rootEvent2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            rootEvent2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+            </listener-method-descriptors>
+            <feature-descriptor name="intf1Events"
+                full-name="intf1Events"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf1Events
+                </short-description>
+            </feature-descriptor>
+        <event-descriptor name="intf1NewEvents"
+            is-unicast=true
+            is-in-default=true
+            is-default=false>
+            <listener-type>
+                org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1NewEvents
+            </listener-type>
+            <add-listener-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf1Bean.addIntf1NewEventsListener(org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1NewEvents) throws java.util.TooManyListenersException
+            </add-listener-method>
+            <remove-listener-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf1Bean.removeIntf1NewEventsListener(org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1NewEvents)
+            </remove-listener-method>
+            <get-listener-method>
+                public synchronized org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1NewEvents[] org.apache.beehive.controls.test.controls.inherit.Intf1Bean.getIntf1NewEventsListeners()
+            </get-listener-method>
+            <listener-method-descriptors>
+                <method-descriptor name="intf1NewEvent1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1NewEvents.intf1NewEvent1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf1NewEvent1"
+                        full-name="intf1NewEvent1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf1NewEvent1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="intf1NewEvent2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1NewEvents.intf1NewEvent2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf1NewEvent2"
+                        full-name="intf1NewEvent2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf1NewEvent2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+            </listener-method-descriptors>
+            <feature-descriptor name="intf1NewEvents"
+                full-name="intf1NewEvents"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf1NewEvents
+                </short-description>
+            </feature-descriptor>
+        <event-descriptor name="intf2Events"
+            is-unicast=false
+            is-in-default=true
+            is-default=false>
+            <listener-type>
+                org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2Events
+            </listener-type>
+            <add-listener-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf2Bean.addIntf2EventsListener(org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2Events)
+            </add-listener-method>
+            <remove-listener-method>
+                public synchronized void org.apache.beehive.controls.test.controls.inherit.Intf2Bean.removeIntf2EventsListener(org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2Events)
+            </remove-listener-method>
+            <get-listener-method>
+                public synchronized org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2Events[] org.apache.beehive.controls.test.controls.inherit.Intf2Bean.getIntf2EventsListeners()
+            </get-listener-method>
+            <listener-method-descriptors>
+                <method-descriptor name="addInEvent1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.AddIn$AddInEvents.addInEvent1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="addInEvent1"
+                        full-name="addInEvent1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            addInEvent1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="addInEvent2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.AddIn$AddInEvents.addInEvent2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="addInEvent2"
+                        full-name="addInEvent2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            addInEvent2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="intf1Event1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1Events.intf1Event1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf1Event1"
+                        full-name="intf1Event1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf1Event1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="intf1Event2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf1$Intf1Events.intf1Event2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf1Event2"
+                        full-name="intf1Event2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf1Event2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="intf2Event1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2Events.intf2Event1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf2Event1"
+                        full-name="intf2Event1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf2Event1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="intf2Event2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Intf2$Intf2Events.intf2Event2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="intf2Event2"
+                        full-name="intf2Event2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            intf2Event2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="rootEvent1"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Root$RootEvents.rootEvent1()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="rootEvent1"
+                        full-name="rootEvent1"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            rootEvent1
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+                <method-descriptor name="rootEvent2"
+                    <method>
+                        public abstract void org.apache.beehive.controls.test.controls.inherit.Root$RootEvents.rootEvent2()
+                    </method>
+                    <param-descriptors/>
+                    <feature-descriptor name="rootEvent2"
+                        full-name="rootEvent2"
+                        is-expert=false
+                        is-hidden=false
+                        is-preferred=false>
+                        <short-description>
+                            rootEvent2
+                        </short-description>
+                    </feature-descriptor>
+                </method-descriptor>
+            </listener-method-descriptors>
+            <feature-descriptor name="intf2Events"
+                full-name="intf2Events"
+                is-expert=false
+                is-hidden=false
+                is-preferred=false>
+                <short-description>
+                    intf2Events
+                </short-description>
+            </feature-descriptor>
+    </event-set-descriptors>
+    <additional-bean-info/>
+</bean-info>

Added: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/EventSetInfoTest.java
URL: http://svn.apache.org/viewvc/beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/EventSetInfoTest.java?rev=419614&view=auto
==============================================================================
--- beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/EventSetInfoTest.java (added)
+++ beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/EventSetInfoTest.java Thu Jul  6 09:45:19 2006
@@ -0,0 +1,79 @@
+/*
+ * Copyright 2006 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * $Header:$
+ */
+
+package org.apache.beehive.controls.test.junit.packaging;
+
+import org.apache.beehive.controls.test.junit.ControlTestCase;
+import org.apache.beehive.controls.test.controls.packaging.HelloBean;
+import org.apache.beehive.controls.api.bean.Control;
+
+import java.beans.BeanInfo;
+import java.beans.EventSetDescriptor;
+import java.beans.Introspector;
+
+/**
+ * A TestCase that tests controls EventInfo
+ * <p/>
+ * EventInfo annotation on control interface is saved into controlBeanInfo class
+ * when the control is packaged.
+ */
+public class EventSetInfoTest extends ControlTestCase {
+
+    @Control
+    private HelloBean _hBean;
+    
+    /**
+     * Test getting FeatureInfo from ControlBeanInfo class
+     */
+    public void testGetEventSetInfo() throws Exception {
+
+        BeanInfo beanInfo = Introspector.getBeanInfo(Class.forName(
+                "org.apache.beehive.controls.test.controls.packaging.HelloBean"));
+        EventSetDescriptor[] descriptors = beanInfo.getEventSetDescriptors();
+
+        // Find and inspect EventSet descriptor declared on HelloBean.
+        EventSetDescriptor descriptor = findEventSet(descriptors, "eventSet0");
+        assertNotNull(descriptor);
+        assertTrue(descriptor.isInDefaultEventSet());
+        assertFalse(descriptor.isUnicast());
+
+        descriptor = findEventSet(descriptors, "eventSet1");
+        assertNotNull(descriptor);
+        assertTrue(descriptor.isInDefaultEventSet());
+        assertFalse(descriptor.isUnicast());
+
+        descriptor = findEventSet(descriptors, "eventSet2");
+        assertNotNull(descriptor);
+        assertTrue(descriptor.isInDefaultEventSet());
+        assertTrue(descriptor.isUnicast());
+    }
+
+    private EventSetDescriptor findEventSet(EventSetDescriptor[] array, String eventname) {
+        EventSetDescriptor result = null;
+        for (EventSetDescriptor anArray : array) {
+            result = anArray;
+            if (result.getName().equals(eventname)) {
+                break;
+            }
+            else {
+                result = null;
+            }
+        }
+        return result;
+    }
+}

Propchange: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/EventSetInfoTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/FeatureInfoTest.java
URL: http://svn.apache.org/viewvc/beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/FeatureInfoTest.java?rev=419614&view=auto
==============================================================================
--- beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/FeatureInfoTest.java (added)
+++ beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/FeatureInfoTest.java Thu Jul  6 09:45:19 2006
@@ -0,0 +1,60 @@
+/*
+ * Copyright 2006 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * $Header:$
+ */
+
+package org.apache.beehive.controls.test.junit.packaging;
+
+import org.apache.beehive.controls.api.bean.Control;
+import org.apache.beehive.controls.test.controls.packaging.FeatureInfoControlBean;
+import org.apache.beehive.controls.test.junit.ControlTestCase;
+
+import java.beans.BeanDescriptor;
+import java.beans.BeanInfo;
+import java.beans.Introspector;
+
+/**
+ * A TestCase that tests controls FeatureInfo in controls packaging
+ * <p/>
+ * FeatureInfo annotation on control interface is saved into controlBeanInfo class
+ * when the control is packaged.
+ * <p/>
+ * The tests in this class get feature info from controlBeanInfo class after the
+ * control is packaged into jar, in order to verify this part of control packaging
+ * process.
+ */
+public class FeatureInfoTest extends ControlTestCase {
+
+    @Control
+    private FeatureInfoControlBean _ficBean;
+
+    /**
+     * Test getting FeatureInfo from ControlBeanInfo class
+     */
+    public void testGetClassLevelFeatureInfo() throws Exception {
+
+        BeanInfo beanInfo = Introspector.getBeanInfo(Class.forName(
+                "org.apache.beehive.controls.test.controls.packaging.FeatureInfoControlBean"));
+
+        BeanDescriptor descriptor = beanInfo.getBeanDescriptor();
+        assertEquals("FeatureInfoControlBean", descriptor.getName());
+        assertEquals("A Control to test packaging", descriptor.getDisplayName());
+        assertEquals("This control is to test control packaging", descriptor.getShortDescription());
+        assertTrue(descriptor.isExpert());
+        assertTrue(descriptor.isHidden());
+        assertTrue(descriptor.isPreferred());
+    }
+}

Propchange: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/FeatureInfoTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/PropertyInfoTest.java
URL: http://svn.apache.org/viewvc/beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/PropertyInfoTest.java?rev=419614&view=auto
==============================================================================
--- beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/PropertyInfoTest.java (added)
+++ beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/PropertyInfoTest.java Thu Jul  6 09:45:19 2006
@@ -0,0 +1,92 @@
+/*
+ * Copyright 2006 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * $Header:$
+ */
+
+package org.apache.beehive.controls.test.junit.packaging;
+
+import junit.framework.TestCase;
+
+import java.beans.BeanInfo;
+import java.beans.Introspector;
+import java.beans.PropertyDescriptor;
+
+import org.apache.beehive.controls.api.bean.Control;
+import org.apache.beehive.controls.test.controls.packaging.BoundPropertyControlBean;
+
+/**
+ * A TestCase that tests controls PropertyInfo
+ * <p/>
+ * PropertyInfo annotation on control interface is saved into controlBeanInfo class
+ * when the control is packaged.
+ * <p/>
+ * The tests in this class get property info from controlBeanInfo class after the
+ * control is packaged into jar, in order to verify this part of control packaging
+ * process.
+ */
+public class PropertyInfoTest extends TestCase {
+
+    @Control
+    private BoundPropertyControlBean _bpcBean;
+
+    /**
+     * Test getting FeatureInfo from ControlBeanInfo class
+     */
+    public void testGetPropertyInfo() throws Exception {
+        BeanInfo beanInfo = Introspector.getBeanInfo(Class.forName(
+                "org.apache.beehive.controls.test.controls.packaging.BoundPropertyControlBean"));
+        PropertyDescriptor[] descriptors = beanInfo.getPropertyDescriptors();
+
+        // Find and inspect property descriptor declared on BoundPropertyControlBean.
+        PropertyDescriptor descriptor = findProperty(descriptors, "Brand");
+        assertNotNull(descriptor);
+        assertTrue(descriptor.isBound());
+        assertFalse(descriptor.isConstrained());
+
+        descriptor = findProperty(descriptors, "Material");
+        assertNotNull(descriptor);
+        assertFalse(descriptor.isBound());
+        assertTrue(descriptor.isConstrained());
+
+        descriptor = findProperty(descriptors, "Quality");
+        assertNotNull(descriptor);
+        assertTrue(descriptor.isBound());
+        assertTrue(descriptor.isConstrained());
+
+        descriptor = findProperty(descriptors, "age");
+        assertNotNull(descriptor);
+        assertTrue(descriptor.isBound());
+        assertFalse(descriptor.isConstrained());
+
+        descriptor = findProperty(descriptors, "height");
+        assertNotNull(descriptor);
+        assertFalse(descriptor.isBound());
+        assertTrue(descriptor.isConstrained());
+    }
+
+    private PropertyDescriptor findProperty(PropertyDescriptor[] array, String propertyname) {
+
+        PropertyDescriptor result = null;
+        for (PropertyDescriptor anArray : array) {
+            result = anArray;
+            if (result.getName().equals(propertyname))
+                break;
+            else
+                result = null;
+        }
+        return result;
+    }
+}

Propchange: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/packaging/PropertyInfoTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/utils/ControlIntrospector.java
URL: http://svn.apache.org/viewvc/beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/utils/ControlIntrospector.java?rev=419614&view=auto
==============================================================================
--- beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/utils/ControlIntrospector.java (added)
+++ beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/utils/ControlIntrospector.java Thu Jul  6 09:45:19 2006
@@ -0,0 +1,391 @@
+/*
+ * Copyright 2004 The Apache Software Foundation.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ * $Header:$
+ */
+package org.apache.beehive.controls.test.junit.utils;
+
+import java.beans.BeanDescriptor;
+import java.beans.BeanInfo;
+import java.beans.EventSetDescriptor;
+import java.beans.FeatureDescriptor;
+import java.beans.IntrospectionException;
+import java.beans.Introspector;
+import java.beans.MethodDescriptor;
+import java.beans.ParameterDescriptor;
+import java.beans.PropertyDescriptor;
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.OutputStream;
+import java.io.PrintStream;
+import java.io.PrintWriter;
+import java.lang.reflect.Method;
+import java.util.Comparator;
+import java.util.Enumeration;
+import java.util.Set;
+import java.util.SortedSet;
+import java.util.TreeSet;
+
+/**
+ * A utility class for introspecting Control beans
+ */
+public final class ControlIntrospector {
+
+    private Class _beanClass;
+    private int _indentLevel = 0;
+    private PrintWriter _pw;
+
+    public ControlIntrospector(Class beanClass, OutputStream output) {
+        _beanClass = beanClass;
+        _pw = new PrintWriter(output);
+    }
+
+    private void indent() {
+        _indentLevel++;
+    }
+
+    private void unindent() {
+        _indentLevel--;
+    }
+
+    private void printf(String format, Object ...args) {
+        for (int i = 0; i < _indentLevel; i++)
+            _pw.append("    ");
+        _pw.printf(format, args);
+        _pw.println();
+    }
+
+    private void printElement(String name, String value) {
+        printf("<%s>", name);
+        indent();
+        printf("%s", value);
+        unindent();
+        printf("</%s>", name);
+    }
+
+    /**
+     * Introspects the target class and writes the formatted results from introspection to
+     * the provided output stream
+     */
+    public void introspect(int flags)
+            throws IntrospectionException {
+
+        BeanInfo beanInfo = Introspector.getBeanInfo(_beanClass, flags);
+        if (beanInfo == null)
+            throw new IntrospectionException("No BeanInfo for " + _beanClass);
+
+        introspectBeanInfo(beanInfo);
+
+        _pw.flush();
+    }
+
+    public void introspect()
+            throws IntrospectionException {
+        introspect(Introspector.USE_ALL_BEANINFO);
+    }
+
+    private void introspectBeanInfo(BeanInfo beanInfo) {
+        printf("<bean-info name=\"%s\">", beanInfo.getBeanDescriptor().getBeanClass().getName());
+        indent();
+        {
+            introspectBeanDescriptor(beanInfo.getBeanDescriptor());
+
+            MethodDescriptor [] methodDescs = beanInfo.getMethodDescriptors();
+            if (methodDescs != null && methodDescs.length != 0) {
+                printf("<method-descriptors>");
+                indent();
+                introspectMethodDescriptors(methodDescs);
+                unindent();
+                printf("</method-descriptors>");
+            }
+            else printf("<method-descriptors/>");
+
+            PropertyDescriptor [] propDescs = beanInfo.getPropertyDescriptors();
+            if (propDescs != null && propDescs.length != 0) {
+                printf("<property-descriptors default-index=%d>", beanInfo.getDefaultPropertyIndex());
+                indent();
+                for (int i = 0; i < propDescs.length; i++)
+                    introspectPropertyDescriptor(propDescs[i],
+                                                 i == beanInfo.getDefaultPropertyIndex());
+                unindent();
+                printf("</property-descriptors>");
+            }
+            else printf("<property-descriptors/>");
+
+            EventSetDescriptor [] eventSetDescs = beanInfo.getEventSetDescriptors();
+            if (eventSetDescs != null && eventSetDescs.length != 0) {
+                printf("<event-set-descriptors default-index=%d>",
+                       beanInfo.getDefaultEventIndex());
+                indent();
+                for (int i = 0; i < eventSetDescs.length; i++)
+                    introspectEventSetDescriptor(eventSetDescs[i],
+                                                 i == beanInfo.getDefaultEventIndex());
+                unindent();
+                printf("</event-set-descriptors>");
+            }
+            else printf("<event-set-descriptors/>");
+
+            BeanInfo [] additionalBeanInfo = beanInfo.getAdditionalBeanInfo();
+            if (additionalBeanInfo != null && additionalBeanInfo.length != 0) {
+                printf("<additional-bean-info>");
+                indent();
+                {
+                    for (int i = 0; i < additionalBeanInfo.length; i++)
+                        introspectBeanInfo(additionalBeanInfo[i]);
+                }
+                unindent();
+                printf("</additional-bean-info>");
+            }
+            else printf("<additional-bean-info/>");
+        }
+        unindent();
+        printf("</bean-info>");
+    }
+
+    private void introspectBeanDescriptor(BeanDescriptor beanDesc) {
+        printf("<bean-descriptor name=\"%s\">", beanDesc.getDisplayName());
+        indent();
+        {
+            introspectFeatureDescriptor(beanDesc);
+            ;
+            printElement("bean-class", beanDesc.getBeanClass().getName());
+            Class customizerClass = beanDesc.getCustomizerClass();
+            if (customizerClass != null)
+                printElement("customizer-class", customizerClass.getName());
+        }
+        unindent();
+        printf("</bean-descriptor>");
+    }
+
+    private void introspectFeatureDescriptor(FeatureDescriptor featureDesc) {
+        printf("<feature-descriptor name=\"%s\"", featureDesc.getDisplayName());
+        indent();
+        {
+            printf("full-name=\"%s\"", featureDesc.getName());
+            printf("is-expert=%b", featureDesc.isExpert());
+            printf("is-hidden=%b", featureDesc.isHidden());
+            printf("is-preferred=%b>", featureDesc.isPreferred());
+
+            printElement("short-description", featureDesc.getShortDescription());
+
+            Enumeration<String> attrNames = featureDesc.attributeNames();
+            if (attrNames != null && attrNames.hasMoreElements()) {
+                SortedSet<String> sortedNames = new TreeSet<String>();
+                while (attrNames.hasMoreElements())
+                    sortedNames.add(attrNames.nextElement());
+                printf("<attributes>");
+                indent();
+                {
+                    for (String attrName : sortedNames) {
+                        // Convert the attribute value to a String, but drop any object ID
+                        // that is going to fail an equivalence comparison
+                        String attrValue = featureDesc.getValue(attrName).toString();
+                        int atIndex = attrValue.indexOf('@');
+                        if (atIndex > 0)
+                            attrValue = attrValue.substring(0, atIndex + 1);
+
+                        printf("<attribute name=\"%s\" value=\"%s\">",
+                               attrName, attrValue);
+                    }
+                }
+                unindent();
+                printf("</attributes>");
+            }
+        }
+        unindent();
+        printf("</feature-descriptor>", featureDesc.getDisplayName());
+    }
+
+    /**
+     * Provides a predictable ordering of method descriptors, based upon the underlying
+     * java.lang.reflect.Method attributes.  Uses the following tests:
+     * - compare method names.  If equal, then:
+     * - compare parameter list lengths.  If equals, then:
+     * - compare parameter type names, in order, until they are unequal
+     */
+    static private class MethodDescriptorComparator
+            implements Comparator<MethodDescriptor> {
+
+        public int compare(MethodDescriptor md1, MethodDescriptor md2) {
+            Method m1 = md1.getMethod();
+            Method m2 = md2.getMethod();
+            int retval = m1.getName().compareTo(m2.getName());
+            if (retval == 0) {
+                Class [] parms1 = m1.getParameterTypes();
+                Class [] parms2 = m1.getParameterTypes();
+                if (parms1.length < parms2.length)
+                    retval = -1;
+                else if (parms1.length > parms2.length)
+                    retval = 1;
+                else {
+                    for (int i = 0; i < parms1.length; i++) {
+                        retval = parms1[i].getName().compareTo(parms2[i].getName());
+                        if (retval != 0)
+                            break;
+                    }
+                }
+            }
+            return retval;
+        }
+
+        public boolean equals(Object o) {
+            return o != null && o instanceof MethodDescriptorComparator;
+        }
+    }
+
+    /**
+     * Sorts an input array of MethodDescriptors
+     */
+    private Set<MethodDescriptor> sortMethodDescriptors(MethodDescriptor [] methodDescs) {
+        Set<MethodDescriptor> sortedMethodDescs =
+                new TreeSet<MethodDescriptor>(new MethodDescriptorComparator());
+        for (int i = 0; i < methodDescs.length; i++)
+            sortedMethodDescs.add(methodDescs[i]);
+        return sortedMethodDescs;
+    }
+
+    private void introspectMethodDescriptors(MethodDescriptor [] methodDescs) {
+        Set<MethodDescriptor> sortedMethodDescs = sortMethodDescriptors(methodDescs);
+        for (MethodDescriptor methodDesc : sortedMethodDescs)
+            introspectMethodDescriptor(methodDesc);
+    }
+
+    private void introspectMethodDescriptor(MethodDescriptor methodDesc) {
+        printf("<method-descriptor name=\"%s\"", methodDesc.getDisplayName());
+        indent();
+        {
+            printElement("method", methodDesc.getMethod().toGenericString());
+            ParameterDescriptor [] paramDescs = methodDesc.getParameterDescriptors();
+            if (paramDescs != null && paramDescs.length != 0) {
+                printf("<parameter-descriptors>");
+                indent();
+                for (int i = 0; i < paramDescs.length; i++)
+                    introspectParameterDescriptor(paramDescs[i]);
+                unindent();
+                printf("</parameter-descriptors>");
+            }
+            else
+                printf("<param-descriptors/>");
+            introspectFeatureDescriptor(methodDesc);
+        }
+        unindent();
+        printf("</method-descriptor>");
+    }
+
+    private void introspectParameterDescriptor(ParameterDescriptor paramDesc) {
+        printf("<parameter-descriptor name=\"%s\">", paramDesc.getDisplayName());
+        indent();
+        introspectFeatureDescriptor(paramDesc);
+        unindent();
+        printf("</parameter-descriptor>", paramDesc.getDisplayName());
+    }
+
+    private void introspectPropertyDescriptor(PropertyDescriptor propDesc, boolean isDefault) {
+        printf("<property-descriptor name=\"%s\">", propDesc.getDisplayName());
+        indent();
+        {
+            printf("type=\"%s\"", propDesc.getPropertyType().getName());
+            printf("isBound=%b", propDesc.isBound());
+            printf("isConstrained=%b", propDesc.isConstrained());
+            printf("isDefault=%b>", isDefault);
+
+            Method readMethod = propDesc.getReadMethod();
+            if (readMethod != null)
+                printElement("read-method", readMethod.toGenericString());
+
+            Method writeMethod = propDesc.getWriteMethod();
+            if (writeMethod != null)
+                printElement("write-method", writeMethod.toGenericString());
+
+            Class propertyEditorClass = propDesc.getPropertyEditorClass();
+            if (propertyEditorClass != null)
+                printElement("property-editor-class", propertyEditorClass.getName());
+            introspectFeatureDescriptor(propDesc);
+        }
+        unindent();
+        printf("</property-descriptor>", propDesc.getDisplayName());
+    }
+
+    private void introspectEventSetDescriptor(EventSetDescriptor eventDesc, boolean isDefault) {
+        printf("<event-descriptor name=\"%s\"", eventDesc.getDisplayName());
+        indent();
+        {
+            printf("is-unicast=%b", eventDesc.isUnicast());
+            printf("is-in-default=%b", eventDesc.isInDefaultEventSet());
+            printf("is-default=%b>", isDefault);
+            printElement("listener-type", eventDesc.getListenerType().getName());
+
+            Method meth = eventDesc.getAddListenerMethod();
+            if (meth != null)
+                printElement("add-listener-method", meth.toGenericString());
+
+            meth = eventDesc.getRemoveListenerMethod();
+            if (meth != null)
+                printElement("remove-listener-method", meth.toGenericString());
+
+            meth = eventDesc.getGetListenerMethod();
+            if (meth != null)
+                printElement("get-listener-method", meth.toGenericString());
+
+            MethodDescriptor [] methodDescs = eventDesc.getListenerMethodDescriptors();
+            if (methodDescs != null && methodDescs.length != 0) {
+                printf("<listener-method-descriptors>");
+                indent();
+                introspectMethodDescriptors(methodDescs);
+                unindent();
+                printf("</listener-method-descriptors>");
+            }
+            else printf("<listener-method-descriptors/>");
+            introspectFeatureDescriptor(eventDesc);
+        }
+        unindent();
+    }
+
+    public static void main(String[] args)
+            throws Exception {
+
+        if (args.length < 1)
+            System.err.println("Usage: java org.apache.beehive.controls.test.controls.util.ControlIntrospector [-path <path>] beanClass");
+
+        String className = null;
+        String outputPath = null;
+        for (int i = 0; i < args.length; i++) {
+            if (args[i].equals("-outputPath")) {
+                if (i + 1 < args.length)
+                    outputPath = args[i + 1];
+                else throw new RuntimeException("Invalid command line; unable to find value for \"-outputPath\"");
+            }
+        }
+
+        className = args[args.length - 1];
+        System.out.println("Create .beaninfo for class \"" + className + "\"");
+        if (outputPath != null)
+            System.out.println("Write .beaninfo to file \"" + outputPath + "\"");
+
+        Class beanClass = Class.forName(className);
+        PrintStream ps = System.out;
+        try {
+            if (outputPath != null)
+                ps = new PrintStream(new FileOutputStream(new File(outputPath)));
+
+            ControlIntrospector ci = new ControlIntrospector(beanClass, ps);
+            ci.introspect();
+        }
+        finally {
+            if (ps != null && ps != System.out)
+                ps.close();
+        }
+    }
+}

Propchange: beehive/trunk/controls/test/src/junit-tests/org/apache/beehive/controls/test/junit/utils/ControlIntrospector.java
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: beehive/trunk/controls/test/src/units/org/apache/beehive/controls/test/java/composition/DeclarativeTest.java
URL: http://svn.apache.org/viewvc/beehive/trunk/controls/test/src/units/org/apache/beehive/controls/test/java/composition/DeclarativeTest.java?rev=419614&r1=419613&r2=419614&view=diff
==============================================================================
--- beehive/trunk/controls/test/src/units/org/apache/beehive/controls/test/java/composition/DeclarativeTest.java (original)
+++ beehive/trunk/controls/test/src/units/org/apache/beehive/controls/test/java/composition/DeclarativeTest.java Thu Jul  6 09:45:19 2006
@@ -41,7 +41,6 @@
  * Instantiating controls declaratively is not supported currently.
  * All tests are deactivated until this is supported
  */
-@Freq("checkin")
 public class DeclarativeTest
     extends ReportTestCase {