com.oroinc.net.tftp
Class TFTPRequestPacket
java.lang.Object
|
+--com.oroinc.net.tftp.TFTPPacket
|
+--com.oroinc.net.tftp.TFTPRequestPacket
- Direct Known Subclasses:
- TFTPReadRequestPacket, TFTPWriteRequestPacket
- public abstract class TFTPRequestPacket
- extends TFTPPacket
An abstract class derived from TFTPPacket definiing a TFTP Request
packet type. It is subclassed by the
TFTPReadRequestPacket and
TFTPWriteRequestPacket classes.
Details regarding the TFTP protocol and the format of TFTP packets can
be found in RFC 783. But the point of these classes is to keep you
from having to worry about the internals. Additionally, only very
few people should have to care about any of the TFTPPacket classes
or derived classes. Almost all users should only be concerned with the
TFTPClient class
receiveFile()
and
sendFile()
methods.
- Author:
- Daniel F. Savarese
- See Also:
TFTPPacket
,
TFTPReadRequestPacket
,
TFTPWriteRequestPacket
,
TFTPPacketException
,
TFTP
Method Summary |
java.lang.String |
getFilename()
Returns the requested filename. |
int |
getMode()
Returns the transfer mode of the request. |
java.net.DatagramPacket |
newDatagram()
This is a method exposed to the programmer in case he
wants to implement his own TFTP client instead of using
the TFTPClient
class. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
newDatagram
public final java.net.DatagramPacket newDatagram()
- This is a method exposed to the programmer in case he
wants to implement his own TFTP client instead of using
the TFTPClient
class. Under normal circumstances, you should not have a need to call
this method. It creates a UDP datagram containing all the TFTP
request packet data in the proper format.
- Overrides:
newDatagram
in class TFTPPacket
- Returns:
- A UDP datagram containing the TFTP request packet.
getMode
public final int getMode()
- Returns the transfer mode of the request.
- Returns:
- The transfer mode of the request.
getFilename
public final java.lang.String getFilename()
- Returns the requested filename.
- Returns:
- The requested filename.
Copyright © 1997-2002 Daniel F. Savarese. All Rights Reserved.