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

## org.modeshape.graph.connector.path
Interface PathWorkspace

All Known Subinterfaces:
  WritablePathWorkspace

All Known Implementing Classes:
  AbstractWritablePathWorkspace

    public interface PathWorkspace

Method Summary
`Path` | `getLowestExistingPath(Path path)` Find the lowest existing node along the path.
`String` | `getName()` Returns the name of the workspace.
`PathNode` | `getNode(Path path)` Returns the node at the given path, if one exists of `null` if no exists at the given path.
`void` | `lockNode(PathNode node, LockBranchRequest.LockScope lockScope, long lockTimeoutInMillis)` Attempts to lock the given node with the given timeout.
`QueryResults` | `query(ExecutionContext context, AccessQueryRequest accessQuery)` Perform a query of this workspace.
`QueryResults` | `search(ExecutionContext context, String fullTextSearchExpression)` Perform a full-text search of this workspace.
`void` | `unlockNode(PathNode node)` Attempts to unlock the given node.

Method Detail

### getName

    String getName()

  Returns the name of the workspace. There can only be one workspace with a given name per repository.

  Returns:
    the name of the workspace

### getNode

    PathNode getNode(Path path)

  Returns the node at the given path, if one exists of `null` if no exists at the given path.

  Parameters:
    `path` - the path of the node to retrieve; may not be null
  Returns:
    the node at the given path, if one exists of `null` if no exists at the given path.

### lockNode

    void lockNode(PathNode node,
                  LockBranchRequest.LockScope lockScope,
                  long lockTimeoutInMillis)
                  throws LockFailedException

  Attempts to lock the given node with the given timeout. If the lock attempt fails, a `LockFailedException` will be thrown.

  Parameters:
    `node` - the node to be locked; may not be null
    `lockScope` - the scope of the lock (i.e., whether descendants of `node` should be included in the lock
    `lockTimeoutInMillis` - the maximum lifetime of the lock in milliseconds; zero (0) indicates that the connector default should be used
  Throws:
    `LockFailedException` - if the implementing connector supports locking but the lock could not be acquired.

### unlockNode

    void unlockNode(PathNode node)

  Attempts to unlock the given node.

  Parameters:
    `node` - the node to be unlocked; may not be null

### getLowestExistingPath

    Path getLowestExistingPath(Path path)

  Find the lowest existing node along the path.

  Parameters:
    `path` - the path to the node; may not be null
  Returns:
    the lowest existing node along the path, or the root node if no node exists on the path

### query

    QueryResults query(ExecutionContext context,
                       AccessQueryRequest accessQuery)

  Perform a query of this workspace.

  Parameters:
    `context` - the context in which the query is to be executed; may not be null
    `accessQuery` - the access query; may not be null
  Returns:
    the query results, or null if the query is not supported

### search

    QueryResults search(ExecutionContext context,
                        String fullTextSearchExpression)

  Perform a full-text search of this workspace.

  Parameters:
    `context` - the context in which the query is to be executed; may not be null
    `fullTextSearchExpression` - the full-text search expression; may not be null
  Returns:
    the query results, or null if the query is not supported

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

Copyright © 2008-2011 JBoss, a division of Red Hat. All Rights Reserved.