com.alibaba.fastjson.support.spring

Class FastJsonRedisSerializer<T>

  • java.lang.Object
    • com.alibaba.fastjson.support.spring.FastJsonRedisSerializer<T>
  • All Implemented Interfaces:
    org.springframework.data.redis.serializer.RedisSerializer<T>

    public class FastJsonRedisSerializer<T>
    extends Object
    implements org.springframework.data.redis.serializer.RedisSerializer<T>
    RedisSerializer FastJson Impl
    Since:
    1.2.36
    Author:
    lihengming, Victor.Zxy
    • Constructor Detail

      • FastJsonRedisSerializer

        public FastJsonRedisSerializer(Class<T> type)
    • Method Detail

      • setFastJsonConfig

        public void setFastJsonConfig(FastJsonConfig fastJsonConfig)
      • serialize

        public byte[] serialize(T t)
                         throws org.springframework.data.redis.serializer.SerializationException
        Specified by:
        serialize in interface  org.springframework.data.redis.serializer.RedisSerializer<T>
        Throws:
        org.springframework.data.redis.serializer.SerializationException
      • deserialize

        public T deserialize(byte[] bytes)
                      throws org.springframework.data.redis.serializer.SerializationException
        Specified by:
        deserialize in interface  org.springframework.data.redis.serializer.RedisSerializer<T>
        Throws:
        org.springframework.data.redis.serializer.SerializationException

Copyright © 2012–2021 Alibaba Group. All rights reserved.