Protocol
Class torrentProcess

public class torrentProcess

Title: torrentProcess.java

Description: This class contains the overall processing of the torrent. A list of peers is passed and the process is done

Copyright: Copyright (c) 2004

Company: Baylor University

Version:
1.0
Author:
CSI 5321
Constructor Detail

torrentProcess

public torrentProcess()
default constructor

Method Detail

isBitSetAt

public boolean isBitSetAt(int a)
checks if bit is set at position a of the bit set
Parameters:
a - int
Returns:
boolean

setBitAt

public boolean setBitAt(int a)
sets the bit at position a of the bit set
Parameters:
a - int
Returns:
boolean

turnBitOffAt

public void turnBitOffAt(int a)
turns the bit off at position a
Parameters:
a - int

doProtocol

public void doProtocol(Vector v)
does the Bittorrent protocol for downloading
Parameters:
v - Vector
Throws:
NumberFormatException -
UnknownHostException -
IOException -

isBitAvailable

public boolean isBitAvailable()
checks if any piece has to be downloaded
Returns:
boolean