Class: Diff::LCS::SequenceCallbacks

### Home Classes Methods

### In Files

- lib/diff/lcs/callbacks.rb

### Parent

Object

### Methods

- ::change
- ::discard_a
- ::discard_b
- ::match

### Files

- Manifest.txt
- README.rdoc
- COPYING.txt
- artistic.txt

### Class/Module Index

Quicksearch

- Diff
- Diff::LCS
- Diff::LCS::BalancedCallbacks
- Diff::LCS::Block
- Diff::LCS::Change
- Diff::LCS::ContextChange
- Diff::LCS::ContextDiffCallbacks
- Diff::LCS::DefaultCallbacks
- Diff::LCS::DiffCallbacks
- Diff::LCS::HTMLDiff
- Diff::LCS::HTMLDiff::Callbacks
- Diff::LCS::Hunk
- Diff::LCS::Ldiff
- Diff::LCS::SDiffCallbacks
- Diff::LCS::SequenceCallbacks
- Array
- String

No matching classes.

# Diff::LCS::SequenceCallbacks

This callback object implements the default set of callback events, which only returns the event itself. Note that finished_a and finished_b are not implemented -- I haven't yet figured out where they would be useful.

Note that this is intended to be called as is, e.g.,

    Diff::LCS.LCS(seq1, seq2, Diff::LCS::DefaultCallbacks)

### Public Class Methods

change(event) click to toggle source

Called when both the old and new values have changed.

    # File lib/diff/lcs/callbacks.rb, line 28
    def change(event)
      event
    end

discard_a(event) click to toggle source

Called when the old value is discarded in favour of the new value.

    # File lib/diff/lcs/callbacks.rb, line 20
    def discard_a(event)
      event
    end

discard_b(event) click to toggle source

Called when the new value is discarded in favour of the old value.

    # File lib/diff/lcs/callbacks.rb, line 24
    def discard_b(event)
      event
    end

match(event) click to toggle source

Called when two items match.

    # File lib/diff/lcs/callbacks.rb, line 16
    def match(event)
      event
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.