4 Replies Latest reply on Mar 14, 2006 6:05 AM by bkeh12

    JavassistReflectionFactory wondering

    bkeh12

      Hi,

       protected void unbox(JBossStringBuilder buffer, CtClass primitive)
       {
       if (CtClass.booleanType.equals(primitive))
       buffer.append(".booleanValue()");
       else if (CtClass.byteType.equals(primitive))
       buffer.append(".byteValue()");
       else if (CtClass.charType.equals(primitive))
       buffer.append(".charValue()");
       else if (CtClass.doubleType.equals(primitive))
       buffer.append(".doubleValue()");
       else if (CtClass.floatType.equals(primitive))
       buffer.append(".floatValue()");
       else if (CtClass.intType.equals(primitive))
       buffer.append(".intValue()");
       else if (CtClass.longType.equals(primitive))
       buffer.append(".longValue()");
       else if (CtClass.shortType.equals(primitive))
       buffer.append(".shortValue()");
       throw new UnreachableStatementException();
       }
      


      Is correct ?
      Can update as below ?
      else { throw new UnreachableStatementException();};