public class JcrReadServlet
extends javax.servlet.http.HttpServlet
Modifier and Type | Field and Description |
---|---|
protected static java.lang.String |
_JCR |
protected static java.lang.String |
ACCEPT_HTTP_HEADER |
protected static java.lang.String |
CONTENT_DISPOSITION_HTTP_HEADER |
protected static java.lang.String |
JCR_NAME |
protected static java.lang.String |
JCR_NODES |
protected static java.lang.String |
JCR_PATH |
protected static java.lang.String |
JCR_PREFIX |
protected static java.lang.String |
JSON_CONTENT_TYPE |
protected static java.lang.String |
OCTET_STREAM_CONTENT_TYPE |
protected static java.lang.String |
REP_PREFIX |
protected static java.lang.String |
XML_CONTENT_TYPE |
Constructor and Description |
---|
JcrReadServlet() |
Modifier and Type | Method and Description |
---|---|
protected void |
doGet(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp) |
protected java.lang.String |
getJcrPath(javax.servlet.http.HttpServletRequest req) |
protected com.fasterxml.jackson.databind.ObjectMapper |
getObjectMapper() |
protected Repository |
getRepository() |
protected java.lang.String |
getWorkspace(javax.servlet.http.HttpServletRequest req) |
protected Session |
openJcrSession(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse resp,
Repository repository,
java.lang.String workspace) |
protected java.util.List<java.lang.String> |
readAcceptHeader(javax.servlet.http.HttpServletRequest req) |
void |
setMaxDepth(java.lang.Integer maxDepth) |
void |
setRepository(Repository repository) |
protected void |
writeNodeChildren(Node node,
com.fasterxml.jackson.core.JsonGenerator jsonGenerator,
int depth,
boolean verbose) |
protected void |
writeNodeProperties(Node node,
com.fasterxml.jackson.core.JsonGenerator jsonGenerator,
boolean verbose) |
protected void |
writeProperty(java.lang.String fieldName,
Property property,
com.fasterxml.jackson.core.JsonGenerator jsonGenerator) |
protected void |
writePropertyValue(int type,
Value value,
com.fasterxml.jackson.core.JsonGenerator jsonGenerator) |
doDelete, doHead, doOptions, doPost, doPut, doTrace, getLastModified, service, service
protected static final java.lang.String ACCEPT_HTTP_HEADER
protected static final java.lang.String CONTENT_DISPOSITION_HTTP_HEADER
protected static final java.lang.String OCTET_STREAM_CONTENT_TYPE
protected static final java.lang.String XML_CONTENT_TYPE
protected static final java.lang.String JSON_CONTENT_TYPE
protected static final java.lang.String JCR_NODES
protected static final java.lang.String JCR_PATH
protected static final java.lang.String JCR_NAME
protected static final java.lang.String _JCR
protected static final java.lang.String JCR_PREFIX
protected static final java.lang.String REP_PREFIX
protected void doGet(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws javax.servlet.ServletException, java.io.IOException
doGet
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
java.io.IOException
protected Session openJcrSession(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp, Repository repository, java.lang.String workspace) throws RepositoryException
RepositoryException
protected java.lang.String getWorkspace(javax.servlet.http.HttpServletRequest req)
protected java.lang.String getJcrPath(javax.servlet.http.HttpServletRequest req)
protected java.util.List<java.lang.String> readAcceptHeader(javax.servlet.http.HttpServletRequest req)
protected void writeNodeProperties(Node node, com.fasterxml.jackson.core.JsonGenerator jsonGenerator, boolean verbose) throws RepositoryException, java.io.IOException
RepositoryException
java.io.IOException
protected void writeProperty(java.lang.String fieldName, Property property, com.fasterxml.jackson.core.JsonGenerator jsonGenerator) throws RepositoryException, java.io.IOException
RepositoryException
java.io.IOException
protected void writePropertyValue(int type, Value value, com.fasterxml.jackson.core.JsonGenerator jsonGenerator) throws RepositoryException, java.io.IOException
RepositoryException
java.io.IOException
protected void writeNodeChildren(Node node, com.fasterxml.jackson.core.JsonGenerator jsonGenerator, int depth, boolean verbose) throws RepositoryException, java.io.IOException
RepositoryException
java.io.IOException
public void setRepository(Repository repository)
public void setMaxDepth(java.lang.Integer maxDepth)
protected Repository getRepository()
protected com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()
Copyright © 2007–2020. All rights reserved.