|
LimeWire Consolidated API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface AlternateLocationFactory
| Method Summary | |
|---|---|
AlternateLocation |
create(RemoteFileDesc rfd)
Creates a new AlternateLocation for the data stored in a RemoteFileDesc. |
AlternateLocation |
create(String location,
URN urn)
Constructs a new AlternateLocation instance based on the specified string argument and URN. |
AlternateLocation |
create(String location,
URN urn,
boolean tlsCapable)
Constructs a new AlternateLocation instance based on the specified string argument and URN. |
AlternateLocation |
create(URN urn)
Creates a new AlternateLocation for a file stored locally with the specified URN. |
AlternateLocation |
createDirectAltLoc(IpPort ipp,
URN urn)
Creates a new direct AlternateLocation |
AlternateLocation |
createDirectDHTAltLoc(IpPort ipp,
URN urn,
long fileSize,
byte[] ttroot)
Creates a new direct AlternateLocation from information that was found in the DHT |
AlternateLocation |
createPushAltLoc(PushEndpoint pe,
URN urn)
Creates a new push AlternateLocation |
| Method Detail |
|---|
AlternateLocation create(URN urn)
urn - the URN of the locally stored file
AlternateLocation create(RemoteFileDesc rfd)
throws IOException
rfd - the RemoteFileDesc to use in creating the
AlternateLocation
IOException - if the rfd does not contain
a valid urn or if it's a private address
NullPointerException - if the rfd is
null
IOException - if the port is invalid
IOException
AlternateLocation createPushAltLoc(PushEndpoint pe,
URN urn)
AlternateLocation createDirectDHTAltLoc(IpPort ipp,
URN urn,
long fileSize,
byte[] ttroot)
throws IOException
IOException
AlternateLocation createDirectAltLoc(IpPort ipp,
URN urn)
throws IOException
IOException
AlternateLocation create(String location,
URN urn,
boolean tlsCapable)
throws IOException
location - a string containing one of the following:
"http://my.address.com:port#/uri-res/N2R?urn:sha:SHA1LETTERS" or
"1.2.3.4[:6346]" or
http representation of a PushEndpoint.
If the first is given, then the SHA1 in the string MUST match
the SHA1 given.location - the URL or IP[port]URN - the urn to use when the location doesn't contain a URNtlsCapable - if the alternate location is capable of receiving
TLS connections. valid only if the location was
not a full URL.
IOException - if there is any problem constructing
the new instance.
IOException
AlternateLocation create(String location,
URN urn)
throws IOException
location - a string containing one of the following:
"http://my.address.com:port#/uri-res/N2R?urn:sha:SHA1LETTERS" or
"1.2.3.4[:6346]" or
http representation of a PushEndpoint.
If the first is given, then the SHA1 in the string MUST match
the SHA1 given.location - the URL or IP[port]URN - the urn to use when the location doesn't contain a URN
IOException - if there is any problem constructing
the new instance.
IOException
|
LimeWire Consolidated API | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||