public class MicroKernelImpl extends Object implements org.apache.jackrabbit.mk.api.MicroKernel
| Modifier and Type | Field and Description |
|---|---|
protected Repository |
rep |
| Constructor and Description |
|---|
MicroKernelImpl()
Creates a new in-memory kernel instance that doesn't need to be
explicitly closed, i.e.
|
MicroKernelImpl(Repository rep)
Alternate constructor, used for testing.
|
MicroKernelImpl(String homeDir) |
| Modifier and Type | Method and Description |
|---|---|
String |
branch(String trunkRevisionId) |
String |
commit(String path,
String jsonDiff,
String revisionId,
String message) |
String |
diff(String fromRevision,
String toRevision,
String path,
int depth) |
void |
dispose() |
long |
getChildNodeCount(String path,
String revisionId) |
String |
getHeadRevision() |
String |
getJournal(String fromRevision,
String toRevision,
String path) |
long |
getLength(String blobId) |
String |
getNodes(String path,
String revisionId,
int depth,
long offset,
int maxChildNodes,
String filter) |
String |
getRevisionHistory(long since,
int maxEntries,
String path) |
protected void |
init(String homeDir) |
String |
merge(String branchRevisionId,
String message) |
boolean |
nodeExists(String path,
String revisionId) |
int |
read(String blobId,
long pos,
byte[] buff,
int off,
int length) |
String |
waitForCommit(String oldHeadRevisionId,
long maxWaitMillis) |
String |
write(InputStream in) |
protected Repository rep
public MicroKernelImpl(String homeDir) throws org.apache.jackrabbit.mk.api.MicroKernelException
org.apache.jackrabbit.mk.api.MicroKernelExceptionpublic MicroKernelImpl()
public MicroKernelImpl(Repository rep)
rep - repository, already initializedprotected void init(String homeDir) throws org.apache.jackrabbit.mk.api.MicroKernelException
org.apache.jackrabbit.mk.api.MicroKernelExceptionpublic void dispose()
public String getHeadRevision() throws org.apache.jackrabbit.mk.api.MicroKernelException
getHeadRevision in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic String getRevisionHistory(long since, int maxEntries, String path) throws org.apache.jackrabbit.mk.api.MicroKernelException
getRevisionHistory in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic String waitForCommit(String oldHeadRevisionId, long maxWaitMillis) throws org.apache.jackrabbit.mk.api.MicroKernelException, InterruptedException
waitForCommit in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionInterruptedExceptionpublic String getJournal(String fromRevision, String toRevision, String path) throws org.apache.jackrabbit.mk.api.MicroKernelException
getJournal in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic String diff(String fromRevision, String toRevision, String path, int depth) throws org.apache.jackrabbit.mk.api.MicroKernelException
diff in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic boolean nodeExists(String path, String revisionId) throws org.apache.jackrabbit.mk.api.MicroKernelException
nodeExists in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic long getChildNodeCount(String path, String revisionId) throws org.apache.jackrabbit.mk.api.MicroKernelException
getChildNodeCount in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic String getNodes(String path, String revisionId, int depth, long offset, int maxChildNodes, String filter) throws org.apache.jackrabbit.mk.api.MicroKernelException
getNodes in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic String commit(String path, String jsonDiff, String revisionId, String message) throws org.apache.jackrabbit.mk.api.MicroKernelException
commit in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic String branch(String trunkRevisionId) throws org.apache.jackrabbit.mk.api.MicroKernelException
branch in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic String merge(String branchRevisionId, String message) throws org.apache.jackrabbit.mk.api.MicroKernelException
merge in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic long getLength(String blobId) throws org.apache.jackrabbit.mk.api.MicroKernelException
getLength in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic int read(String blobId, long pos, byte[] buff, int off, int length) throws org.apache.jackrabbit.mk.api.MicroKernelException
read in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionpublic String write(InputStream in) throws org.apache.jackrabbit.mk.api.MicroKernelException
write in interface org.apache.jackrabbit.mk.api.MicroKernelorg.apache.jackrabbit.mk.api.MicroKernelExceptionCopyright © 2012-2013 The Apache Software Foundation. All Rights Reserved.