Package javax.management

Examples of javax.management.MBeanConstructorInfo


   }

   public void testValidMBeanStarInfoInvalidName2() throws Exception
   {
      new MBeanAttributeInfo(".123", "java.lang.String", "description", true, false, false);
      new MBeanConstructorInfo(".123", "description", null);
      new MBeanOperationInfo(".123", "description", null, "java.lang.String", MBeanOperationInfo.UNKNOWN);
      new MBeanParameterInfo(".123", "java.lang.String", "description");
   }
View Full Code Here


   }

   public void testValidMBeanStarInfoInvalidName3() throws Exception
   {
      new MBeanAttributeInfo(" identifier", "java.lang.String", "description", true, false, false);
      new MBeanConstructorInfo(" identifier", "description", null);
      new MBeanOperationInfo(" identifier", "description", null, "java.lang.String", MBeanOperationInfo.UNKNOWN);
      new MBeanParameterInfo(" identifier", "java.lang.String", "description");
   }
View Full Code Here

   }

   public void testValidMBeanStarInfo1() throws Exception
   {
      new MBeanAttributeInfo("name", "type", "description", true, false, false);
      new MBeanConstructorInfo("name", "description", null);
      new MBeanNotificationInfo(new String[0], "type", "description");
      new MBeanOperationInfo("name", "description", null, "type", MBeanOperationInfo.UNKNOWN);
      new MBeanParameterInfo("name", "type", "description");
   }
View Full Code Here

   }

   public void testValidMBeanStarInfo2() throws Exception
   {
      new MBeanAttributeInfo("_", int.class.getName(), "description", true, false, false);
      new MBeanConstructorInfo("_", "description", null);
      new MBeanNotificationInfo(new String[0], "java.lang.String", "description");
      new MBeanOperationInfo("_", "description", null, int[].class.getName(), MBeanOperationInfo.UNKNOWN);
      new MBeanParameterInfo("_", int[][].class.getName(), "description");
   }
View Full Code Here

   }

   public void testValidMBeanStarInfo3() throws Exception
   {
      new MBeanAttributeInfo("a", String.class.getName(), "description", true, false, false);
      new MBeanConstructorInfo("a", "description", null);
      new MBeanNotificationInfo(new String[0], "java.lang.String", "description");
      new MBeanOperationInfo("a", "description", null, String[].class.getName(), MBeanOperationInfo.UNKNOWN);
      new MBeanParameterInfo("a", String[][].class.getName(), "description");
   }
View Full Code Here

   }

   public void testValidMBeanStarInfo4() throws Exception
   {
      new MBeanAttributeInfo("a", Map.Entry.class.getName(), "description", true, false, false);
      new MBeanConstructorInfo("a", "description", null);
      new MBeanNotificationInfo(new String[0], "java.lang.String", "description");
      new MBeanOperationInfo("a", "description", null, Map.Entry[].class.getName(), MBeanOperationInfo.UNKNOWN);
      new MBeanParameterInfo("a", Map.Entry[][].class.getName(), "description");
   }
View Full Code Here

      attrs[1] = new MBeanAttributeInfo("DynamicAttribute2", "java.lang.String", "A second dynamic attribute", true, true, false);


      MBeanConstructorInfo[] ctors = new MBeanConstructorInfo[1];

      ctors[0] = new MBeanConstructorInfo("Parameterless Constructor", "A dynamic constructor", new MBeanParameterInfo[0]);


      MBeanOperationInfo[] opers = new MBeanOperationInfo[1];

      MBeanParameterInfo[] params = new MBeanParameterInfo[1];
View Full Code Here

      MBeanAttributeInfo[] attrs = new MBeanAttributeInfo[2];
      attrs[0] = new MBeanAttributeInfo("DynamicAttribute1", "java.lang.String", "A first dynamic attribute", true, true, false);
      attrs[1] = new MBeanAttributeInfo("DynamicAttribute2", "java.lang.String", "A second dynamic attribute", true, true, false);

      MBeanConstructorInfo[] ctors = new MBeanConstructorInfo[1];
      ctors[0] = new MBeanConstructorInfo("ParameterlessConstructor", "A dynamic constructor", new MBeanParameterInfo[0]);

      MBeanOperationInfo[] opers = new MBeanOperationInfo[1];
      MBeanParameterInfo[] params = new MBeanParameterInfo[1];
      params[0] = new MBeanParameterInfo("supposedAttributeValue", "java.lang.String", "Checks if the value of the argument is equal to the value of the attribute");
      opers[0] = new MBeanOperationInfo("dynamicOperation", "A dynamic operation", params, "boolean", MBeanOperationInfo.INFO);
View Full Code Here

         }
      }
      if (model.getConstructors() != null)
      {
         // cannot assume they are already ModelMBeanConstructorInfo
         MBeanConstructorInfo constructors[] = model.getConstructors();
         modelMBeanConstructors = new ModelMBeanConstructorInfo[constructors.length];
         for (int i = 0; i < constructors.length; i++)
         {
            MBeanConstructorInfo constructor = constructors[i];
            if (constructor instanceof ModelMBeanConstructorInfo)
               modelMBeanConstructors[i] = new ModelMBeanConstructorInfo((ModelMBeanConstructorInfo)constructor);
            else
               modelMBeanConstructors[i] = new ModelMBeanConstructorInfo(constructor.getName(), constructor.getDescription(), constructor.getSignature());
         }
      }
      if (model.getOperations() != null)
      {
         // cannot assume they are already ModelMBeanOperationInfo
View Full Code Here

   public void compareMBeanConstructorInfo(Object o1, Object o2)
   {
      compareMBeanFeatureInfo(o1, o2);

      MBeanConstructorInfo c1 = (MBeanConstructorInfo)o1;
      MBeanConstructorInfo c2 = (MBeanConstructorInfo)o2;

      MBeanParameterInfo[] p1 = c1.getSignature();
      MBeanParameterInfo[] p2 = c2.getSignature();

      if (p1.length != p2.length) throw new RuntimeException();
      for (int i = 0; i < p1.length; ++i)
      {
         compareMBeanParameterInfo(p1[i], p2[i]);
View Full Code Here

TOP

Related Classes of javax.management.MBeanConstructorInfo

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.