diff --git a/program/Build/RaspberryCloud.sdf b/program/Build/RaspberryCloud.sdf
index 4f9c5f3fccc5d753f47837fe77623c5b5edbfd87..fc689ef9c000ed498bd0eccd96149902c6b599d0 100644
Binary files a/program/Build/RaspberryCloud.sdf and b/program/Build/RaspberryCloud.sdf differ
diff --git a/program/Build/RaspberryCloud.v12.suo b/program/Build/RaspberryCloud.v12.suo
index 0e72be7db554e35abd8b10faa06020a369326f72..96f8b4f1153a378a17093a8ad958187a533169a2 100644
Binary files a/program/Build/RaspberryCloud.v12.suo and b/program/Build/RaspberryCloud.v12.suo differ
diff --git a/program/Build/RaspberryCloud/RaspberryCloud.vcxproj b/program/Build/RaspberryCloud/RaspberryCloud.vcxproj
index 26fc1aa682480dc35924317fe93786e45acf6e07..cdcaf8ea04be812327e1dbe219a391e6d4813211 100644
--- a/program/Build/RaspberryCloud/RaspberryCloud.vcxproj
+++ b/program/Build/RaspberryCloud/RaspberryCloud.vcxproj
@@ -89,6 +89,11 @@
   <ItemGroup>
     <ClCompile Include="..\..\Source\app\Application.cpp" />
     <ClCompile Include="..\..\Source\app\UI.cpp" />
+    <ClCompile Include="..\..\Source\cache\BasicCache.cpp" />
+    <ClCompile Include="..\..\Source\cache\FIFOCache.cpp" />
+    <ClCompile Include="..\..\Source\cache\LFUCache.cpp" />
+    <ClCompile Include="..\..\Source\cache\LRUCache.cpp" />
+    <ClCompile Include="..\..\Source\cache\NoCache.cpp" />
     <ClCompile Include="..\..\Source\cloud\CloudAccessLayer.cpp" />
     <ClCompile Include="..\..\Source\cloud\CloudAdapter.cpp" />
     <ClCompile Include="..\..\Source\cloud\CloudManager.cpp" />
@@ -100,7 +105,6 @@
     <ClCompile Include="..\..\Source\dataAccess\CloudFileSystem.cpp" />
     <ClCompile Include="..\..\Source\dataAccess\ComputeOnClient.cpp" />
     <ClCompile Include="..\..\Source\dataAccess\ComputeOnPi.cpp" />
-    <ClCompile Include="..\..\Source\dataAccess\ConcreteCache.cpp" />
     <ClCompile Include="..\..\Source\dataAccess\Decoder.cpp" />
     <ClCompile Include="..\..\Source\dataAccess\Distributor.cpp" />
     <ClCompile Include="..\..\Source\dataAccess\Encoder.cpp" />
@@ -119,6 +123,13 @@
   <ItemGroup>
     <ClInclude Include="..\..\Source\app\Application.h" />
     <ClInclude Include="..\..\Source\app\UI.h" />
+    <ClInclude Include="..\..\Source\cache\BasicCache.h" />
+    <ClInclude Include="..\..\Source\cache\Cache.h" />
+    <ClInclude Include="..\..\Source\cache\CacheFile.h" />
+    <ClInclude Include="..\..\Source\cache\FIFOCache.h" />
+    <ClInclude Include="..\..\Source\cache\LFUCache.h" />
+    <ClInclude Include="..\..\Source\cache\LRUCache.h" />
+    <ClInclude Include="..\..\Source\cache\NoCache.h" />
     <ClInclude Include="..\..\Source\cloud\CloudAccessLayer.h" />
     <ClInclude Include="..\..\Source\cloud\CloudAdapter.h" />
     <ClInclude Include="..\..\Source\cloud\CloudException.h" />
@@ -127,12 +138,10 @@
     <ClInclude Include="..\..\Source\cloud\ExampleCloudAdapter.h" />
     <ClInclude Include="..\..\Source\cloud\FTPAdapter.h" />
     <ClInclude Include="..\..\Source\cloud\LocalCloudAdapter.h" />
-    <ClInclude Include="..\..\Source\dataAccess\Cache.h" />
     <ClInclude Include="..\..\Source\dataAccess\CloudFileList.h" />
     <ClInclude Include="..\..\Source\dataAccess\CloudFileSystem.h" />
     <ClInclude Include="..\..\Source\dataAccess\ComputeOnClient.h" />
     <ClInclude Include="..\..\Source\dataAccess\ComputeOnPi.h" />
-    <ClInclude Include="..\..\Source\dataAccess\ConcreteCache.h" />
     <ClInclude Include="..\..\Source\dataAccess\Decoder.h" />
     <ClInclude Include="..\..\Source\dataAccess\Distributor.h" />
     <ClInclude Include="..\..\Source\dataAccess\Encoder.h" />
