Class: Pod::YamlPod
- Inherits:
-
Object
- Object
- Pod::YamlPod
- Defined in:
- lib/core_blur/yaml/yaml_pod.rb
Instance Attribute Summary collapse
-
#binary ⇒ Object
Returns the value of attribute binary.
-
#branch ⇒ Object
Returns the value of attribute branch.
-
#configurations ⇒ Object
Returns the value of attribute configurations.
-
#git ⇒ Object
Returns the value of attribute git.
-
#inhibit_warnings ⇒ Object
Returns the value of attribute inhibit_warnings.
-
#module_name ⇒ Object
Returns the value of attribute module_name.
-
#path ⇒ Object
Returns the value of attribute path.
-
#pod ⇒ Object
Returns the value of attribute pod.
-
#podspec ⇒ Object
Returns the value of attribute podspec.
-
#source ⇒ Object
Returns the value of attribute source.
-
#subspecs ⇒ Object
Returns the value of attribute subspecs.
-
#tag ⇒ Object
Returns the value of attribute tag.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
-
#version ⇒ Object
Returns the value of attribute version.
Instance Method Summary collapse
-
#initialize(pod) ⇒ YamlPod
constructor
A new instance of YamlPod.
- #option ⇒ Object
Constructor Details
#initialize(pod) ⇒ YamlPod
Returns a new instance of YamlPod.
3 4 5 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 3 def initialize(pod) @pod = pod end |
Instance Attribute Details
#binary ⇒ Object
Returns the value of attribute binary.
18 19 20 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 18 def binary @binary end |
#branch ⇒ Object
Returns the value of attribute branch.
12 13 14 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 12 def branch @branch end |
#configurations ⇒ Object
Returns the value of attribute configurations.
14 15 16 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 14 def configurations @configurations end |
#git ⇒ Object
Returns the value of attribute git.
10 11 12 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 10 def git @git end |
#inhibit_warnings ⇒ Object
Returns the value of attribute inhibit_warnings.
16 17 18 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 16 def inhibit_warnings @inhibit_warnings end |
#module_name ⇒ Object
Returns the value of attribute module_name.
6 7 8 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 6 def module_name @module_name end |
#path ⇒ Object
Returns the value of attribute path.
15 16 17 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 15 def path @path end |
#pod ⇒ Object
Returns the value of attribute pod.
7 8 9 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 7 def pod @pod end |
#podspec ⇒ Object
Returns the value of attribute podspec.
13 14 15 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 13 def podspec @podspec end |
#source ⇒ Object
Returns the value of attribute source.
17 18 19 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 17 def source @source end |
#subspecs ⇒ Object
Returns the value of attribute subspecs.
8 9 10 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 8 def subspecs @subspecs end |
#tag ⇒ Object
Returns the value of attribute tag.
11 12 13 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 11 def tag @tag end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
19 20 21 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 19 def type @type end |
#version ⇒ Object
Returns the value of attribute version.
9 10 11 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 9 def version @version end |
Instance Method Details
#option ⇒ Object
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/core_blur/yaml/yaml_pod.rb', line 20 def option result = {:configurations => self.configurations, :inhibit_warnings => self.inhibit_warnings, :subspecs => self.subspecs} if self.path #路径依赖 result[:path] = self.path elsif self.podspec #podspec引用 result[:podspec] = self.podspec elsif self.version #版本号依赖 result[:source] = self.source elsif self.git #git仓库引用 result[:git] = self.git if self.tag #tag引用 result[:tag] = self.tag else #分支引用 或着未指定分支 也按分支引用 result[:branch] = self.branch end end result end |