cryptix.pgp
Class PacketFactory

java.lang.Object
  extended bycryptix.pgp.PacketFactory

public final class PacketFactory
extends java.lang.Object

This class contains static methods to read and write encoded packets. When a packet is read, an instance of the correct subclass of Packet is created according to the encoded packet's type field.


Copyright © 1995-1997 Systemics Ltd on behalf of the Cryptix Development Team.
All rights reserved.

$Revision: 1.1.1.1 $

Since:
Cryptix 2.2 or earlier
Author:
original author not stated, Jill Baker
See Also:
Packet

Method Summary
static Packet load(byte[] buf)
           
static Packet read(java.io.DataInput in)
           
static byte[] save(Packet pkt)
           
static void write(java.io.DataOutput out, Packet pkt)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

read

public static Packet read(java.io.DataInput in)
                   throws java.io.IOException
Throws:
java.io.IOException

write

public static void write(java.io.DataOutput out,
                         Packet pkt)
                  throws java.io.IOException
Throws:
java.io.IOException

save

public static byte[] save(Packet pkt)
                   throws java.io.IOException
Throws:
java.io.IOException

load

public static Packet load(byte[] buf)
                   throws java.io.IOException
Throws:
java.io.IOException