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

io.deephaven.api.literal.LiteralBool Maven / Gradle / Ivy

The newest version!
//
// Copyright (c) 2016-2024 Deephaven Data Labs and Patent Pending
//
package io.deephaven.api.literal;

import io.deephaven.annotations.SimpleStyle;
import io.deephaven.api.filter.Filter;
import org.immutables.value.Value.Immutable;
import org.immutables.value.Value.Parameter;

@Immutable
@SimpleStyle
abstract class LiteralBool extends LiteralBase implements LiteralFilter {

    public static LiteralBool of(boolean value) {
        return ImmutableLiteralBool.of(value);
    }

    @Parameter
    public abstract boolean value();

    @Override
    public final LiteralBool invert() {
        return of(!value());
    }

    @Override
    public final  T walk(Literal.Visitor visitor) {
        return visitor.visit(value());
    }

    @Override
    public final  T walk(Filter.Visitor visitor) {
        return visitor.visit(value());
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy