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

org.fluentlenium.core.proxy.FirstElementLocator Maven / Gradle / Ivy

package org.fluentlenium.core.proxy;

import org.openqa.selenium.support.pagefactory.ElementLocator;

/**
 * {@link ElementLocator} retrieving the first element from another locator.
 */
public class FirstElementLocator extends AtIndexElementLocator {
    /**
     * Creates a new first element locator.
     *
     * @param listLocator element list locator
     */
    public FirstElementLocator(ElementLocator listLocator) {
        super(listLocator, 0);
    }

    @Override
    public String toString() {
        return listLocator.toString() + " (first)";
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy