code: public static Object convert(Object fromInstance, Class toType)
      {
          if (toType == null)
          {
              throw new IllegalArgumentException("Type cannot be null in Converter.convert(value, type)");
          }
  
          Work work = conversion.get(toType);
          if (work != null)
          {
              return work.convert(fromInstance);
          }
          throw new IllegalArgumentException("Unsupported type '" + toType.getName() + "' for conversion");
      }
docs: Turn the passed in value to the class indicated.  This will allow, for
  example, a String value to be passed in and have it coerced to a Long.
  <pre>
  Examples:
  Long x = convert("35", Long.class);
  Date d = convert("2015/01/01", Date.class)
  int y = convert(45.0, int.class)
  String date = convert(date, String.class)
  String date = convert(calendar, String.class)
  Short t = convert(true, short.class);     // returns (short) 1 or  (short) 0
  Long date = convert(calendar, long.class); // get calendar's time into long
  </pre>
  @param fromInstance A value used to create the targetType, even though it may
  not (most likely will not) be the same data type as the targetType
  @param toType Class which indicates the targeted (final) data type.
  Please note that in addition to the 8 Java primitives, the targeted class
  can also be Date.class, String.class, BigInteger.class, and BigDecimal.class.
  The primitive class can be either primitive class or primitive wrapper class,
  however, the returned value will always [obviously] be a primitive wrapper.
  @return An instanceof targetType class, based upon the value passed in.