@Test public void testMismatch() throws Exception { Marshaller<Enum> enumMarshaller = ProtoLiteUtils.marshaller(Enum.getDefaultInstance()); Enum altProto = Enum.newBuilder().setName(proto.getName()).build(); assertEquals(proto, marshaller.parse(enumMarshaller.stream(altProto))); }
public static <T extends MessageLite> Marshaller<T> marshaller(T defaultInstance) { return new MessageMarshaller<T>(defaultInstance); }
ProtoLiteUtils { public static <T extends MessageLite> Marshaller<T> marshaller(T defaultInstance) { return new MessageMarshaller<T>(defaultInstance); } }
ProtoLiteUtils { public static <T extends MessageLite> Marshaller<T> marshaller(T defaultInstance) { return new MessageMarshaller<T>(defaultInstance); } private  ProtoLiteUtils(); }
ProtoLiteUtils { public static <T extends MessageLite> Marshaller<T> marshaller(T defaultInstance) { return new MessageMarshaller<T>(defaultInstance); } private  ProtoLiteUtils(); @ExperimentalApi("https://github.com/grpc/grpc-java/issues/1787") static void setExtensionRegistry(ExtensionRegistryLite newRegistry); static Marshaller<T> marshaller(T defaultInstance); static Metadata.BinaryMarshaller<T> metadataMarshaller(
      T defaultInstance); }
ProtoLiteUtils { public static <T extends MessageLite> Marshaller<T> marshaller(T defaultInstance) { return new MessageMarshaller<T>(defaultInstance); } private  ProtoLiteUtils(); @ExperimentalApi("https://github.com/grpc/grpc-java/issues/1787") static void setExtensionRegistry(ExtensionRegistryLite newRegistry); static Marshaller<T> marshaller(T defaultInstance); static Metadata.BinaryMarshaller<T> metadataMarshaller(
      T defaultInstance);  }