void copyEntireChunkAsIs(PackOutputStream out, DhtObjectToPack obj, boolean validate) throws IOException { if (validate && !isValid()) { if (obj != null) throw new CorruptObjectException(obj, MessageFormat.format( DhtText.get().corruptChunk, getChunkKey())); else throw new DhtException(MessageFormat.format( DhtText.get().corruptChunk, getChunkKey())); } // Do not copy the trailer onto the output stream. out.write(dataBuf, dataPtr, dataLen - TRAILER_SIZE); }
void copyEntireChunkAsIs(PackOutputStream out, DhtObjectToPack obj, boolean validate) throws IOException { if (validate && !isValid()) { if (obj != null) throw new CorruptObjectException(obj, MessageFormat.format( DhtText.get().corruptChunk, getChunkKey())); else throw new DhtException(MessageFormat.format( DhtText.get().corruptChunk, getChunkKey())); } // Do not copy the trailer onto the output stream. out.write(dataBuf, dataPtr, dataLen - TRAILER_SIZE); }
void copyObjectAsIs(PackOutputStream out, DhtObjectToPack obj, boolean validate, DhtReader ctx) throws IOException, StoredObjectRepresentationNotAvailableException { if (validate && !isValid()) { StoredObjectRepresentationNotAvailableException gone;
void copyObjectAsIs(PackOutputStream out, DhtObjectToPack obj, boolean validate, DhtReader ctx) throws IOException, StoredObjectRepresentationNotAvailableException { if (validate && !isValid()) { StoredObjectRepresentationNotAvailableException gone;