public class ID extends Object implements org.fcrepo.jcr.FedoraJcrTypes
Fedora3FederationConnector to the types of objects each represents.
Objects within the federation can fall into 4 types:
The IDs are meant to be opaque and the implementation may change in later versions of this class, but for reference, the current implementation creates ids in the following pattern. /, /pid, /pid/dsid, /pid/dsid/content
| Modifier and Type | Field and Description |
|---|---|
static ID |
ROOT_ID
The ID for the root of the federation.
|
| Constructor and Description |
|---|
ID(String id)
A constructor that accepts a known id.
|
| Modifier and Type | Method and Description |
|---|---|
static ID |
contentID(String pid,
String datastream)
Gets the ID for the node within the federation representing datastream
content with the given dsid on the object in the federation having the
given pid.
|
static ID |
datastreamID(String pid,
String datastream)
Gets the ID for the node within the federation representing a datastream
with the given dsid on the object in the federation having the given
pid.
|
String |
getDSID()
Gets the DSID associated with this id or null if the object represented
by the node with this id does not pertain to a datastream or its
content.
|
String |
getId()
Gets the ID within the federation.
|
String |
getName()
Gets a name for the node with this id.
|
String |
getParentId()
Gets the id for the parent within the federation of the node with
this id.
|
String |
getPid()
Gets the PID associated with this id.
|
String |
getURLPath()
Gets the URL path (relative to the federation root) that would address
the node with this id.
|
boolean |
isContentID()
Determines if the id is for a fedora 3 datastream content node.
|
boolean |
isDatastreamID()
Determines if the id is for a fedora 3 datastream.
|
boolean |
isObjectID()
Determines if the id is for a fedora 3 object.
|
boolean |
isRootID()
Determines if the id is the root id.
|
static ID |
objectID(String pid)
Gets the ID for the node within the federation representing an object
with the given pid.
|
public static final ID ROOT_ID
public ID(String id)
public String getName()
public String getId()
public String getURLPath()
public String getParentId()
public boolean isRootID()
public boolean isObjectID()
public String getPid()
public String getDSID()
public boolean isDatastreamID()
public boolean isContentID()
public static ID objectID(String pid)
public static ID datastreamID(String pid, String datastream)
Copyright © 2013 DuraSpace, Inc.. All rights reserved.