Revert for Java 5 compatibility
This commit is contained in:
parent
fb5eb0afd9
commit
11b139ace7
@ -58,14 +58,14 @@ public class DiskAttribute extends AbstractDiskHttpData implements Attribute {
|
||||
|
||||
public String getValue() throws IOException {
|
||||
byte [] bytes = get();
|
||||
return new String(bytes, charset);
|
||||
return new String(bytes, charset.name());
|
||||
}
|
||||
|
||||
public void setValue(String value) throws IOException {
|
||||
if (value == null) {
|
||||
throw new NullPointerException("value");
|
||||
}
|
||||
byte [] bytes = value.getBytes(charset);
|
||||
byte [] bytes = value.getBytes(charset.name());
|
||||
ChannelBuffer buffer = ChannelBuffers.wrappedBuffer(bytes);
|
||||
if (definedSize > 0) {
|
||||
definedSize = buffer.readableBytes();
|
||||
|
Loading…
x
Reference in New Issue
Block a user