Record Class SearchOperators

java.lang.Object
java.lang.Record
net.ygbstudio.jbrave.core.domain.dto.web.SearchOperators
Record Components:
applied - whether search operators were detected and applied to the query
cleanedQuery - the query string after operator cleanup
sites - the sites or domains extracted from the search operators

public record SearchOperators(Boolean applied, String cleanedQuery, List<String> sites) extends Record
Search operators that were detected and applied to the query according to the Brave Search API documentation.
  • Constructor Details

    • SearchOperators

      public SearchOperators(Boolean applied, String cleanedQuery, List<String> sites)
      Creates an instance of a SearchOperators record class.
      Parameters:
      applied - the value for the applied record component
      cleanedQuery - the value for the cleanedQuery record component
      sites - the value for the sites record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • applied

      public Boolean applied()
      Returns the value of the applied record component.
      Returns:
      the value of the applied record component
    • cleanedQuery

      public String cleanedQuery()
      Returns the value of the cleanedQuery record component.
      Returns:
      the value of the cleanedQuery record component
    • sites

      public List<String> sites()
      Returns the value of the sites record component.
      Returns:
      the value of the sites record component