org.apache.jackrabbit.oak.jcr.Jcr Java Examples

The following examples show how to use org.apache.jackrabbit.oak.jcr.Jcr. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: PrincipalBasedTest.java    From jackrabbit-filevault with Apache License 2.0 5 votes vote down vote up
@BeforeClass
public static void initRepository() {
    repository = new Jcr()
            .with(createSecurityProvider())
            .withAtomicCounter()
            .createRepository();
}
 
Example #2
Source File: TestCugHandling.java    From jackrabbit-filevault with Apache License 2.0 5 votes vote down vote up
private static Repository createRepository() {
    SecurityProvider securityProvider = createSecirityProvider();
    QueryEngineSettings queryEngineSettings = new QueryEngineSettings();
    queryEngineSettings.setFailTraversal(true);
    Jcr jcr = new Jcr();
    jcr.with(securityProvider);
    jcr.with(queryEngineSettings);
    return jcr.createRepository();
}
 
Example #3
Source File: TestBase.java    From sling-whiteboard with Apache License 2.0 4 votes vote down vote up
protected static void setupRepository() {
    log.debug("Initializing Repository");
    final Repository rawRepository = new Jcr(new Oak()).createRepository();
    repository = new LazyLoadingRepository(rawRepository, CONTENT_LOADER_SUPPLIER.get());
}
 
Example #4
Source File: TestNamespaceImport.java    From jackrabbit-filevault with Apache License 2.0 4 votes vote down vote up
private Instance()
        throws RepositoryException {
    repository = new Jcr().createRepository();
    admin = repository.login(new SimpleCredentials("admin", "admin".toCharArray()));
    packMgr = new JcrPackageManagerImpl(admin, new String[0]);
}