diff --git a/documentation/extensions/filetransfer.html b/documentation/extensions/filetransfer.html index 70082e8f9..f71fcc5df 100644 --- a/documentation/extensions/filetransfer.html +++ b/documentation/extensions/filetransfer.html @@ -29,31 +29,31 @@ The file transfer extension allows the user to transmit and receive files. A user may wish to send a file to another user. The other user has the option of acception, rejecting, or ignoring the users request. Smack provides a simple interface in order -to enable the user to easily send a file.

+to enable the user to easily send a file. Usage

-In order to send a file you must first construct an instance of the FileTransferManager +In order to send a file you must first construct an instance of the FileTransferManager class. This class has one constructor with one parameter which is your XMPPConnection. -In order to instantiate the manager you should call new FileTransferManager(connection)

+In order to instantiate the manager you should call new FileTransferManager(connection) -

Once you have your FileTransferManager you will need to create an outgoing -file transfer to send a file. The method to use on the FileTransferManager +

Once you have your FileTransferManager you will need to create an outgoing +file transfer to send a file. The method to use on the FileTransferManager is the createOutgoingFileTransfer(userID) method. The userID you provide to this method is the fully-qualified jabber ID of the user you wish to send the file to. A fully-qualified jabber ID consists of a node, a domain, and a resource, the user -must be connected to the resource in order to be able to recieve the file transfer.

+must be connected to the resource in order to be able to recieve the file transfer. -

Now that you have your OutgoingFileTransfer instance you will want +

Now that you have your OutgoingFileTransfer instance you will want to send the file. The method to send a file is sendFile(file, description). The file you provide to this method should be a readable file on the local file system, and the description is a short - description of the file to help the user decide whether or not they would like to recieve the file.

+ description of the file to help the user decide whether or not they would like to recieve the file.

For information on monitoring the progress of a file transfer see the monitoring progress -section of this document.

+section of this document. -

Other means to send a file are also provided as part of the OutgoingFileTransfer. Please -consult the Javadoc for more information.

+

Other means to send a file are also provided as part of the OutgoingFileTransfer. Please +consult the Javadoc for more information. Examples

@@ -85,29 +85,29 @@ manager.

Usage

-In order to recieve a file you must first construct an instance of the FileTransferManager +In order to recieve a file you must first construct an instance of the FileTransferManager class. This class has one constructor with one parameter which is your XMPPConnection. -In order to instantiate the manager you should call new FileTransferManager(connection)

+In order to instantiate the manager you should call new FileTransferManager(connection) -

Once you have your FileTransferManager you will need to register a listener +

Once you have your FileTransferManager you will need to register a listener with it. The FileTransferListner interface has one method, fileTransferRequest(request). When a request is recieved through this method, you can either accept or reject the -request. To help you make your decision there are several methods in the FileTransferRequest -class that return information about the transfer request.

+request. To help you make your decision there are several methods in the FileTransferRequest +class that return information about the transfer request.

To accept the file transfer, call the accept(), -this method will create an IncomingFileTransfer. After you have the file transfer you may start +this method will create an IncomingFileTransfer. After you have the file transfer you may start to transfer the file by calling the recieveFile(file) method. The file provided to this method will be where the data from thefile transfer is saved.

Finally, to reject the file transfer the only method you need to call is reject() -on the IncomingFileTransfer.

+on the IncomingFileTransfer.

For information on monitoring the progress of a file transfer see the monitoring progress -section of this document.

+section of this document. -

Other means to recieve a file are also provided as part of the IncomingFileTransfer. Please -consult the Javadoc for more information.

+

Other means to recieve a file are also provided as part of the IncomingFileTransfer. Please +consult the Javadoc for more information. Examples

@@ -143,9 +143,9 @@ While a file transfer is in progress you may wish to monitor the progress of a f Usage

-

Both the IncomingFileTransfer and the OutgoingFileTransfer -extend the FileTransfer class which provides several methods to monitor -how a file transfer is progressing:

+

Both the IncomingFileTransfer and the OutgoingFileTransfer +extend the FileTransfer class which provides several methods to monitor +how a file transfer is progressing: