title: Copy files from box folder to AWS s3 bucket
body: <p>I am working to copy box files to S3 bucket. How to get file object from box file to copy in to S3 bucket using box-java-sdk</p>
  
  <p>I have to tried to get file's metadata from box folder, but end up with limited documentation to get file object.</p>
  
  <pre><code>import com.box.sdk.BoxAPIConnection;
  import com.box.sdk.BoxFile;
  import com.box.sdk.BoxFolder;
  import com.box.sdk.BoxItem;
  import com.box.sdk.Metadata;
  
  String access_token = "some_access_token";
  String refresh_token = "some_refresh_token";
  BoxAPIConnection api = new BoxAPIConnection(client_id,
                  client_secret,
                  access_token,
                  refresh_token);
  for (BoxItem.Info itemInfo : folder) {
      if (itemInfo instanceof BoxFile.Info) {
          // getting file info, metadata
          // have to upload the file content here to S3 bucket
      } else if (itemInfo instanceof BoxFolder.Info)
      {
          BoxFolder.Info folderInfo = (BoxFolder.Info) itemInfo;
         // Do something with the folder.
  
  
       }
          }
  </code></pre>
  
  <p>Goal is to upload box content to S3 bucket.</p>