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 classNuxeoContentStream.LazyInputStreamAnInputStreamthat fetches the actual stream from aSupplieron first use.static classNuxeoContentStream.NuxeoRedirectingContentStreamANuxeoContentStreamthat will generate a redirect.
-
Field Summary
Fields Modifier and Type Field Description protected Blobblobstatic StringCONTENT_MD5_DIGEST_ALGORITHMDeprecated.since 11.1, now unusedstatic StringCONTENT_MD5_HEADER_NAMEDeprecated.since 11.1, now unusedstatic StringDIGEST_HEADER_NAMEstatic longLAST_MODIFIEDprotected CalendarlastModifiedprotected InputStreamstreamstatic StringWANT_DIGEST_HEADER_NAMEDeprecated.since 11.1, now unused
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static NuxeoContentStreamcreate(DocumentModel doc, String xpath, Blob blob, String reason, Map<String,Serializable> extendedInfos, Calendar lastModified, javax.servlet.http.HttpServletRequest request)protected InputStreamgetActualStream()BigIntegergetBigLength()StringgetCacheControl()StringgetETag()GregorianCalendargetExpires()List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement>getExtensions()StringgetFileName()GregorianCalendargetLastModified()longgetLength()StringgetMimeType()InputStreamgetStream()static booleanhasWantDigestRequestHeader(javax.servlet.http.HttpServletRequest request, String digestAlgorithm)Deprecated.since 11.1, now unusedstatic booleanisHeadRequest(javax.servlet.http.HttpServletRequest request)voidsetExtensions(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:
getLengthin interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getBigLength
public BigInteger getBigLength()
- Specified by:
getBigLengthin interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getMimeType
public String getMimeType()
- Specified by:
getMimeTypein interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getFileName
public String getFileName()
- Specified by:
getFileNamein interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getStream
public InputStream getStream()
- Specified by:
getStreamin interfaceorg.apache.chemistry.opencmis.commons.data.ContentStream
-
getActualStream
protected InputStream getActualStream()
-
getExtensions
public List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement> getExtensions()
- Specified by:
getExtensionsin interfaceorg.apache.chemistry.opencmis.commons.data.ExtensionsData
-
setExtensions
public void setExtensions(List<org.apache.chemistry.opencmis.commons.data.CmisExtensionElement> extensions)
- Specified by:
setExtensionsin interfaceorg.apache.chemistry.opencmis.commons.data.ExtensionsData
-
getCacheControl
public String getCacheControl()
- Specified by:
getCacheControlin interfaceorg.apache.chemistry.opencmis.commons.data.CacheHeaderContentStream
-
getETag
public String getETag()
- Specified by:
getETagin interfaceorg.apache.chemistry.opencmis.commons.data.CacheHeaderContentStream
-
getExpires
public GregorianCalendar getExpires()
- Specified by:
getExpiresin interfaceorg.apache.chemistry.opencmis.commons.data.CacheHeaderContentStream
-
getLastModified
public GregorianCalendar getLastModified()
- Specified by:
getLastModifiedin interfaceorg.apache.chemistry.opencmis.commons.data.LastModifiedContentStream
-
-