com.cedarsoft.provider
Class InputStreamFromFileProvider

java.lang.Object
  extended by com.cedarsoft.provider.InputStreamFromFileProvider
All Implemented Interfaces:
Provider<InputStream,IOException>

public class InputStreamFromFileProvider
extends Object
implements Provider<InputStream,IOException>

A provider that returns an input stream using a file

Author:
Johannes Schneider (js@cedarsoft.com)

Constructor Summary
InputStreamFromFileProvider(File file)
          Constructor for InputStreamFromFileProvider.
 
Method Summary
 String getDescription()
          getDescription
 InputStream provide()
          Provides the object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InputStreamFromFileProvider

public InputStreamFromFileProvider(@NotNull
                                   File file)

Constructor for InputStreamFromFileProvider.

Parameters:
file - a File object.
Method Detail

provide

@NotNull
public InputStream provide()
                    throws IOException
Provides the object

Specified by:
provide in interface Provider<InputStream,IOException>
Returns:
the object that is provided
Throws:
IOException

getDescription

@NotNull
public String getDescription()

getDescription

Specified by:
getDescription in interface Provider<InputStream,IOException>
Returns:
a String object.


Copyright © 2010 cedarsoft GmbH. All Rights Reserved.