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
a3cc38de
Commit
a3cc38de
authored
Feb 06, 2013
by
Fabio Pelosin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix for Ruby 1.8.7
parent
c6be52a7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
28 deletions
+0
-28
cocoapods.rb
lib/cocoapods.rb
+0
-1
dependency_injection.rb
lib/cocoapods/dependency_injection.rb
+0
-27
No files found.
lib/cocoapods.rb
View file @
a3cc38de
...
...
@@ -20,7 +20,6 @@ module Pod
require
'cocoapods/downloader'
require
'cocoapods/file_list'
require
'cocoapods/config'
require
'cocoapods/dependency_injection'
autoload
:Command
,
'cocoapods/command'
autoload
:Executable
,
'cocoapods/executable'
...
...
lib/cocoapods/dependency_injection.rb
deleted
100644 → 0
View file @
c6be52a7
module
Pod
# Provides basic support for Dependency Injection in a class.
#
module
DependencyInjection
# Declares a dependency in another class specifying a default. The class
# implementing this method should should initialize the dependency
# accessing this property.
#
# @param [Symbol] name
# the name of the dependency.
#
# @param [Class] default_class
# the default class to use for the dependency.
#
# @return [void]
#
def
dependency
(
name
,
default_class
)
singleton_class
.
class_eval
do
attr_writer
name
define_method
(
name
)
{
instance_variable_get
(
"@
#{
name
}
"
)
||
default_class
}
end
end
end
end
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