@Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("{");
        if (getReplaceRootVolumeTaskId() != null)
            sb.append("ReplaceRootVolumeTaskId: ").append(getReplaceRootVolumeTaskId()).append(",");
        if (getInstanceId() != null)
            sb.append("InstanceId: ").append(getInstanceId()).append(",");
        if (getTaskState() != null)
            sb.append("TaskState: ").append(getTaskState()).append(",");
        if (getStartTime() != null)
            sb.append("StartTime: ").append(getStartTime()).append(",");
        if (getCompleteTime() != null)
            sb.append("CompleteTime: ").append(getCompleteTime()).append(",");
        if (getTags() != null)
            sb.append("Tags: ").append(getTags()).append(",");
        if (getImageId() != null)
            sb.append("ImageId: ").append(getImageId()).append(",");
        if (getSnapshotId() != null)
            sb.append("SnapshotId: ").append(getSnapshotId()).append(",");
        if (getDeleteReplacedRootVolume() != null)
            sb.append("DeleteReplacedRootVolume: ").append(getDeleteReplacedRootVolume());
        sb.append("}");
        return sb.toString();
    }
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be
redacted from this string using a placeholder value.

@return A string representation of this object.

@see java.lang.Object#toString()
aws-java-sdk-ec2/src/main/java/com/amazonaws/services/ec2/model/ReplaceRootVolumeTask.java