udt.packets
Class PacketFactory
java.lang.Object
udt.packets.PacketFactory
public class PacketFactory
- extends Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PacketFactory
public PacketFactory()
createPacket
public static UDTPacket createPacket(byte[] encodedData)
- creates a Control or Data packet depending on the highest bit
of the first 32 bit of data
- Parameters:
packetData -
- Returns:
createPacket
public static UDTPacket createPacket(byte[] encodedData,
int length)
createControlPacket
public static ControlPacket createControlPacket(byte[] encodedData,
int length)
- create the right type of control packet based on the packet data
- Parameters:
packetData -
- Returns:
Copyright © 2013 LittleShoot. All Rights Reserved.