Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.slide.store
Class ResourceId

    java.lang.Object
      org.apache.slide.common.Uri
          org.apache.slide.store.ResourceId

All Implemented Interfaces:
  java.lang.Cloneable, java.io.Serializable

public final class ResourceId
extends Uri

Uniquely identifies a resource. The main operation with ResourceIds is equals. Immutable. Technically, ResourceId extends Uri, but the only reason to do so is compatibility with existing store interfaces. Logically, a ResourceId is *not* an Uri: Uris have a structure, resourceId have not. Consequently, almost all Uri methods in this class throw UnsupportedOperation exceptions.

Version:
  $Revision: 1.4.2.1 $
See Also:
  Serialized Form

Field Summary
`static java.lang.String` | `RESOURCE_ID_SCHEMA`

Fields inherited from class org.apache.slide.common.Uri
`namespace, scope, scopes, store, token, uri`

Method Summary
`java.lang.String` | `asXml()`
`Uri` | `cloneObject()` Do not clone ResourceId's, use aliasing.
`static ResourceId` | `create(Uri uri, java.lang.String uuri)`
`static ResourceId` | `createNew(Uri uri)`
`boolean` | `equals(java.lang.Object obj)` Tests equivalence of two ResourceIds.
`Namespace` | `getNamespace()` Return the namespace to which this Uri belongs.
`Uri` | `getParentUri()` Get the parent uri.
`java.lang.String` | `getRelative()` Get the relative path to the matched scope.
`Scope` | `getScope()` Scope accessor.
`java.util.Enumeration` | `getScopes()` Returns the scopes tokenized by the ScopeTokenizer associated with this Uri object.
`Store` | `getStore()` Store accessor.
`SlideToken` | `getToken()` Token accessor.
`java.lang.String` | `getUuri()` Intentionally does not return anything like the origianl uri.
`int` | `hashCode()` Hash code.
`void` | `invalidateServices()` Invalidate the current Services and PK.
`boolean` | `isParent(Uri uri)` Tests if the given uri represents a parent object.
`boolean` | `isStoreRoot()` Test whether this Uri is equivalent to its scope
`void` | `reconnectServices()` Reconnect the Uri services.
`void` | `setToken(SlideToken token)` Token mutator.
`void` | `setUri(java.lang.String uri)` Uri mutator.
`java.lang.String` | `toString()` String representation of the uri object.

Methods inherited from class org.apache.slide.common.Uri
`getRoot`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### RESOURCE_ID_SCHEMA

    public static java.lang.String RESOURCE_ID_SCHEMA

Method Detail

### createNew

    public static ResourceId createNew(Uri uri)

### create

    public static ResourceId create(Uri uri,
                                    java.lang.String uuri)

### equals

    public boolean equals(java.lang.Object obj)

  Tests equivalence of two ResourceIds.

  Overrides:
    `equals` in class `Uri`
  Parameters:
    `obj` - Object to test
  Returns:
    boolean

### toString

    public java.lang.String toString()

  Description copied from class: `Uri`
  String representation of the uri object.

  Overrides:
    `toString` in class `Uri`
  Returns:
    String

### getUuri

    public java.lang.String getUuri()

  Intentionally does not return anything like the origianl uri.

  Returns:
    String

### hashCode

    public int hashCode()

  Hash code.

  Overrides:
    `hashCode` in class `Uri`
  Returns:
    int hash code

### getScope

    public Scope getScope()

  Description copied from class: `Uri`
  Scope accessor.

  Overrides:
    `getScope` in class `Uri`
  Returns:
    StringTokenizer

### getStore

    public Store getStore()

  Description copied from class: `Uri`
  Store accessor.

  Overrides:
    `getStore` in class `Uri`
  Returns:
    Store

### getToken

    public SlideToken getToken()

  Description copied from class: `Uri`
  Token accessor.

  Overrides:
    `getToken` in class `Uri`
  Returns:
    The SlideToken, or null if no token has been set (which is valid)

### getNamespace

    public Namespace getNamespace()

  Description copied from class: `Uri`
  Return the namespace to which this Uri belongs.

  Overrides:
    `getNamespace` in class `Uri`
  Returns:
    Namespace

### isStoreRoot

    public boolean isStoreRoot()

  Description copied from class: `Uri`
  Test whether this Uri is equivalent to its scope

  Overrides:
    `isStoreRoot` in class `Uri`
  Returns:
    a boolean

### setUri

    public void setUri(java.lang.String uri)

  Description copied from class: `Uri`
  Uri mutator.

  Overrides:
    `setUri` in class `Uri`
  Parameters:
    `uri` - New uri

### getScopes

    public java.util.Enumeration getScopes()

  Description copied from class: `Uri`
  Returns the scopes tokenized by the ScopeTokenizer associated with this Uri object.

  Overrides:
    `getScopes` in class `Uri`
  Returns:
    Enumeration

### setToken

    public void setToken(SlideToken token)

  Description copied from class: `Uri`
  Token mutator.

  Overrides:
    `setToken` in class `Uri`
  Parameters:
    `token` - New Slide token

### getParentUri

    public Uri getParentUri()

  Description copied from class: `Uri`
  Get the parent uri.

  Overrides:
    `getParentUri` in class `Uri`
  Returns:
    Uri

### invalidateServices

    public void invalidateServices()

  Description copied from class: `Uri`
  Invalidate the current Services and PK. Used if there are changes in the namespace at runtime.

  Overrides:
    `invalidateServices` in class `Uri`

### reconnectServices

    public void reconnectServices()

  Description copied from class: `Uri`
  Reconnect the Uri services.

  Overrides:
    `reconnectServices` in class `Uri`

### getRelative

    public java.lang.String getRelative()

  Description copied from class: `Uri`
  Get the relative path to the matched scope.

  Overrides:
    `getRelative` in class `Uri`

### cloneObject

    public Uri cloneObject()

  Do not clone ResourceId's, use aliasing.

  Overrides:
    `cloneObject` in class `Uri`

### isParent

    public boolean isParent(Uri uri)

  Description copied from class: `Uri`
  Tests if the given uri represents a parent object.

  Overrides:
    `isParent` in class `Uri`
  Parameters:
    `uri` - Uri to test
  Returns:
    boolean

### asXml

    public java.lang.String asXml()

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD