Package com.day.cq.wcm.emulator
Interface Emulator
public interface Emulator
The
Emulator interface specifies emulators.- Since:
- CQ 5.4.0
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionbooleanIndicates whether the device represented by this emulator supports device rotation (dual mode).Returns the path of the CSS to be used for displaying the page content in the emulator.Returns the description of this emulator.intReturns the height of this emulator.getName()Returns the name of this emulator.getPath()Returns the path of this emulator.doubleReturns the pixel ratio of this emulator.getTitle()Returns the title of this emulator.intgetWidth()Returns the width of this emulator.booleanIndicates whether the devices represented by this emulator uses touch scrolling.voidsetContentCssPath(String cssPath) Instructs the emulator to use the givencssPathfor displaying the page content.
-
Field Details
-
RESOURCE_TYPE
- See Also:
-
PN_CANROTATE
- See Also:
-
PN_TOUCHSCROLLING
- See Also:
-
PN_WIDTH
- See Also:
-
PN_HEIGHT
- See Also:
-
PN_PIXELRATIO
- See Also:
-
NN_EMULATORCONFIG
Node names- See Also:
-
-
Method Details
-
getContentCssPath
String getContentCssPath()Returns the path of the CSS to be used for displaying the page content in the emulator. This is set viasetContentCssPath(String).- Returns:
- A
Stringrepresenting the content CSS path, ornullif never set.
-
setContentCssPath
Instructs the emulator to use the givencssPathfor displaying the page content. This is the same CSS path as used for rendering the page e.g. on a publish instance.- Parameters:
cssPath- >Stringrepresenting the css path.
-
getDescription
String getDescription()Returns the description of this emulator.- Returns:
- A
Stringrepresenting the description, ornullif not defined.
-
getName
String getName()Returns the name of this emulator.- Returns:
- A
Stringrepresenting the name.
-
getPath
String getPath()Returns the path of this emulator.- Returns:
- A
Stringrepresenting the path.
-
getTitle
String getTitle()Returns the title of this emulator.- Returns:
- A
Stringrepresenting the title ornullif not defined.
-
canRotate
boolean canRotate()Indicates whether the device represented by this emulator supports device rotation (dual mode).- Returns:
trueif rotation is supported.
-
hasTouchScrolling
boolean hasTouchScrolling()Indicates whether the devices represented by this emulator uses touch scrolling.- Returns:
trueif touch scrolling is supported.
-
getWidth
int getWidth()Returns the width of this emulator.- Returns:
- An
intrepresenting the width or-1if not defined.
-
getHeight
int getHeight()Returns the height of this emulator.- Returns:
- An
intrepresenting the height or-1if not defined.
-
getPixelRatio
double getPixelRatio()Returns the pixel ratio of this emulator.- Returns:
- A
doublerepresenting the pixel ratio or1if not defined.
-