Analyser - Generic MFM: Block Matching

2008-07-09

  • Changed block pattern matching to take a group as a parameter, since ultimately it ends up processing a group anyway.
  • Right now, the block matching uses the concept of having a header and a data block pattern, which changes some constraints during the process. This however restricts the way the complexity of the blocks that can be matched in one go.

Practically there shouldn’t be any difference between the the two processes, it’s the matching data itself that should define (or not) a block type it is looking for. So block matching should only match one group against a block pattern, where the block pattern defines the current constraints according to the expected block type. It has become the responsibility of the pattern to use only appropriate constrains for the block type it describes.

Once the match succeeds the definition, the pattern decides the real block type that is set for the group. Parameters of the block identified can be changed or remain unaltered at will.

Since the block type is just defining constraints (on buffer handling) and block matching is done individually not in pairs, a constraint can be defined by the format matching pattern indicating how many blocks (i.e. consecutive segments) must be present for that specific part of the format match description to succeed.