<commit_before>/**********************************************************************
 *
 * GEOS - Geometry Engine Open Source
 * http://geos.osgeo.org
 *
 * Copyright (C) 2020 <NAME> <<EMAIL>>
 *
 * This is free software; you can redistribute and/or modify it under
 * the terms of the GNU Lesser General Public Licence as published
 * by the Free Software Foundation.
 * See the COPYING file for more information.
 *
 **********************************************************************/


#pragma once

#include <geos/edgegraph/HalfEdge.h>

#include <geos/export.h>
#include <string>
#include <cassert>
#include <map>
#include <array>
#include <memory>
#include <vector>

// Forward declarations
namespace geos {
namespace geom {
class Coordinate;
}
}

#undef EDGEGRAPH_HEAPHACK

namespace geos {
namespace edgegraph { // geos.edgegraph


/**
 * A graph comprised of {@link HalfEdge}s.
 * It supports tracking the vertices in the graph
 * via edges incident on them,
 * to allow efficient lookup of edges and vertices.
 * <p>
 * This class may be subclassed to use a
 * different subclass of HalfEdge,
 * by overriding {@link #createEdge(Coordinate)}.
 * If additional logic is required to initialize
 * edges then {@link EdgeGraph#addEdge(Coordinate, Coordinate)}
 * can be overridden as well.
 *
 * @author <NAME>
 *
 */

class GEOS_DLL EdgeGraph {

private:

    static constexpr size_t HalfEdgeArraySize = 32;

    std::deque<HalfEdge> edges;
    std::map<geom::Coordinate, HalfEdge*> vertexMap;


    HalfEdge* create(const geom::Coordinate& p0, const geom::Coordinate& p1);


protected:<commit_msg>Remove unused constant<commit_after>/**********************************************************************
 *
 * GEOS - Geometry Engine Open Source
 * http://geos.osgeo.org
 *
 * Copyright (C) 2020 <NAME> <<EMAIL>>
 *
 * This is free software; you can redistribute and/or modify it under
 * the terms of the GNU Lesser General Public Licence as published
 * by the Free Software Foundation.
 * See the COPYING file for more information.
 *
 **********************************************************************/


#pragma once

#include <geos/edgegraph/HalfEdge.h>

#include <geos/export.h>
#include <string>
#include <cassert>
#include <map>
#include <array>
#include <memory>
#include <vector>

// Forward declarations
namespace geos {
namespace geom {
class Coordinate;
}
}

#undef EDGEGRAPH_HEAPHACK

namespace geos {
namespace edgegraph { // geos.edgegraph


/**
 * A graph comprised of {@link HalfEdge}s.
 * It supports tracking the vertices in the graph
 * via edges incident on them,
 * to allow efficient lookup of edges and vertices.
 * <p>
 * This class may be subclassed to use a
 * different subclass of HalfEdge,
 * by overriding {@link #createEdge(Coordinate)}.
 * If additional logic is required to initialize
 * edges then {@link EdgeGraph#addEdge(Coordinate, Coordinate)}
 * can be overridden as well.
 *
 * @author <NAME>
 *
 */

class GEOS_DLL EdgeGraph {

private:

    std::deque<HalfEdge> edges;
    std::map<geom::Coordinate, HalfEdge*> vertexMap;

    HalfEdge* create(const geom::Coordinate& p0, const geom::Coordinate& p1);


protected:
{'fraction_non_alphanumeric': 0.18393700787401573, 'fraction_numerical': 0.004409448818897638, 'mean_word_length': 4.601410934744268, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 33, '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': '7639992', 'n_tokens_mistral': 954, 'n_tokens_neox': 882, 'n_words': 324}