FileDocCategorySizeDatePackage
PRUDPPacket.javaAPI DocAzureus 3.0.3.42638Thu Jan 05 05:43:26 GMT 2006com.aelitis.net.udp.uc

PRUDPPacket

public abstract class PRUDPPacket extends Object
author
parg

Fields Summary
public static final int
MAX_PACKET_SIZE
public static final int
DEFAULT_UDP_TIMEOUT
private static int
next_id
private static org.gudy.azureus2.core3.util.AEMonitor
class_mon
private InetSocketAddress
address
private int
type
private int
transaction_id
private PRUDPPacket
previous_packet
private int
serialised_size
Constructors Summary
protected PRUDPPacket(int _type, int _transaction_id)

	
	
	
				
				 
	
		type			= _type;
		transaction_id	= _transaction_id;
	
protected PRUDPPacket(int _type)

		type			= _type;
		
		try{
			class_mon.enter();
			
			transaction_id	= next_id++;
			
		}finally{
			
			class_mon.exit();
		}
	
Methods Summary
public intgetAction()

		return( type );
	
public java.net.InetSocketAddressgetAddress()

		return( address );
	
public com.aelitis.net.udp.uc.PRUDPPacketgetPreviousPacket()

		return( previous_packet );
	
public intgetSerialisedSize()

		return( serialised_size );
	
public java.lang.StringgetString()

		return( "type=" + type + ",addr=" + address );
	
public intgetTransactionId()

		return( transaction_id );
	
public booleanhasContinuation()

		return( false );
	
public abstract voidserialise(java.io.DataOutputStream os)

public voidsetAddress(java.net.InetSocketAddress _address)

		address	= _address;
	
public voidsetPreviousPacket(com.aelitis.net.udp.uc.PRUDPPacket p)

		previous_packet = p;
	
public voidsetSerialisedSize(int len)

		serialised_size	= len;