@Override public boolean isRepeatable() { return !entity.isTransient(); }
@Override public boolean isStreaming() { return entity.isTransient(); }
@Override public boolean isTransient() { return getWrappedRepresentation().isTransient(); }
/** * This implementation throws IllegalStateException if attempting to read * the underlying stream multiple times. */ public InputStream getInputStream() throws IOException, IllegalStateException { if (this.read && this.representation.isTransient()) { throw new IllegalStateException( "Representation has already been read and is transient."); } this.read = true; return this.representation.getStream(); }