Returns the standard time timezone offset regardless of whether the current time is on standard or daylight saving time.

@param node
@param nodeType
@param feedType
331864
function getStandardTimeOffset(date) {
  var jan = new Date(date.getFullYear(), 0, 1);
  var jul = new Date(date.getFullYear(), 6, 1);
  return Math.max(jan.getTimezoneOffset(), jul.getTimezoneOffset());
}
225971
def timezone(self, value):
        """"""
        self._timezone = (value if isinstance(value, datetime.tzinfo)
                          else tz.gettz(value))
1258374
public static OffsetDateTime toOffsetDateTime(final Calendar self) {
        return OffsetDateTime.of(toLocalDateTime(self), getZoneOffset(self));
    }
394657
public static SimpleDateFormat getDateFormat(TimeType timeType) {
        if (timeType == null) {
            timeType = TimeType.DEFAULT;
        }
        SimpleDateFormat sdf = simpleDateFormatMap.get(timeType);
        if (sdf == null) {
            sdf = new SimpleDateFormat(timeType.getType());
            simpleDateFormatMap.put(timeType, sdf);
        }
        return sdf;
    }
121805
public static OffsetTime toOffsetTime(final Calendar self) {
        return OffsetTime.of(toLocalTime(self), getZoneOffset(self));
    }
1355130
@Override
    @SuppressWarnings("unchecked")
    public ChronoZonedDateTime<InternationalFixedDate> zonedDateTime(TemporalAccessor temporal) {
        return (ChronoZonedDateTime<InternationalFixedDate>) super.zonedDateTime(temporal);
    }
184653
def cst_now():
    
    try:
        ret = datetime.utcnow() + timedelta(hours=DEFAULT_TIMEZONE)
        if DEFAULT_TIMEZONE_AWARE:
            ret = ret.replace(
                tzinfo=psycopg2.tz.FixedOffsetTimezone(
                    name=None, offset=DEFAULT_TIMEZONE * 60))
        return ret
    except Exception as ex:
        return datetime.utcnow() + timedelta(hours=DEFAULT_TIMEZONE)
1019640
public static DateTime toDate(Object o, boolean alsoNumbers, TimeZone tz) throws PageException {
	return DateCaster.toDateAdvanced(o, alsoNumbers ? DateCaster.CONVERTING_TYPE_OFFSET : DateCaster.CONVERTING_TYPE_NONE, tz);
    }
529564
function offset(date) {
        // Difference to Greenwich time (GMT) in hours
        var os = Math.abs(date.getTimezoneOffset());
        var h = String(Math.floor(os/60));
        var m = String(os%60);
        h.length === 1? h = '0'+h:1;
        m.length === 1? m = '0'+m:1;
        return date.getTimezoneOffset() < 0 ? '+'+h+m : '-'+h+m;
    }
541761
@Override
  public ZonedDateTime read(JsonReader reader) throws IOException {
    if (reader.peek() == JsonToken.NULL) {
      reader.nextNull();
      return null;
    }

    String timeZoneId = "";
    long secondsSinceEpoch = 0L;

    reader.beginObject();
    while (reader.hasNext()) {
      String name = reader.nextName();
      if (name.equals("text")) {
        // Ignore the human-readable rendering.
        reader.nextString();
      } else if (name.equals("time_zone")) {
        timeZoneId = reader.nextString();
      } else if (name.equals("value")) {
        secondsSinceEpoch = reader.nextLong();
      }
    }
    reader.endObject();

    return ZonedDateTime.ofInstant(
        Instant.ofEpochMilli(secondsSinceEpoch * 1000), ZoneId.of(timeZoneId));
  }
1010329
static synchronized TimeZone getDefaultRef() {
        if (defaultTimeZone == null) {
            defaultTimeZone = NativeTimeZone.getDefaultNativeTimeZone();
        }

        if (defaultTimeZone == null) {
            defaultTimeZone = GMTHolder.INSTANCE;
        }

        return defaultTimeZone;
    }
1374319
public final void setTimeZone(final TimeZone timeZone) {
        if (!Value.DATE.equals(type)) {
            for (Date date: this) {
                ((DateTime) date).setTimeZone(timeZone);
            }
        }
        this.timeZone = timeZone;
        this.utc = false;
    }
1372283
public static long getTimeSpan(Date begin, Date end, int type) {
        long diff = end.getTime() - begin.getTime();
        switch (type) {
            case DAY:
            default:
                return diff / org.apache.commons.lang.time.DateUtils.MILLIS_PER_DAY;
            case HOUR:
                return diff / org.apache.commons.lang.time.DateUtils.MILLIS_PER_HOUR;
            case MINUTE:
                return diff / org.apache.commons.lang.time.DateUtils.MILLIS_PER_MINUTE;
            case SECOND:
                return diff / org.apache.commons.lang.time.DateUtils.MILLIS_PER_SECOND;
        }
    }
492826
function vtimezone( $timezonetype=FALSE ) {
    if( !$timezonetype )
      $this->timezonetype = 'VTIMEZONE';
    else
      $this->timezonetype = strtoupper( $timezonetype );
    $this->calendarComponent();
  }
367516
public void setNodeType(int nodeType) {
        if (nodeType != Token.COLON
            && nodeType != Token.GET
            && nodeType != Token.SET
            && nodeType != Token.METHOD)
            throw new IllegalArgumentException("invalid node type: "
                                               + nodeType);
        setType(nodeType);
    }
744955
def dst(self, dt):
        
        if self.__is_daylight_time(dt):
            return self.__dst_offset - self.__offset
        else:
            return datetime.timedelta(0)
163966
def set_time_offset(self, offset, is_utc):
        """"""

        is_utc = bool(is_utc)
        self.clock_manager.time_offset = offset
        self.clock_manager.is_utc = is_utc

        return [Error.NO_ERROR]