// Path: src/main/java/redis/clients/collections/MapStructure.java
// public interface MapStructure <T> extends Expirable{
// 
// 
// 	Map<String, T> get(String key);
// 	
// 	void delete(String key);
// 	
// }
// 
// Path: src/main/java/redis/clients/collections/builder/RedisStrutureBuilder.java
// public class RedisStrutureBuilder {
// 
// 	public static <T> KeyValueBuilder<T> ofKeyValue(Jedis jedis,Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz, "The class must be specificed to do the RedisStruturebuilder");
// 		return new KeyValueBuilder<>(jedis, clazz);
// 	}
// 
// 	public static CountStructureBuilder ofCount(Jedis jedis) {
// 		Objects.requireNonNull(jedis);
// 		return new CountStructureBuilder(jedis);
// 	}
// 
// 	public static <T> ListStructureBuilder<T> ofList(Jedis jedis, Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz, "The class must be specificed to do the ListStruturebuilder");
// 		return new ListStructureBuilder<>(jedis, clazz);
// 	}
// 
// 	public static <T> SetStructureBuilder<T> ofSet(Jedis jedis, Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz, "The class must be specificed to do the SetStruturebuilder");
// 		return new SetStructureBuilder<>(jedis, clazz);
// 	}
// 	
// 	public static <T> MapStructureBuilder<T> ofMap(Jedis jedis, Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz, "The class must be specificed to do the MapStruturebuilder");
// 		return new MapStructureBuilder<>(jedis, clazz);
// 		
// 	}
// 
// 	public static <T> QueueStructureBuilder<T> ofQueue(Jedis jedis, Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz);
// 		return new QueueStructureBuilder<>(jedis, clazz);
// 	}
// 
// 	public static RankingStructureBuilder ofRanking(Jedis jedis) {
// 		Objects.requireNonNull(jedis);
// 		return new RankingStructureBuilder(jedis);
// 	}
// 
// }
// 
// Path: src/test/java/redis/clients/collections/model/Species.java
// public class Species implements Serializable {
// 
// 	private static final long serialVersionUID = -1493508757572337719L;
// 	
// 	private List<String> animals;
// 
// 	public Species(String... animals) {
// 		this.animals = Arrays.asList(animals);
// 	}
// 
// 	public List<String> getAnimals() {
// 		return animals;
// 	}
// 	public void setAnimals(List<String> animals) {
// 		this.animals = animals;
// 	}
// 	
// }
// 
// Path: src/test/java/redis/clients/collections/util/RedisConnection.java
// public class RedisConnection {
// 
// 	public static final Jedis JEDIS;
// 	
// 	static{
// 	 JEDIS = new Jedis("localhost");
// 	}
// }


import java.util.Collection;
import java.util.HashMap;
import java.util.Map;
import java.util.Set;
import junit.framework.Assert;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import redis.clients.collections.MapStructure;
import redis.clients.collections.builder.RedisStrutureBuilder;
import redis.clients.collections.model.Species;
import redis.clients.collections.util.RedisConnection;
package redis.clients.collections;





public class MapStructureTest {

	private MapStructure<Species> zoo;
	
	private Species mammals = new Species("lion", "cow", "dog");
	private Species fishes = new Species("redfish", "glassfish");
	private Species amphibians = new Species("crododile", "frog");
	
	@Before
	public void init() {
		zoo = RedisStrutureBuilder.ofMap(RedisConnection.JEDIS, Species.class).withNameSpace("animalZoo").build();
	}
	
	@Test
	public void shouldPutAndGetMap() {
		Map<String, Species> vertebrates = zoo.get("vertebrates");
		Assert.assertTrue(vertebrates.isEmpty());
		Assert.assertNotNull(vertebrates.put("mammals", mammals));
		Species species = vertebrates.get("mammals");
		Assert.assertNotNull(species);
		Assert.assertEquals(species.getAnimals().get(0), mammals.getAnimals().get(0));
		Assert.assertTrue(vertebrates.size() == 1);
	}
	
	@Test
	public void shouldVerifyExist() {
// Path: src/main/java/redis/clients/collections/MapStructure.java
// public interface MapStructure <T> extends Expirable{
// 
// 
// 	Map<String, T> get(String key);
// 	
// 	void delete(String key);
// 	
// }
// 
// Path: src/main/java/redis/clients/collections/builder/RedisStrutureBuilder.java
// public class RedisStrutureBuilder {
// 
// 	public static <T> KeyValueBuilder<T> ofKeyValue(Jedis jedis,Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz, "The class must be specificed to do the RedisStruturebuilder");
// 		return new KeyValueBuilder<>(jedis, clazz);
// 	}
// 
// 	public static CountStructureBuilder ofCount(Jedis jedis) {
// 		Objects.requireNonNull(jedis);
// 		return new CountStructureBuilder(jedis);
// 	}
// 
// 	public static <T> ListStructureBuilder<T> ofList(Jedis jedis, Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz, "The class must be specificed to do the ListStruturebuilder");
// 		return new ListStructureBuilder<>(jedis, clazz);
// 	}
// 
// 	public static <T> SetStructureBuilder<T> ofSet(Jedis jedis, Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz, "The class must be specificed to do the SetStruturebuilder");
// 		return new SetStructureBuilder<>(jedis, clazz);
// 	}
// 	
// 	public static <T> MapStructureBuilder<T> ofMap(Jedis jedis, Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz, "The class must be specificed to do the MapStruturebuilder");
// 		return new MapStructureBuilder<>(jedis, clazz);
// 		
// 	}
// 
// 	public static <T> QueueStructureBuilder<T> ofQueue(Jedis jedis, Class<T> clazz) {
// 		Objects.requireNonNull(jedis);
// 		Objects.requireNonNull(clazz);
// 		return new QueueStructureBuilder<>(jedis, clazz);
// 	}
// 
// 	public static RankingStructureBuilder ofRanking(Jedis jedis) {
// 		Objects.requireNonNull(jedis);
// 		return new RankingStructureBuilder(jedis);
// 	}
// 
// }
// 
// Path: src/test/java/redis/clients/collections/model/Species.java
// public class Species implements Serializable {
// 
// 	private static final long serialVersionUID = -1493508757572337719L;
// 	
// 	private List<String> animals;
// 
// 	public Species(String... animals) {
// 		this.animals = Arrays.asList(animals);
// 	}
// 
// 	public List<String> getAnimals() {
// 		return animals;
// 	}
// 	public void setAnimals(List<String> animals) {
// 		this.animals = animals;
// 	}
// 	
// }
// 
// Path: src/test/java/redis/clients/collections/util/RedisConnection.java
// public class RedisConnection {
// 
// 	public static final Jedis JEDIS;
// 	
// 	static{
// 	 JEDIS = new Jedis("localhost");
// 	}
// }


// Path: src/test/java/redis/clients/collections/MapStructureTest.java
import java.util.Collection;
import java.util.HashMap;
import java.util.Map;
import java.util.Set;
import junit.framework.Assert;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import redis.clients.collections.MapStructure;
import redis.clients.collections.builder.RedisStrutureBuilder;
import redis.clients.collections.model.Species;
import redis.clients.collections.util.RedisConnection;

package redis.clients.collections;





public class MapStructureTest {

	private MapStructure<Species> zoo;
	
	private Species mammals = new Species("lion", "cow", "dog");
	private Species fishes = new Species("redfish", "glassfish");
	private Species amphibians = new Species("crododile", "frog");
	
	@Before
	public void init() {
		zoo = RedisStrutureBuilder.ofMap(RedisConnection.JEDIS, Species.class).withNameSpace("animalZoo").build();
	}
	
	@Test
	public void shouldPutAndGetMap() {
		Map<String, Species> vertebrates = zoo.get("vertebrates");
		Assert.assertTrue(vertebrates.isEmpty());
		Assert.assertNotNull(vertebrates.put("mammals", mammals));
		Species species = vertebrates.get("mammals");
		Assert.assertNotNull(species);
		Assert.assertEquals(species.getAnimals().get(0), mammals.getAnimals().get(0));
		Assert.assertTrue(vertebrates.size() == 1);
	}
	
	@Test
	public void shouldVerifyExist() {
		Map<String, Species> vertebrates = zoo.get("vertebrates");