Class GeolocationProximityBoost

  • All Implemented Interfaces:
    Boost

    public class GeolocationProximityBoost
    extends Object
    implements Boost
    • Constructor Detail

      • GeolocationProximityBoost

        public GeolocationProximityBoost()
    • Method Detail

      • getType

        public Boost.BoostType getType()
        Description copied from interface: Boost
        Type of boost
        Specified by:
        getType in interface Boost
        Returns:
        The boost type
      • getFunction

        public Boost.Function getFunction()
        Type of function to calculate the boost value. Can be linear, exponential, or gaussian.
        Returns:
        The function
      • getCenter

        public GeoLocation getCenter()
        The mode of the distribution, specified as a latitude-longitude pair
        Returns:
        The geolocation center
      • getFactor

        public BigDecimal getFactor()
        Description copied from interface: Boost
        Alter the impact of a boost on the score of a document. Must be between 0 and 10. Defaults to 1.0. A negative factor or fractional factor will not deboost a result. The factor parameter multiplies the value of the boost but does not significantly affect the decay function scale.
        Specified by:
        getFactor in interface Boost
        Returns:
        The factor
      • setFunction

        public GeolocationProximityBoost setFunction​(Boost.Function function)
        Type of function to calculate the boost value. Can be linear, exponential, or gaussian.
        Parameters:
        function - The function to calculate the boost
        Returns:
        this.
      • setCenter

        public GeolocationProximityBoost setCenter​(GeoLocation center)
        The mode of the distribution, specified as a latitude-longitude pair
        Parameters:
        center - The anchor point for the boost
        Returns:
        this.
      • setFactor

        public GeolocationProximityBoost setFactor​(BigDecimal factor)
        Description copied from interface: Boost
        Alter the impact of a boost on the score of a document. Must be between 0 and 10. Defaults to 1.0. A negative factor or fractional factor will not deboost a result. The factor parameter multiplies the value of the boost but does not significantly affect the decay function scale.
        Specified by:
        setFactor in interface Boost
        Parameters:
        factor - A value between (inclusive) 0.0 and 10.0
        Returns:
        this.