类 AbstractEndpoint<T>
- java.lang.Object
- org.springframework.boot.actuate.endpoint.AbstractEndpoint<T>
- 类型参数:
T
- the endpoint data type
- 所有已实现的接口:
org.springframework.beans.factory.Aware
,Endpoint<T>
,org.springframework.context.EnvironmentAware
- 直接已知子类:
AutoConfigurationReportEndpoint
,BeansEndpoint
,ConfigurationPropertiesReportEndpoint
,DumpEndpoint
,EnvironmentEndpoint
,FlywayEndpoint
,HealthEndpoint
,InfoEndpoint
,LiquibaseEndpoint
,LoggersEndpoint
,MetricsEndpoint
,RequestMappingEndpoint
,ShutdownEndpoint
,TraceEndpoint
public abstract class AbstractEndpoint<T> extends Object implements Endpoint<T>, org.springframework.context.EnvironmentAware
Abstract base forEndpoint
implementations.
构造器概要
构造器 构造器 说明 AbstractEndpoint(String id)
Create a new sensitive endpoint instance.AbstractEndpoint(String id, boolean sensitive)
Create a new endpoint instance.AbstractEndpoint(String id, boolean sensitive, boolean enabled)
Create a new endpoint instance.
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 protected org.springframework.core.env.Environment
getEnvironment()
String
getId()
The logical ID of the endpoint.boolean
isEnabled()
Return if the endpoint is enabled.boolean
isSensitive()
Return if the endpoint is sensitive, i.e. may return data that the average user should not see.void
setEnabled(Boolean enabled)
void
setEnvironment(org.springframework.core.env.Environment environment)
void
setId(String id)
void
setSensitive(Boolean sensitive)
构造器详细资料
AbstractEndpoint
public AbstractEndpoint(String id)
Create a new sensitive endpoint instance. The endpoint will enabled flag will be based on the springEnvironment
unless explicitly set.- 参数:
id
- the endpoint ID
AbstractEndpoint
public AbstractEndpoint(String id, boolean sensitive)
Create a new endpoint instance. The endpoint will enabled flag will be based on the springEnvironment
unless explicitly set.- 参数:
id
- the endpoint IDsensitive
- if the endpoint is sensitive by default
AbstractEndpoint
public AbstractEndpoint(String id, boolean sensitive, boolean enabled)
Create a new endpoint instance.- 参数:
id
- the endpoint IDsensitive
- if the endpoint is sensitiveenabled
- if the endpoint is enabled or not.
方法详细资料
getEnvironment
protected final org.springframework.core.env.Environment getEnvironment()
setEnvironment
public void setEnvironment(org.springframework.core.env.Environment environment)
- 指定者:
setEnvironment
在接口中org.springframework.context.EnvironmentAware
getId
public String getId()
从接口复制的说明:Endpoint
The logical ID of the endpoint. Must only contain simple letters, numbers and '_' characters (i.e. a "\w" regex).
setEnabled
public void setEnabled(Boolean enabled)
isSensitive
public boolean isSensitive()
从接口复制的说明:Endpoint
Return if the endpoint is sensitive, i.e. may return data that the average user should not see. Mappings can use this as a security hint.- 指定者:
isSensitive
在接口中Endpoint<T>
- 返回:
- if the endpoint is sensitive
setSensitive
public void setSensitive(Boolean sensitive)