+ and even more javadocs
This commit is contained in:
@@ -16,14 +16,26 @@
|
||||
package org.springframework.data.keyvalue.redis.serializer;
|
||||
|
||||
/**
|
||||
* Basic interface serialization and deserialization of Objects to byte arrays.
|
||||
* Basic interface serialization and deserialization of Objects to byte arrays (binary data).
|
||||
*
|
||||
* @author Mark Pollack
|
||||
* @author Costin Leau
|
||||
*/
|
||||
public interface RedisSerializer<T> {
|
||||
|
||||
/**
|
||||
* Serialize the given object to binary data.
|
||||
*
|
||||
* @param t object to serialize
|
||||
* @return the equivalent binary data
|
||||
*/
|
||||
byte[] serialize(T t);
|
||||
|
||||
/**
|
||||
* Deserialize an object from the given binary data.
|
||||
*
|
||||
* @param bytes object binary representation
|
||||
* @return the equivalent object instance
|
||||
*/
|
||||
T deserialize(byte[] bytes);
|
||||
}
|
||||
|
||||
@@ -21,7 +21,7 @@ import org.springframework.core.serializer.support.SerializingConverter;
|
||||
import org.springframework.data.keyvalue.redis.UncategorizedRedisException;
|
||||
|
||||
/**
|
||||
* Simple Redis serializer delegating to the default serializer in Spring 3.
|
||||
* Simple Redis serializer delegating to the default (Java based) serializer in Spring 3.
|
||||
*
|
||||
* @author Mark Pollack
|
||||
* @author Costin Leau
|
||||
|
||||
@@ -18,8 +18,10 @@ package org.springframework.data.keyvalue.redis.serializer;
|
||||
import java.nio.charset.Charset;
|
||||
|
||||
/**
|
||||
* Simple String to byte[] (and back) serializer. Relies on the specified charset
|
||||
* to properly convert the String into bytes and vice-versa.
|
||||
* Simple String to byte[] (and back) serializer. Relies on the specified charset
|
||||
* (by default UTF-8) to properly convert the String into bytes and vice-versa.
|
||||
*
|
||||
* Useful when the interaction with the Redis happens mainly through Strings.
|
||||
*
|
||||
* @author Costin Leau
|
||||
*/
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
/**
|
||||
* Serialization/Deserialization package for converting Object to (and from) binary data.
|
||||
*/
|
||||
package org.springframework.data.keyvalue.redis.serializer;
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
/**
|
||||
* Small toolkit mirroring the {@code java.util.atomic} package in Redis.
|
||||
*/
|
||||
package org.springframework.data.keyvalue.redis.support.atomic;
|
||||
@@ -22,6 +22,7 @@ import java.util.List;
|
||||
|
||||
/**
|
||||
* Utility class used mainly for type conversion by the default collection implementations.
|
||||
* Meant for internal use.
|
||||
*
|
||||
* @author Costin Leau
|
||||
*/
|
||||
|
||||
@@ -28,6 +28,8 @@ import org.springframework.data.keyvalue.redis.core.RedisOperations;
|
||||
|
||||
/**
|
||||
* Default implementation for {@link RedisList}.
|
||||
* Suitable for not just lists, but also queues (FIFO ordering) or stacks (LIFO ordering) and deques
|
||||
* (or double ended queues).
|
||||
*
|
||||
* Allows the maximum size (or the cap) to be specified to prevent the list from over growing.
|
||||
*
|
||||
|
||||
@@ -15,13 +15,14 @@
|
||||
*/
|
||||
package org.springframework.data.keyvalue.redis.support.collections;
|
||||
|
||||
import java.util.Deque;
|
||||
import java.util.List;
|
||||
import java.util.Queue;
|
||||
import java.util.concurrent.BlockingDeque;
|
||||
|
||||
/**
|
||||
* Redis extension for the {@link List} contract. Supports {@link List} and {@link Queue} specific
|
||||
* operations backed by Redis operations.
|
||||
* Redis extension for the {@link List} contract. Supports {@link List}, {@link Queue} and {@link Deque} contracts
|
||||
* as well as their equivalent blocking siblings {@link BlockingDeque} and {@link BlockingDeque}.
|
||||
*
|
||||
* @author Costin Leau
|
||||
*/
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* Package providing implementations for most of the {@code java.util} collections on top of Redis.
|
||||
* <p/>
|
||||
* For indexed collections, such as {@link java.util.List}, {@link java.util.Queue} or {@link java.util.Deque}
|
||||
* consider {@link RedisList}.<p/>
|
||||
* For collections without duplicates the obvious candidate is {@link RedisSet}. Use {@link RedisZSet} if a
|
||||
* certain order is required.</p/>
|
||||
* Lastly, for key/value associations {@link RedisMap} providing a Map-like abstraction on top of a Redis hash.
|
||||
*/
|
||||
package org.springframework.data.keyvalue.redis.support.collections;
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
/**
|
||||
* Classes supporting the Redis packages, such as collection or atomic counters.
|
||||
*/
|
||||
package org.springframework.data.keyvalue.redis.support;
|
||||
|
||||
Reference in New Issue
Block a user