パッケージ org.springframework.http

インターフェース RequestEntity.BodyBuilder

すべてのスーパーインターフェース:
RequestEntity.HeadersBuilder<RequestEntity.BodyBuilder>
含まれているクラス:
RequestEntity<T>

public static interface RequestEntity.BodyBuilder extends RequestEntity.HeadersBuilder<RequestEntity.BodyBuilder>
レスポンスエンティティに本文を追加するビルダーを定義します。
  • メソッドの詳細

    • contentLength

      RequestEntity.BodyBuilder contentLength(long contentLength)
      Content-Length ヘッダーで指定されているように、本文の長さをバイト単位で設定します。
      パラメーター:
      contentLength - コンテンツの長さ
      戻り値:
      このビルダー
      関連事項:
    • contentType

      RequestEntity.BodyBuilder contentType(MediaType contentType)
      Content-Type ヘッダーで指定されているように、本文のメディア型を設定します。
      パラメーター:
      contentType - コンテンツ型
      戻り値:
      このビルダー
      関連事項:
    • body

      <T> RequestEntity<T> body(T body)
      リクエストエンティティの本体を設定し、RequestEntity を構築します。
      型パラメーター:
      T - 体の種類
      パラメーター:
      body - リクエストエンティティの本体
      戻り値:
      構築されたリクエストエンティティ
    • body

      <T> RequestEntity<T> body(T body, TypeSE type)
      リクエストエンティティのボディと型を設定し、RequestEntity を構築します。
      型パラメーター:
      T - 体の種類
      パラメーター:
      body - リクエストエンティティの本体
      type - 汎用の型解決に役立つボディの型
      戻り値:
      構築されたリクエストエンティティ
      導入:
      4.3