Package org.apache.maven.index.context

Examples of org.apache.maven.index.context.MergedIndexingContext


        NexusIndexer indexer = prepare();

        File indexMergedDir = super.getDirectory( "index/testMerged" );

        IndexingContext mergedContext =
            new MergedIndexingContext( "test", "merged", context.getRepository(), indexMergedDir, true,
                new StaticContextMemberProvider( Collections.singletonList( context ) ) );

        performQueryCreatorNGSearch( indexer, mergedContext );
    }
View Full Code Here


                                                        File indexDirectory, boolean searchable,
                                                        ContextMemberProvider membersProvider )
        throws IOException
    {
        IndexingContext context =
            new MergedIndexingContext( id, repositoryId, repository, indexDirectory, searchable, membersProvider );
        return context;
    }
View Full Code Here

        Directory indexDirectory, boolean searchable,
        Collection<IndexingContext> contexts )
        throws IOException
    {
        IndexingContext context =
            new MergedIndexingContext( id, repositoryId, repository, indexDirectory, searchable,
                                       new StaticContextMemberProvider( contexts ) );
        indexingContexts.put( context.getId(), context );
        return context;
    }
View Full Code Here

        Directory indexDirectory, boolean searchable,
        ContextMemberProvider membersProvider )
        throws IOException
    {
        IndexingContext context =
            new MergedIndexingContext( id, repositoryId, repository, indexDirectory, searchable, membersProvider );
        indexingContexts.put( context.getId(), context );
        return context;
    }
View Full Code Here

    {
        // remove the merged
        nexusIndexer.removeIndexingContext( context, true );

        // remove members
        MergedIndexingContext mctx = (MergedIndexingContext) context;

        for ( IndexingContext member : mctx.getMembers() )
        {
            nexusIndexer.removeIndexingContext( member, true );
        }
    }
View Full Code Here

    }

    public void testMembersAndMergedRootGroups()
        throws Exception
    {
        MergedIndexingContext mctx = (MergedIndexingContext) context;

        for ( IndexingContext member : mctx.getMembers() )
        {
            Assert.assertEquals( "Members should have one root group!", 1, member.getRootGroups().size() );
        }

        Assert.assertEquals( "Merged should have one root multiply members count!", mctx.getMembers().size(),
            mctx.getRootGroups().size() );
    }
View Full Code Here

        if (groupContext instanceof LockingIndexingContext) {
          groupContext = ((LockingIndexingContext) groupContext).getContext();
        }

        lockedContext = new MergedIndexingContext(groupContext.getId(), //
            groupContext.getRepositoryId(), //
            groupContext.getRepository(), //
            groupContext.getIndexDirectory(), //
            groupContext.isSearchable(), //
            new StaticContextMemberProvider(memberContexts))
View Full Code Here

TOP

Related Classes of org.apache.maven.index.context.MergedIndexingContext

Copyright © 2018 www.massapicom. 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.