Examples of ReaderInputStream


Examples of com.ibm.commons.util.io.ReaderInputStream

 
  private void emit(HttpServletResponse resp, String text, String contentType) throws IOException {
    resp.setStatus(200);
    resp.setContentType(contentType);
    ByteStreamCache bs = new ByteStreamCache();
    InputStream is = new ReaderInputStream(new StringReader(text),"utf-8");
    bs.copyFrom(is);
    resp.setContentLength((int)bs.getLength());
    OutputStream os = resp.getOutputStream();
    bs.copyTo(os);
    os.flush();
View Full Code Here

Examples of com.ibm.commons.util.io.ReaderInputStream

          }
          if(StringUtil.isNotEmpty(sProperties)) {
          try {
            // Pass the properties from the file
            if(StringUtil.isNotEmpty(sProperties)) {
              this.properties.load(new ReaderInputStream(new StringReader(sProperties)));
            }
          } catch(Exception ex) {}
          }
        }
View Full Code Here

Examples of de.timefinder.core.util.ReaderInputStream

    private InputStream reader;
    private ObjectParsing objectParsing = new ObjectParsing();
    private Map<Class, Map<Long, DBInterface>> simpleDaos = FastMap.newInstance();

    XmlImport(DataPool pool, DataPoolSettings settings, Reader reader) {
        this(pool, settings, new ReaderInputStream(reader));
    }
View Full Code Here

Examples of edu.stanford.nlp.io.ReaderInputStream

    TreebankLanguagePack tlp = new SpanishTreebankLanguagePack();

    this.simplifiedTagset = simplifiedTagset;
    this.detailedAnnotations = detailedAnnotations;

    stream = new ReaderInputStream(in, tlp.getEncoding());
    treeFactory = new LabeledScoredTreeFactory();
    treeNormalizer =
      new SpanishTreeNormalizer(simplifiedTagset,
                                aggressiveNormalization,
                                retainNER);
View Full Code Here

Examples of org.apache.any23.util.ReaderInputStream

        return NQuads.FORMAT;
    }

    public void parse(Reader reader, String s)
    throws IOException, RDFParseException, RDFHandlerException {
        ReaderInputStream readerInputStream = new ReaderInputStream(reader);
        parse(readerInputStream, s);
    }
View Full Code Here

Examples of org.apache.axis2.transport.base.streams.ReaderInputStream

    public String getName() {
        return null;
    }

    public InputStream getInputStream() throws IOException {
        return new ReaderInputStream(ElementHelper.getTextAsStream(element, true), charset);
    }
View Full Code Here

Examples of org.apache.commons.io.input.ReaderInputStream

  @Override
  public void readFrom(Reader in, Syntax syntax, String baseURI)
      throws IOException, ModelRuntimeException,
      SyntaxNotSupportedException {
    ReaderInputStream is = new ReaderInputStream(in, StandardCharsets.UTF_8);
    readFrom(is, syntax, baseURI);
  }
View Full Code Here

Examples of org.apache.james.fetchmail.ReaderInputStream

            mail =
                new MailImpl(session.getConfigurationData().getMailServer().getId(),
                             (MailAddress) session.getState().get(SMTPSession.SENDER),
                             recipientCollection,
                             new SequenceInputStream(new SequenceInputStream(headersIn, msgIn),
                                     new ReaderInputStream(new StringReader("\r\n"))));
            // Call mail.getSize() to force the message to be
            // loaded. Need to do this to enforce the size limit
            if (session.getConfigurationData().getMaxMessageSize() > 0) {
                mail.getMessageSize();
            }
View Full Code Here

Examples of org.apache.tools.ant.util.ReaderInputStream

    /**
     * Transforms the given InputStream. The original InputStream will be closed by the returned InputStream.
     */
    public InputStream transform(InputStream original) {
        return new ReaderInputStream(transform(new InputStreamReader(original)));
    }
View Full Code Here

Examples of org.apache.tools.ant.util.ReaderInputStream

                    }
                }
                rdr = new MultiReader(Arrays.asList(readers).iterator(),
                        identityReaderFactory);
            }
            return outputEncoding == null ? new ReaderInputStream(rdr)
                    : new ReaderInputStream(rdr, outputEncoding);
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.