public Waiter<DescribeProjectVersionsRequest> projectVersionTrainingCompleted() {

        return new WaiterBuilder<DescribeProjectVersionsRequest, DescribeProjectVersionsResult>()
                .withSdkFunction(new DescribeProjectVersionsFunction(client))
                .withAcceptors(new ProjectVersionTrainingCompleted.IsTRAINING_COMPLETEDMatcher(),
                        new ProjectVersionTrainingCompleted.IsTRAINING_FAILEDMatcher())
                .withDefaultPollingStrategy(new PollingStrategy(new MaxAttemptsRetryStrategy(360), new FixedDelayStrategy(120)))
                .withExecutorService(executorService).build();
    }
Builds a ProjectVersionTrainingCompleted waiter by using custom parameters waiterParameters and other parameters
defined in the waiters specification, and then polls until it determines whether the resource entered the desired
state or not, where polling criteria is bound by either default polling strategy or custom polling strategy.
aws-java-sdk-rekognition/src/main/java/com/amazonaws/services/rekognition/waiters/AmazonRekognitionWaiters.java