Class: Nx::Yaml
- Inherits:
-
Object
- Object
- Nx::Yaml
- Defined in:
- lib/nx/yaml.rb,
lib/nx/version.rb
Constant Summary collapse
- VERSION =
"1.0.4"
Class Method Summary collapse
Class Method Details
.load(in_path, in_data = nil) ⇒ Object
19 20 21 22 23 |
# File 'lib/nx/yaml.rb', line 19 def self.load(in_path, in_data = nil) raw_content = File.read(in_path) str = in_data.nil? ? raw_content : ErbalT::render_from_hash(raw_content, in_data) YAML::load(str, symbolize_names: true) end |