Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I need to take backup of calendar on my phone. We have requirement that we need to take backup of entire calendar data. Now, phone always supports recurring events. So, event may exist from 01-01-1601 to 31-12-3000. Logically, there is no point of taking backup from 01-01-1601 to 31-12-3000.

I just want to know your views on the ideal range for the same.

share|improve this question
add comment

4 Answers

up vote 0 down vote accepted

The ideal range is what the person/organisation that gave the requirement says anything else might be wrong.

If the requirement seems wrong/too complex then discuss it with the originator.

share|improve this answer
add comment

How do you think the phone stores the recurring appointments? Try to do the same. Mostly sure the recurring events are stored using three values: <start date, recurrence period, end date (optional)>.

For non-recurring events, just make a normal copy.

And to be really on-topic: store ALL the future events/appointments and, eventually, ask the user if anything from the past should be saved because some don't want at all, some want at most x months/weeks ago, some want everything.

share|improve this answer
    
+1 for storing EVERYTHING. Backup is backup, you shouldn't loose anything. Additionally making a user-controlled cleanup is a good idea. –  maaartinus Sep 9 '11 at 11:17
add comment

Can't you record the recurring event once and the period of recursion? For non-recurring events, you can record them all.

share|improve this answer
add comment

Ideal range == the maximum existing range. The backup will likely contain only existing events, so e.g. if you only have a single event in your calendar at 2011-09-09, it doesn't matter where the possible range begins and ends. As for recurring events - do you have your schedule booked all the way up to year 3000? That seems a bit...too optimistic, IMHO.

Logically, there's no point in having a "complete" backup which is not a complete backup, but only pretends to be.

BTW, it's such "cleverness" and cutting corners with dates ("naah, we'll never need that") which has brought us the famous Y2K.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.