|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.jackrabbit.server.io.ImportContextImpl
public class ImportContextImpl
ImportContextImpl...
| Constructor Summary | |
|---|---|
ImportContextImpl(javax.jcr.Item importRoot,
String systemId,
InputContext inputCtx)
Creates a new item import context with the given root item and the specified InputContext. |
|
ImportContextImpl(javax.jcr.Item importRoot,
String systemId,
InputContext inputCtx,
MimeResolver mimeResolver)
Creates a new item import context with the given root item and the specified InputContext. |
|
ImportContextImpl(javax.jcr.Item importRoot,
String systemId,
InputStream in,
IOListener ioListener)
Creates a new item import context. |
|
ImportContextImpl(javax.jcr.Item importRoot,
String systemId,
InputStream in,
IOListener ioListener,
MimeResolver mimeResolver)
Creates a new item import context. |
|
| Method Summary | |
|---|---|
String |
getContentLanguage()
Returns the content language or null |
long |
getContentLength()
Returns the length of the data or -1 if
the content length could not be determined. |
String |
getEncoding()
Returns the encoding extracted from a content type as present in a request header or null |
javax.jcr.Item |
getImportRoot()
Returns the import root of the resource to import, i.e. the parent node of the new content to be created. |
InputStream |
getInputStream()
Returns a new InputStream to the temporary file created
during instanciation or null, if this context does not
provide a stream. |
IOListener |
getIOListener()
Returns the IOListener. |
MimeResolver |
getMimeResolver()
Return the MimeResolver defined for this import context. |
String |
getMimeType()
Returns the main media type. |
long |
getModificationTime()
Returns the modification time of the resource or the current time if the modification time has not been set. |
Object |
getProperty(Object propertyName)
|
String |
getSystemId()
Returns the system id of the resource to be imported. |
boolean |
hasStream()
Return true if the given export context can provide an output stream |
void |
informCompleted(boolean success)
Informs this context that it will not be used for futher exports any more. |
boolean |
isCompleted()
Returns true if this context already has been completed. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ImportContextImpl(javax.jcr.Item importRoot,
String systemId,
InputContext inputCtx)
throws IOException
InputContext. If the input context provides an
input stream, the stream is written to a temporary file in order to avoid
problems with multiple IOHandlers that try to run the import but fail.
The temporary file is deleted as soon as this context is informed that
the import has been completed and it will not be used any more.
importRoot - the import root nodesystemId - inputCtx - wrapped by this ImportContext
IOException
public ImportContextImpl(javax.jcr.Item importRoot,
String systemId,
InputContext inputCtx,
MimeResolver mimeResolver)
throws IOException
InputContext. If the input context provides an
input stream, the stream is written to a temporary file in order to avoid
problems with multiple IOHandlers that try to run the import but fail.
The temporary file is deleted as soon as this context is informed that
the import has been completed and it will not be used any more.
importRoot - the import root nodesystemId - inputCtx - wrapped by this ImportContextmimeResolver -
IOException
public ImportContextImpl(javax.jcr.Item importRoot,
String systemId,
InputStream in,
IOListener ioListener)
throws IOException
importRoot - systemId - in - ioListener -
IOExceptionIOContext.informCompleted(boolean)
public ImportContextImpl(javax.jcr.Item importRoot,
String systemId,
InputStream in,
IOListener ioListener,
MimeResolver mimeResolver)
throws IOException
importRoot - systemId - in - ioListener - mimeResolver -
IOExceptionIOContext.informCompleted(boolean)| Method Detail |
|---|
public IOListener getIOListener()
IOContext
getIOListener in interface IOContextIOContext.getIOListener()public javax.jcr.Item getImportRoot()
ImportContext
getImportRoot in interface ImportContextImportContext.getImportRoot()public MimeResolver getMimeResolver()
ImportContextMimeResolver defined for this import context.
getMimeResolver in interface ImportContextImportContext.getImportRoot()public boolean hasStream()
IOContext
hasStream in interface IOContextIOContext.hasStream()public InputStream getInputStream()
InputStream to the temporary file created
during instanciation or null, if this context does not
provide a stream.
getInputStream in interface ImportContextImportContext.getInputStream(),
hasStream()public String getSystemId()
ImportContext
getSystemId in interface ImportContextImportContext.getSystemId()public long getModificationTime()
ImportContext
getModificationTime in interface ImportContextImportContext.getModificationTime()public String getContentLanguage()
ImportContextnull
getContentLanguage in interface ImportContextImportContext.getContentLanguage()public long getContentLength()
ImportContext-1 if
the content length could not be determined.
getContentLength in interface ImportContextImportContext.getContentLength()public String getMimeType()
ImportContextnull should be returned.
getMimeType in interface ImportContextImportContext.getMimeType()public String getEncoding()
ImportContextnull
getEncoding in interface ImportContextImportContext.getEncoding()public Object getProperty(Object propertyName)
getProperty in interface ImportContextImportContext.getProperty(Object)public void informCompleted(boolean success)
IOContext
informCompleted in interface IOContextIOContext.informCompleted(boolean)public boolean isCompleted()
IOContext
isCompleted in interface IOContextIOContext.isCompleted()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||