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

com.video.recorder.AppiumScreenRecordFactory Maven / Gradle / Ivy

There is a newer version: 14.0.4
Show newest version
package com.video.recorder;

import com.appium.android.AndroidDeviceConfiguration;
import com.appium.entities.MobilePlatform;
import com.appium.manager.AppiumDeviceManager;

import java.io.IOException;

public class AppiumScreenRecordFactory {
    private static AndroidDeviceConfiguration androidDeviceConfiguration
            = new AndroidDeviceConfiguration();

    public static IScreenRecord recordScreen() throws IOException, InterruptedException {
        if (AppiumDeviceManager.getMobilePlatform().equals(MobilePlatform.ANDROID)) {
            if (androidDeviceConfiguration.getDeviceManufacturer()
                    .equals("unknown") && !androidDeviceConfiguration
                    .checkIfRecordable()) {
                return new Flick();
            }
        }
        return new AppiumScreenRecorder();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy