Package netscape.net

Class TransferProtocolClient

java.lang.Object
netscape.net.NetworkClient
netscape.net.TransferProtocolClient
Direct Known Subclasses:
SmtpClient

public class TransferProtocolClient extends NetworkClient
This class implements that basic intefaces of transfer protocols. It is used by subclasses implementing specific protocols.
Version:
1.25, 08/07/97
Author:
Jonathan Payne
  • Field Details

    • serverResponse

      protected Vector<String> serverResponse
      Array of strings (usually 1 entry) for the last reply from the server.
    • lastReplyCode

      protected int lastReplyCode
      code for last reply
  • Constructor Details

    • TransferProtocolClient

      public TransferProtocolClient(String host, int port) throws IOException
      standard constructor to host host, port port.
      Throws:
      IOException
    • TransferProtocolClient

      public TransferProtocolClient()
      creates an uninitialized instance of this class.
  • Method Details

    • readServerResponse

      public int readServerResponse() throws IOException
      Pulls the response from the server and returns the code as a number. Returns -1 on failure.
      Throws:
      IOException
    • sendServer

      public void sendServer(String cmd)
      Sends command cmd to the server.
    • getResponseString

      public String getResponseString()
      converts the server response into a string.
    • getResponseStrings

      public Vector<String> getResponseStrings()
      Returns all server response strings.