Calculates all dates of the series.
@return all dates of the series in milliseconds.
762961
private SortedSet<Date> calculateDates() {

        if (null == m_allDates) {
            SortedSet<Date> result = new TreeSet<>();
            if (isAnyDatePossible()) {
                Calendar date = getFirstDate();
                int previousOccurrences = 0;
                while (showMoreEntries(date, previousOccurrences)) {
                    result.add(date.getTime());
                    toNextDate(date);
                    previousOccurrences++;
                }
            }
            m_allDates = result;
        }
        return m_allDates;
    }
1144485
private static Calendar toCalendar(Date self) {
        Calendar cal = Calendar.getInstance();
        cal.setTime(self);
        return cal;
    }
749545
public static Date plusMillis(Date date, int millis) {
		return plus(date, millis, DateTimeField.MILLIS);
	}
139639
public synchronized double getAverageMS()
    {
        double result = 0.0;

        for( Double d : m_times.m_values )
        {
            result += d;
        }

        return result / m_times.size();
    }
94744
public CmsJspDateSeriesBean getToDateSeries() {

        if (m_dateSeries == null) {
            m_dateSeries = new CmsJspDateSeriesBean(this, m_cms.getRequestContext().getLocale());
        }
        return m_dateSeries;
    }
43886
public Calendar calendarValue()
    {
        Calendar cal = new GregorianCalendar(_Private_Utils.UTC);

        long millis = getMillis();
        Integer offset = _offset;
        if (offset != null && offset != 0)
        {
            int offsetMillis = offset * 60 * 1000;
            millis += offsetMillis;
            cal.setTimeInMillis(millis);                // Resets the offset!
            cal.set(Calendar.ZONE_OFFSET, offsetMillis);
        }
        else
        {
            cal.setTimeInMillis(millis);
        }

        switch (_precision) {
            case YEAR:
                cal.clear(Calendar.MONTH);
            case MONTH:
                cal.clear(Calendar.DAY_OF_MONTH);
            case DAY:
                cal.clear(Calendar.HOUR_OF_DAY);
                cal.clear(Calendar.MINUTE);
            case MINUTE:
                cal.clear(Calendar.SECOND);
                cal.clear(Calendar.MILLISECOND);
            case SECOND:
                if (_fraction == null) {
                    cal.clear(Calendar.MILLISECOND);
                }
        }

        return cal;
    }
1154922
public ArrayList<String> getAllColumns() {
		ArrayList<String> columns = new ArrayList<String>();
		for (String col : columnLookup.keySet()) {
			columns.add(col);
		}
		return columns;
	}
964955
public static double todaysDate()
    {
        java.util.Date date = new java.util.Date();
        m_calendar.setTime(date);
        m_calendar.set(Calendar.HOUR_OF_DAY, 0);
        m_calendar.set(Calendar.MINUTE, 0);
        m_calendar.set(Calendar.SECOND, 0);
        m_calendar.set(Calendar.MILLISECOND, 0);
        date = m_calendar.getTime();
        return date.getTime(); // Convert to double
    }
978783
public Map<Long, Integer> computeDays(List<Long> sortedDates) {

        if (sortedDates.isEmpty()) {
            return Collections.<Long, Integer> emptyMap();
        }
        Map<Long, Integer> days = new HashMap<Long, Integer>();
        long lastDate = System.currentTimeMillis();
        int dayCounter = 0;
        for (Long dateObj : sortedDates) {
            long date = dateObj.longValue();
            long dayDifference = getDayDifference(lastDate, date);
            dayCounter += dayDifference;
            lastDate = date;
            days.put(dateObj, new Integer(dayCounter));
        }
        return days;
    }
1266370
public long minTimestamp()
  {
    return ranges == null
            ? topLevel.markedForDeleteAt
            : Math.min(topLevel.markedForDeleteAt, ranges.minMarkedAt());
  }
1136752
public NumberExpression<Integer> milliSecond() {
        if (milliseconds == null) {
            milliseconds = Expressions.numberOperation(Integer.class, Ops.DateTimeOps.MILLISECOND, mixin);
        }
        return milliseconds;
    }
606405
function() {
		var dates = [];
		for (var i = 0; i < this.events.length; i++) {
			if (this.events[i].end_date) {
				dates.push({ date: this.events[i].end_date });
			} else {
				dates.push({ date: this.events[i].start_date });
			}
		}
		for (var i = 0; i < this.eras.length; i++) {
			if (this.eras[i].end_date) {
				dates.push({ date: this.eras[i].end_date });
			} else {
				dates.push({ date: this.eras[i].start_date });
			}
		}
		TL.DateUtil.sortByDate(dates, 'date');
		return dates.slice(-1)[0].date;
	}
111342
public static Builder at (long millis)
    {
        Calendar calendar = Calendar.getInstance();
        calendar.setTimeInMillis(millis);
        return with(calendar);
    }
1114414
private static synchronized List<String> getAllTenderCurrencies() {
        List<String> all = (ALL_TENDER_CODES == null) ? null : ALL_TENDER_CODES.get();
        if (all == null) {
            // Filter out non-tender currencies which have "from" date set to 9999-12-31
            // CurrencyFilter has "to" value set to 9998-12-31 in order to exclude them
            //CurrencyFilter filter = CurrencyFilter.onDateRange(null, new Date(253373299200000L));
            CurrencyFilter filter = CurrencyFilter.all();
            all = Collections.unmodifiableList(getTenderCurrencies(filter));
            ALL_TENDER_CODES = new SoftReference<List<String>>(all);
        }
        return all;
    }
335811
public List<T> values() {
        List<T> result = new ArrayList<T>();
        for (Iterator<T> itr = iterator(); itr.hasNext(); ) {
            result.add(itr.next());
        }
        return result;
    }
788075
function(seriesCallback) {
                if(!obtainDates) {
                    seriesCallback();
                    return;
                }

                getDatesForPinsFromScraping(pinsThatNeedScrapedDates, null, function (pinDateMap) {
                    for (var i = 0; i < allPinsData.length; i++) {
                        if (allPinsData[i].created_at == null && pinDateMap[allPinsData[i].id] && pinDateMap[allPinsData[i].id].date) {
                            allPinsData[i].created_at = pinDateMap[allPinsData[i].id].date;
                            allPinsData[i].created_at_source = pinDateMap[allPinsData[i].id].source;
                        }
                    }
                    seriesCallback();
                    return;
                });
            }
38039
static double fromDate(Date dt) {

        // the number of milliseconds since January 1, 1970, 00:00:00 GMT
        long t = dt.getTime();

        // the number of milliseconds since January 1, 1970, 00:00:00 Local Time
        Calendar c = new GregorianCalendar();
        c.setTime(dt);
        t += (c.get(Calendar.ZONE_OFFSET) + c.get(Calendar.DST_OFFSET)) ;

        // the number of milliseconds since December 30, 1899, 00:00:00 Local Time
        t += 2209161600000L;

        // DATE is an offset from "30 December 1899"
        if (t < 0) {
            // -0.3 -> -0.7
            long offset = -(t % MSPD);    // TODO: check
            t = t - MSPD + offset;
        }
        double d = ((double) t) / MSPD;
        return d;
    }