Package javax.management.openmbean

Examples of javax.management.openmbean.CompositeDataInvocationHandler


  map.put("Birthday",cal.getTime());
  map.put("alive",true);
  CompositeData data = new CompositeDataSupport(type, map);
  Person p = (Person) Proxy.newProxyInstance(Person.class.getClassLoader(),
               new Class[] { Person.class },
               new CompositeDataInvocationHandler(data));
  h.checkPoint("Accessor tests");
  h.check(p.getName(), "Andrew");
  h.check(p.getBirthday(), cal.getTime());
  h.check(p.isAlive(), true);
  h.check(p.equals(p), "Reflection test");
  h.check(p.equals(p), "Consistency test");
  Person p2 = (Person) Proxy.newProxyInstance(Person.class.getClassLoader(),
               new Class[] { Person.class },
               new CompositeDataInvocationHandler(data));
  h.check(p.equals(p2), "Equality over creation test");
  h.check(p2.equals(p), "Symmetric test");
  Person p3 = (Person) Proxy.newProxyInstance(Person.class.getClassLoader(),
               new Class[] { Person.class },
               new CompositeDataInvocationHandler(data));
  h.check(p2.equals(p2), "Second equality over creation test");
  h.check(p.equals(p3), "Transitivity test");
  h.check(!p.equals(null), "Null test");
  h.check(p.hashCode(), p.hashCode(), "Hashcode reflection test");
  h.check(p.hashCode(), p.hashCode(), "Hashcode consistency test");
View Full Code Here


                                 OpenConverter[] converters) {
      final Class targetClass = getTargetClass();
      return
    Proxy.newProxyInstance(targetClass.getClassLoader(),
               new Class[] {targetClass},
               new CompositeDataInvocationHandler(cd));
  }
View Full Code Here

                                       MXBeanMapping[] converters) {
            final Class<?> targetClass = getTargetClass();
            return
                Proxy.newProxyInstance(targetClass.getClassLoader(),
                                       new Class<?>[] {targetClass},
                                       new CompositeDataInvocationHandler(cd));
        }
View Full Code Here

                                 OpenConverter[] converters) {
            final Class targetClass = getTargetClass();
            return
                Proxy.newProxyInstance(targetClass.getClassLoader(),
                                       new Class[] {targetClass},
                                       new CompositeDataInvocationHandler(cd));
        }
View Full Code Here

TOP

Related Classes of javax.management.openmbean.CompositeDataInvocationHandler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.