code: public static TimeZone resolveTimeZone(Object timeZone) {
          if (timeZone instanceof String) {
              return TimeZone.getTimeZone((String) timeZone);
          }
          else if (timeZone instanceof TimeZone) {
              return (TimeZone) timeZone;
          }
          else {
              return TimeZone.getDefault();
          }
      }
docs: Gets a {@link TimeZone} instance by the parameter "timeZone" which can be String or {@link TimeZone} or null.
  
  @param timeZone given time zone
  @return resolved TimeZone