Project JXTA

net.jxta.codat
Class CodatID

java.lang.Object
  extended bynet.jxta.id.ID
      extended bynet.jxta.codat.CodatID
All Implemented Interfaces:
Serializable

public abstract class CodatID
extends ID

Codats are JXTA objects that can hold both data or code.

Codats are containers objects that are used to hold any kinds of objects or data. A codat can represent a file, a class file, the saved state of an application, a loadable C library. Codats are handled transparently by the JXTA platform, and are used as placeholders for any type of data. Codats holds a Document that represent the data that they hold.

Each Codat is assigned a unique codat id that enables canonical references to be made to the codat in the context of a specific peer group. A CodatID is formed by the conjuction of a PeerGroupID, a randomly chosen value that has a high probability of being unique, and an optional SHA1 cryptographic hash of the codat contents. The Id is the unique Id for this Codat within the JXTA world. Some codats may not hold a document. In that case the CodatId is constructed without the document hash value.

See Also:
Codat, Document, StructuredDocument, Serialized Form

Field Summary
 
Fields inherited from class net.jxta.id.ID
nullID, URIEncodingName, URNNamespace
 
Constructor Summary
protected CodatID()
          Constructs a new CodatID
 
Method Summary
abstract  ID getPeerGroupID()
          Returns PeerGroupID of the Peer Group to which this Codat ID belongs.
abstract  boolean isStatic()
          Returns true if this CodatID is associated with a static Codat.
 
Methods inherited from class net.jxta.id.ID
clone, create, getIDFormat, getUniqueValue, getURL, toString, toURI
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CodatID

protected CodatID()
Constructs a new CodatID

Method Detail

getPeerGroupID

public abstract ID getPeerGroupID()
Returns PeerGroupID of the Peer Group to which this Codat ID belongs.

Returns:
PeerGroupID of the Peer Group which this ID is part of.

isStatic

public abstract boolean isStatic()
Returns true if this CodatID is associated with a static Codat.

Returns:
boolean check if the codatId is for a codat without document (Static codat)

JXTA J2SE