Class: Project

Inherits:
Object
  • Object
show all
Defined in:
lib/project.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name) {|_self| ... } ⇒ Project

Returns a new instance of Project.

Yields:

  • (_self)

Yield Parameters:

  • _self (Project)

    the object that the method was called on



23
24
25
26
27
28
29
30
31
# File 'lib/project.rb', line 23

def initialize(name)

	@name = name
	@targets = []
	@config_files = {}
		
	yield self

end

Instance Attribute Details

#config_filesObject (readonly)

Returns the value of attribute config_files.



19
20
21
# File 'lib/project.rb', line 19

def config_files
  @config_files
end

#nameObject

Returns the value of attribute name.



21
22
23
# File 'lib/project.rb', line 21

def name
  @name
end

#targetsObject (readonly)

Returns the value of attribute targets.



20
21
22
# File 'lib/project.rb', line 20

def targets
  @targets
end

Instance Method Details

#file_nameObject



39
40
41
42
43
# File 'lib/project.rb', line 39

def file_name
	
	return @name + ".xcodeproj"
	
end

#target(name, &block) ⇒ Object



33
34
35
36
37
# File 'lib/project.rb', line 33

def target(name, &block)

	targets << Target.new(name, &block)
	
end