Package io.jmix.masquerade.component
Class RangeSlider
- All Implemented Interfaces:
SpecificConditionHandler,ByLocator,SelenideElementWrapper<RangeSlider>
Web-element wrapper for range slider. Also, can be used for wrapping range-slider-like web-elements:
integerRangeSlider, decimalRangeSlider. Supports setting start and end values and
RangeValue condition checking.
A range slider has two values, so the Value and ValueContains conditions are not supported:
use the RangeValue condition to check both range bounds.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final intprotected static final intFields inherited from class io.jmix.masquerade.component.AbstractComponent
by, wrappedElement -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected com.codeborne.selenide.SelenideElementprotected Stringprotected com.codeborne.selenide.SelenideElementgetInputDelegate(int index) protected com.codeborne.selenide.SelenideElementprotected Stringprotected booleanisAboveCurrentEndValue(String startValue) resolve(SpecificCondition condition) Resolves the passedSpecificConditioninto aSpecificCheckthat describes how it must be checked for the current handler.setEndValue(String value) Sets the end value to the range slider.setStartValue(String value) Sets the start value to the range slider.Sets the start and end values to the range slider.Methods inherited from class io.jmix.masquerade.component.AbstractSlider
setValueInternalMethods inherited from class io.jmix.masquerade.component.AbstractField
getInputDelegate, getLabelDelegateMethods inherited from class io.jmix.masquerade.component.AbstractComponent
getBy, getDelegateMethods inherited from class io.jmix.masquerade.component.AbstractSpecificConditionHandler
should, should, shouldBe, shouldBe, shouldHave, shouldHave, shouldNot, shouldNot, shouldNotBe, shouldNotBe, shouldNotHave, shouldNotHaveMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.jmix.masquerade.sys.SelenideElementWrapper
disabled, displayed, enabled, exists, shouldHaveAttribute, shouldHaveAttributeValue, shouldHaveCss, shouldHaveCssValue, shouldNotHaveAttribute, shouldNotHaveAttributeValue, shouldNotHaveCss, shouldNotHaveCssValue
-
Field Details
-
START_INPUT_INDEX
protected static final int START_INPUT_INDEX- See Also:
-
END_INPUT_INDEX
protected static final int END_INPUT_INDEX- See Also:
-
-
Constructor Details
-
RangeSlider
public RangeSlider(org.openqa.selenium.By by)
-
-
Method Details
-
resolve
Description copied from interface:SpecificConditionHandlerResolves the passedSpecificConditioninto aSpecificCheckthat describes how it must be checked for the current handler. The actual verdict is computed centrally bySpecificCondition.check(com.codeborne.selenide.Driver, org.openqa.selenium.WebElement).- Specified by:
resolvein interfaceSpecificConditionHandler- Overrides:
resolvein classAbstractField<RangeSlider>- Parameters:
condition- condition to resolve- Returns:
- a
SpecificCheckdescribing how to check the passed condition
-
setValue
Sets the start and end values to the range slider.A range slider limits its start value by the current end value and vice versa, so the bounds are set in the order that keeps the intermediate range valid.
- Parameters:
startValue- start value as a string presentation valueendValue- end value as a string presentation value- Returns:
thisto call fluent API
-
setStartValue
Sets the start value to the range slider. The value is limited by the current end value.- Parameters:
value- start value as a string presentation value- Returns:
thisto call fluent API
-
setEndValue
Sets the end value to the range slider. The value is limited by the current start value.- Parameters:
value- end value as a string presentation value- Returns:
thisto call fluent API
-
isAboveCurrentEndValue
-
getStartValue
-
getEndValue
-
getStartInputDelegate
protected com.codeborne.selenide.SelenideElement getStartInputDelegate()- Returns:
SelenideElementof a start value input web-element
-
getEndInputDelegate
protected com.codeborne.selenide.SelenideElement getEndInputDelegate()- Returns:
SelenideElementof an end value input web-element
-
getInputDelegate
protected com.codeborne.selenide.SelenideElement getInputDelegate(int index)
-