class Inspec::Lockfile
def parse_content_hash(lockfile_content_hash)
develop. It does help people easily set breakpoints/track
"parse_flat_dependencies" or what not as things generally
defined methods like "parse_v0_dependencies" or
different. Then that dispatch routine can call more well
it can describe the part of the code that it expects to be
function for each version so that even if it duplicates code,
Refactor this to be "version-wise" - i.e. make one dispatch
def parse_content_hash(lockfile_content_hash) case version when 1 parse_content_hash_1(lockfile_content_hash) else # If we've gotten here, there is likely a mistake in the # lockfile version validation in the constructor. raise "No lockfile parser for version #{version}" end end