- java.lang.Object
-
- org.testfx.service.support.impl.CaptureSupportImpl
-
- All Implemented Interfaces:
CaptureSupport
public class CaptureSupportImpl extends Object implements CaptureSupport
-
-
Field Summary
Fields Modifier and Type Field Description static StringPNG_IMAGE_FORMAT
-
Constructor Summary
Constructors Constructor Description CaptureSupportImpl(BaseRobot baseRobot)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ImageannotateImage(Shape shape, Image image)NOT YET IMPLEMENTEDImagecaptureNode(Node node)Returns a snapshot of the node.ImagecaptureRegion(Rectangle2D region)Returns a screenshot of the given region.ImageloadImage(Path path)Loads the image file from the given path.PixelMatcherResultmatchImages(Image image0, Image image1, PixelMatcher pixelMatcher)Compares two images and returns aPixelMatcherResultthat defines the how similar/dissimilar one was from the other.voidsaveImage(Image image, Path path)Saves the given image to the given path.
-
-
-
Field Detail
-
PNG_IMAGE_FORMAT
public static final String PNG_IMAGE_FORMAT
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
CaptureSupportImpl
public CaptureSupportImpl(BaseRobot baseRobot)
-
-
Method Detail
-
captureNode
public Image captureNode(Node node)
Description copied from interface:CaptureSupportReturns a snapshot of the node.- Specified by:
captureNodein interfaceCaptureSupport
-
captureRegion
public Image captureRegion(Rectangle2D region)
Description copied from interface:CaptureSupportReturns a screenshot of the given region.- Specified by:
captureRegionin interfaceCaptureSupport
-
loadImage
public Image loadImage(Path path)
Description copied from interface:CaptureSupportLoads the image file from the given path.- Specified by:
loadImagein interfaceCaptureSupport
-
saveImage
public void saveImage(Image image, Path path)
Description copied from interface:CaptureSupportSaves the given image to the given path.- Specified by:
saveImagein interfaceCaptureSupport
-
annotateImage
public Image annotateImage(Shape shape, Image image)
Description copied from interface:CaptureSupportNOT YET IMPLEMENTED- Specified by:
annotateImagein interfaceCaptureSupport
-
matchImages
public PixelMatcherResult matchImages(Image image0, Image image1, PixelMatcher pixelMatcher)
Description copied from interface:CaptureSupportCompares two images and returns aPixelMatcherResultthat defines the how similar/dissimilar one was from the other.- Specified by:
matchImagesin interfaceCaptureSupport
-
-