Class BeanUtility


  • public final class BeanUtility
    extends java.lang.Object
    The BeanUtility class enables access to bean properties using the reflection API.
    Author:
    Thomas Morgner
    • Constructor Detail

      • BeanUtility

        public BeanUtility​(java.lang.Object o)
                    throws java.beans.IntrospectionException
        Throws:
        java.beans.IntrospectionException
    • Method Detail

      • derive

        public BeanUtility derive​(java.lang.Object o)
      • getPropertyInfos

        public java.beans.PropertyDescriptor[] getPropertyInfos()
      • getPropertyAsString

        public java.lang.String getPropertyAsString​(java.lang.String name)
                                             throws BeanException
        Throws:
        BeanException
      • setProperty

        public void setProperty​(java.lang.String name,
                                java.lang.Object o)
                         throws BeanException
        Throws:
        BeanException
      • setPropertyAsString

        public void setPropertyAsString​(java.lang.String name,
                                        java.lang.String txt)
                                 throws BeanException
        Throws:
        BeanException
      • getPropertyType

        public static java.lang.Class getPropertyType​(java.beans.PropertyDescriptor pd)
                                               throws BeanException
        Throws:
        BeanException
      • setPropertyAsString

        public void setPropertyAsString​(java.lang.String name,
                                        java.lang.Class type,
                                        java.lang.String txt)
                                 throws BeanException
        Throws:
        BeanException