Record Class PathContainer.Options
java.lang.Object
java.lang.Record
cn.taketoday.http.server.PathContainer.Options
- 封闭类:
- PathContainer
public static record PathContainer.Options(char separator, boolean decodeAndParseSegments)
extends Record
Options to customize parsing based on the type of input path.
-
字段概要
字段修饰符和类型字段说明private final booleandecodeAndParseSegments记录组件的字段。static final PathContainer.OptionsOptions for HTTP URL paths.static final PathContainer.OptionsOptions for a message route.private final charseparator记录组件的字段。 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static PathContainer.Optionscreate(char separator, boolean decodeAndParseSegments) Create anPathContainer.Optionsinstance with the given settings.boolean返回decodeAndParseSegments记录组件的值。final boolean指示某个其他对象是否“等于”此对象。final inthashCode()返回此对象的哈希代码值。char返回separator记录组件的值。booleanfinal StringtoString()返回此记录的字符串表示形式。
-
字段详细资料
-
separator
private final char separatorseparator记录组件的字段。 -
decodeAndParseSegments
private final boolean decodeAndParseSegmentsdecodeAndParseSegments记录组件的字段。 -
HTTP_PATH
Options for HTTP URL paths.Separator '/' with URL decoding and parsing of path parameters.
-
MESSAGE_ROUTE
Options for a message route.Separator '.' with neither URL decoding nor parsing of path parameters. Escape sequences for the separator character in segment values are still decoded.
-
-
构造器详细资料
-
Options
public Options(char separator, boolean decodeAndParseSegments) 创建Options记录的实例。- 参数:
separator-separator记录组件的值decodeAndParseSegments-decodeAndParseSegments记录组件的值
-
-
方法详细资料
-
shouldDecodeAndParseSegments
public boolean shouldDecodeAndParseSegments() -
create
Create anPathContainer.Optionsinstance with the given settings.- 参数:
separator- the separator for parsing the path into segments; currently this must be slash or dot.decodeAndParseSegments- whether to URL decode path segment values and parse path parameters. If set to false, only escape sequences for the separator char are decoded.
-
toString
返回此记录的字符串表示形式。此表示形式包含类型的名称,后跟每个记录组件的名称和值。 -
hashCode
public final int hashCode()返回此对象的哈希代码值。此值派生自每个记录组件的哈希代码。 -
equals
指示某个其他对象是否“等于”此对象。如果两个对象属于同一个类,而且所有记录组件都相等,则这两个对象相等。 此记录中的所有组件都使用 '==' 进行比较。 -
separator
public char separator()返回separator记录组件的值。- 返回:
separator记录组件的值
-
decodeAndParseSegments
public boolean decodeAndParseSegments()返回decodeAndParseSegments记录组件的值。- 返回:
decodeAndParseSegments记录组件的值
-