com.contentgrid.thunx.predicates.model.Scalar Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of thunx-model Show documentation
Show all versions of thunx-model Show documentation
Set of (vendor-neutral) data structures to model authorization policy expressions
package com.contentgrid.thunx.predicates.model;
import java.math.BigDecimal;
public interface Scalar extends ThunkExpression {
T getValue();
default R accept(ThunkExpressionVisitor visitor, C context) {
return visitor.visit(this, context);
}
static NumberValue of(BigDecimal number) {
return new NumberValue(number);
}
static NumberValue of(double number) {
return of(BigDecimal.valueOf(number));
}
static NumberValue of(long number) {
return of(BigDecimal.valueOf(number));
}
static StringValue of(String value) {
return new StringValue(value);
}
static BooleanValue of(boolean value) {
return new BooleanValue(value);
}
static NullValue nullValue() {
return NullValue.INSTANCE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy