Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit da7a9383 authored by Ricki Hirner's avatar Ricki Hirner
Browse files

Clarify usage of SYNC_VERSION

parent 41b850cf
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -35,8 +35,10 @@ import java.util.*
import java.util.logging.Level

/**
 * Extend this class for your local implementation of the
 * event that's stored in the Android Calendar Provider.
 * Stores and retrieves VEVENT iCalendar objects (represented as [Event]s) to/from the
 * Android Calendar provider.
 *
 * Extend this class to process specific fields of the event.
 *
 * Important: To use recurrence exceptions, you MUST set _SYNC_ID and ORIGINAL_SYNC_ID
 * in populateEvent() / buildEvent. Setting _ID and ORIGINAL_ID is not sufficient.
+11 −1
Original line number Diff line number Diff line
@@ -26,6 +26,16 @@ import java.net.URISyntaxException
import java.util.*
import java.util.logging.Level

/**
 * Stores and retrieves VTODO iCalendar objects (represented as [Task]s) to/from the
 * OpenTasks provider.
 *
 * Extend this class to process specific fields of the task.
 *
 * The SEQUENCE field is stored in [Tasks.SYNC_VERSION], so don't use [Tasks.SYNC_VERSION]
 * for anything else.
 *
 */
abstract class AndroidTask(
        val taskList: AndroidTaskList<AndroidTask>
) {
@@ -64,7 +74,7 @@ abstract class AndroidTask(
                    return task
                }
            }
            throw FileNotFoundException("Couldn't find task #" + id)
            throw FileNotFoundException("Couldn't find task #$id")
        }

    protected open fun populateTask(values: ContentValues) {