tzwrapper.cc: fixed use of iterator after erase
[barry.git] / doc / bb_task_format.txt
blob21b17b6509794be5e33c4721eed579d0ddea3692
2 BlackBerry Task Database Record format.
4 This information is result of many btool -d Tasks dumps from a single BB 8700R.
5 firmware v4.1.0.351 (platform 2.0.0.143)
7 It would be interesting to receive btool -d Tasks dumps from other blackberries
8 to see if strings which appear constant, really are.
11 Task Header, fixed length, 0xe bytes long.
13 00000000: 09 00 43 00 40 03 44 02 01 00 53 32 2f 0a 01 01  ..C.@.D...S2/...
14           _____ _____ ??????????? _____ ??????????? __ __
15           rec   rec               task
16           type  len               index#
17                       u1                UniqueID?   u2
19 00000010: 00 01 74
20           ????????
23 rec type   - always 09 00  I guess this is a 'Task' Record type?
24 rec len    - length of this record in bytes, including header.
25 u1         - always 40 03 44 02  unknown...
26 task index - the record number within the data base.
27              determines posting order in the device (That is, if you
28              change sort order, the indices of tasks will be modified.
29              Similarly, if you change the priority or due date of a task
30              the ordinal might change as well.
31 UniqueID   - 32byte Integer, unique for each task.
32 u2         - boolean 00 or 01 , unknown.
33 end of header
35 01 00 01 74 - see type 1 field description.
38 Fields:
39 rest of a record is a series of fields, each with a 3 byte header:
41 Field Header
42         04 00             sz - size in bytes (2 bytes), excluding header.
43         09                field type (1 byte)
44         <value>           sz bytes, in the value format.
46 field types:
47 type         value       Meaning of field
48 value        format.
49 ------       ----------  ----------------------
50 11           string      Categories, comma separated.
51 10           4tz         timezone for deadlines, reminders etc...
52 0f           min1900_t   reminder by date (the minute when to remind.)
53 0e           4byte       relative reminder flag 2 = true?,
54                          this field is absent if reminder is not relative.
55 0a           4byte       priority  (0-high,1-normal,2-low)
56 09           4byte       status (0-not started, 1-in progress, 2-completed, 3-Waiting, 4-Defered)
57 08           4boolean    0-no due date, 1 there is a due date.
58 06           min1900_t   ???
59 05           min1900_t   due date
60 03           string      Note: (value of notes.)
61 02           string      Title (the name of the task.)
62 01           byte        always 0x74, unknown...
63                          (01 00 01 74) is always the first field of a task record.
64                          from http://off.net/cassis/protocol-description.html#h-1.3
65                          it looks used in other DB's in the same way.
66                           no idea of it's purpose.
68 formats:
70 string
71   -- null terminated string.
73 4tz:
74   -- 32-bit LSB integer, values documented in doc/TimeZones.txt.
75         ie.  0x23 is eastern time.
77 min1900_t:
78   -- signed 32-bit LSB integer offset in minutes. (before origin is -ve.)
79   -- origin is 0000 hours january 1st, 1900 in the prime meridian time zone GMT/UTC
80   -- Code to manipulate this type is present in the source code.
83 Recurrence:
84   -- Recurrence information does not appear to be stored in the Tasks DB.
85   -- Recurrence is systematically mis-spelled in the protocol description document
87 Order of fields... as observed in dump, do not know if it is significant, given fields
88 are so self-descriptive.
90 <header> <2-title> <9-status> <a-priority> <10-timezone> <6-??> <8-due_flag>
91    [ <5-due_date> ] [ [ <e-relative_reminder_flag> ] <f-reminder_date> ]
92    [ <11-categories> ] <3-Note>