SemanticCloneDetector class

Semantic clone detector using embeddings.

Constructors

SemanticCloneDetector({required OnnxRuntime runtime, required WordPieceTokenizer tokenizer, double similarityThreshold = 0.85})

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

clearCache() → void
Clears the embedding cache.
findClones(String functionId, String code) Future<List<CloneCandidate>>
Finds potential clones for a function.
indexFunction(String functionId, String code) Future<void>
Computes and caches embedding for a function.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited