public class SshIpLookupStrategy extends java.lang.Object implements IpLookupStrategy
IpLookupStrategy that uses SSH to execute a command on a remote host to look up the IP based on the MAC.| Constructor and Description |
|---|
SshIpLookupStrategy(java.net.URI url,
java.lang.String command,
int timeout) |
| Modifier and Type | Method and Description |
|---|---|
static SshIpLookupStrategy |
create(java.lang.String prefix) |
java.lang.String |
lookup(java.lang.String mac)
attempt to lookup an IP for a MAC.
|
public SshIpLookupStrategy(java.net.URI url,
java.lang.String command,
int timeout)
public static SshIpLookupStrategy create(java.lang.String prefix)
public java.lang.String lookup(java.lang.String mac)
IpLookupStrategyIpLookupException when the lookup fails abnormally. May
throw IpNotFoundException when the IP was not found. mac may be null if it is not required
for the lookup.lookup in interface IpLookupStrategy