Class NeoAddressTriggerField
java.lang.Object
com.onenetwork.platform.tools.test.ui.neo.components.NeoComponent
com.onenetwork.platform.tools.test.ui.neo.components.NeoAddressTriggerField
public class NeoAddressTriggerField extends NeoComponent
This class represents the NeoAddressTrigger Field of the React UI
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
COMPONENT_NAME
protected org.openqa.selenium.WebElement
popUpButton
Fields inherited from class com.onenetwork.platform.tools.test.ui.neo.components.NeoComponent
context, driver, element
-
Constructor Summary
Constructors Constructor Description NeoAddressTriggerField(NeoUIContext context, org.openqa.selenium.WebElement element)
Initializes the context, element and popUpButton of the address field -
Method Summary
Modifier and Type Method Description java.lang.String
getLabel()
org.json.JSONObject
getValue()
This method returns theJSONObject
containing the different address components Return JSONObject likeboolean
isDisabled()
void
openAddressPopup()
void
setAddress(org.json.JSONObject address)
void
setAddressUsingControls(org.json.JSONObject address)
This method sets the address of supplied in the parameterJSONObject
Returns jsonObject as below:void
setLabel(java.lang.String label)
Methods inherited from class com.onenetwork.platform.tools.test.ui.neo.components.NeoComponent
getEl, getFieldErrorMessage, getTooltipMessage, isDisplayed, setMultipleValues, setValue
-
Field Details
-
COMPONENT_NAME
public static final java.lang.String COMPONENT_NAME- See Also:
- Constant Field Values
-
popUpButton
protected org.openqa.selenium.WebElement popUpButton
-
-
Constructor Details
-
NeoAddressTriggerField
Initializes the context, element and popUpButton of the address field- Parameters:
context
-element
-
-
-
Method Details
-
openAddressPopup
public void openAddressPopup() -
isDisabled
public boolean isDisabled() -
getLabel
public java.lang.String getLabel()- Returns:
- the label
-
setLabel
public void setLabel(java.lang.String label)- Parameters:
label
- the label to set
-
getValue
public org.json.JSONObject getValue()This method returns theJSONObject
containing the different address components Return JSONObject like{ "ZIP":"48795" or "POSTAL_CODE":"48795", "STREET1":"Line1 Value", "STREET2":"Line2 Value", "STREET3":"Line3 Value", "STATE:"AA", "COUNTRY":"US", "CITY":"City Name" }
- Returns:
JSONObject
-
setAddressUsingControls
public void setAddressUsingControls(org.json.JSONObject address)This method sets the address of supplied in the parameterJSONObject
Returns jsonObject as below:{ "ZIP":"48795" or "POSTAL_CODE":"48795", "STREET1":"Line1 Value", "STREET2":"Line2 Value", "STREET3":"Line3 Value", "STATE":"AA", "COUNTRY":"US", "CITY":"City Name" }
- Parameters:
address
-
-
setAddress
public void setAddress(org.json.JSONObject address)
-