class Pandora::Models::Framework
Attributes
dependencies[R]
Array of dependencies (names)
name[R]
Framework
name
project_path[R]
Project path (.xcodeproj)
Public Class Methods
from_yml(name, yml)
click to toggle source
Initializes a Framework
from a YAML dictionary. @param [String] framework name. @param [Hash] dictionary that represents the framework @raise [StandardError] if the dictionary doesn't include a project_path
@return [Framework] initialized Framework
.
# File lib/pandora/models/framework.rb, line 31 def self.from_yml(name, yml) project_path = yml["project_path"] raise "Project not specified for framework #{name}" unless project_path dependencies = yml["dependencies"] dependencies ||= [] Framework.new(name, project_path, dependencies) end
new(name, project_path, dependencies)
click to toggle source
Initializes the framework from a YML hash. @param [String] framework name. @param [String] project path. @param [[String]] framework dependencies list. @return [Framework] initialized Framework
.
# File lib/pandora/models/framework.rb, line 19 def initialize(name, project_path, dependencies) @name = name @project_path = project_path raise "Wrong project path. It should be a .xcodeproj" unless @project_path.include?(".xcodeproj") @dependencies = dependencies end