diff --git a/jnosql-communication/jnosql-communication-query/src/main/java/org/eclipse/jnosql/communication/query/DefaultQueryValue.java b/jnosql-communication/jnosql-communication-query/src/main/java/org/eclipse/jnosql/communication/query/DefaultQueryValue.java index 07f41acd5..768374f77 100644 --- a/jnosql-communication/jnosql-communication-query/src/main/java/org/eclipse/jnosql/communication/query/DefaultQueryValue.java +++ b/jnosql-communication/jnosql-communication-query/src/main/java/org/eclipse/jnosql/communication/query/DefaultQueryValue.java @@ -13,40 +13,17 @@ import org.eclipse.jnosql.query.grammar.QueryParser; -import java.util.Objects; /** * The default implementation of {@link ParamQueryValue} - */ -final class DefaultQueryValue implements ParamQueryValue { - - private final String value; + */ record DefaultQueryValue(String value) implements ParamQueryValue { - DefaultQueryValue(String value) { - this.value = value; - } @Override public String get() { return value; } - @Override - public boolean equals(Object o) { - if (this == o) { - return true; - } - if (!(o instanceof DefaultQueryValue that)) { - return false; - } - return Objects.equals(value, that.value); - } - - @Override - public int hashCode() { - return Objects.hashCode(value); - } - @Override public String toString() { return "@" + value;