Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Create shared between two threads <code>LinkedBlockingQueue</code>.</p> <p>From thread <code>CaptureScreenshots</code> put into this queue newly created <code>File</code> objects.</p> <p>From thread <code>RenameScreenShots</code> sequentially read from this queue prepared <code>File</code> objects and process them.</p> <p><strong>UPD:</strong> If you are afraid that billions of image file will eat a lot of memory by their <code>File</code> descriptor, you can apply such algorithm enhancing:</p> <ol> <li><p>Create subfolders in folder, which contains your image files and put image files into this subfolders.</p></li> <li><p>Name those subfolders and integer names: <code>1</code>, <code>2</code>, <code>3</code>, ... , <code>89</code>.</p></li> <li><p>Artificially limit number of files in each subfolder. When the number of files reaches limit just increase name-number of subfoler, create new and go on.</p></li> <li><p>Instead of putting <code>File</code> descriptor for each image file to <code>LinkedBlockingQueue</code>, put there <code>Integer</code> objects, where each will correspond to filled subfolder with same name.</p></li> <li><p>Inside <code>RenameScreenShots</code> take new element from <code>LinkedBlockingQueue</code>, consider this element as subfolder name and process all quietly files within this subfolder.</p></li> </ol> <p><strong>UPD-2</strong> The scheme introduced in my <code>UPD-1</code> could be more easily implemented using shared <code>synchornized</code> getter of some integer value, which will correspond to last number of processed subfolder.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload