@Override
	public RMIFileBean rescueFile(String id) throws RemoteException {
		// TODO Auto-generated method stub
		String host = "localhost";
		DBObject myDoc = null;
		RMIFileBean fb = null;
		try {
			MongoClient mongoClient = new MongoClient(host);

			DB db = mongoClient.getDB( "sdfinal" );
			
			DBCollection coll = db.getCollection("videos");
			
			BasicDBObject query = new BasicDBObject("_id", id);

			DBCursor cursor = coll.find(query);

	        try {
	        	if(cursor.hasNext())
				    myDoc = cursor.next();
				fb = new RMIFileBean();
				// { "_id" : "cone123456" , "name" : "teste" , "description" : "lala no mudo dos poneis"}
				String name = (String)myDoc.get("name");
				
				fb.setData((byte[])myDoc.get("data"));
				fb.setName(name);
	        } finally {
	            cursor.close();
	        }
			
		} catch (Exception e) {
			System.out.println(e);
		}
		return fb;
	}