Code example for SequenceInputStream

0
 
    CombinedEntity(final Resource resource, final InputStream instream) throws IOException {
        super(); 
        this.resource = resource;
        this.combinedStream = new SequenceInputStream(
                new ResourceStream(resource.getInputStream()), instream);
    } 
 
    public long getContentLength() { 
        return -1; 
    } 
 
    public boolean isRepeatable() { 
        return false; 
    } 
 
    public boolean isStreaming() { 
        return true; 
    }