diff --git a/program/Build/RaspberryCloud/RaspberryCloud.vcxproj.filters b/program/Build/RaspberryCloud/RaspberryCloud.vcxproj.filters
index 96ef00de5d090fd98671506cd3d9f86887d7ccea..c5fe3838bc9c9303a9218b94e89444897835c2bb 100644
--- a/program/Build/RaspberryCloud/RaspberryCloud.vcxproj.filters
+++ b/program/Build/RaspberryCloud/RaspberryCloud.vcxproj.filters
@@ -55,6 +55,12 @@
     <Filter Include="Header Files\cloud\adapter">
       <UniqueIdentifier>{4bd543fd-eb05-47c9-a515-f7f94b0e9009}</UniqueIdentifier>
     </Filter>
+    <Filter Include="Header Files\cache">
+      <UniqueIdentifier>{3bc6f97a-3e60-44c4-8fcb-6d0700e45c04}</UniqueIdentifier>
+    </Filter>
+    <Filter Include="Source Files\cache">
+      <UniqueIdentifier>{7a804dde-3827-48f5-97f3-de7ea5499492}</UniqueIdentifier>
+    </Filter>
   </ItemGroup>
   <ItemGroup>
     <ClCompile Include="..\..\Source\app\Application.cpp">
@@ -78,9 +84,6 @@
     <ClCompile Include="..\..\Source\dataAccess\ComputeOnPi.cpp">
       <Filter>Source Files\dataAccess</Filter>
     </ClCompile>
-    <ClCompile Include="..\..\Source\dataAccess\ConcreteCache.cpp">
-      <Filter>Source Files\dataAccess</Filter>
-    </ClCompile>
     <ClCompile Include="..\..\Source\dataAccess\Decoder.cpp">
       <Filter>Source Files\dataAccess</Filter>
     </ClCompile>
@@ -141,6 +144,21 @@
     <ClCompile Include="..\..\Source\fileModel\ReturnableFile.cpp">
       <Filter>Source Files\fileModel</Filter>
     </ClCompile>
+    <ClCompile Include="..\..\Source\cache\NoCache.cpp">
+      <Filter>Source Files\cache</Filter>
+    </ClCompile>
+    <ClCompile Include="..\..\Source\cache\LRUCache.cpp">
+      <Filter>Source Files\cache</Filter>
+    </ClCompile>
+    <ClCompile Include="..\..\Source\cache\LFUCache.cpp">
+      <Filter>Source Files\cache</Filter>
+    </ClCompile>
+    <ClCompile Include="..\..\Source\cache\FIFOCache.cpp">
+      <Filter>Source Files\cache</Filter>
+    </ClCompile>
+    <ClCompile Include="..\..\Source\cache\BasicCache.cpp">
+      <Filter>Source Files\cache</Filter>
+    </ClCompile>
   </ItemGroup>
   <ItemGroup>
     <ClInclude Include="..\..\Source\app\UI.h">
@@ -152,9 +170,6 @@
     <ClInclude Include="..\..\Source\cloud\CloudManager.h">
       <Filter>Header Files\cloud</Filter>
     </ClInclude>
-    <ClInclude Include="..\..\Source\dataAccess\Cache.h">
-      <Filter>Header Files\dataAccess</Filter>
-    </ClInclude>
     <ClInclude Include="..\..\Source\dataAccess\CloudFileSystem.h">
       <Filter>Header Files\dataAccess</Filter>
     </ClInclude>
@@ -164,9 +179,6 @@
     <ClInclude Include="..\..\Source\dataAccess\ComputeOnPi.h">
       <Filter>Header Files\dataAccess</Filter>
     </ClInclude>
-    <ClInclude Include="..\..\Source\dataAccess\ConcreteCache.h">
-      <Filter>Header Files\dataAccess</Filter>
-    </ClInclude>
     <ClInclude Include="..\..\Source\dataAccess\Decoder.h">
       <Filter>Header Files\dataAccess</Filter>
     </ClInclude>
@@ -242,5 +254,26 @@
     <ClInclude Include="..\..\Source\fileModel\ReturnableFile.h">
       <Filter>Header Files\fileModel</Filter>
     </ClInclude>
+    <ClInclude Include="..\..\Source\cache\NoCache.h">
+      <Filter>Header Files\cache</Filter>
+    </ClInclude>
+    <ClInclude Include="..\..\Source\cache\LRUCache.h">
+      <Filter>Header Files\cache</Filter>
+    </ClInclude>
+    <ClInclude Include="..\..\Source\cache\LFUCache.h">
+      <Filter>Header Files\cache</Filter>
+    </ClInclude>
+    <ClInclude Include="..\..\Source\cache\FIFOCache.h">
+      <Filter>Header Files\cache</Filter>
+    </ClInclude>
+    <ClInclude Include="..\..\Source\cache\Cache.h">
+      <Filter>Header Files\cache</Filter>
+    </ClInclude>
+    <ClInclude Include="..\..\Source\cache\BasicCache.h">
+      <Filter>Header Files\cache</Filter>
+    </ClInclude>
+    <ClInclude Include="..\..\Source\cache\CacheFile.h">
+      <Filter>Header Files\cache</Filter>
+    </ClInclude>
   </ItemGroup>
 </Project>
\ No newline at end of file
diff --git a/program/Build/RaspberryCloud/RaspberryCloud.vcxproj.user b/program/Build/RaspberryCloud/RaspberryCloud.vcxproj.user
index 64a3621a437c792daa9e8ebbf84ed009acb26092..ff5921cf0d2fd9ab81317dc308955058e0042125 100644
--- a/program/Build/RaspberryCloud/RaspberryCloud.vcxproj.user
+++ b/program/Build/RaspberryCloud/RaspberryCloud.vcxproj.user
@@ -1,7 +1,8 @@
 <?xml version="1.0" encoding="utf-8"?>
 <Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
-    <LocalDebuggerCommandArguments>-dc:\Work\raspberrycloud\program\data\ -cc:\Work\raspberrycloud\program\cloud\ -fc:\Work\raspberrycloud\program\temp\</LocalDebuggerCommandArguments>
+    <LocalDebuggerCommandArguments>
+    </LocalDebuggerCommandArguments>
     <DebuggerFlavor>WindowsLocalDebugger</DebuggerFlavor>
   </PropertyGroup>
 </Project>
\ No newline at end of file
diff --git a/program/Source/app/Application.cpp b/program/Source/app/Application.cpp
index d65e9ac2e5cd21574c9dddd3967aadb7a8f37b75..db0d9a9d076f957bd75f6c1ea96e0b3feee8e9b3 100644
--- a/program/Source/app/Application.cpp
+++ b/program/Source/app/Application.cpp
@@ -4,6 +4,11 @@
 #include "../cloud/LocalCloudAdapter.h"
 #include "../cloud/DropboxAdapter.h"
 #include "../cloud/FTPAdapter.h"
+#include "../cache/NoCache.h"
+#include "../cache/BasicCache.h"
+#include "../cache/FIFOCache.h"
+#include "../cache/LRUCache.h"
+#include "../cache/LFUCache.h"
 
 using namespace std;
 
@@ -40,6 +45,7 @@ int main(int argc, char **argv) {
 	string dataFolder = "C:\\Users\\krisz\\raspberrycloud\\skeleton\\Program\\data\\";
 	string fragFolder = "C:\\Users\\krisz\\raspberrycloud\\skeleton\\Program\\temp\\";
 	string cloudFolder = "C:\\Users\\krisz\\raspberrycloud\\skeleton\\Program\\cloud\\";
+	string cacheFolder = "C:\\Users\\krisz\\raspberrycloud\\skeleton\\Program\\cache\\";
 
 	for (int i = 1; i < argc; i++)
 	{
@@ -60,6 +66,41 @@ int main(int argc, char **argv) {
 	application.cfs.getEncoder()->setFolders(dataFolder,fragFolder);
 	application.cfs.getDecoder()->setFolders(dataFolder,fragFolder);
 	application.cfs.setFolders(fragFolder);
+	
+	bool waitAnswer = true;
+	Cache *cacheToSetup;
+	while (waitAnswer){
+		cout << "Please select caching method (1: no, 2: FIFO, 3: LRU, 4: LFU)" << endl;
+		int answer = 0;
+		cin >> answer;
+
+		int cacheSize = 3;
+
+		switch (answer){
+			case 1:
+				cacheToSetup = new NoCache();
+				waitAnswer = false;
+				break;
+			case 2:
+				cacheToSetup = new FIFOCache(cacheSize);
+				waitAnswer = false;
+				break;
+			case 3:
+				cacheToSetup = new LRUCache(cacheSize);
+				waitAnswer = false;
+				break;
+			case 4:
+				cacheToSetup = new LFUCache(cacheSize);
+				waitAnswer = false;
+				break;
+			default:
+				break;			
+		}
+	}
+
+	application.cfs.setCache(cacheToSetup);
+	application.cfs.getCache()->setFolders(cacheFolder, dataFolder);
+	application.cfs.getCache()->readCache();
 
 	application.hnc.setDataFolder(dataFolder);
 
@@ -105,8 +146,7 @@ int main(int argc, char **argv) {
 			application.ui.setComputeOnPi(false);
 			break;
 		}
-	}
-		
+	}		
 
 	cout << "To list avaliable orders enter \"help\"." << endl;
 
diff --git a/program/Source/cache/BasicCache.cpp b/program/Source/cache/BasicCache.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..c8a5a22237781cf8963038ebd6a412ed25356fe6
--- /dev/null
+++ b/program/Source/cache/BasicCache.cpp
@@ -0,0 +1,64 @@
+#include "BasicCache.h"
+#include "../logger/Logger.h"
+#include <fstream>
+
+#include <boost/filesystem.hpp>
+
+using namespace std;
+using namespace boost::filesystem;
+
+/**
+ * BasicCache implementation
+ */
+
+ReturnableFile BasicCache::getFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+	ReturnableFile fileFromCache(localFileID);
+
+	//copy file from cache to source
+	ifstream src(cacheFolder + localFileID, ios::binary);
+	if (src) {
+		ofstream dst(sourceFolder + localFileID, ios::binary);
+		if (dst) {
+			dst << src.rdbuf();
+			dst.close();
+			fileFromCache.setValid(true);
+		}
+		else {
+			fileFromCache.setErrorMessage("Cache output could not be initialized.");
+		}
+		src.close();		
+	}
+	else {
+		fileFromCache.setErrorMessage("Cache source could not be initialized.");
+	}
+	
+	return fileFromCache;
+}
+
+bool BasicCache::addFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+
+	path cacheLocation = cacheFolder + localFileID;
+	path cacheParentDir = cacheLocation.parent_path();
+
+	if (!exists(cacheParentDir))
+	{
+		create_directories(cacheParentDir);
+	}
+
+	bool successful = false;
+
+	//copy file to cache
+	ifstream src(sourceFolder + localFileID, ios::binary);
+	if (src) {
+		ofstream dst(cacheFolder + localFileID, ios::binary);
+		if (dst) {
+			dst << src.rdbuf();
+			dst.close();
+			successful = true;
+		}
+		src.close();
+	}	
+	return successful;
+}
\ No newline at end of file
diff --git a/program/Source/cache/BasicCache.h b/program/Source/cache/BasicCache.h
new file mode 100644
index 0000000000000000000000000000000000000000..d7a9ea3fa728dc0885afe38cd3fbb12245debbd1
--- /dev/null
+++ b/program/Source/cache/BasicCache.h
@@ -0,0 +1,30 @@
+/**
+ * Project Untitled
+ */
+
+
+#ifndef _BASICCACHE_H
+#define _BASICCACHE_H
+
+#include "Cache.h"
+
+/**
+ * BasicCache class
+ * implenents Cache interface
+ */
+class BasicCache : public Cache {
+public:
+	BasicCache(int size) { maxSize = size; }
+
+	/**
+	 * Tries to get a file from the cache
+	 */
+	ReturnableFile getFile(std::string localFileID);
+
+	/**
+	* Adds a file to the cache
+	*/
+	bool addFile(std::string localFileID);
+};
+
+#endif //_BASICCACHE_H
\ No newline at end of file
diff --git a/program/Source/dataAccess/Cache.h b/program/Source/cache/Cache.h
similarity index 55%
rename from program/Source/dataAccess/Cache.h
rename to program/Source/cache/Cache.h
index 9b035e5abf22c4e81e804b96c9b8f36a7bca799a..71b4b2699da919e649963d6b2c76a87426a9327e 100644
--- a/program/Source/dataAccess/Cache.h
+++ b/program/Source/cache/Cache.h
@@ -1,6 +1,7 @@
 #ifndef _CACHE_H
 #define _CACHE_H
 
+#include "CacheFile.h"
 #include "../fileModel/ReturnableFile.h"
 
 /**
@@ -8,7 +9,18 @@
  * provides interface to the caching functionality
  */
 class Cache {
-public: 
+protected:
+	int maxSize;
+	int realSize;
+	CacheFile* files;
+	std::string sourceFolder;
+	std::string cacheFolder;
+public:
+	void setFolders(std::string _cacheFolder, std::string _sourceFolder){
+		cacheFolder = _cacheFolder;
+		sourceFolder = _sourceFolder;
+	}
+
 	/**
 	 * Tries to get a file from the cache
 	 */
@@ -18,6 +30,8 @@ public:
 	 * Adds a file to the cache
 	 */
 	virtual bool addFile(std::string localFileID) = 0;
+
+	virtual void readCache() = 0;
 };
 
 #endif //_CACHE_H
\ No newline at end of file
diff --git a/program/Source/cache/CacheFile.h b/program/Source/cache/CacheFile.h
new file mode 100644
index 0000000000000000000000000000000000000000..7534058508907162baf71f845952a942d8c9fd8c
--- /dev/null
+++ b/program/Source/cache/CacheFile.h
@@ -0,0 +1,22 @@
+#ifndef _CACHEFILE_H
+#define _CACHEFILE_H
+
+#include <string>
+
+using namespace std; 
+
+class CacheFile
+{
+private:
+	string fileId;
+public:
+	int used;
+
+	CacheFile() {}
+	CacheFile(string fileId, int used) : fileId(fileId), used(used) {}
+
+	string getFileId() { return fileId; }
+	void setFileId(string _fileId) { fileId = _fileId; }
+};
+
+#endif
\ No newline at end of file
diff --git a/program/Source/cache/FIFOCache.cpp b/program/Source/cache/FIFOCache.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..18654d1170f3213d0111ecb05826686b7807b6a4
--- /dev/null
+++ b/program/Source/cache/FIFOCache.cpp
@@ -0,0 +1,141 @@
+#include "FIFOCache.h"
+#include "../logger/Logger.h"
+#include <fstream>
+#include <sstream>
+
+#include <boost/filesystem.hpp>
+
+using namespace std;
+using namespace boost::filesystem;
+
+/**
+ * FIFOCache implementation
+ */
+FIFOCache::FIFOCache(int _size)
+{
+	maxSize = _size;
+	realSize = 0;
+	files = new CacheFile[maxSize];
+}
+
+FIFOCache::~FIFOCache()
+{
+	delete[] files;
+}
+
+ReturnableFile FIFOCache::getFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+	ReturnableFile fileFromCache(localFileID);
+
+	//copy file from cache to source
+	ifstream src(cacheFolder + localFileID, ios::binary);
+	if (src) {
+		ofstream dst(sourceFolder + localFileID, ios::binary);
+		if (dst) {
+			dst << src.rdbuf();
+			dst.close();
+			fileFromCache.setValid(true);
+		}
+		else {
+			fileFromCache.setErrorMessage("Cache output could not be initialized.");
+		}
+		src.close();		
+	}
+	else {
+		fileFromCache.setErrorMessage("Cache source could not be initialized.");
+	}
+	
+	return fileFromCache;
+}
+
+bool FIFOCache::addFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+	bool successful = true;
+	if (!checkFile(localFileID)){
+		successful = false;
+		path cacheLocation = cacheFolder + localFileID;
+		path cacheParentDir = cacheLocation.parent_path();
+
+		if (!exists(cacheParentDir))
+		{
+			create_directories(cacheParentDir);
+		}
+
+		//copy file to cache
+		ifstream src(sourceFolder + localFileID, ios::binary);
+		if (src) {
+			ofstream dst(cacheFolder + localFileID, ios::binary);
+			if (dst) {
+				if (realSize == maxSize)
+				{
+					// tele van, ez�rt az utols�t kit�r�lj�k
+					string spath = cacheFolder + files[maxSize - 1].getFileId();
+					const char* path = spath.c_str();
+					int res = remove(path);
+
+					for (int idx = realSize - 1; idx >= 0; idx--)
+					{
+						if ((idx + 1) < maxSize)
+						{
+							files[idx + 1] = files[idx];
+						}
+					}
+					files[0] = CacheFile(localFileID, 0);
+				}
+				else
+				{
+					for (int idx = realSize - 1; idx >= 0; idx--)
+					{
+						if ((idx + 1) < maxSize)
+						{
+							files[idx + 1] = files[idx];
+						}
+					}
+					files[0] = CacheFile(localFileID, 0);
+					realSize++;
+				}
+				
+				dst << src.rdbuf();
+				dst.close();
+				successful = true;
+
+				cout << toString();
+			}
+			src.close();
+		}
+	}
+	return successful;
+}
+
+bool FIFOCache::checkFile(string id){
+	for (int idx = 0; idx < realSize; idx++) {
+		if (files[idx].getFileId() == id) {
+			return true;
+		}
+	}
+	return false;
+}
+
+string FIFOCache::toString() {
+	ostringstream ss;
+	ss << "rs:" << realSize << " data: ";
+	for (int i = 0; i < realSize; i++) {
+		ss << files[i].getFileId() << " ";
+	}
+
+	return ss.str();
+}
+
+void FIFOCache::readCache() {
+	path p = cacheFolder;
+	if (exists(p) && is_directory(p)) 
+	{
+		vector<path> v;
+		copy(directory_iterator(p), directory_iterator(), back_inserter(v));
+		for (int i = 0; i < v.size(); i++)
+		{
+			path p = v.at(i).filename();
+			files[i] = CacheFile(p.string(), 0);
+		}		
+	}
+}
\ No newline at end of file
diff --git a/program/Source/cache/FIFOCache.h b/program/Source/cache/FIFOCache.h
new file mode 100644
index 0000000000000000000000000000000000000000..4174db890b1c77f2d51984a95b734a81d4b5dba8
--- /dev/null
+++ b/program/Source/cache/FIFOCache.h
@@ -0,0 +1,35 @@
+/**
+ * Project Untitled
+ */
+
+
+#ifndef _FIFOCACHE_H
+#define _FIFOCACHE_H
+
+#include "Cache.h"
+
+/**
+ * FIFOCache class
+ * implenents Cache interface
+ */
+class FIFOCache : public Cache {
+public:
+	FIFOCache(int size);
+	~FIFOCache();
+
+	/**
+	 * Tries to get a file from the cache
+	 */
+	ReturnableFile getFile(std::string localFileID);
+
+	/**
+	* Adds a file to the cache
+	*/
+	bool addFile(std::string localFileID);
+
+	void readCache();
+	bool checkFile(std::string id);
+	string toString();
+};
+
+#endif //_FIFOCACHE_H
\ No newline at end of file
diff --git a/program/Source/cache/LFUCache.cpp b/program/Source/cache/LFUCache.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..2b94cf24529a05f54815286243cddbd409b5d2d6
--- /dev/null
+++ b/program/Source/cache/LFUCache.cpp
@@ -0,0 +1,89 @@
+#include "LFUCache.h"
+#include "../logger/Logger.h"
+#include <fstream>
+
+#include <boost/filesystem.hpp>
+
+using namespace std;
+using namespace boost::filesystem;
+
+/**
+ * LFUCache implementation
+ */
+
+LFUCache::LFUCache(int _size)
+{
+	maxSize = _size;
+	realSize = 0;
+	files = new CacheFile[maxSize];
+
+	for (int i = 0; i < maxSize; i++){
+		files[i] = CacheFile("", -1);
+	}
+}
+
+LFUCache::~LFUCache()
+{
+	delete[] files;
+}
+
+ReturnableFile LFUCache::getFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+	ReturnableFile fileFromCache(localFileID);
+
+	//copy file from cache to source
+	ifstream src(cacheFolder + localFileID, ios::binary);
+	if (src) {
+		ofstream dst(sourceFolder + localFileID, ios::binary);
+		if (dst) {
+			dst << src.rdbuf();
+			dst.close();
+			fileFromCache.setValid(true);
+		}
+		else {
+			fileFromCache.setErrorMessage("Cache output could not be initialized.");
+		}
+		src.close();		
+	}
+	else {
+		fileFromCache.setErrorMessage("Cache source could not be initialized.");
+	}
+	
+	return fileFromCache;
+}
+
+bool LFUCache::addFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+
+	path cacheLocation = cacheFolder + localFileID;
+	path cacheParentDir = cacheLocation.parent_path();
+
+	if (!exists(cacheParentDir))
+	{
+		create_directories(cacheParentDir);
+	}
+
+	bool successful = false;
+
+	//copy file to cache
+	ifstream src(sourceFolder + localFileID, ios::binary);
+	if (src) {
+		ofstream dst(cacheFolder + localFileID, ios::binary);
+		if (dst) {
+			dst << src.rdbuf();
+			dst.close();
+			successful = true;
+		}
+		src.close();
+	}	
+	return successful;
+}
+
+bool LFUCache::checkFile(string id){
+	for (int idx = 0; idx < maxSize; idx++) {
+		if (files[idx].getFileId() == id) {
+			return true;
+		}
+	}
+	return false;
+}
\ No newline at end of file
diff --git a/program/Source/cache/LFUCache.h b/program/Source/cache/LFUCache.h
new file mode 100644
index 0000000000000000000000000000000000000000..592479d0d32103f39f5625c5ad85041924f2d3b8
--- /dev/null
+++ b/program/Source/cache/LFUCache.h
@@ -0,0 +1,36 @@
+/**
+ * Project Untitled
+ */
+
+
+#ifndef _LFUCACHE_H
+#define _LFUCACHE_H
+
+#include "Cache.h"
+
+/**
+ * LFUCache class
+ * implenents Cache interface
+ */
+class LFUCache : public Cache {
+public:
+	LFUCache(int size);
+	~LFUCache();
+
+	/**
+	 * Tries to get a file from the cache
+	 */
+	ReturnableFile getFile(std::string localFileID);
+
+	/**
+	* Adds a file to the cache
+	*/
+	bool addFile(std::string localFileID);
+
+
+	bool checkFile(std::string id);
+
+	void readCache() {}
+};
+
+#endif //_LFUCACHE_H
\ No newline at end of file
diff --git a/program/Source/cache/LRUCache.cpp b/program/Source/cache/LRUCache.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..bf933e8787853127d261113cd0681152b62545cd
--- /dev/null
+++ b/program/Source/cache/LRUCache.cpp
@@ -0,0 +1,89 @@
+#include "LRUCache.h"
+#include "../logger/Logger.h"
+#include <fstream>
+
+#include <boost/filesystem.hpp>
+
+using namespace std;
+using namespace boost::filesystem;
+
+/**
+ * LRUCache implementation
+ */
+
+LRUCache::LRUCache(int _size)
+{
+	maxSize = _size;
+	realSize = 0;
+	files = new CacheFile[maxSize];
+
+	for (int i = 0; i < maxSize; i++){
+		files[i] = CacheFile("", 1);
+	}
+}
+
+LRUCache::~LRUCache()
+{
+	delete[] files;
+}
+
+ReturnableFile LRUCache::getFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+	ReturnableFile fileFromCache(localFileID);
+
+	//copy file from cache to source
+	ifstream src(cacheFolder + localFileID, ios::binary);
+	if (src) {
+		ofstream dst(sourceFolder + localFileID, ios::binary);
+		if (dst) {
+			dst << src.rdbuf();
+			dst.close();
+			fileFromCache.setValid(true);
+		}
+		else {
+			fileFromCache.setErrorMessage("Cache output could not be initialized.");
+		}
+		src.close();		
+	}
+	else {
+		fileFromCache.setErrorMessage("Cache source could not be initialized.");
+	}
+	
+	return fileFromCache;
+}
+
+bool LRUCache::addFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+
+	path cacheLocation = cacheFolder + localFileID;
+	path cacheParentDir = cacheLocation.parent_path();
+
+	if (!exists(cacheParentDir))
+	{
+		create_directories(cacheParentDir);
+	}
+
+	bool successful = false;
+
+	//copy file to cache
+	ifstream src(sourceFolder + localFileID, ios::binary);
+	if (src) {
+		ofstream dst(cacheFolder + localFileID, ios::binary);
+		if (dst) {
+			dst << src.rdbuf();
+			dst.close();
+			successful = true;
+		}
+		src.close();
+	}	
+	return successful;
+}
+
+bool LRUCache::checkFile(string id){
+	for (int idx = 0; idx < maxSize; idx++) {
+		if (files[idx].getFileId() == id) {
+			return true;
+		}
+	}
+	return false;
+}
\ No newline at end of file
diff --git a/program/Source/cache/LRUCache.h b/program/Source/cache/LRUCache.h
new file mode 100644
index 0000000000000000000000000000000000000000..0853e242696f540bb6ad084263d02286a6c5b736
--- /dev/null
+++ b/program/Source/cache/LRUCache.h
@@ -0,0 +1,36 @@
+/**
+ * Project Untitled
+ */
+
+
+#ifndef _LRUCACHE_H
+#define _LRUCACHE_H
+
+#include "Cache.h"
+
+/**
+ * LRUCache class
+ * implenents Cache interface
+ */
+class LRUCache : public Cache {
+public:
+	LRUCache(int size);
+	~LRUCache();
+
+	/**
+	 * Tries to get a file from the cache
+	 */
+	ReturnableFile getFile(std::string localFileID);
+
+	/**
+	* Adds a file to the cache
+	*/
+	bool addFile(std::string localFileID);
+
+
+	bool checkFile(std::string id);
+
+	void readCache() {}
+};
+
+#endif //_LRUCACHE_H
\ No newline at end of file
diff --git a/program/Source/cache/NoCache.cpp b/program/Source/cache/NoCache.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..ba51cd9e8958954c19373324014a7b28daab74a1
--- /dev/null
+++ b/program/Source/cache/NoCache.cpp
@@ -0,0 +1,17 @@
+#include "NoCache.h"
+#include "../logger/Logger.h"
+
+/**
+ * NoCache implementation
+ */
+
+ReturnableFile NoCache::getFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+	ReturnableFile fileFromCache(localFileID);	
+	return fileFromCache;
+}
+
+bool NoCache::addFile(std::string localFileID) {
+	LOG_ENTER_EXIT;
+	return false;
+}
\ No newline at end of file
diff --git a/program/Source/dataAccess/ConcreteCache.h b/program/Source/cache/NoCache.h
similarity index 65%
rename from program/Source/dataAccess/ConcreteCache.h
rename to program/Source/cache/NoCache.h
index 44bc7357388eb2554a99230ede8b626b5c97fb67..b413a4c4ebe4a19bdc87ecfdfd98013f0db6debb 100644
--- a/program/Source/dataAccess/ConcreteCache.h
+++ b/program/Source/cache/NoCache.h
@@ -3,17 +3,17 @@
  */
 
 
-#ifndef _CONCRETECACHE_H
-#define _CONCRETECACHE_H
+#ifndef _NOCACHE_H
+#define _NOCACHE_H
 
 #include "Cache.h"
 
 /**
- * ConcreteCache class
+ * NoCache class
  * implenents Cache interface
  */
-class ConcreteCache: public Cache {
-public: 
+class NoCache : public Cache {
+public:
 	/**
 	 * Tries to get a file from the cache
 	 */
@@ -23,6 +23,8 @@ public:
 	* Adds a file to the cache
 	*/
 	bool addFile(std::string localFileID);
+
+	void readCache() {}
 };
 
-#endif //_CONCRETECACHE_H
\ No newline at end of file
+#endif //_NOCACHE_H
\ No newline at end of file
diff --git a/program/Source/dataAccess/CloudFileSystem.cpp b/program/Source/dataAccess/CloudFileSystem.cpp
index 3cb0f235dda38c75171b0cbafbfe2a53c5c4cdb2..039bd58b98b43bdfc91d959dbbf1ace45f8064e4 100644
--- a/program/Source/dataAccess/CloudFileSystem.cpp
+++ b/program/Source/dataAccess/CloudFileSystem.cpp
@@ -1,6 +1,7 @@
 #include "../app/Application.h"
 #include "ComputeOnPi.h"
 #include "ComputeOnClient.h"
+#include "../cache/NoCache.h"
 
 using namespace std;
 
@@ -14,7 +15,7 @@ CloudFileSystem::CloudFileSystem(Application &application) :
 		homeNetworkBehaviour(new ComputeOnClient(*this)),
 		application(application),
 		distributor(application.cm),
-		cache(new ConcreteCache())
+		cache(new NoCache())
 {
 	cfl.setPersPath("store.dat");
 	cfl.load();
@@ -41,6 +42,11 @@ void CloudFileSystem::setFolders(string _fragFolder){
 	fragFolder = _fragFolder;
 }
 
+void CloudFileSystem::setCache(Cache* c){
+	delete cache;
+	cache = c;
+}
+
 string CloudFileSystem::fragFolder = "";
 
 // Not working as we planned, maybe should be rethinked
diff --git a/program/Source/dataAccess/CloudFileSystem.h b/program/Source/dataAccess/CloudFileSystem.h
index 7e71b176f4afdf32cc1fc6f6910a1c23d151b51d..a1fbfc99d66852b48ae5998eb04b29b6d11dadad 100644
--- a/program/Source/dataAccess/CloudFileSystem.h
+++ b/program/Source/dataAccess/CloudFileSystem.h
@@ -4,7 +4,6 @@
 #include <string>
 #include <set>
 #include <fstream>
-#include "ConcreteCache.h"
 #include "CloudFileSystem.h"
 #include "../logger/Logger.h"
 #include "../cloud/CloudAccessLayer.h"
@@ -13,7 +12,7 @@
 #include "Distributor.h"
 #include "../cloud/CloudAccessLayer.h"
 #include "../networking/HomeNetworkCommunications.h"
-#include "Cache.h"
+#include "../cache/Cache.h"
 #include "CloudFileList.h"
 #include "../dataAccess/Encoder.h"
 #include "../dataAccess/Decoder.h"
@@ -67,6 +66,8 @@ public:
 
 	void setFolders(std::string _fragFolder);
 
+	void setCache(Cache* c);
+
 	/**
 	 * Setter to the setComputePi variable
 	 * Sets the right HomeNetworkBehaviour
diff --git a/program/Source/dataAccess/ComputeOnClient.cpp b/program/Source/dataAccess/ComputeOnClient.cpp
index d3a904c896070e19565b8b90179d0cdd7a51813d..00c130a091eacdc2185f2ecbfc6ce14e21c0c2ab 100644
--- a/program/Source/dataAccess/ComputeOnClient.cpp
+++ b/program/Source/dataAccess/ComputeOnClient.cpp
@@ -4,7 +4,7 @@
 #include "Encoder.h"
 #include "Distributor.h"
 #include "../cloud/CloudAccessLayer.h"
-#include "Cache.h"
+#include "../cache/Cache.h"
 
 using namespace fileModel;
 using namespace std;
@@ -17,8 +17,9 @@ bool ComputeOnClient::addFile(string localFileID, string destinationFileID) {
 	LOG_ENTER_EXIT;
 	bool success;
 
-	//TODO: well, I guess it needs a parameter... sooner or later.
-	cloudFileSystem.getCache()->addFile(localFileID);
+	if (!cloudFileSystem.getCache()->addFile(localFileID)){
+		return false;
+	}
 
 	auto fileDescriptor = Encoder::encode(localFileID, destinationFileID);
 
diff --git a/program/Source/dataAccess/ConcreteCache.cpp b/program/Source/dataAccess/ConcreteCache.cpp
deleted file mode 100644
index a84ef938d596c13d1a7572a3ba31b80cd4883076..0000000000000000000000000000000000000000
--- a/program/Source/dataAccess/ConcreteCache.cpp
+++ /dev/null
@@ -1,17 +0,0 @@
-#include "ConcreteCache.h"
-#include "../logger/Logger.h"
-
-/**
- * ConcreteCache implementation
- */
-
-ReturnableFile ConcreteCache::getFile(std::string localFileID) {
-	LOG_ENTER_EXIT;
-	ReturnableFile fileFromCache(localFileID);
-	return fileFromCache;
-}
-
-bool ConcreteCache::addFile(std::string localFileID) {
-	LOG_ENTER_EXIT;
-	return false;
-}
\ No newline at end of file