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

se.eris.notnull.AnnotationConfiguration Maven / Gradle / Ivy

There is a newer version: 1.1.1
Show newest version
package se.eris.notnull;

import org.jetbrains.annotations.NotNull;

import java.util.Collections;
import java.util.Set;

public class AnnotationConfiguration {

    @NotNull
    private final Set notNull;
    @NotNull
    private final Set nullable;

    public AnnotationConfiguration(@NotNull final Set notNull, @NotNull final Set nullable) {
        this.notNull = notNull;
        this.nullable = nullable;
    }

    public AnnotationConfiguration() {
        notNull = Collections.emptySet();
        nullable = Collections.emptySet();
    }

    public boolean isAnnotationsConfigured() {
        return !notNull.isEmpty() || !nullable.isEmpty();
    }

    @NotNull
    public Set getNotNull() {
        return notNull;
    }

    @NotNull
    public Set getNullable() {
        return nullable;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy