'Deletes all stats in the given time range.'

def DeleteStats(self, timestamp=ALL_TIMESTAMPS, sync=False):

    if (timestamp == self.NEWEST_TIMESTAMP):
        raise ValueError("Can't    use    NEWEST_TIMESTAMP    in    DeleteStats.")
    predicates = []
    for key in stats.STATS.GetAllMetricsMetadata().keys():
        predicates.append((self.STATS_STORE_PREFIX + key))
    start = None
    end = None
    if (timestamp and (timestamp != self.ALL_TIMESTAMPS)):
        (start, end) = timestamp
    data_store.DB.DeleteAttributes(self.urn, predicates, start=start, end=end, token=self.token, sync=sync)
