Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

FTreeP
Class FTPCommandRelay  view FTPCommandRelay download FTPCommandRelay.java

java.lang.Object
  extended byjava.lang.Thread
      extended byFTreeP.FTPCommandRelay
All Implemented Interfaces:
java.lang.Runnable

class FTPCommandRelay
extends java.lang.Thread


Nested Class Summary
 
Nested classes inherited from class java.lang.Thread
java.lang.Thread.UncaughtExceptionHandler
 
Field Summary
private  java.io.BufferedReader cmd_in_in
           
private  java.io.BufferedWriter cmd_in_out
           
private  java.io.BufferedReader cmd_out_in
           
private  java.io.BufferedWriter cmd_out_out
           
private  java.net.Socket command_in_socket
           
private  java.net.Socket command_out_socket
           
private  FTPConsole console
           
private  java.lang.String current_host
           
private  int current_host_port
           
private  java.lang.String mode
           
private  java.lang.String pwd
           
private  boolean quit
           
private  java.lang.String type
           
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
FTPCommandRelay(java.net.Socket command_in_socket)
           
 
Method Summary
private  void cdup()
           
private  void connectToHostWithResource(java.lang.String resource)
           
private  void createGUIElements()
           
private  void cwd(java.lang.String directory)
           
private  void destroyGUIElements()
           
private  DirectoryIndexer.Resource getResourceFromPath(java.lang.String path)
           
private  void interpret(java.lang.String cmd)
           
private  void list(java.lang.String directory)
           
private  void mode(java.lang.String mode)
           
private  void noop()
           
private  void pasv()
           
private  void port(java.lang.String port_text)
           
private  void pwd()
           
private  void quit()
           
 void relay(java.io.BufferedWriter cmd_out, java.lang.String message)
           
 void respond(java.io.BufferedWriter cmd_out, int response_code, java.lang.String message)
           
private  void retr(java.lang.String file)
           
 void run()
          The method of Thread that will be run if there is no Runnable object associated with the Thread.
private  java.lang.String simplifyPath(java.lang.String path)
           
private  void size(java.lang.String file)
           
private  void type(java.lang.String type)
           
private  void user(java.lang.String user)
           
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

command_in_socket

private java.net.Socket command_in_socket

command_out_socket

private java.net.Socket command_out_socket

cmd_in_in

private java.io.BufferedReader cmd_in_in

cmd_out_in

private java.io.BufferedReader cmd_out_in

cmd_in_out

private java.io.BufferedWriter cmd_in_out

cmd_out_out

private java.io.BufferedWriter cmd_out_out

mode

private java.lang.String mode

pwd

private java.lang.String pwd

type

private java.lang.String type

current_host

private java.lang.String current_host

current_host_port

private int current_host_port

quit

private boolean quit

console

private FTPConsole console
Constructor Detail

FTPCommandRelay

public FTPCommandRelay(java.net.Socket command_in_socket)
                throws java.lang.Exception
Method Detail

run

public void run()
Description copied from class: java.lang.Thread
The method of Thread that will be run if there is no Runnable object associated with the Thread. Thread's implementation does nothing at all.


interpret

private void interpret(java.lang.String cmd)
                throws java.lang.Exception

getResourceFromPath

private DirectoryIndexer.Resource getResourceFromPath(java.lang.String path)
                                               throws java.lang.Exception

connectToHostWithResource

private void connectToHostWithResource(java.lang.String resource)
                                throws java.lang.Exception

simplifyPath

private java.lang.String simplifyPath(java.lang.String path)
                               throws java.lang.Exception

respond

public void respond(java.io.BufferedWriter cmd_out,
                    int response_code,
                    java.lang.String message)
             throws java.lang.Exception

relay

public void relay(java.io.BufferedWriter cmd_out,
                  java.lang.String message)
           throws java.lang.Exception

createGUIElements

private void createGUIElements()

destroyGUIElements

private void destroyGUIElements()

cdup

private void cdup()
           throws java.lang.Exception

cwd

private void cwd(java.lang.String directory)
          throws java.lang.Exception

list

private void list(java.lang.String directory)
           throws java.lang.Exception

mode

private void mode(java.lang.String mode)
           throws java.lang.Exception

noop

private void noop()
           throws java.lang.Exception

pasv

private void pasv()
           throws java.lang.Exception

port

private void port(java.lang.String port_text)
           throws java.lang.Exception

pwd

private void pwd()
          throws java.lang.Exception

quit

private void quit()
           throws java.lang.Exception

retr

private void retr(java.lang.String file)
           throws java.lang.Exception

size

private void size(java.lang.String file)
           throws java.lang.Exception

type

private void type(java.lang.String type)
           throws java.lang.Exception

user

private void user(java.lang.String user)
           throws java.lang.Exception