22namespace fs = std::filesystem;
47 Comparation(
string _path1,
string _path2,
double _sim);
72 string PROJECT_PATH_MESSAGE =
"Enter your project path:";
73 string MINIMUM_SIMILARITY_MESSAGE =
"Enter minimum similarity desired on using the tool:";
76 double similarity_cap;
77 std::set<Comparation> comparations;
84 vector<string> parser_line(
const string& line);
91 bool is_an_file(
const std::string& s);
98 double retrive_similarity(
const std::string& s);
105 void parser_block_stream(
const std::string& path,
const std::vector<std::string>& tokens, set<Comparation>& comparations);
113 explicit Parser(
const fs::path& output_file,
double similarity_cap);
Parses and transforms duplication detection tool output.
void exec_from_stream(FILE *pipe)
Main parsing execution method using stream.
Parser(const fs::path &output_file, double similarity_cap)
Constructs parser with configuration.
Structure representing a code comparison result.
bool operator<(const Comparation &com) const
Comparison operator for sorting.
double similarity
Similarity score between the files (0-100)
Comparation()
Default constructor.
string path1
Path to first code file being compared.
bool operator==(const Comparation &com) const
Equality comparison operator.
string path2
Path to second code file being compared.