public static PathComparator fromNode(Node node) {
        String value = node.expectStringNode().getValue();
        for (PathComparator comparator : values()) {
            if (comparator.toString().equals(value)) {
                return comparator;
            }
        }

        throw new ExpectationNotMetException("Expected valid path comparator, but found " + value, node);
    }
Creates a {@code PathComparator} from a {@link Node}.
@param node Node to create the {@code PathComparator} from.
@return Returns the created {@code PathComparator}.
@throws ExpectationNotMetException if the given {@code node} is invalid.
smithy-waiters/src/main/java/software/amazon/smithy/waiters/PathComparator.java