|
Secure iNet Factory | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jscape.inet.finger.Finger
public class Finger
Implements the basic functionality of a FINGER client.
Example Usage:
Finger finger = new Finger(); finger.setHostname("myserver.com"); try { // attempts to lookup information about user jsmith on machine myserver.com String results = finger.query("jsmith"); System.out.println(results); } catch(FingerException e) { System.out.println(e); }
Constructor Summary | |
---|---|
Finger()
Constructs new Finger instance. |
|
Finger(java.lang.String hostname)
Constructs new Finger instance. |
Method Summary | |
---|---|
java.lang.String |
getHostname()
Gets hostname of FINGER server. |
int |
getPort()
Gets port of finger server. |
int |
getTimeout()
Gets the timeout for opening a FINGER connection. |
java.lang.String |
query(java.lang.String user)
Connects to finger server and performs finger query. |
void |
setHostname(java.lang.String hostname)
Sets hostname of FINGER server. |
void |
setPort(int port)
Sets port of FINGER server. |
void |
setProxyAuthentication(java.lang.String proxyUsername,
java.lang.String proxyPassword)
Sets the username and password to use when for authentication with proxy server. |
void |
setProxyHost(java.lang.String proxyHostname,
int proxyPort)
Sets the proxy hostname and port for this connection. |
void |
setProxyType(java.lang.String proxyType)
Sets the proxy type will be used for this connection. |
void |
setTimeout(int timeout)
Sets the timeout for opening a FINGER connection. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Finger()
public Finger(java.lang.String hostname)
hostname
- the hostname of FINGER serverMethod Detail |
---|
public void setPort(int port)
port
- the port of FINGER serverpublic int getPort()
public void setHostname(java.lang.String hostname)
hostname
- the hostname of FINGER serverpublic java.lang.String getHostname()
public void setTimeout(int timeout)
timeout
- in millisecondspublic int getTimeout()
public void setProxyAuthentication(java.lang.String proxyUsername, java.lang.String proxyPassword)
#clearProxySettings
method.
proxyUsername
- the proxy usernameproxyPassword
- the proxy passwordpublic void setProxyHost(java.lang.String proxyHostname, int proxyPort)
#clearProxySettings
method.
proxyHostname
- the hostname or ip address of the proxy serverproxyPort
- the port of the proxy serverpublic void setProxyType(java.lang.String proxyType)
proxyType
- The proxy type. Valid values: HTTP, SOCKS5public java.lang.String query(java.lang.String user) throws FingerException
user
- the user to query
FingerException
- if a FINGER or I/O error occurs
|
Secure iNet Factory | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |