src/main/java/org/mvel2/optimizers/impl/asm/ASMAccessorOptimizer.java
public static int toPrimitiveTypeOperand(Class<?> c) {
      if (c == int.class) return Opcodes.T_INT;
      if (c == long.class) return Opcodes.T_LONG;
      if (c == double.class) return Opcodes.T_DOUBLE;
      if (c == float.class) return Opcodes.T_FLOAT;
      if (c == short.class) return Opcodes.T_SHORT;
      if (c == byte.class) return Opcodes.T_BYTE;
      if (c == char.class) return Opcodes.T_CHAR;
      if (c == boolean.class) return Opcodes.T_BOOLEAN;
      throw new IllegalStateException("Non-primitive type passed to toPrimitiveTypeOperand: " + c);
   }
/**
   * Gets the ASM instruction operand for the given primitive type.
   * Will throw IllegalStateException if the type is not primitive.
   * @param c The class representing the primitive type. 
   * @return The operand
   */
Gets the ASM instruction operand for the given primitive type.
Will throw IllegalStateException if the type is not primitive.
@param c The class representing the primitive type.
@return The operand
Gets the ASM instruction operand for the given primitive type . Will throw IllegalStateException if the type is not primitive . @param c The class representing the primitive type . @return The operand
public static int toPrimitiveTypeOperand(Class<?> c) {
      if (c == int.class) return Opcodes.T_INT;
      if (c == long.class) return Opcodes.T_LONG;
      if (c == double.class) return Opcodes.T_DOUBLE;
      if (c == float.class) return Opcodes.T_FLOAT;
      if (c == short.class) return Opcodes.T_SHORT;
      if (c == byte.class) return Opcodes.T_BYTE;
      if (c == char.class) return Opcodes.T_CHAR;
      if (c == boolean.class) return Opcodes.T_BOOLEAN;
      throw new IllegalStateException("Non-primitive type passed to toPrimitiveTypeOperand: " + c);
   }
public static int toPrimitiveTypeOperand ( Class < ? > c ) { if ( c == int . class ) return Opcodes . T_INT ; if ( c == long . class ) return Opcodes . T_LONG ; if ( c == double . class ) return Opcodes . T_DOUBLE ; if ( c == float . class ) return Opcodes . T_FLOAT ; if ( c == short . class ) return Opcodes . T_SHORT ; if ( c == byte . class ) return Opcodes . T_BYTE ; if ( c == char . class ) return Opcodes . T_CHAR ; if ( c == boolean . class ) return Opcodes . T_BOOLEAN ; throw new IllegalStateException ( "Non-primitive type passed to toPrimitiveTypeOperand: " + c ) ; }
Gets the ASM instruction operand for the given primitive type.
Gets the ASM instruction operand for the given primitive type .