コード例 #1
0
 public RandomAccessTemporaryFileChannel glueFilesTogether(
     FileFragmentMetaDataStore fileFragmentMetaDataStore, String path) throws FuseException {
   splittingQueue.set(fileFragmentMetaDataStore);
   RandomAccessTemporaryFileChannel ret = splittingQueue.get(path);
   byte[] arr = new byte[6];
   try {
     ret.getChannel().read(ByteBuffer.wrap(arr));
     ret.getChannel().position(0);
   } catch (IOException e) {
     // TODO Auto-generated catch block
     e.printStackTrace();
   }
   // System.out.println("CachingStore read:"+new String(arr,0));
   return ret;
 }
コード例 #2
0
 @Override
 public void rename(String from, String to) {
   splittingQueue.rename(from, to);
 }
コード例 #3
0
 public void remove(String path) {
   splittingQueue.remove(path);
 }
コード例 #4
0
 public FileFragments splitFile(
     FileFragmentMetaDataStore fileFragmentMetaDataStore, String path, FileChannel temp)
     throws FuseException, IOException {
   splittingQueue.set(fileFragmentMetaDataStore);
   return splittingQueue.put(path, temp);
 }