
com.applitools.eyes.images.Target Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of eyes-images-java5 Show documentation
Show all versions of eyes-images-java5 Show documentation
Applitools Eyes SDK for Images
package com.applitools.eyes.images;
import com.applitools.ICheckSettings;
import com.applitools.eyes.Region;
import com.applitools.utils.ImageUtils;
import java.awt.image.BufferedImage;
import java.net.URL;
public class Target {
/**
* Specify the target as image.
*
* @param image the buffered image.
* @return the check settings
*/
public static ICheckSettings image(BufferedImage image) {
return new ImagesCheckSettings(image);
}
/**
* Specify the target as image.
*
* @param imageBytes byte array of the image.
* @return the check settings
*/
public static ICheckSettings image(byte[] imageBytes) {
return image(ImageUtils.imageFromBytes(imageBytes));
}
/**
* Specify the target as image.
*
* @param path the path to the image, or the url if remote.
* @return the check settings
*/
public static ICheckSettings image(String path) {
return new ImagesCheckSettings(path);
}
/**
* Specify the target as a region.
*
* @param image the image.
* @param region the region to capture inside the image.
* @return the check settings
*/
public static ICheckSettings region(BufferedImage image, Region region) {
return new ImagesCheckSettings(image, region);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy