All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.mike10004.xvfbmanager.Screenshooter Maven / Gradle / Ivy

There is a newer version: 0.19
Show newest version
/*
 * (c) 2016 Mike Chaberski
 *
 * Created by mike
 */
package com.github.mike10004.xvfbmanager;

import java.io.IOException;

/**
 * Interface for a class that can capture a screenshot of a virtual framebuffer.
 * @param  screenshot type
 */
public interface Screenshooter {
    /**
     * Captures a screenshot.
     * @return the screenshot
     * @throws IOException if capture encounters an I/O error
     * @throws XvfbException if a virtual framebuffer error occurs
     */
    T capture() throws IOException, XvfbException;

    @SuppressWarnings("unused")
    class ScreenshooterException extends XvfbException {
        public ScreenshooterException() {
        }

        public ScreenshooterException(String message) {
            super(message);
        }

        public ScreenshooterException(String message, Throwable cause) {
            super(message, cause);
        }

        public ScreenshooterException(Throwable cause) {
            super(cause);
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy