/** return a serializer for a specific type */
public static <T> AbstractSerializer<T> serializerFor(Class<T> type) {
if (type == null)
throw new RuntimeException("serializable type cannot be null",
new SerializationException("serializable type cannot be null"));
else if (type.equals(String.class))
throw new RuntimeException("We don't serialize strings anymore",
new SerializationException("We don't serialize strings anymore"));
if (type.equals(BasicRollup.class))
return (AbstractSerializer<T>) basicRollupInstance;
else if (type.equals(TimerRollup.class))
return (AbstractSerializer<T>)timerRollupInstance;