Exemplo n.º 1
0
 public object[] ReadValue(
     DataInput input,
     byte[] unitKey)
 {
     var notNull = input.ReadBoolean();
     return notNull ? DIOJsonSerdeHelper.ReadArray(input) : null;
 }
Exemplo n.º 2
0
 public void Write(
     object @object,
     DataOutput output,
     byte[] unitKey,
     EventBeanCollatedWriter writer)
 {
     DIOJsonSerdeHelper.WriteValue(@object, output);
 }
Exemplo n.º 3
0
 public void Write(
     object[] @object,
     DataOutput output,
     byte[] unitKey,
     EventBeanCollatedWriter writer)
 {
     output.WriteBoolean(@object != null);
     if (@object != null) {
         DIOJsonSerdeHelper.WriteArray(@object, output);
     }
 }
Exemplo n.º 4
0
        public IDictionary <string, object> Read(DataInput input)
        {
            var size = input.ReadInt();
            var map  = new LinkedHashMap <string, object>();

            for (var i = 0; i < size; i++)
            {
                var key   = input.ReadUTF();
                var value = DIOJsonSerdeHelper.ReadValue(input);
                map.Put(key, value);
            }

            return(map);
        }
Exemplo n.º 5
0
 public object Read(
     DataInput input,
     byte[] unitKey)
 {
     return DIOJsonSerdeHelper.ReadValue(input);
 }