eu.scape_project.pit.invoke
Class In

java.lang.Object
  extended by eu.scape_project.pit.invoke.In

public class In
extends Object

This class supports mapping between the input types the clients support and those supported by the tool.

Author:
Andrew Jackson

Nested Class Summary
static class In.Type
          Enumeration to represent the type of data object
 
Constructor Summary
In(File file)
          Constructor for a java.io.File containing the data object
In(InputStream is)
          Constructor for InputStream based input
In(URI uri)
          Constructor for URI for the data object
 
Method Summary
 File getFile()
           
 InputStream getInputStream()
           
 In.Type getType()
          Get the type of the underlying data object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

In

public In(InputStream is)
Constructor for InputStream based input

Parameters:
is - a java.io.InputStream to the data object

In

public In(URI uri)
Constructor for URI for the data object

Parameters:
uri - the URI identifying the object, should be a URL

In

public In(File file)
Constructor for a java.io.File containing the data object

Parameters:
file - the file
Method Detail

getType

public In.Type getType()
Get the type of the underlying data object

Returns:
a Type enum

getInputStream

public InputStream getInputStream()
                           throws IOException
Returns:
a java.io.InputStream to the object.
Throws:
IOException - If there's a problem obtaining the stream

getFile

public File getFile()
Returns:
a java.io.File object


Copyright © 2013. All Rights Reserved.