<commit_before>// Copyright (c) 2010 <NAME> and <NAME>.
// All rights reserved.  See the LICENSE file for details.
package com.oocode;

import java.util.Set;

import static com.oocode.Possibilities.*;

public enum Square {
    Unknown('?', false),
    OutOfBounds('X', false),
    Water('~', false),
    GuessedShip('*', true),
    Top('^', true),
    Bottom('v', true),
    Left('<', true),
    Right('>', true),
    Centre('#', true),
    Single('o', true);

    private final boolean isShip;
    private final char c;

    Square(char representation, boolean isShip) {
        this.c = representation;
        this.isShip = isShip;
    }

    public String toString() {
        return Character.toString(c);
    }

    public boolean isShip() {
        return isShip;
    }

    public static Square from(char square) {<commit_msg>reordering ready for switch refactoring<commit_after>// Copyright (c) 2010 <NAME> and <NAME>.
// All rights reserved.  See the LICENSE file for details.
package com.oocode;

import java.util.Set;

import static com.oocode.Possibilities.*;

public enum Square {
    GuessedShip('*', true),
    Single('o', true),
    Centre('#', true),
    Top('^', true),
    Bottom('v', true),
    Left('<', true),
    Right('>', true),
    Water('~', false),
    OutOfBounds('X', false),
    Unknown('?', false);

    private final boolean isShip;
    private final char c;

    Square(char representation, boolean isShip) {
        this.c = representation;
        this.isShip = isShip;
    }

    public String toString() {
        return Character.toString(c);
    }

    public boolean isShip() {
        return isShip;
    }

    public static Square from(char square) {
{'fraction_non_alphanumeric': 0.14521841794569068, 'fraction_numerical': 0.004722550177095631, 'mean_word_length': 2.808988764044944, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7432345', 'n_tokens_mistral': 527, 'n_tokens_neox': 523, 'n_words': 158}