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

net.ravendb.client.documents.queries.highlighting.QueryHighlightings Maven / Gradle / Ivy

package net.ravendb.client.documents.queries.highlighting;

import net.ravendb.client.documents.queries.QueryResult;

import java.util.ArrayList;
import java.util.List;

public class QueryHighlightings {
    private final List _highlightings = new ArrayList<>();

    public Highlightings add(String fieldName) {
        Highlightings fieldHighlightings = new Highlightings(fieldName);
        _highlightings.add(fieldHighlightings);
        return fieldHighlightings;
    }

    public void update(QueryResult queryResult) {
        for (Highlightings fieldHighlightings : _highlightings) {
            fieldHighlightings.update(queryResult.getHighlightings());
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy