IPProvider
public class IPProvider
↳ package com.onekosmos.blockid.sdk.BIDAPIs.publicip;
The IPProvider class provides a mechanism for fetching and caching the user's IP address from a remote API. This class ensures that the IP address is regularly updated in the background, and it provides a simple interface for retrieving the current IP address from the cache.
By default, the IP address cache time interval is 10 minutes, after which the IP address is automatically refreshed from the API.
Method Summary
| Type | Method | Description |
|---|---|---|
| String | getIPAddress() | Returns the current IP address from the cache. |
| IPProvider | getInstance() | Returns an instance of IPProvider. |