PageRenderTime 757ms CodeModel.GetById 22ms RepoModel.GetById 0ms app.codeStats 0ms

/QingTingFanBianYi/src/com/alibaba/fastjson/serializer/ByteArraySerializer.java

https://gitlab.com/qt-prometheus/qt-prometheus
Java | 32 lines | 24 code | 4 blank | 4 comment | 3 complexity | 16426769734d88efa9a6ab170a2b8a0f MD5 | raw file
  1. package com.alibaba.fastjson.serializer;
  2. import java.io.IOException;
  3. import java.lang.reflect.Type;
  4. public class ByteArraySerializer
  5. implements ObjectSerializer
  6. {
  7. public static ByteArraySerializer instance = new ByteArraySerializer();
  8. public final void write(JSONSerializer paramJSONSerializer, Object paramObject1, Object paramObject2, Type paramType)
  9. throws IOException
  10. {
  11. paramJSONSerializer = paramJSONSerializer.getWriter();
  12. if (paramObject1 == null)
  13. {
  14. if (paramJSONSerializer.isEnabled(SerializerFeature.WriteNullListAsEmpty))
  15. {
  16. paramJSONSerializer.write("[]");
  17. return;
  18. }
  19. paramJSONSerializer.writeNull();
  20. return;
  21. }
  22. paramJSONSerializer.writeByteArray((byte[])paramObject1);
  23. }
  24. }
  25. /* Location: C:\Users\User\dex2jar-2.0\dex\qting\classes-dex2jar.jar
  26. * Qualified Name: com.alibaba.fastjson.serializer.ByteArraySerializer
  27. * JD-Core Version: 0.6.2
  28. */