Package org.globus.ftp
Class HostPort6
java.lang.Object
org.globus.ftp.HostPort
org.globus.ftp.HostPort6
Utility class for parsing and converting host-port information from EPSV
and EPRT ftp commands.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetHost()
Returns the host addressstatic String
getIPAddressVersion
(String address) int
getPort()
Returns the port numberReturns the address versionvoid
Sets the host addressvoid
setVersion
(String version) Sets the address versionReturns the host-port information in the format used by EPRT command.
-
Field Details
-
IPv4
- See Also:
-
IPv6
- See Also:
-
host
-
port
private int port -
version
-
-
Constructor Details
-
HostPort6
-
HostPort6
Parses host-port from passive mode reply message. Note that the argument is not the whole message, but only the content of the brackets: <d><net-prt><d><net-addr><d><tcp-port><d>- Parameters:
passiveReplyMessage
- reply message for the EPSV command
-
-
Method Details
-
getPort
public int getPort()Returns the port number -
setHost
Sets the host address- Parameters:
host
- the host address
-
getHost
Returns the host address -
getVersion
Returns the address version- Returns:
- address version
-
setVersion
Sets the address version- Parameters:
version
- the address version
-
toFtpCmdArgument
Returns the host-port information in the format used by EPRT command. <d><net-prt><d><net-addr><d><tcp-port><d>- Overrides:
toFtpCmdArgument
in classHostPort
- Returns:
- host-port information in EPRT command representation.
-
getIPAddressVersion
-