Package org.infinispan.protostream.impl

Examples of org.infinispan.protostream.impl.ProtobufReaderImpl


      writeTo(ctx, baos, t);
      return baos.toByteArray();
   }

   public static <A> A readFrom(SerializationContext ctx, CodedInputStream in, Class<A> clazz) throws IOException {
      ProtobufReaderImpl reader = new ProtobufReaderImpl(ctx);
      return reader.read(in, clazz);
   }
View Full Code Here


      if (messageBytes != null) {
         MessageMarshaller marshaller = ctx.getMarshaller(descriptorFullName);
         ByteArrayInputStream bais2 = new ByteArrayInputStream(messageBytes);
         CodedInputStream in2 = CodedInputStream.newInstance(bais2);
         ProtobufReaderImpl reader = new ProtobufReaderImpl(ctx);
         return reader.read(in2, marshaller);
      } else {
         EnumEncoder<? extends Enum> enumEncoder = ctx.getEnumEncoder(descriptorFullName);
         return enumEncoder.decode(enumValue);
      }
   }
View Full Code Here

      writeTo(ctx, baos, t);
      return baos.toByteArray();
   }

   public static <A> A readFrom(SerializationContext ctx, CodedInputStream in, Class<A> clazz) throws IOException {
      ProtobufReaderImpl reader = new ProtobufReaderImpl(ctx);
      return reader.read(in, clazz);
   }
View Full Code Here

      if (messageBytes != null) {
         MessageMarshaller marshaller = ctx.getMarshaller(descriptorFullName);
         ByteArrayInputStream bais2 = new ByteArrayInputStream(messageBytes);
         CodedInputStream in2 = CodedInputStream.newInstance(bais2);
         ProtobufReaderImpl reader = new ProtobufReaderImpl(ctx);
         return reader.read(in2, marshaller);
      } else {
         EnumEncoder<? extends Enum> enumEncoder = ctx.getEnumEncoder(descriptorFullName);
         return enumEncoder.decode(enumValue);
      }
   }
View Full Code Here

TOP

Related Classes of org.infinispan.protostream.impl.ProtobufReaderImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.