public class L10Nparser
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static java.util.Locale |
actualLocale |
static java.lang.String |
assertErrorMsg |
protected static int |
BASIC_WAIT_SHORT_TIMEOUT |
protected static org.apache.log4j.Logger |
LOGGER |
static boolean |
newLocalization |
static java.util.LinkedList<java.lang.String> |
newLocList |
static java.util.Properties |
prop |
static java.lang.String |
propFileName |
| Constructor and Description |
|---|
L10Nparser() |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem)
check Localization Text.
|
static boolean |
checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem,
boolean skipMissed)
check Localization Text.
|
static boolean |
checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem,
boolean skipMissed,
int timeout,
boolean skipPunctuationAndNumbers)
check Localization Text.
|
static boolean |
checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem,
java.lang.String locKey)
check Localization Text.
|
static boolean |
checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem,
java.lang.String locKey,
int timeout,
boolean skipPunctuationAndNumbers)
check Localization Text.
|
static boolean |
checkLocalizationText(java.lang.String expectedText,
java.lang.String locKey,
boolean skipPunctuationAndNumbers)
check Localization Text
|
static boolean |
checkMultipleLocalization(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement[] localizationCheckList)
check MultipleLocalization
|
static boolean |
checkMultipleLocalization(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement[] localizationCheckList,
boolean skipPunctuationAndNumbers)
check MultipleLocalization
|
static boolean |
checkMultipleLocalization(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement[] localizationCheckList,
int timeout,
boolean skipPunctuationAndNumbers)
check MultipleLocalization
|
static java.util.Locale |
getActualLocale()
get Actual Locale
|
static java.lang.String |
getAssertErrorMsg()
get AssertErrorMsg
|
static boolean |
getNewLocalization()
should we add New Localization - true or false
|
static void |
init() |
static void |
saveLocalization()
Save Localization to property file
|
static void |
setActualLocale(java.util.Locale locale)
set Actual Locale
|
static void |
setActualLocale(java.util.Locale locale,
boolean updateConfig)
set Actual Locale
|
static void |
setActualLocale(java.lang.String countryCode)
set Actual Locale
|
protected static final org.apache.log4j.Logger LOGGER
public static java.util.Locale actualLocale
public static java.lang.String assertErrorMsg
public static boolean newLocalization
public static java.util.LinkedList<java.lang.String> newLocList
public static java.util.Properties prop
public static java.lang.String propFileName
protected static final int BASIC_WAIT_SHORT_TIMEOUT
public static void init()
public static java.util.Locale getActualLocale()
public static java.lang.String getAssertErrorMsg()
public static boolean getNewLocalization()
public static void setActualLocale(java.lang.String countryCode)
countryCode - Stringpublic static void setActualLocale(java.util.Locale locale)
locale - - Localepublic static void setActualLocale(java.util.Locale locale,
boolean updateConfig)
locale - - LocaleupdateConfig - - can be useful for updating config file just with actual
locale and be used separately on PageObject methods not only
in test classes.public static boolean checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem)
elem - ExtendedWebElementpublic static boolean checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem,
boolean skipMissed)
elem - ExtendedWebElementskipMissed - - boolean - if true - will ignore missed elements.public static boolean checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem,
boolean skipMissed,
int timeout,
boolean skipPunctuationAndNumbers)
elem - ExtendedWebElementskipMissed - - boolean - if true - will ignore missed elements.timeout - - timeout for element presence waiting.skipPunctuationAndNumbers - - if true - there will be no numbers and tricky punctuation in l10n valuespublic static boolean checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem,
java.lang.String locKey)
elem - ExtendedWebElementlocKey - Stringpublic static boolean checkLocalizationText(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement elem,
java.lang.String locKey,
int timeout,
boolean skipPunctuationAndNumbers)
elem - ExtendedWebElementlocKey - Stringtimeout - - timeout for element presence waiting.skipPunctuationAndNumbers - - if true - there will be no numbers and tricky punctuation in l10n valuespublic static boolean checkLocalizationText(java.lang.String expectedText,
java.lang.String locKey,
boolean skipPunctuationAndNumbers)
expectedText - StringlocKey - StringskipPunctuationAndNumbers - - if true - there will be no numbers and
tricky punctuation in l10n values and in checking.
As well as validation will be case insensitive.public static boolean checkMultipleLocalization(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement[] localizationCheckList)
localizationCheckList - - ExtendedWebElement[] should be set on required page with all
needed public elementspublic static boolean checkMultipleLocalization(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement[] localizationCheckList,
boolean skipPunctuationAndNumbers)
localizationCheckList - - ExtendedWebElement[] should be set on required page with all
needed public elementsskipPunctuationAndNumbers - - if true - there will be no numbers and tricky punctuation in l10n valuespublic static boolean checkMultipleLocalization(com.qaprosoft.carina.core.foundation.webdriver.decorator.ExtendedWebElement[] localizationCheckList,
int timeout,
boolean skipPunctuationAndNumbers)
localizationCheckList - - ExtendedWebElement[] should be set on required page with all
needed public elementstimeout - - timeout for element presence waiting.skipPunctuationAndNumbers - - if true - there will be no numbers and tricky punctuation in l10n valuespublic static void saveLocalization()
Copyright © 2018. All Rights Reserved.