public static class OperaMobileEmulation.Builder extends Object
OperaMobileEmulation emulation profiles.| Constructor and Description |
|---|
OperaMobileEmulation.Builder()
Creates a new builder.
|
| Modifier and Type | Method and Description |
|---|---|
EmulationProfile |
build()
Returns a newly-created
EmulationProfile based on the contents of the builder. |
OperaMobileEmulation.Builder |
setHeight(int height)
Sets the height of the screen emulation resolution.
|
OperaMobileEmulation.Builder |
setIME(EmulationProfile.IME ime)
Sets the input mechanism to use for this emulation profile.
|
OperaMobileEmulation.Builder |
setPPI(int ppi)
Sets the pixel density of the device's screen.
|
OperaMobileEmulation.Builder |
setProfileName(String profileName)
Sets this emulation profile's unique description.
|
OperaMobileEmulation.Builder |
setResolution(org.openqa.selenium.Dimension resolution)
Sets the resolution of the emulation profile to the given dimensions.
|
OperaMobileEmulation.Builder |
setResolution(int width,
int height)
Sets the resolution of the emulation profile to the given dimensions by
width
and height. |
OperaMobileEmulation.Builder |
setUserAgent(OperaMobileEmulation.UserAgent userAgent)
Sets the user agent to use for this emulation profile.
|
OperaMobileEmulation.Builder |
setWidth(int width)
Sets the width of the screen emulation resolution.
|
public OperaMobileEmulation.Builder()
OperaMobileEmulation.builder().public OperaMobileEmulation.Builder setProfileName(String profileName)
profileName - a unique description of this profilepublic OperaMobileEmulation.Builder setResolution(org.openqa.selenium.Dimension resolution)
resolution - the dimensions of the screenpublic OperaMobileEmulation.Builder setResolution(int width, int height)
width
and height.width - the width of the screenheight - the height of the screenpublic OperaMobileEmulation.Builder setWidth(int width)
width - the width of the screenpublic OperaMobileEmulation.Builder setHeight(int height)
height - the height of the screenpublic OperaMobileEmulation.Builder setPPI(int ppi)
ppi - the pixel density as an integerpublic OperaMobileEmulation.Builder setIME(EmulationProfile.IME ime)
ime - the IME to usepublic OperaMobileEmulation.Builder setUserAgent(OperaMobileEmulation.UserAgent userAgent)
EmulationProfile.getUserAgent() returns a string, OperaMobileEmulation.UserAgent provides a convenience enum of the supported user agent
strings in Opera Mobile.userAgent - the user agent to usepublic EmulationProfile build()
EmulationProfile based on the contents of the builder.Copyright © 2012. All Rights Reserved.