Package com.adyen.model.payment
Class BrowserInfo
- java.lang.Object
-
- com.adyen.model.payment.BrowserInfo
-
public class BrowserInfo extends Object
BrowserInfo
-
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_ACCEPT_HEADERstatic StringJSON_PROPERTY_COLOR_DEPTHstatic StringJSON_PROPERTY_JAVA_ENABLEDstatic StringJSON_PROPERTY_JAVA_SCRIPT_ENABLEDstatic StringJSON_PROPERTY_LANGUAGEstatic StringJSON_PROPERTY_SCREEN_HEIGHTstatic StringJSON_PROPERTY_SCREEN_WIDTHstatic StringJSON_PROPERTY_TIME_ZONE_OFFSETstatic StringJSON_PROPERTY_USER_AGENT
-
Constructor Summary
Constructors Constructor Description BrowserInfo()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description BrowserInfoacceptHeader(String acceptHeader)The accept header value of the shopper's browser.BrowserInfocolorDepth(Integer colorDepth)The color depth of the shopper's browser in bits per pixel.booleanequals(Object o)Return true if this BrowserInfo object is equal to o.static BrowserInfofromJson(String jsonString)Create an instance of BrowserInfo given an JSON stringStringgetAcceptHeader()The accept header value of the shopper's browser.IntegergetColorDepth()The color depth of the shopper's browser in bits per pixel.BooleangetJavaEnabled()Boolean value indicating if the shopper's browser is able to execute Java.BooleangetJavaScriptEnabled()Boolean value indicating if the shopper's browser is able to execute JavaScript.StringgetLanguage()The `navigator.language` value of the shopper's browser (as defined in IETF BCP 47).IntegergetScreenHeight()The total height of the shopper's device screen in pixels.IntegergetScreenWidth()The total width of the shopper's device screen in pixels.IntegergetTimeZoneOffset()Time difference between UTC time and the shopper's browser local time, in minutes.StringgetUserAgent()The user agent value of the shopper's browser.inthashCode()BrowserInfojavaEnabled(Boolean javaEnabled)Boolean value indicating if the shopper's browser is able to execute Java.BrowserInfojavaScriptEnabled(Boolean javaScriptEnabled)Boolean value indicating if the shopper's browser is able to execute JavaScript.BrowserInfolanguage(String language)The `navigator.language` value of the shopper's browser (as defined in IETF BCP 47).BrowserInfoscreenHeight(Integer screenHeight)The total height of the shopper's device screen in pixels.BrowserInfoscreenWidth(Integer screenWidth)The total width of the shopper's device screen in pixels.voidsetAcceptHeader(String acceptHeader)The accept header value of the shopper's browser.voidsetColorDepth(Integer colorDepth)The color depth of the shopper's browser in bits per pixel.voidsetJavaEnabled(Boolean javaEnabled)Boolean value indicating if the shopper's browser is able to execute Java.voidsetJavaScriptEnabled(Boolean javaScriptEnabled)Boolean value indicating if the shopper's browser is able to execute JavaScript.voidsetLanguage(String language)The `navigator.language` value of the shopper's browser (as defined in IETF BCP 47).voidsetScreenHeight(Integer screenHeight)The total height of the shopper's device screen in pixels.voidsetScreenWidth(Integer screenWidth)The total width of the shopper's device screen in pixels.voidsetTimeZoneOffset(Integer timeZoneOffset)Time difference between UTC time and the shopper's browser local time, in minutes.voidsetUserAgent(String userAgent)The user agent value of the shopper's browser.BrowserInfotimeZoneOffset(Integer timeZoneOffset)Time difference between UTC time and the shopper's browser local time, in minutes.StringtoJson()Convert an instance of BrowserInfo to an JSON stringStringtoString()BrowserInfouserAgent(String userAgent)The user agent value of the shopper's browser.
-
-
-
Field Detail
-
JSON_PROPERTY_ACCEPT_HEADER
public static final String JSON_PROPERTY_ACCEPT_HEADER
- See Also:
- Constant Field Values
-
JSON_PROPERTY_COLOR_DEPTH
public static final String JSON_PROPERTY_COLOR_DEPTH
- See Also:
- Constant Field Values
-
JSON_PROPERTY_JAVA_ENABLED
public static final String JSON_PROPERTY_JAVA_ENABLED
- See Also:
- Constant Field Values
-
JSON_PROPERTY_JAVA_SCRIPT_ENABLED
public static final String JSON_PROPERTY_JAVA_SCRIPT_ENABLED
- See Also:
- Constant Field Values
-
JSON_PROPERTY_LANGUAGE
public static final String JSON_PROPERTY_LANGUAGE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_SCREEN_HEIGHT
public static final String JSON_PROPERTY_SCREEN_HEIGHT
- See Also:
- Constant Field Values
-
JSON_PROPERTY_SCREEN_WIDTH
public static final String JSON_PROPERTY_SCREEN_WIDTH
- See Also:
- Constant Field Values
-
JSON_PROPERTY_TIME_ZONE_OFFSET
public static final String JSON_PROPERTY_TIME_ZONE_OFFSET
- See Also:
- Constant Field Values
-
JSON_PROPERTY_USER_AGENT
public static final String JSON_PROPERTY_USER_AGENT
- See Also:
- Constant Field Values
-
-
Method Detail
-
acceptHeader
public BrowserInfo acceptHeader(String acceptHeader)
The accept header value of the shopper's browser.- Parameters:
acceptHeader-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getAcceptHeader
public String getAcceptHeader()
The accept header value of the shopper's browser.- Returns:
- acceptHeader
-
setAcceptHeader
public void setAcceptHeader(String acceptHeader)
The accept header value of the shopper's browser.- Parameters:
acceptHeader-
-
colorDepth
public BrowserInfo colorDepth(Integer colorDepth)
The color depth of the shopper's browser in bits per pixel. This should be obtained by using the browser's `screen.colorDepth` property. Accepted values: 1, 4, 8, 15, 16, 24, 30, 32 or 48 bit color depth.- Parameters:
colorDepth-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getColorDepth
public Integer getColorDepth()
The color depth of the shopper's browser in bits per pixel. This should be obtained by using the browser's `screen.colorDepth` property. Accepted values: 1, 4, 8, 15, 16, 24, 30, 32 or 48 bit color depth.- Returns:
- colorDepth
-
setColorDepth
public void setColorDepth(Integer colorDepth)
The color depth of the shopper's browser in bits per pixel. This should be obtained by using the browser's `screen.colorDepth` property. Accepted values: 1, 4, 8, 15, 16, 24, 30, 32 or 48 bit color depth.- Parameters:
colorDepth-
-
javaEnabled
public BrowserInfo javaEnabled(Boolean javaEnabled)
Boolean value indicating if the shopper's browser is able to execute Java.- Parameters:
javaEnabled-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getJavaEnabled
public Boolean getJavaEnabled()
Boolean value indicating if the shopper's browser is able to execute Java.- Returns:
- javaEnabled
-
setJavaEnabled
public void setJavaEnabled(Boolean javaEnabled)
Boolean value indicating if the shopper's browser is able to execute Java.- Parameters:
javaEnabled-
-
javaScriptEnabled
public BrowserInfo javaScriptEnabled(Boolean javaScriptEnabled)
Boolean value indicating if the shopper's browser is able to execute JavaScript. A default 'true' value is assumed if the field is not present.- Parameters:
javaScriptEnabled-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getJavaScriptEnabled
public Boolean getJavaScriptEnabled()
Boolean value indicating if the shopper's browser is able to execute JavaScript. A default 'true' value is assumed if the field is not present.- Returns:
- javaScriptEnabled
-
setJavaScriptEnabled
public void setJavaScriptEnabled(Boolean javaScriptEnabled)
Boolean value indicating if the shopper's browser is able to execute JavaScript. A default 'true' value is assumed if the field is not present.- Parameters:
javaScriptEnabled-
-
language
public BrowserInfo language(String language)
The `navigator.language` value of the shopper's browser (as defined in IETF BCP 47).- Parameters:
language-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getLanguage
public String getLanguage()
The `navigator.language` value of the shopper's browser (as defined in IETF BCP 47).- Returns:
- language
-
setLanguage
public void setLanguage(String language)
The `navigator.language` value of the shopper's browser (as defined in IETF BCP 47).- Parameters:
language-
-
screenHeight
public BrowserInfo screenHeight(Integer screenHeight)
The total height of the shopper's device screen in pixels.- Parameters:
screenHeight-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getScreenHeight
public Integer getScreenHeight()
The total height of the shopper's device screen in pixels.- Returns:
- screenHeight
-
setScreenHeight
public void setScreenHeight(Integer screenHeight)
The total height of the shopper's device screen in pixels.- Parameters:
screenHeight-
-
screenWidth
public BrowserInfo screenWidth(Integer screenWidth)
The total width of the shopper's device screen in pixels.- Parameters:
screenWidth-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getScreenWidth
public Integer getScreenWidth()
The total width of the shopper's device screen in pixels.- Returns:
- screenWidth
-
setScreenWidth
public void setScreenWidth(Integer screenWidth)
The total width of the shopper's device screen in pixels.- Parameters:
screenWidth-
-
timeZoneOffset
public BrowserInfo timeZoneOffset(Integer timeZoneOffset)
Time difference between UTC time and the shopper's browser local time, in minutes.- Parameters:
timeZoneOffset-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getTimeZoneOffset
public Integer getTimeZoneOffset()
Time difference between UTC time and the shopper's browser local time, in minutes.- Returns:
- timeZoneOffset
-
setTimeZoneOffset
public void setTimeZoneOffset(Integer timeZoneOffset)
Time difference between UTC time and the shopper's browser local time, in minutes.- Parameters:
timeZoneOffset-
-
userAgent
public BrowserInfo userAgent(String userAgent)
The user agent value of the shopper's browser.- Parameters:
userAgent-- Returns:
- the current
BrowserInfoinstance, allowing for method chaining
-
getUserAgent
public String getUserAgent()
The user agent value of the shopper's browser.- Returns:
- userAgent
-
setUserAgent
public void setUserAgent(String userAgent)
The user agent value of the shopper's browser.- Parameters:
userAgent-
-
equals
public boolean equals(Object o)
Return true if this BrowserInfo object is equal to o.
-
fromJson
public static BrowserInfo fromJson(String jsonString) throws com.fasterxml.jackson.core.JsonProcessingException
Create an instance of BrowserInfo given an JSON string- Parameters:
jsonString- JSON string- Returns:
- An instance of BrowserInfo
- Throws:
com.fasterxml.jackson.core.JsonProcessingException- if the JSON string is invalid with respect to BrowserInfo
-
toJson
public String toJson() throws com.fasterxml.jackson.core.JsonProcessingException
Convert an instance of BrowserInfo to an JSON string- Returns:
- JSON string
- Throws:
com.fasterxml.jackson.core.JsonProcessingException
-
-