com.aspose.imaging
Class FileStreamContainer

java.lang.Object
  extended by com.aspose.imaging.DisposableObject
      extended by com.aspose.imaging.StreamContainer
          extended by com.aspose.imaging.FileStreamContainer

public final class FileStreamContainer
extends StreamContainer

Helper for file stream processing.


Method Summary
 java.lang.String getFilePath()
           Gets the file path.
 boolean isCreated()
           Gets a value indicating whether stream was created explicitly.
 boolean isTemporal()
           Gets a value indicating whether stream is temporal.
static FileStreamContainer openFileStream(java.lang.String fileLocation)
           Opens an existing file stream.
 void setTemporal(boolean value)
           Sets a value indicating whether stream is temporal.
static FileStream toFileStream(FileStreamContainer fileStreamContainer)
           Performs an explicit conversion from FileStreamContainer to System.IO.FileStream.
static Stream toStream(FileStreamContainer fileStreamContainer)
           Performs an explicit conversion from FileStreamContainer to System.IO.Stream.
 
Methods inherited from class com.aspose.imaging.StreamContainer
afterStreamDisposed, beforeStreamDisposed, canRead, canSeek, canWrite, flush, getLength, getPosition, getStream, isStreamDisposedOnClose, read, read, readByte, releaseManagedResources, save, save, save, save, save, save, seek, seekBegin, setLength, setPosition, shift, toBytes, toBytes, toStream, write, write, writeByte
 
Methods inherited from class com.aspose.imaging.DisposableObject
dispose, getDisposed, releaseUnmanagedResources, verifyNotDisposed
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getFilePath

public java.lang.String getFilePath()

Gets the file path.

Value: The file path.


isCreated

public boolean isCreated()

Gets a value indicating whether stream was created explicitly.

Value: true if stream was created explicitly; otherwise, false.


isTemporal

public boolean isTemporal()

Gets a value indicating whether stream is temporal.

Value: true if stream is temporal; otherwise, false.


A temporal stream will remove iself when disposed. If the stream is memory based this property has no effect. The stream can be marked as temporal or persistent in case it was created explicitly otherwise the appropriate exception is thrown.


openFileStream

public static FileStreamContainer openFileStream(java.lang.String fileLocation)

Opens an existing file stream. If file stream does not exist the appropriate exception is thrown.

Parameters:
fileLocation - The file location.
Returns:
The files tream holder.

setTemporal

public void setTemporal(boolean value)

Sets a value indicating whether stream is temporal.

Value: true if stream is temporal; otherwise, false.


A temporal stream will remove iself when disposed. If the stream is memory based this property has no effect. The stream can be marked as temporal or persistent in case it was created explicitly otherwise the appropriate exception is thrown.


toFileStream

public static FileStream toFileStream(FileStreamContainer fileStreamContainer)

Performs an explicit conversion from FileStreamContainer to System.IO.FileStream.

Parameters:
fileStreamContainer - The file stream container.
Returns:
The result of the conversion.

toStream

public static Stream toStream(FileStreamContainer fileStreamContainer)

Performs an explicit conversion from FileStreamContainer to System.IO.Stream.

Parameters:
fileStreamContainer - The file stream container.
Returns:
The result of the conversion.