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

org.openqa.selenium.devtools.v90.dom.model.ShapeOutsideInfo Maven / Gradle / Ivy

Go to download

Selenium automates browsers. That's it! What you do with that power is entirely up to you.

There is a newer version: 4.0.0-beta-4
Show newest version
package org.openqa.selenium.devtools.v90.dom.model;

import org.openqa.selenium.Beta;
import org.openqa.selenium.json.JsonInput;

/**
 * CSS Shape Outside details.
 */
public class ShapeOutsideInfo {

    private final org.openqa.selenium.devtools.v90.dom.model.Quad bounds;

    private final java.util.List shape;

    private final java.util.List marginShape;

    public ShapeOutsideInfo(org.openqa.selenium.devtools.v90.dom.model.Quad bounds, java.util.List shape, java.util.List marginShape) {
        this.bounds = java.util.Objects.requireNonNull(bounds, "bounds is required");
        this.shape = java.util.Objects.requireNonNull(shape, "shape is required");
        this.marginShape = java.util.Objects.requireNonNull(marginShape, "marginShape is required");
    }

    /**
     * Shape bounds
     */
    public org.openqa.selenium.devtools.v90.dom.model.Quad getBounds() {
        return bounds;
    }

    /**
     * Shape coordinate details
     */
    public java.util.List getShape() {
        return shape;
    }

    /**
     * Margin shape bounds
     */
    public java.util.List getMarginShape() {
        return marginShape;
    }

    private static ShapeOutsideInfo fromJson(JsonInput input) {
        org.openqa.selenium.devtools.v90.dom.model.Quad bounds = null;
        java.util.List shape = null;
        java.util.List marginShape = null;
        input.beginObject();
        while (input.hasNext()) {
            switch(input.nextName()) {
                case "bounds":
                    bounds = input.read(org.openqa.selenium.devtools.v90.dom.model.Quad.class);
                    break;
                case "shape":
                    shape = input.read(new com.google.common.reflect.TypeToken>() {
                    }.getType());
                    break;
                case "marginShape":
                    marginShape = input.read(new com.google.common.reflect.TypeToken>() {
                    }.getType());
                    break;
                default:
                    input.skipValue();
                    break;
            }
        }
        input.endObject();
        return new ShapeOutsideInfo(bounds, shape, marginShape);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy