public String toString() {
        StringBuilder out = new StringBuilder();
        for (TraverseMode mode : TraverseMode.values()) {
            int mask = getMaskForMode(mode);
            if (mask != 0 && (modes & mask) == mask) {
                if (out.length() != 0) {
                    out.append(",");
                }
                out.append(mode);
            }
        }
        return out.toString(); //return "TraverseMode (" + out + ")";
    }