public void addPeriod(String from, String to) {
    Period p = new Period();
    if (from != null) {
      p.setFrom(from);
    } else {
      p.setFrom(AdDBConstants.ADDB_BANNER_DATE_ALL);
    }

    if (to != null) {
      p.setTo(to);
    } else {
      p.setTo(AdDBConstants.ADDB_BANNER_DATE_ALL);
    }

    periods.add(p);
  }
 static {
   ALL_TIMES.setFrom(AdDBConstants.ADDB_BANNER_DATE_ALL);
   ALL_TIMES.setTo(AdDBConstants.ADDB_BANNER_DATE_ALL);
 }