public class FtpSocketFactory extends Object
Modifier and Type | Field and Description |
---|---|
protected FtpServerChannel |
m_Channel |
protected ServerSocket |
m_DataServerSocket |
protected InetAddress |
m_LocalHost |
protected int |
m_LocalPort |
protected InetAddress |
m_RemoteHost |
protected int |
m_RemotePort |
protected static IfsLogger |
s_Logger |
Constructor and Description |
---|
FtpSocketFactory(FtpServerChannel channel,
InetAddress localHost,
int localPort,
InetAddress remoteHost,
int remotePort) |
Modifier and Type | Method and Description |
---|---|
void |
closeDataServerSocket()
Close the data ServerSocket.
|
Socket |
getConnection(FtpServer server)
Returns a Socket for data transfer.
|
void |
setActive(int remotePort)
Using the PORT command, manually set the remote port.
|
int |
setPassive()
A PASV request asks the server to accept a data connection on a new TCP
port selected by the server.
|
protected static IfsLogger s_Logger
protected ServerSocket m_DataServerSocket
protected InetAddress m_RemoteHost
protected int m_RemotePort
protected InetAddress m_LocalHost
protected int m_LocalPort
protected FtpServerChannel m_Channel
public FtpSocketFactory(FtpServerChannel channel, InetAddress localHost, int localPort, InetAddress remoteHost, int remotePort)
public int setPassive() throws IOException
IOException
public void setActive(int remotePort) throws Exception
Exception
public Socket getConnection(FtpServer server) throws Exception
Exception
public void closeDataServerSocket() throws IOException
IOException
Copyright © 2023. All rights reserved.