Class: AllowedDependency
- Inherits:
-
Object
- Object
- AllowedDependency
- Defined in:
- lib/cocoapods-whitelist/model/allowed_dependency.rb
Instance Attribute Summary collapse
-
#allows_granular_projects ⇒ Object
Returns the value of attribute allows_granular_projects.
-
#expire ⇒ Object
Returns the value of attribute expire.
-
#name ⇒ Object
Returns the value of attribute name.
-
#source ⇒ Object
Returns the value of attribute source.
-
#target ⇒ Object
Returns the value of attribute target.
-
#version ⇒ Object
Returns the value of attribute version.
Instance Method Summary collapse
- #expire? ⇒ Boolean
-
#initialize(name, version, expire, source, target, allows_granular_projects) ⇒ AllowedDependency
constructor
A new instance of AllowedDependency.
Constructor Details
#initialize(name, version, expire, source, target, allows_granular_projects) ⇒ AllowedDependency
Returns a new instance of AllowedDependency.
9 10 11 12 13 14 15 16 |
# File 'lib/cocoapods-whitelist/model/allowed_dependency.rb', line 9 def initialize(name, version, expire, source, target, allows_granular_projects) @name = name @version = version @expire = expire @source = source @target = target @allows_granular_projects = allows_granular_projects end |
Instance Attribute Details
#allows_granular_projects ⇒ Object
Returns the value of attribute allows_granular_projects.
7 8 9 |
# File 'lib/cocoapods-whitelist/model/allowed_dependency.rb', line 7 def allows_granular_projects @allows_granular_projects end |
#expire ⇒ Object
Returns the value of attribute expire.
4 5 6 |
# File 'lib/cocoapods-whitelist/model/allowed_dependency.rb', line 4 def expire @expire end |
#name ⇒ Object
Returns the value of attribute name.
2 3 4 |
# File 'lib/cocoapods-whitelist/model/allowed_dependency.rb', line 2 def name @name end |
#source ⇒ Object
Returns the value of attribute source.
5 6 7 |
# File 'lib/cocoapods-whitelist/model/allowed_dependency.rb', line 5 def source @source end |
#target ⇒ Object
Returns the value of attribute target.
6 7 8 |
# File 'lib/cocoapods-whitelist/model/allowed_dependency.rb', line 6 def target @target end |
#version ⇒ Object
Returns the value of attribute version.
3 4 5 |
# File 'lib/cocoapods-whitelist/model/allowed_dependency.rb', line 3 def version @version end |
Instance Method Details
#expire? ⇒ Boolean
18 19 20 21 22 23 24 |
# File 'lib/cocoapods-whitelist/model/allowed_dependency.rb', line 18 def expire? if @expire != nil expire = DateTime.parse(@expire,"%Y-%m-%d") return expire < DateTime.now end return false end |