Package org.apache.jackrabbit.webdav.io
Class InputContextImpl
java.lang.Object
org.apache.jackrabbit.webdav.io.InputContextImpl
- All Implemented Interfaces:
InputContext
InputContextImpl class encapsulates the InputStream
and some header values as present in the POST, PUT or MKCOL request.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the content language ornull.longReturns the length of the data or -1 if the contentlength could not be determined.Return the content type ornullReturns the input stream of the resource to import.longReturns the modification time of the resource or the current time if the modification time has not been set.getProperty(String propertyName) Returns the value of the given property ornullif this property does not exist.booleanReturn true, if there are any data to be imported (and not only properties)
-
Constructor Details
-
InputContextImpl
-
-
Method Details
-
hasStream
public boolean hasStream()Description copied from interface:InputContextReturn true, if there are any data to be imported (and not only properties)- Specified by:
hasStreamin interfaceInputContext- Returns:
-
getInputStream
Returns the input stream of the resource to import.- Specified by:
getInputStreamin interfaceInputContext- Returns:
- the input stream.
-
getModificationTime
public long getModificationTime()Description copied from interface:InputContextReturns the modification time of the resource or the current time if the modification time has not been set.- Specified by:
getModificationTimein interfaceInputContext- Returns:
- the modification time.
-
getContentLanguage
Returns the content language ornull.- Specified by:
getContentLanguagein interfaceInputContext- Returns:
- contentLanguage
-
getContentLength
public long getContentLength()Description copied from interface:InputContextReturns the length of the data or -1 if the contentlength could not be determined.- Specified by:
getContentLengthin interfaceInputContext- Returns:
- content length or -1 when unknown
-
getContentType
Description copied from interface:InputContextReturn the content type ornull- Specified by:
getContentTypein interfaceInputContext- Returns:
-
getProperty
Description copied from interface:InputContextReturns the value of the given property ornullif this property does not exist.- Specified by:
getPropertyin interfaceInputContext- Parameters:
propertyName-- Returns:
- String property value or
null
-