public ListWorkforcesRequest withSortBy(String sortBy) {
        setSortBy(sortBy);
        return this;
    }
<p>
Sort workforces using the workforce name or creation date.
</p>

@param sortBy
       Sort workforces using the workforce name or creation date.
@return Returns a reference to this object so that method calls can be chained together.
@see ListWorkforcesSortByOptions
aws-java-sdk-sagemaker/src/main/java/com/amazonaws/services/sagemaker/model/ListWorkforcesRequest.java