You are here

interface GeoLocatorInterface in GeoIP API 8.2

Interface GeoLocatorInterface.

Hierarchy

Expanded class hierarchy of GeoLocatorInterface

All classes that implement GeoLocatorInterface

1 file declares its use of GeoLocatorInterface
GeoLocationTest.php in tests/src/Unit/GeoLocationTest.php

File

src/Plugin/GeoLocator/GeoLocatorInterface.php, line 8

Namespace

Drupal\geoip\Plugin\GeoLocator
View source
interface GeoLocatorInterface {

  /**
   * Get the plugin's ID.
   *
   * @return string
   *   The geolocator ID
   */
  public function getId();

  /**
   * Get the plugin's label.
   *
   * @return string
   *   The geolocator label
   */
  public function getLabel();

  /**
   * Get the plugin's description.
   *
   * @return string
   *   The geolocator description
   */
  public function getDescription();

  /**
   * Performs geolocation on an address.
   *
   * @param string $ip_address
   *   The IP address to geolocate.
   *
   * @return string
   *   The geolocated country code, or NULL if not found.
   */
  public function geolocate($ip_address);

}

Members

Namesort descending Modifiers Type Description Overrides
GeoLocatorInterface::geolocate public function Performs geolocation on an address. 2
GeoLocatorInterface::getDescription public function Get the plugin's description. 1
GeoLocatorInterface::getId public function Get the plugin's ID. 1
GeoLocatorInterface::getLabel public function Get the plugin's label. 1