Code Search for Developers
 
 
  

DailyStatisticMapRepository.java from Tea Stats at Krugle


Show DailyStatisticMapRepository.java syntax highlighted

package net.time4tea.webstats.statistic.repo;

import net.time4tea.webstats.jms.EnvironmentException;
import net.time4tea.webstats.statistic.StatisticMap;
import org.joda.time.Instant;

import java.util.Collection;

/**
 * Originally richja 20-Jun-2007
 */
public class DailyStatisticMapRepository implements StatisticMapRepository {
    private StatisticMapRepository statisticMapRepository;

    public DailyStatisticMapRepository(StatisticMapRepository statisticMapRepository) {
        this.statisticMapRepository = statisticMapRepository;
    }

    public StatisticMap getStatisticMapForInstant(String name, Instant instant) throws EnvironmentException {
        Instant instantToDay = instant.toDateTime().toDateMidnight().toInstant();
        return statisticMapRepository.getStatisticMapForInstant(name, instantToDay);

    }

    public Collection<StatisticMap> findAll() throws EnvironmentException {
        return statisticMapRepository.findAll();
    }

    public Collection<Instant> findPeriodsAvailableForNamedMap(String name) throws EnvironmentException {
        return statisticMapRepository.findPeriodsAvailableForNamedMap(name);
    }

    public void sync() throws EnvironmentException {
        statisticMapRepository.sync();
    }
}




See more files for this project here

Tea Stats

Web log analyzer... Written in OO Perl, provides the usual host / page analysis. Can also do site graphing using graphviz, browser, os, worm and search engine identification, and country and session tracking.

Project homepage: http://sourceforge.net/projects/teastats
Programming language(s): Java
License: other

  CachingStatisticMapRepository.java
  DailyStatisticMapRepository.java
  DiskBasedStatisticMapRepository.java
  MonthlyStatisticMapRepository.java
  SingleStatisticMapRepository.java
  StatisticMapRepository.java