private ObjectConverter chooseConverter(Class cls) {
        if (cls.equals(Float.class) || cls.equals(Double.class)) {
            throw new SerializationException("Float values should not be serialized!");
        } else if (Number.class.isAssignableFrom(cls)) {
            return numberConverter;
        } else if (CharSequence.class.isAssignableFrom(cls)
                || (cls.isArray() && byte.class.equals(cls.getComponentType()))) {
            return stringConverter;
        } else if (List.class.isAssignableFrom(cls) || cls.isArray()) {
            return listConverter;
        } else if (Map.class.isAssignableFrom(cls)) {
            return mapConverter;
        }
        return pojoConverter;
    }