added cacheadapter interface and memorycache of notification.
[platform/upstream/iotivity.git] / service / notification / src / provider / cache / linux / NSProviderMemoryCache.h
old mode 100644 (file)
new mode 100755 (executable)
similarity index 68%
rename from service/notification/src/provider/NSProviderCacheAdapter.h
rename to service/notification/src/provider/cache/linux/NSProviderMemoryCache.h
index 32b2c21..4e96aff
 #ifndef _NS_PROVIDER_CACHEADAPTER__H_\r
 #define _NS_PROVIDER_CACHEADAPTER__H_\r
 \r
-#include "logger.h"\r
+#include <stdbool.h>\r
 #include <octypes.h>\r
+#include <pthread.h>\r
+#include "logger.h"\r
 #include "ocstack.h"\r
 #include "ocpayload.h"\r
 #include "NSStructs.h"\r
 #include "NSConstants.h"\r
+#include "NSCacheAdapter.h"\r
+\r
+NSResult NSProviderDeleteCacheData(NSCacheType, void *);\r
 \r
-typedef struct _messageData\r
-{\r
-    NSMessage * msg;\r
-    uint8_t state;\r
-    uint8_t size;\r
-}NSMessageData;\r
+bool NSProviderCompareIdCacheData(NSCacheType, void *, char *);\r
 \r
-typedef struct _observerList\r
-{\r
-    OCObservationId idList[100];\r
-    uint8_t size;\r
-}NSWhiteList, NSBlackList;\r
+bool NSProviderIsFoundCacheData(NSCacheType, void *, void*);\r
 \r
-typedef NSWhiteList NSCommonList;\r
+NSResult NSCacheUpdateSubScriptionState(NSCacheList *, NSCacheSubData *);\r
 \r
-NSResult NSProviderWriteToCache(NSCache target, OCObservationId observeId, int state);\r
-NSCommonList * NSProviderReadCache(NSCache target, int state);\r
+pthread_mutex_t NSCacheMutex;\r
 \r
-#endif /* _NS_PROVIDER_CACHE__H_ */\r
+#endif /* _NS_PROVIDER_CACHEADAPTER__H_ */\r