public class ClientIp extends AbstractModel
Constructor and Description |
---|
ClientIp() |
ClientIp(ClientIp source)
NOTE: Any ambiguous key set via .set("AnyKey", "value") will be a shallow copy,
and any explicit key, i.e Foo, set via .setFoo("value") will be a deep copy.
|
Modifier and Type | Method and Description |
---|---|
String |
getHeaderName()
Get 回源时,存放客户端IP的请求头名称。
为空则使用默认值:X-Forwarded-IP。
注意:此字段可能返回 null,表示取不到有效值。
|
String |
getSwitch()
Get 配置开关,取值有:
on:开启;
off:关闭。
|
void |
setHeaderName(String HeaderName)
Set 回源时,存放客户端IP的请求头名称。
为空则使用默认值:X-Forwarded-IP。
注意:此字段可能返回 null,表示取不到有效值。
|
void |
setSwitch(String Switch)
Set 配置开关,取值有:
on:开启;
off:关闭。
|
void |
toMap(HashMap<String,String> map,
String prefix)
Internal implementation, normal users should not use it.
|
any, fromJsonString, getBinaryParams, getMultipartRequestParams, set, setParamArrayObj, setParamArraySimple, setParamObj, setParamSimple, toJsonString
public ClientIp()
public ClientIp(ClientIp source)
public String getSwitch()
public void setSwitch(String Switch)
Switch
- 配置开关,取值有:
public String getHeaderName()
public void setHeaderName(String HeaderName)
HeaderName
- 回源时,存放客户端IP的请求头名称。
为空则使用默认值:X-Forwarded-IP。
注意:此字段可能返回 null,表示取不到有效值。Copyright © 2022. All rights reserved.