org.deegree.protocol.wps.client.input
Class BinaryInput

java.lang.Object
  extended by org.deegree.protocol.wps.client.input.ExecutionInput
      extended by org.deegree.protocol.wps.client.input.BinaryInput

public class BinaryInput
extends ExecutionInput

ExecutionInput that encapsulates a binary value.

Version:
$Revision: 26137 $, $Date: 2010-08-25 18:05:25 +0200 (Wed, 25 Aug 2010) $
Author:
Andrei Ionita, Markus Schneider, last edited by: $Author: aionita $

Constructor Summary
BinaryInput(CodeType id, InputStream inputStream, String mimeType, String encoding)
          Creates a new BinaryInput instance.
BinaryInput(CodeType id, URL url, boolean isWebAccessible, String mimeType, String encoding)
          Creates a new BinaryInput instance.
 
Method Summary
 InputStream getAsBinaryStream()
          Returns the value as a binary stream.
 ComplexFormat getFormat()
          Returns the format of the input.
 URL getWebAccessibleURL()
          Returns the web-accessible URL for retrieving the input value.
 
Methods inherited from class org.deegree.protocol.wps.client.input.ExecutionInput
getId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BinaryInput

public BinaryInput(CodeType id,
                   URL url,
                   boolean isWebAccessible,
                   String mimeType,
                   String encoding)
Creates a new BinaryInput instance.

Parameters:
id - parameter identifier, must not be null
url - URL for accessing the binary resource, must not be null
isWebAccessible - if true, the data will be submitted to the process as reference, otherwise it will be encoded in the request
mimeType - mime type of the binary resource, may be null (unspecified)
encoding - encoding to be used for the binary data, may be null (unspecified)

BinaryInput

public BinaryInput(CodeType id,
                   InputStream inputStream,
                   String mimeType,
                   String encoding)
Creates a new BinaryInput instance.

Parameters:
id - parameter identifier, must not be null
inputStream - binary stream, must not be null
mimeType - mime type of the binary resource, may be null (unspecified)
encoding - encoding to be used for the binary data, may be null (unspecified)
Method Detail

getFormat

public ComplexFormat getFormat()
Returns the format of the input.

Returns:
the format of the input, never null

getAsBinaryStream

public InputStream getAsBinaryStream()
                              throws IOException
Returns the value as a binary stream.

Returns:
the value as a binary stream, never null
Throws:
IOException - if accessing the data fails

getWebAccessibleURL

public URL getWebAccessibleURL()
Description copied from class: ExecutionInput
Returns the web-accessible URL for retrieving the input value.

Overrides:
getWebAccessibleURL in class ExecutionInput
Returns:
web-accessible URL, can be null (not web-acessible)


Copyright © 2011. All Rights Reserved.