9 * @author Christian Weiske <cweiske@cweiske.de>
10 * @copyright 2014 Christian Weiske
11 * @license http://www.gnu.org/licenses/agpl.html GNU AGPL v3
12 * @link http://cweiske.de/grauphel.htm
14 namespace OCA\Grauphel\Lib;
17 * Synchronization data model
21 * @author Christian Weiske <cweiske@cweiske.de>
22 * @copyright 2014 Christian Weiske
23 * @license http://www.gnu.org/licenses/agpl.html GNU AGPL v3
24 * @version Release: @package_version@
25 * @link http://cweiske.de/grauphel.htm
30 * The latest sync revision from Tomboy, given from last PUT
31 * of a note from Tomboy.
32 * Give a -1 here if you have not synced with Tomboy yet.,
36 public $latestSyncRevision;
39 * A uuid generated by the sync application.
40 * It should change only if the user decides to clear their
41 * sync history from the server and start over
42 * with an empty note set.
46 public $currentSyncGuid;
49 * Initialize the variables to represent the data of a user
52 * @param string $username Name of user
56 public function initNew($username)
58 $this->latestSyncRevision = -1;
59 $this->currentSyncGuid = uniqid($username . '-', true);