Interface MessageFactory

  • All Known Implementing Classes:
    DynamicMessageFactory, MessageFactory.CombinedMessageFactory
    Functional Interface:
    This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

    @Immutable
    @FunctionalInterface
    @Deprecated
    public interface MessageFactory
    Deprecated.
    Do not use. Internally, ProtoMessageFactory should be used.
    The MessageFactory provides a method to create a protobuf builder objects by name.
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Interface Description
      static class  MessageFactory.CombinedMessageFactory
      Deprecated.
      The CombinedMessageFactory takes one or more MessageFactory instances and attempts to create a Message.Builder instance for a given messageName by calling each MessageFactory in the order that they are provided to the constructor.
    • Method Detail

      • newBuilder

        @Nullable Message.Builder newBuilder​(java.lang.String messageName)
        Deprecated.
        Create a Message.Builder instance for the protobuf by messageName.

        Returns null if the builder could not be created.

      • toProtoMessageFactory

        default ProtoMessageFactory toProtoMessageFactory()
        Deprecated.
        Exists only to maintain FunctionalInterface requirement and to make legacy Dynamic/Linked message factories compatible with the new ProtoMessageFactory.