Java 6 wants @Override for interface implementations as well
git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1570959 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
def5c423ab
commit
d30d5c4883
|
@ -75,24 +75,29 @@ class InternalByteArrayEntity extends AbstractHttpEntity implements Cloneable {
|
|||
this(b, off, len, null);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isRepeatable() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getContentLength() {
|
||||
return this.len;
|
||||
}
|
||||
|
||||
@Override
|
||||
public InputStream getContent() {
|
||||
return new ByteArrayInputStream(this.b, this.off, this.len);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeTo(final OutputStream outstream) throws IOException {
|
||||
Args.notNull(outstream, "Output stream");
|
||||
outstream.write(this.b, this.off, this.len);
|
||||
outstream.flush();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isStreaming() {
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -49,18 +49,22 @@ class InternalFileEntity extends AbstractHttpEntity implements Cloneable {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isRepeatable() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getContentLength() {
|
||||
return this.file.length();
|
||||
}
|
||||
|
||||
@Override
|
||||
public InputStream getContent() throws IOException {
|
||||
return new FileInputStream(this.file);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeTo(final OutputStream outstream) throws IOException {
|
||||
Args.notNull(outstream, "Output stream");
|
||||
final InputStream instream = new FileInputStream(this.file);
|
||||
|
@ -76,6 +80,7 @@ class InternalFileEntity extends AbstractHttpEntity implements Cloneable {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isStreaming() {
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -49,18 +49,22 @@ class InternalInputStreamEntity extends AbstractHttpEntity {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isRepeatable() {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getContentLength() {
|
||||
return this.length;
|
||||
}
|
||||
|
||||
@Override
|
||||
public InputStream getContent() throws IOException {
|
||||
return this.content;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeTo(final OutputStream outstream) throws IOException {
|
||||
Args.notNull(outstream, "Output stream");
|
||||
final InputStream instream = this.content;
|
||||
|
@ -89,6 +93,7 @@ class InternalInputStreamEntity extends AbstractHttpEntity {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isStreaming() {
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue