Examples of JcrRepository


Examples of org.apache.chemistry.opencmis.jcr.JcrRepository

    @Override
    public List<RepositoryInfo> getRepositoryInfos(ExtensionsData extension) {
        ArrayList<RepositoryInfo> info = new ArrayList<RepositoryInfo>();
        Set<String> IDs = jcrRepositories.keySet();
        for (String Id : IDs) {
            JcrRepository repo = jcrRepositories.get(Id);
            info.addAll(repo.getRepositoryInfos(login(Id)));
        }
        return info;
    }
View Full Code Here

Examples of org.apache.chemistry.opencmis.jcr.JcrRepository

        return session;
    }

    private JcrRepository jcrRepository(String repositoryId) {
        String name = name(repositoryId);
        JcrRepository repo = jcrRepositories.get(name);
        if (repo == null) {
            throw new CmisInvalidArgumentException("Repository lookup failed for \"" + repositoryId + "\" (using name \"" + name + "\")");
        }
        return repo;
    }
View Full Code Here

Examples of org.apache.chemistry.opencmis.jcr.JcrRepository

        for (String repositoryId : names) {
            // Map params = jcrConfig.get(repositoryId);
            // Repository repository = acquireJcrRepository(params);
            try {
                Repository repository = RepositoryManager.getRepository(repositoryId);
                list.put(repositoryId, new JcrRepository(repository, pathManger, typeManager, typeHandlerManager));
                log.debug("--- loaded repository " + repositoryId);
            } catch (NoSuchRepositoryException e) {
                // should never happen;
                e.printStackTrace();
            }
View Full Code Here

Examples of org.apache.chemistry.opencmis.jcr.JcrRepository

     * should return "bar".
     */
    @Test
    public void testWorkspace() {
        String[] names = {"foo", "", "baz", "a"};
        JcrRepository mockRepo = mock(JcrRepository.class);
        Map<String, JcrRepository> jrs = new HashMap<String, JcrRepository>();
        for (String name : names) {
            jrs.put(name, mockRepo);
        }

View Full Code Here

Examples of org.modeshape.jcr.JcrRepository

    @Override
    public void start( StartContext arg0 ) throws StartException {
        ModeShapeEngine engine = getModeShapeEngine();

        JcrRepository repository = null;
        try {
            repository = engine.getRepository(repositoryName);
        } catch (NoSuchRepositoryException e) {
            throw new StartException(e);
        }

        RepositoryConfiguration repositoryConfig = repository.getConfiguration();

        Editor configEditor = repositoryConfig.edit();
        EditableDocument security = configEditor.getOrCreateDocument(FieldName.SECURITY);
        EditableArray providers = security.getOrCreateArray(FieldName.PROVIDERS);
View Full Code Here

Examples of org.modeshape.jcr.JcrRepository

    @Override
    public void start( StartContext arg0 ) throws StartException {
        ModeShapeEngine engine = getModeShapeEngine();

        JcrRepository repository = null;
        try {
            repository = engine.getRepository(repositoryName);
        } catch (NoSuchRepositoryException e) {
            throw new StartException(e);
        }

        RepositoryConfiguration repositoryConfig = repository.getConfiguration();

        Editor editor = repositoryConfig.edit();

        EditableDocument indexes = editor.getOrCreateDocument(FieldName.INDEXES);
View Full Code Here

Examples of org.modeshape.jcr.JcrRepository

    @Override
    public void start( StartContext arg0 ) throws StartException {
        ModeShapeEngine engine = getModeShapeEngine();

        JcrRepository repository = null;
        try {
            repository = engine.getRepository(repositoryName);
        } catch (NoSuchRepositoryException e) {
            throw new StartException(e);
        }

        RepositoryConfiguration repositoryConfig = repository.getConfiguration();

        Editor configEditor = repositoryConfig.edit();
        EditableDocument externalSources = configEditor.getOrCreateDocument(RepositoryConfiguration.FieldName.EXTERNAL_SOURCES);

        EditableDocument externalSource = Schematic.newDocument();
View Full Code Here

Examples of org.modeshape.jcr.JcrRepository

    @Override
    public void start( StartContext arg0 ) throws StartException {
        ModeShapeEngine engine = getModeShapeEngine();

        JcrRepository repository = null;
        try {
            repository = engine.getRepository(repositoryName);
        } catch (NoSuchRepositoryException e) {
            throw new StartException(e);
        }

        RepositoryConfiguration repositoryConfig = repository.getConfiguration();

        Editor configEditor = repositoryConfig.edit();
        EditableDocument textExtracting = configEditor.getOrCreateDocument(FieldName.TEXT_EXTRACTION);
        EditableDocument extractors = textExtracting.getOrCreateDocument(FieldName.EXTRACTORS);
View Full Code Here

Examples of org.modeshape.jcr.JcrRepository

    @Override
    public void start( StartContext arg0 ) throws StartException {
        ModeShapeEngine engine = getModeShapeEngine();

        JcrRepository repository = null;
        try {
            repository = engine.getRepository(repositoryName);
        } catch (NoSuchRepositoryException e) {
            throw new StartException(e);
        }

        RepositoryConfiguration repositoryConfig = repository.getConfiguration();

        Editor editor = repositoryConfig.edit();

        EditableDocument sequencing = editor.getOrCreateDocument(FieldName.SEQUENCING);
        EditableDocument sequencers = sequencing.getOrCreateDocument(FieldName.SEQUENCERS);
View Full Code Here

Examples of org.modeshape.jcr.JcrRepository

    @Override
    public void start( StartContext arg0 ) throws StartException {
        ModeShapeEngine engine = getModeShapeEngine();

        JcrRepository repository = null;
        try {
            repository = engine.getRepository(repositoryName);
        } catch (NoSuchRepositoryException e) {
            throw new StartException(e);
        }

        RepositoryConfiguration repositoryConfig = repository.getConfiguration();

        Editor editor = repositoryConfig.edit();

        EditableDocument providers = editor.getOrCreateDocument(FieldName.INDEX_PROVIDERS);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.