Adding a custom operator LIKE for RSQL while keeping my API code intact

71 Views Asked by At

I want to add another operator LIKE (similar to how LIKE in SQL works) to my RSQL. However, I do not want to change my API code because there are a lot of them and I cannot go in and fix all of them. Here is a snippet of my API code:

if (search != null) {
            Node rootNode = new RSQLParser().parse(search);
            Specification<Data> spec = rootNode.accept(new CustomRsqlVisitor<>());
            results = dataRepo.findAll(spec, pageable);

What do I have to add/change?

0

There are 0 best solutions below