com.abstractics.xmlpanel.swing.componentcreator
Class ComponentCreatorUtils

java.lang.Object
  extended bycom.abstractics.xmlpanel.swing.componentcreator.ComponentCreatorUtils

public class ComponentCreatorUtils
extends java.lang.Object

This utility class contains static methods for handling common needs in configuring a Component with the XML that was provided.

Version:
$Id: ComponentCreatorUtils.java,v 1.2 2006/03/15 05:37:40 andyman99 Exp $
Author:
Andrew Lawrence, Copyright 2006 Abstractics, L.L.C., Licensed under the Apache License, Version 2.0

Method Summary
static void applyPropertiesViaReflection(java.awt.Component component, org.w3c.dom.Element element)
          Sets all the properties on the provided component by interrogating the element for attributes, and then using reflection and the StringToObject converters to set the properties on the Component.

If there is a textdata child element, and there is a setText method on the component, then that method will be called as well.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

applyPropertiesViaReflection

public static void applyPropertiesViaReflection(java.awt.Component component,
                                                org.w3c.dom.Element element)
Sets all the properties on the provided component by interrogating the element for attributes, and then using reflection and the StringToObject converters to set the properties on the Component.

If there is a textdata child element, and there is a setText method on the component, then that method will be called as well.

See Also:
com.abstractics.xmlpanel.utils.stringtoobject.StringToObject, com.abstractics.xmlpanel.swing.componentcreator.ComponentCreator#setComponentProperties(java.awt.Component, org.w3c.dom.Element)