Class: ComplianceEngine::DataLoader::Yaml

Inherits:
File show all
Defined in:
lib/compliance_engine/data_loader/yaml.rb

Overview

Load compliance engine data from a YAML file

Instance Attribute Summary

Attributes inherited from File

#key, #mtime, #size

Attributes inherited from ComplianceEngine::DataLoader

#data

Instance Method Summary collapse

Methods inherited from File

#initialize, #refresh

Methods inherited from ComplianceEngine::DataLoader

#initialize, #key

Constructor Details

This class inherits a constructor from ComplianceEngine::DataLoader::File

Instance Method Details

#parse(content) ⇒ Hash

Parse YAML content into a Hash

Parameters:

  • content (String)

    The content to parse

Returns:

  • (Hash)


14
15
16
# File 'lib/compliance_engine/data_loader/yaml.rb', line 14

def parse(content)
  YAML.safe_load(content)
end