code: public final int getOffset(final int era, final int year, final int month, final int dayOfMonth,
                                 final int dayOfWeek, final int milliseconds) {
  
          // calculate time of day
          int ms = milliseconds;
          final int hour = ms / 3600000;
          ms -= hour * 3600000;
          final int minute = ms / 60000;
          ms -= minute * 60000;
          final int second = ms / 1000;
          ms -= second * 1000;
  
          final Calendar cal = Calendar.getInstance();
          cal.clear();    // don't retain current date/time, it may disturb the calculation
  
          // set date and time
          cal.set(Calendar.ERA, era);
          cal.set(Calendar.DAY_OF_WEEK, dayOfWeek);
          cal.set(year, month, dayOfMonth, hour, minute, second);
          cal.set(Calendar.MILLISECOND, ms);
  
          final Observance observance = vTimeZone.getApplicableObservance(new DateTime(cal.getTime()));
          if (observance != null) {
              final TzOffsetTo offset = observance.getProperty(Property.TZOFFSETTO);
              return (int) (offset.getOffset().getTotalSeconds() * 1000L);
          }
          return 0;
      }
docs: {@inheritDoc}