Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cocoapods
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gengmeiios
cocoapods
Commits
71d754c4
Commit
71d754c4
authored
Jun 09, 2012
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Docs] Platform#support?
parent
d0ebef6a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
9 deletions
+5
-9
platform.rb
lib/cocoapods/platform.rb
+5
-9
No files found.
lib/cocoapods/platform.rb
View file @
71d754c4
...
@@ -103,22 +103,18 @@ module Pod
...
@@ -103,22 +103,18 @@ module Pod
end
end
end
end
# A platform supports (from the point of view of a pod) another platform
# In the context of operating system SDKs, a platform supports another
# if they represent the same SDK and if the deployment target of the other
# one if they have the same name and the other platform has a minor or
# is lower. If one of the platforms does not specify the deployment target,
# equal deployment target.
# it is not taken into account.
#
#
# @note This method returns true if one of the platforms is nil.
# @note This method returns true if one of the platforms is nil.
#
#
# @return Whether the platform supports being used in the environment
# @return Whether the platform supports another platform.
# described by another platform.
#
# @todo rename to supported_on?
#
#
def
supports?
(
other
)
def
supports?
(
other
)
return
true
if
@symbolic_name
.
nil?
||
other
.
nil?
return
true
if
@symbolic_name
.
nil?
||
other
.
nil?
other
=
Platform
.
new
(
other
)
other
=
Platform
.
new
(
other
)
(
name
==
other
.
name
)
&&
(
deployment_target
>=
other
.
deployment_target
)
(
other
.
name
==
name
)
&&
(
other
.
deployment_target
<=
deployment_target
)
end
end
# @return [String] A string representation including the deployment target.
# @return [String] A string representation including the deployment target.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment