Package io.github.easy4j.opencode
Enum Class HttpResponseMode
- All Implemented Interfaces:
Serializable,Comparable<HttpResponseMode>,Constable
HTTP 对话响应模式。
- Since:
- 1.0.0
- Author:
- Loong Wan
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionstatic HttpResponseModeReturns the enum constant of this class with the specified name.static HttpResponseMode[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
BLOCKING
等待响应体完整读取后再返回,适用于普通同步 REST 调用。 -
STREAM
保持响应连接并逐段消费数据,适用于 SSE 或其他流式响应。 -
AUTO
由具体 API 根据端点类型自动选择缓冲或流式模式。
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-