"use strict";

exports.__esModule = true;

var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();

function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }

/**
	Base class for property offline-first data. A single instance is registered with a {@link Store}
	and utilized by all properties supporting offline-first behavior.

	The `Store` does not enforcce instance to subclass this class and its purpose is meant to
	define the expected API.
*/

var OfflineDataStore = function () {
	function OfflineDataStore() {
		_classCallCheck(this, OfflineDataStore);
	}

	_createClass(OfflineDataStore, [{
		key: "clear",
		value: function clear() {
			throw new Error("Subclasses must implement clear()");
		}
	}, {
		key: "deleteBackups",
		value: function deleteBackups(storageKey, prop) {
			throw new Error("Subclasses must implement deleteBackups()");
		}
	}, {
		key: "getOfflineData",
		value: function getOfflineData(storageKey, dataKey, prop) {
			throw new Error("Subclasses must implement getOfflineData()");
		}
	}, {
		key: "setOfflineData",
		value: function setOfflineData(storageKey, dataKey, state, prop) {
			throw new Error("Subclasses must implement setOfflineData()");
		}
	}]);

	return OfflineDataStore;
}();

exports.default = OfflineDataStore;