Adds interval given in microseconds *
325649
public synchronized void addMicro(long micros) {
		total.addAndGet(micros);

		if (count.incrementAndGet() == 1) {
			min.set(micros);
			max.set(micros);
		} else {
			if (micros < min.get()) {
				min.set(micros);
			}
			if (micros > max.get()) {
				max.set(micros);
			}
		}
	}
742789
def min_values(args):
    
    return Interval(min(x.low for x in args), min(x.high for x in args))
1341524
public Interval expand(Interval<E> other)
  {
    if (other == null) return this;
    E a = min(this.first, other.first);
    E b = max(this.second, other.second);
    return toInterval(a,b);
  }
1326732
def eval_interval(interval):
    
    kwargs = {
        "years": 0,
        "months": 0,
        "weeks": 0,
        "days": 0,
        "hours": 0,
        "minutes": 0,
        "seconds": 0,
        "microseconds": 0,
    }
    for section in interval[1:]:
        name = section.getName()
        if name == "year":
            kwargs["years"] += int(section[0])
        elif name == "month":
            kwargs["months"] += int(section[0])
        elif name == "week":
            kwargs["weeks"] += int(section[0])
        elif name == "day":
            kwargs["days"] += int(section[0])
        elif name == "hour":
            kwargs["hours"] += int(section[0])
        elif name == "minute":
            kwargs["minutes"] += int(section[0])
        elif name == "second":
            kwargs["seconds"] += int(section[0])
        elif name == "millisecond":
            kwargs["microseconds"] += 1000 * int(section[0])
        elif name == "microsecond":
            kwargs["microseconds"] += int(section[0])
        else:
            raise SyntaxError("Unrecognized interval type %r: %s" % (name, section))
    return relativedelta(**kwargs)
1016844
def FromMicroseconds(self, micros):
    """"""
    self.seconds = micros // _MICROS_PER_SECOND
    self.nanos = (micros % _MICROS_PER_SECOND) * _NANOS_PER_MICROSECOND
1050260
def intervals(start, end, interval):
    
    interval = _seconds_or_timedelta(interval)
    current_timestamp = start
    while current_timestamp.epoch < end.epoch:
        yield current_timestamp

        current_timestamp = current_timestamp.add(
            seconds=interval.total_seconds()
        )
316348
public Interval withEndTime(LocalTime time) {
        requireNonNull(time);
        return new Interval(startDate, startTime, endDate, time, zoneId);
    }
897521
def add(
        self,
        years=0,
        months=0,
        weeks=0,
        days=0,
        hours=0,
        minutes=0,
        seconds=0,
        microseconds=0,
    ):  # type: (int, int, int, int, int, int, int) -> DateTime
        
        units_of_variable_length = any([years, months, weeks, days])

        current_dt = datetime.datetime(
            self.year,
            self.month,
            self.day,
            self.hour,
            self.minute,
            self.second,
            self.microsecond,
        )
        if not units_of_variable_length:
            offset = self.utcoffset()
            if offset:
                current_dt = current_dt - offset

        dt = add_duration(
            current_dt,
            years=years,
            months=months,
            weeks=weeks,
            days=days,
            hours=hours,
            minutes=minutes,
            seconds=seconds,
            microseconds=microseconds,
        )

        if units_of_variable_length or self.tzinfo is None:
            return pendulum.datetime(
                dt.year,
                dt.month,
                dt.day,
                dt.hour,
                dt.minute,
                dt.second,
                dt.microsecond,
                tz=self.tz,
            )

        dt = self.__class__(
            dt.year,
            dt.month,
            dt.day,
            dt.hour,
            dt.minute,
            dt.second,
            dt.microsecond,
            tzinfo=UTC,
        )

        dt = self.tz.convert(dt)

        return self.__class__(
            dt.year,
            dt.month,
            dt.day,
            dt.hour,
            dt.minute,
            dt.second,
            dt.microsecond,
            tzinfo=self.tz,
            fold=dt.fold,
        )
40227
function (value, min, max) {
            var interval;
            if (min > max) {
                max = min + max;
                min = max - min;
                max = max - min;
            }
            interval = max - min;
            return min + ((value % interval) + interval) % interval;
        }
188660
def copy(self):
        """"""
        return Interval(self._lower, self._lower_value, self._upper_value, self._upper)
913207
function(timeStamp) {
        var secondsPerStamp = 1.001,
            timesplit = timeStamp.split(':'),
            timestampSeconds = (parseInt(timesplit[0], 10) * 3600 +
                parseInt(timesplit[1], 10) * 60 +
                parseInt(timesplit[2], 10) +
                parseInt(timesplit[3], 10) / 30),
            seconds = timestampSeconds * secondsPerStamp,
            microSeconds = seconds * 1000 * 1000;
        return (microSeconds > 0) ? microSeconds : 0;
    }
728348
public static Date addMilliseconds(final Date date, final int addMilliseconds)
	{
		final Calendar dateOnCalendar = Calendar.getInstance();
		dateOnCalendar.setTime(date);
		dateOnCalendar.add(Calendar.MILLISECOND, addMilliseconds);
		return dateOnCalendar.getTime();
	}
445359
def __set_interval(self, value):
        '''
        
        '''
        if not isinstance(self, Interval):
            raise ValueError("'value' must be of type Interval")

        self.__interval = value
50347
function Interval(sourceString, startIdx, endIdx) {
  this.sourceString = sourceString;
  this.startIdx = startIdx;
  this.endIdx = endIdx;
}
733338
public boolean addInterval(Bounds i) {
		if(i.max < this.minimum || i.min > this.maximum) {
			return false;
		}
		bs.add(i);
		return true;
	}
187286
def min_interval(self,name, alpha=_alpha, **kwargs):
        
        data = self.get(name, **kwargs)
        return min_interval(data,alpha)
593323
def go_to(self, time):
        """"""
        half_dur = self.half_duration
        self.set_interval((time - half_dur, time + half_dur))