Class NuxeoContentStream
- java.lang.Object
-
- org.nuxeo.ecm.core.opencmis.impl.server.NuxeoContentStream
-
- All Implemented Interfaces:
org.apache.chemistry.opencmis.commons.data.CacheHeaderContentStream
,org.apache.chemistry.opencmis.commons.data.ContentLengthContentStream
,org.apache.chemistry.opencmis.commons.data.ContentStream
,org.apache.chemistry.opencmis.commons.data.ExtensionsData
,org.apache.chemistry.opencmis.commons.data.LastModifiedContentStream
- Direct Known Subclasses:
NuxeoContentStream.NuxeoRedirectingContentStream
public class NuxeoContentStream extends Object implements org.apache.chemistry.opencmis.commons.data.CacheHeaderContentStream, org.apache.chemistry.opencmis.commons.data.LastModifiedContentStream, org.apache.chemistry.opencmis.commons.data.ContentLengthContentStream
Nuxeo implementation of a CMISContentStream
, backed by aBlob
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
NuxeoContentStream.LazyInputStream
AnInputStream
that fetches the actual stream from aSupplier
on first use.static class
NuxeoContentStream.NuxeoRedirectingContentStream
ANuxeoContentStream
that will generate a redirect.
-
Field Summary
Fields Modifier and Type Field Description protected Blob
blob
static String
CONTENT_MD5_DIGEST_ALGORITHM
Deprecated.since 11.1, now unusedstatic String
CONTENT_MD5_HEADER_NAME
Deprecated.since 11.1, now unusedstatic String
DIGEST_HEADER_NAME
static long
LAST_MODIFIED
protected Calendar
lastModified
protected InputStream
stream
static String
WANT_DIGEST_HEADER_NAME
Deprecated.since 11.1, now unused
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static NuxeoContentStream
create(DocumentModel doc, String xpath, Blob blob, String reason, Map<String,Serializable> extendedInfos, Calendar lastModified, javax.servlet.http.HttpServletRequest request)
protected InputStream
getActualStream()
BigInteger
getBigLength()
String
getCacheControl()
String
getETag()
GregorianCalendar
getExpires()
List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement>
getExtensions()
String
getFileName()
GregorianCalendar
getLastModified()
long
getLength()
String
getMimeType()
InputStream
getStream()
static boolean
hasWantDigestRequestHeader(javax.servlet.http.HttpServletRequest request, String digestAlgorithm)
Deprecated.since 11.1, now unusedstatic boolean
isHeadRequest(javax.servlet.http.HttpServletRequest request)
void
setExtensions(List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement> extensions)
-
-
-
Field Detail
-
CONTENT_MD5_DIGEST_ALGORITHM
@Deprecated public static final String CONTENT_MD5_DIGEST_ALGORITHM
Deprecated.since 11.1, now unused- See Also:
- Constant Field Values
-
CONTENT_MD5_HEADER_NAME
@Deprecated public static final String CONTENT_MD5_HEADER_NAME
Deprecated.since 11.1, now unused- See Also:
- Constant Field Values
-
WANT_DIGEST_HEADER_NAME
@Deprecated public static final String WANT_DIGEST_HEADER_NAME
Deprecated.since 11.1, now unused- See Also:
- Constant Field Values
-
DIGEST_HEADER_NAME
public static final String DIGEST_HEADER_NAME
- See Also:
- Constant Field Values
-
LAST_MODIFIED
public static long LAST_MODIFIED
-
blob
protected final Blob blob
-
lastModified
protected final Calendar lastModified
-
stream
protected final InputStream stream
-
-
Method Detail
-
create
public static NuxeoContentStream create(DocumentModel doc, String xpath, Blob blob, String reason, Map<String,Serializable> extendedInfos, Calendar lastModified, javax.servlet.http.HttpServletRequest request)
-
isHeadRequest
public static boolean isHeadRequest(javax.servlet.http.HttpServletRequest request)
-
hasWantDigestRequestHeader
@Deprecated public static boolean hasWantDigestRequestHeader(javax.servlet.http.HttpServletRequest request, String digestAlgorithm)
Deprecated.since 11.1, now unused
-
getLength
public long getLength()
- Specified by:
getLength
in interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getBigLength
public BigInteger getBigLength()
- Specified by:
getBigLength
in interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getMimeType
public String getMimeType()
- Specified by:
getMimeType
in interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getFileName
public String getFileName()
- Specified by:
getFileName
in interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getStream
public InputStream getStream()
- Specified by:
getStream
in interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getActualStream
protected InputStream getActualStream()
-
getExtensions
public List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement> getExtensions()
- Specified by:
getExtensions
in interfaceorg.apache.chemistry.opencmis.commons.data.ExtensionsData
-
setExtensions
public void setExtensions(List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement> extensions)
- Specified by:
setExtensions
in interfaceorg.apache.chemistry.opencmis.commons.data.ExtensionsData
-
getCacheControl
public String getCacheControl()
- Specified by:
getCacheControl
in interfaceorg.apache.chemistry.opencmis.commons.data.CacheHeaderContentStream
-
getETag
public String getETag()
- Specified by:
getETag
in interfaceorg.apache.chemistry.opencmis.commons.data.CacheHeaderContentStream
-
getExpires
public GregorianCalendar getExpires()
- Specified by:
getExpires
in interfaceorg.apache.chemistry.opencmis.commons.data.CacheHeaderContentStream
-
getLastModified
public GregorianCalendar getLastModified()
- Specified by:
getLastModified
in interfaceorg.apache.chemistry.opencmis.commons.data.LastModifiedContentStream
-
-