Enum Class SecurityHeaders.ReferrerPolicy
java.lang.Object
java.lang.Enum<SecurityHeaders.ReferrerPolicy>
cloud.opencode.base.web.security.SecurityHeaders.ReferrerPolicy
- All Implemented Interfaces:
Serializable, Comparable<SecurityHeaders.ReferrerPolicy>, Constable
- Enclosing class:
SecurityHeaders
Referrer-Policy header values.
Referrer-Policy 头部值。
- Since:
- JDK 25, opencode-base-web V1.0.3
- Author:
- Leon Soo www.LeonSoo.com
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionNo referrer information is sent - 不发送来源信息Referrer sent for same-protocol navigations - 同协议导航时发送来源Only the origin is sent as referrer - 仅发送来源域Full URL for same-origin, origin for cross-origin - 同源发送完整 URL,跨域仅发送来源域Full URL for same-origin, no referrer for cross-origin - 同源发送完整 URL,跨域不发送Origin for cross-origin HTTPS requests only - 仅跨域 HTTPS 请求发送来源域Full URL for same-origin, origin for secure cross-origin - 同源发送完整 URL,安全跨域发送来源域Full URL always - 始终发送完整 URL -
Method Summary
Modifier and TypeMethodDescriptionvalue()Returns the header value.Returns the enum constant of this class with the specified name.static SecurityHeaders.ReferrerPolicy[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
NO_REFERRER
No referrer information is sent - 不发送来源信息 -
NO_REFERRER_WHEN_DOWNGRADE
Referrer sent for same-protocol navigations - 同协议导航时发送来源 -
ORIGIN
Only the origin is sent as referrer - 仅发送来源域 -
ORIGIN_WHEN_CROSS_ORIGIN
Full URL for same-origin, origin for cross-origin - 同源发送完整 URL,跨域仅发送来源域 -
SAME_ORIGIN
Full URL for same-origin, no referrer for cross-origin - 同源发送完整 URL,跨域不发送 -
STRICT_ORIGIN
Origin for cross-origin HTTPS requests only - 仅跨域 HTTPS 请求发送来源域 -
STRICT_ORIGIN_WHEN_CROSS_ORIGIN
Full URL for same-origin, origin for secure cross-origin - 同源发送完整 URL,安全跨域发送来源域 -
UNSAFE_URL
Full URL always - 始终发送完整 URL
-
-
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
-
value
-