This function removes all items from the store.
If there are no items in the store in the first place, that is still counted as a success.
clear( successCallback, errorCallback )
Name | Type | Description |
successCallback | sap.EncryptedStorage~successCallback | If successful, the successCallback is invoked with no parameters. |
errorCallback | sap.EncryptedStorage~errorCallback | If there is an error, the errorCallback is invoked with an ErrorInfo object as the parameter. |
var store = new sap.EncryptedStorage("storeName", "storePassword"); var successCallback = function() { alert("Store cleared!"); } var errorCallback = function(error) { alert("An error occurred: " + JSON.stringify(); } store.clear(successCallback, errorCallback);