Class IpAddress

java.lang.Object
com.maxmind.geoip2.model.AbstractResponse
com.maxmind.geoip2.model.AbstractCountryResponse
com.maxmind.geoip2.model.AbstractCityResponse
com.maxmind.geoip2.model.InsightsResponse
com.maxmind.minfraud.response.IpAddress
All Implemented Interfaces:
IpAddressInterface

public final class IpAddress extends com.maxmind.geoip2.model.InsightsResponse implements IpAddressInterface
This class contains minFraud response data related to the IP location
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    IpAddress(com.maxmind.geoip2.record.City city, com.maxmind.geoip2.record.Continent continent, com.maxmind.geoip2.record.Country country, GeoIp2Location location, com.maxmind.geoip2.record.MaxMind maxmind, com.maxmind.geoip2.record.Postal postal, com.maxmind.geoip2.record.Country registeredCountry, com.maxmind.geoip2.record.RepresentedCountry representedCountry, Double risk, List<IpRiskReason> riskReasons, List<com.maxmind.geoip2.record.Subdivision> subdivisions, com.maxmind.geoip2.record.Traits traits)
     
  • Method Summary

    Modifier and Type
    Method
    Description
     
     
     

    Methods inherited from class com.maxmind.geoip2.model.AbstractCityResponse

    getCity, getLeastSpecificSubdivision, getMostSpecificSubdivision, getPostal, getSubdivisions

    Methods inherited from class com.maxmind.geoip2.model.AbstractCountryResponse

    getContinent, getCountry, getMaxMind, getRegisteredCountry, getRepresentedCountry, getTraits

    Methods inherited from class com.maxmind.geoip2.model.AbstractResponse

    toJson, toString

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • IpAddress

      public IpAddress(com.maxmind.geoip2.record.City city, com.maxmind.geoip2.record.Continent continent, com.maxmind.geoip2.record.Country country, GeoIp2Location location, com.maxmind.geoip2.record.MaxMind maxmind, com.maxmind.geoip2.record.Postal postal, com.maxmind.geoip2.record.Country registeredCountry, com.maxmind.geoip2.record.RepresentedCountry representedCountry, Double risk, List<IpRiskReason> riskReasons, List<com.maxmind.geoip2.record.Subdivision> subdivisions, com.maxmind.geoip2.record.Traits traits)
      Parameters:
      city - The city information.
      continent - The continent information.
      country - The country information.
      location - The location information.
      maxmind - MaxMind-specific information.
      postal - The postal information.
      registeredCountry - The information about the country where the IP was registered.
      representedCountry - The represented country, e.g., for military bases in other countries.
      risk - The IP risk.
      riskReasons - The reasons for the IP risk.
      subdivisions - The list of subdivisions.
      traits - Information about various other IP traits.
    • IpAddress

      public IpAddress()
  • Method Details

    • getLocation

      public GeoIp2Location getLocation()
      Overrides:
      getLocation in class com.maxmind.geoip2.model.AbstractCityResponse
      Returns:
      Location record for the requested IP address.
    • getRisk

      public Double getRisk()
      Specified by:
      getRisk in interface IpAddressInterface
      Returns:
      The risk associated with the IP address. The value ranges from 0.01 to 99. A higher score indicates a higher risk.
    • getRiskReasons

      public final List<IpRiskReason> getRiskReasons()
      Returns:
      An unmodifiable list containing risk reason objects that identify the reasons why the IP address received the associated risk. This will be an empty list if there are no reasons.