public void addInput(String port, InputStream inputStream, String uri, Type type, String contentType) throws IOException { inputStream = new BufferedInputStream(inputStream); contentType = ((contentType == null) || "content/unknown".equals(contentType)) ? guessContentTypeFromStream(inputStream) : contentType; contentType = ((contentType == null) || "content/unknown".equals(contentType)) ? guessContentTypeFromName(uri) : contentType; curStep.addInput(port, inputStream, uri, type, contentType); }
public void addInput(String port, InputStream inputStream, String uri, Type type, String contentType) throws IOException { inputStream = new BufferedInputStream(inputStream); contentType = ((contentType == null) || "content/unknown".equals(contentType)) ? guessContentTypeFromStream(inputStream) : contentType; contentType = ((contentType == null) || "content/unknown".equals(contentType)) ? guessContentTypeFromName(uri) : contentType; curStep.addInput(port, inputStream, uri, type, contentType); }