code: public static Class<?> arrayElementType(Class<?> arrType) {
          if ( null == arrType )
              return null;
          while ( arrType.isArray() )
              arrType = arrType.getComponentType();
          return arrType;
      }
docs: Find array element type for class.
  Roll back component type until class is not an array anymore.
  @param arrType the class to inspect
  @return null if type is null or the class when class not array