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

com.sap.cloud.security.ams.dcl.client.dcn.TestInput Maven / Gradle / Ivy

The newest version!
/************************************************************************
 * © 2019-2024 SAP SE or an SAP affiliate company. All rights reserved. *
 ************************************************************************/
package com.sap.cloud.security.ams.dcl.client.dcn;

import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.function.Consumer;

import com.sap.cloud.security.ams.dcl.client.annotation.Beta;
import com.sap.cloud.security.ams.dcl.client.el.AttributeName;

@Beta
public class TestInput {

    private Map content;

    private List ignores;

    private List unknowns;

    private transient Object userData; // NOSONAR

    public TestInput() {
        super();
    }

    public Map content() {
        return content;
    }

    public TestInput content(Map content) {
        this.content = content;
        return this;
    }

    public List ignores() {
        return ignores;
    }

    public TestInput ignores(List ignores) {
        this.ignores = ignores;
        return this;
    }

    public List unknowns() {
        return unknowns;
    }

    public TestInput unknowns(List unknowns) {
        this.unknowns = unknowns;
        return this;
    }

    /**
     * Gets the custom user data. This data is not stored or loaded (i.e transient). The value is not take into account for hashCode() or
     * equals(Object other).
     * 
     * @return user data
     */
    public Object userData() {
        return userData;
    }

    /**
     * Sets the user data. This data is not stored or loaded (i.e transient). The value is not take into account for hashCode() or equals(Object
     * other).
     * 
     * @param userData
     *            custom user data
     * @return this
     */
    public TestInput userData(Object userData) {
        this.userData = userData;
        return this;
    }

    public TestInput apply(Consumer consumer) {
        consumer.accept(this);
        return this;
    }

    //

    @Override
    public String toString() {
        return "TestInput [content=" + content
                + ", ignores=" + ignores
                + ", unknowns=" + unknowns
                + "]";
    }

    @Override
    public int hashCode() {
        return Objects.hash(content, ignores, unknowns);
    }

    @Override
    public boolean equals(Object obj) {
        if (this == obj)
            return true;
        if (obj == null)
            return false;
        if (getClass() != obj.getClass())
            return false;
        TestInput other = (TestInput) obj;
        return Objects.equals(content, other.content)
                && Objects.equals(ignores, other.ignores)
                && Objects.equals(unknowns, other.unknowns);
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy