Record Class ProtoSchema.Method

java.lang.Object
java.lang.Record
org.microproxy.contentviews.ProtoSchema.Method
Record Components:
service - the service's full name, such as example.Shop
name - the method's name
inputType - the request message type's full name
outputType - the response message type's full name
clientStreaming - whether the client sends a stream of messages
serverStreaming - whether the server sends a stream of messages
Enclosing class:
ProtoSchema

public static record ProtoSchema.Method(String service, String name, String inputType, String outputType, boolean clientStreaming, boolean serverStreaming) extends Record
An RPC method of a service.
  • Constructor Details

    • Method

      public Method(String service, String name, String inputType, String outputType, boolean clientStreaming, boolean serverStreaming)
      Creates an instance of a Method record class.
      Parameters:
      service - the value for the service record component
      name - the value for the name record component
      inputType - the value for the inputType record component
      outputType - the value for the outputType record component
      clientStreaming - the value for the clientStreaming record component
      serverStreaming - the value for the serverStreaming record component
  • Method Details

    • path

      public String path()
      Returns the gRPC request path, /<service>/<method>.
      Returns:
      the gRPC request path, /<service>/<method>
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • service

      public String service()
      Returns the value of the service record component.
      Returns:
      the value of the service record component
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • inputType

      public String inputType()
      Returns the value of the inputType record component.
      Returns:
      the value of the inputType record component
    • outputType

      public String outputType()
      Returns the value of the outputType record component.
      Returns:
      the value of the outputType record component
    • clientStreaming

      public boolean clientStreaming()
      Returns the value of the clientStreaming record component.
      Returns:
      the value of the clientStreaming record component
    • serverStreaming

      public boolean serverStreaming()
      Returns the value of the serverStreaming record component.
      Returns:
      the value of the serverStreaming record component