From 4aa56320d255fc955ad0bc6a83658bdbe55def71 Mon Sep 17 00:00:00 2001 From: Pritesh Nandgaonkar Date: Sun, 12 Feb 2017 20:11:03 +0530 Subject: [PATCH] updated readme --- README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index d499b66..7cb457e 100644 --- a/README.md +++ b/README.md @@ -70,10 +70,16 @@ This `KVStoreManager` has the following API's which eases the storage and fetchi func insert(value: Data, for key: T) throws func deleteValue(for key: T) throws func update(value: Data, for key: T) throws -func getValue(for key: T) throws -> Data +func getValue(for key: T) -> Data? ``` +You can also access the value through subscript syntax, like as follows + +``` swift +let data = storeManager[key] +``` + The method definitions are self explanatory as to what they perform. The important point is that the `key` which is passed as argument should be of type `Hashable` and the value would be stored as `Data` You can checkout the example in the framework and play around with it. To get used to this library. \ No newline at end of file