Package io.micronaut.security.endpoints
Class LogoutControllerConfigurationProperties
java.lang.Object
io.micronaut.security.endpoints.LogoutControllerConfigurationProperties
- All Implemented Interfaces:
io.micronaut.core.util.Toggleable,ControllerConfiguration,LogoutControllerConfiguration
@Requires(property="micronaut.security.endpoints.logout.enabled",
notEquals="false",
defaultValue="true")
@ConfigurationProperties("micronaut.security.endpoints.logout")
public class LogoutControllerConfigurationProperties
extends Object
implements LogoutControllerConfiguration
Implementation of
LogoutControllerConfiguration used to configure the LogoutController.- Since:
- 1.0
- Author:
- Sergio del Amo
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@NonNull StringgetPath()booleanWhether the controller is enabled.booleanvoidsetEnabled(boolean enabled) EnablesLogoutController.voidsetGetAllowed(boolean getAllowed) Enables HTTP GET invocations ofLogoutController.voidPath to theLogoutController.voidsetPostContentTypes(Set<String> postContentTypes) Supported content types for POST endpoints.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.micronaut.security.endpoints.ControllerConfiguration
getPath, getPostContentTypesMethods inherited from interface io.micronaut.core.util.Toggleable
isEnabled
-
Field Details
-
PREFIX
- See Also:
-
DEFAULT_ENABLED
Deprecated, for removal: This API element is subject to removal in a future version.Not used.ControllerConfigurationProperties.DEFAULT_ENABLEDis used instead.The default enable value.- See Also:
-
DEFAULT_PATH
The default path.- See Also:
-
DEFAULT_GETALLOWED
public static final boolean DEFAULT_GETALLOWEDDefault Get Allowed.- See Also:
-
-
Constructor Details
-
LogoutControllerConfigurationProperties
public LogoutControllerConfigurationProperties()
-
-
Method Details
-
setEnabled
public void setEnabled(boolean enabled) EnablesLogoutController. Default value true.- Parameters:
enabled- true if it is
-
setPath
Path to theLogoutController. Default value "/logout".- Parameters:
path- The path
-
isGetAllowed
public boolean isGetAllowed()- Specified by:
isGetAllowedin interfaceLogoutControllerConfiguration- Returns:
- true if you want to support HTTP GET invocations in the
LogoutController.
-
setGetAllowed
public void setGetAllowed(boolean getAllowed) Enables HTTP GET invocations ofLogoutController. Default value (false).- Parameters:
getAllowed- Whether Http GET should be supported.
-
getPostContentTypes
- Specified by:
getPostContentTypesin interfaceControllerConfiguration- Returns:
- Supported HTTP methods for POST endpoints.
-
setPostContentTypes
Supported content types for POST endpoints. Default Value application/json and application/x-www-form-urlencoded- Parameters:
postContentTypes- supported content types for POST endpoints.
-
isEnabled
public boolean isEnabled()Whether the controller is enabled.- Specified by:
isEnabledin interfaceio.micronaut.core.util.Toggleable- Returns:
- Whether the controller is enabled.
-
getPath
- Specified by:
getPathin interfaceControllerConfiguration- Returns:
- the path where the controller is enabled.
-