public UploadConfiguration withUploadBehavior(UploadBehavior uploadBehavior) {
        this.uploadBehavior = uploadBehavior.toString();
        return this;
    }
<p>
Specifies when to upload the files:
</p>
<dl>
<dt>UPLOAD_ON_TERMINATE</dt>
<dd>
<p>
Matching files are uploaded once the simulation enters the <code>TERMINATING</code> state. Matching files are not
uploaded until all of your code (including tools) have stopped.
</p>
<p>
If there is a problem uploading a file, the upload is retried. If problems persist, no further upload attempts
will be made.
</p>
</dd>
<dt>UPLOAD_ROLLING_AUTO_REMOVE</dt>
<dd>
<p>
Matching files are uploaded as they are created. They are deleted after they are uploaded. The specified path is
checked every 5 seconds. A final check is made when all of your code (including tools) have stopped.
</p>
</dd>
</dl>

@param uploadBehavior
       Specifies when to upload the files:</p>
       <dl>
       <dt>UPLOAD_ON_TERMINATE</dt>
       <dd>
       <p>
       Matching files are uploaded once the simulation enters the <code>TERMINATING</code> state. Matching files
       are not uploaded until all of your code (including tools) have stopped.
       </p>
       <p>
       If there is a problem uploading a file, the upload is retried. If problems persist, no further upload
       attempts will be made.
       </p>
       </dd>
       <dt>UPLOAD_ROLLING_AUTO_REMOVE</dt>
       <dd>
       <p>
       Matching files are uploaded as they are created. They are deleted after they are uploaded. The specified
       path is checked every 5 seconds. A final check is made when all of your code (including tools) have
       stopped.
       </p>
       </dd>
@return Returns a reference to this object so that method calls can be chained together.
@see UploadBehavior
aws-java-sdk-robomaker/src/main/java/com/amazonaws/services/robomaker/model/UploadConfiguration.java