Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-4880

Unchecked warnings in JMXManagementService and VTI demos

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 10.7.1.1
    • 10.7.1.1
    • Demos/Scripts, JMX
    • None

    Description

      These warnings I only see if java15compile.classpath points to Java 6 class libraries (either set explicitly in ant.properties, or implicitly by the property setter):

      [javac] /code/derby/trunk2/java/engine/org/apache/derby/impl/services/jmx/JMXManagementService.java:215: warning: [unchecked] unchecked conversion
      [javac] found : java.lang.Class
      [javac] required: java.lang.Class<java.lang.Object>
      [javac] new StandardMBean(bean, beanInterface) {
      [javac] ^
      [javac] /code/derby/trunk2/java/engine/org/apache/derby/impl/services/jmx/JMXManagementService.java:215: warning: [unchecked] unchecked method invocation: <T>StandardMBean(T,java.lang.Class<T>) in javax.management.StandardMBean is applied to (java.lang.Object,java.lang.Class)
      [javac] new StandardMBean(bean, beanInterface) {
      [javac] ^
      [javac] 2 warnings
      [javac] /code/derby/trunk2/java/demo/vtis/java/org/apache/derbyDemo/vtis/core/QueryVTIHelper.java:185: warning: [unchecked] unchecked call to getMethod(java.lang.String,java.lang.Class<?>...) as a member of the raw type java.lang.Class
      [javac] ( methodName, new Class[]

      { String.class } );
      [javac] ^
      [javac] /code/derby/trunk2/java/demo/vtis/java/org/apache/derbyDemo/vtis/core/XmlVTI.java:253: warning: [unchecked] unchecked call to getMethod(java.lang.String,java.lang.Class<?>...) as a member of the raw type java.lang.Class
      [javac] ( methodName, new Class[] { String.class }

      );
      [javac] ^
      [javac] /code/derby/trunk2/java/demo/vtis/java/org/apache/derbyDemo/vtis/core/XmlVTI.java:260: warning: [unchecked] unchecked call to getConstructor(java.lang.Class<?>...) as a member of the raw type java.lang.Class
      [javac] ( new Class[]

      { String.class, String.class, String[].class }

      );
      [javac] ^
      [javac] /code/derby/trunk2/java/demo/vtis/java/org/apache/derbyDemo/vtis/snapshot/Subscription.java:278: warning: [unchecked] unchecked call to getMethod(java.lang.String,java.lang.Class<?>...) as a member of the raw type java.lang.Class
      [javac] ( methodName, new Class[] {} );
      [javac] ^
      [javac] 4 warnings

      Attachments

        1. deprecated.diff
          4 kB
          Knut Anders Hatlen

        Activity

          People

            knutanders Knut Anders Hatlen
            knutanders Knut Anders Hatlen
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: