类 OkHttpTransport.Builder

java.lang.Object
io.agentscope.core.model.transport.OkHttpTransport.Builder
封闭类:
OkHttpTransport

public static class OkHttpTransport.Builder extends Object
Builder for OkHttpTransport.
  • 构造器详细资料

    • Builder

      public Builder()
  • 方法详细资料

    • config

      Set the transport configuration.
      参数:
      config - the configuration
      返回:
      this builder
    • client

      public OkHttpTransport.Builder client(okhttp3.OkHttpClient client)
      Use an existing OkHttpClient instance.

      When set, the configuration will only be used for reference, and the provided client will be used as-is.

      参数:
      client - the existing OkHttpClient
      返回:
      this builder
    • build

      public OkHttpTransport build()
      Build the OkHttpTransport.
      返回:
      a new OkHttpTransport instance