-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp.rb
71 lines (55 loc) · 1.12 KB
/
app.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
require './book_methods'
require './game_methods'
require_relative 'music_methods'
require_relative 'storage'
class App
include Storage
attr_accessor :book_methods, :game_methods, :music_methods
def initialize
@book_methods = BookMethods.new
@game_methods = GameMethods.new
@music_methods = MusicMethods.new
end
def list_all_books
book_methods.list_all_books
end
def list_all_labels
book_methods.list_all_labels
end
def add_a_book
book_methods.add_a_book
end
def save_book
book_methods.save_book
end
def load_book
book_methods.load_book
end
def list_games
game_methods.list_games
end
def list_authors
game_methods.list_authors
end
def add_game
game_methods.add_game
end
def save_game
game_methods.save_game
end
def load_game
game_methods.load_game
end
def list_all_music_albums
music_methods.list_all_music_albums
end
def list_all_genres
music_methods.list_all_genres
end
def add_music_album
music_methods.add_music_album
end
def find_or_create_genre
music_methods.find_or_create_genre
end
end