September 2002
Intermediate to advanced
416 pages
14h 46m
English
IDFactory
The IDFactory class
creates different types of IDs. The static methods of this class
create known types of IDs (codat IDs, pipe IDs, etc.). The
fromURL( ) method creates these IDs based on the
protocol that is associated with each ID.
If
you want to create a new type of ID, you must provide a subclass of
the ID class and use the registerIDType( ) method
so that instances of the ID are known to the factory. You can then
use the fromURL( ) method to create instances of
the newly defined ID.
public final class IDFactory extends net.jxta.util.ClassFactory { // No Constructor // Inner Classes public static class Instantiator; // Public Class Methods public static ID fromURL(java.net.URL source) throws java.net.MalformedURLExceptionjava.net.UnknownServiceException; public static net.jxta.codat.CodatID newCodatID(net.jxta.peergroup.PeerGroupID groupID, InputStream in) throws IOException; public static net.jxta.platform.ModuleClassID newModuleClassID(); public static net.jxta.platform.ModuleClassID newModuleClassID(net.jxta.platform.ModuleClassID baseClass); public static net.jxta.platform.ModuleSpecID newModuleSpecID(net.jxta.platform.ModuleClassID baseClass); public static net.jxta.peergroup.PeerGroupID newPeerGroupID(); public static net.jxta.peer.PeerID newPeerID(net.jxta.peergroup.PeerGroupID groupID); public static net.jxta.pipe.PipeID newPipeID(net.jxta.peergroup.PeerGroupID groupID, byte[ ] seed); public static boolean registerIDType(int type, Class ...
Read now
Unlock full access