pub struct CloneDetector { /* private fields */ }Implementations§
Source§impl CloneDetector
impl CloneDetector
Sourcepub fn new(config: CloneConfig) -> Result<Self>
pub fn new(config: CloneConfig) -> Result<Self>
Creates a detector after validating all safety bounds.
§Errors
Returns an error for inconsistent thresholds or zero limits.
pub const fn config(&self) -> CloneConfig
Sourcepub fn detect(&self, fragments: &[SourceFragment]) -> Result<CloneReport>
pub fn detect(&self, fragments: &[SourceFragment]) -> Result<CloneReport>
Detects deterministic Type-1, Type-2, and bounded near-miss Type-3 clones over caller-provided fragments.
§Errors
Rejects malformed or duplicate fragments and configured capacity limits without returning partial output.
Trait Implementations§
Source§impl Clone for CloneDetector
impl Clone for CloneDetector
Source§fn clone(&self) -> CloneDetector
fn clone(&self) -> CloneDetector
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for CloneDetector
Source§impl Debug for CloneDetector
impl Debug for CloneDetector
Source§impl Default for CloneDetector
impl Default for CloneDetector
Source§fn default() -> CloneDetector
fn default() -> CloneDetector
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CloneDetector
impl RefUnwindSafe for CloneDetector
impl Send for CloneDetector
impl Sync for CloneDetector
impl Unpin for CloneDetector
impl UnsafeUnpin for CloneDetector
impl UnwindSafe for CloneDetector
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more