Overview | Package | Class | Tree | Deprecated | Index | Help
| © 2005 BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.content.manager
Interface RepositoryManager

All Superinterfaces:
  Serializable

public interface RepositoryManager
extends Serializable

This class acts as a virtual repository to all configured repositories. It is the entry point to connect to and operate on the repositories. For each available Repository, a RepositorySession will be created and added to the returned array. A connection may also be attempted to a specific Repository in which case, the RepositorySession for that attempted connection will be added to the RepositorySession array and returned. The RepositoryManager may be cached (perhaps in the HttpSession). If this is the case, it is up to the client to keep RepositorySessions in sync with the user's connection and disconnections to Repositories.

Method Summary
`void` | `addSession(String repositoryName, RepositorySession session)` Adds a RepositorySession.
`RepositorySession[]` | `connect()` Attempts to connect to all availble Repositories with the current user's Credenntials.
`RepositorySession` | `connect(String repositoryName)` Attempts to connect to a specific repository using the current user's credentials and returns the RepositorySession based on the attempt.
`RepositorySession` | `connect(String repositoryName, String userName, String password)` Attempts to connect to a specific repository and returns the RepositorySession based on the attempt.
`NodeOps` | `getNodeOps()` Gets a NodeOps service.
`ObjectClassOps` | `getObjectClassOps()` Gets a ObjectClassOps service.
`RepositoryOps` | `getRepositoryOps()` Gets a RepositoryOps service.
`SearchOps` | `getSearchOps()` Gets a SearchOps service.
`RepositorySession[]` | `getSessions()` Gets the RepositorySessions.
`WorkspaceOps` | `getWorkspaceOps()` Gets a WorkspaceOps service object
`void` | `removeSession(String repositoryName)` Removes a RepositorySession

Method Detail

### addSession

    public void addSession(String repositoryName,
                           RepositorySession session)

  Adds a RepositorySession.

  Parameters:
    `repositoryName` - - the name of the Repository to which the RepositorySession is for.
    `session` - - the RepositorySession for the the Repository.

### connect

    public RepositorySession[] connect()
                                throws NoRepositoriesDefinedException,
                                       RepositoryException

  Attempts to connect to all availble Repositories with the current user's Credenntials. A RepositorySession is created for each Repository and added to the returned array. Any error in connecting is described by the RepositorySession's state.

  Returns:
    RepositorySession[] - an array of the RepositiorySessions, one for each Repository that a connection was attempted.
  Throws:
    `NoRepositoriesDefinedException` - - if there isn't any Repository defined to connect to.
    `RepositoryException` - if an error occurs.

### connect

    public RepositorySession connect(String repositoryName)

  Attempts to connect to a specific repository using the current user's credentials and returns the RepositorySession based on the attempt. Any error in connecting is described by the RepositorySession's state.

  Parameters:
    `repositoryName` - the name of the Repository to connect to.

### connect

    public RepositorySession connect(String repositoryName,
                                     String userName,
                                     String password)

  Attempts to connect to a specific repository and returns the RepositorySession based on the attempt. Any error in connecting is described by the RepositorySession's state.

  Parameters:
    `repositoryName` - - the name of the Repository to connect to.
    `userName` - - the username to connect with.
    `password` - - the password to connect with.
  Returns:
    RepositorySession - the session that contains the state of the connection attempt.

### getNodeOps

    public NodeOps getNodeOps()

  Gets a NodeOps service.

  Returns:
    NodeOps - the NodeOps manager.

### getObjectClassOps

    public ObjectClassOps getObjectClassOps()

  Gets a ObjectClassOps service.

  Returns:
    ObjectClassOps - the ObjectClassOps manager.

### getRepositoryOps

    public RepositoryOps getRepositoryOps()

  Gets a RepositoryOps service.

  Returns:
    RepositoryOps - the RepositoryOps manager.

### getSearchOps

    public SearchOps getSearchOps()

  Gets a SearchOps service.

  Returns:
    SearchOps - the SearchOps manager.

### getSessions

    public RepositorySession[] getSessions()

  Gets the RepositorySessions.

### getWorkspaceOps

    public WorkspaceOps getWorkspaceOps()

  Gets a WorkspaceOps service object

  Returns:
    WorkspaceOps - the WorkspaceOps service.

### removeSession

    public void removeSession(String repositoryName)

  Removes a RepositorySession

  Parameters:
    `repositoryName` - - the name of the repository to remove the RepositorySession for.

Overview | Package | Class | Tree | Deprecated | Index | Help
| © 2005 BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2005 BEA Systems, Inc. All Rights Reserved