Class UrlReplaceHandlerOption
java.lang.Object
com.microsoft.kiota.http.middleware.options.UrlReplaceHandlerOption
- All Implemented Interfaces:
com.microsoft.kiota.RequestOption
The options to be passed to the UrlReplaceHandler.
Defines the replacement pairs and whether the handler is enabled or not.
-
Constructor Summary
ConstructorsConstructorDescriptionInstantiates a new UrlReplaceOption with an empty replacementPairs map and enabled set to true.UrlReplaceHandlerOption(Map<String, String> replacementPairs) Instantiates a new UrlReplaceOption with the specified replacementPairs map and enabled set to true.UrlReplaceHandlerOption(Map<String, String> replacementPairs, boolean enabled) Instantiates a new UrlReplaceOption with the specified replacementPairs map and enabled set to the specified value. -
Method Summary
Modifier and TypeMethodDescriptionvoiddisable()Disables the handler.voidenable()Enables the handler.Gets the replacement pairs map.<T extends com.microsoft.kiota.RequestOption>
Class<T> getType()booleanGets whether the handler is enabled or not.voidsetReplacementPairs(Map<String, String> replacementPairs) Sets the replacement pairs map.
-
Constructor Details
-
UrlReplaceHandlerOption
public UrlReplaceHandlerOption()Instantiates a new UrlReplaceOption with an empty replacementPairs map and enabled set to true. -
UrlReplaceHandlerOption
Instantiates a new UrlReplaceOption with the specified replacementPairs map and enabled set to true.- Parameters:
replacementPairs- the replacement pairs map.
-
UrlReplaceHandlerOption
Instantiates a new UrlReplaceOption with the specified replacementPairs map and enabled set to the specified value.- Parameters:
replacementPairs- the replacement pairs map.enabled- whether the handler is enabled or not.
-
-
Method Details
-
getReplacementPairs
Gets the replacement pairs map.- Returns:
- the replacement pairs map.
-
setReplacementPairs
Sets the replacement pairs map.- Parameters:
replacementPairs- the replacement pairs map.
-
enable
public void enable()Enables the handler. -
disable
public void disable()Disables the handler. -
isEnabled
public boolean isEnabled()Gets whether the handler is enabled or not.- Returns:
- whether the handler is enabled or not.
-
getType
- Specified by:
getTypein interfacecom.microsoft.kiota.RequestOption
-