Class: Spotify::Music::Importer::CollectionMatch
- Inherits:
-
Object
- Object
- Spotify::Music::Importer::CollectionMatch
- Defined in:
- lib/spotify/music/importer/collection_match.rb
Instance Method Summary collapse
- #album_match ⇒ Object
- #full_match ⇒ Object
-
#initialize(collection_record, spotify_match) ⇒ CollectionMatch
constructor
A new instance of CollectionMatch.
- #name_match ⇒ Object
Constructor Details
#initialize(collection_record, spotify_match) ⇒ CollectionMatch
Returns a new instance of CollectionMatch.
5 6 7 8 |
# File 'lib/spotify/music/importer/collection_match.rb', line 5 def initialize(collection_record, spotify_match) @collection_record = collection_record @spotify_match = spotify_match end |
Instance Method Details
#album_match ⇒ Object
18 19 20 |
# File 'lib/spotify/music/importer/collection_match.rb', line 18 def album_match @collection_record.album == @spotify_match.album end |
#full_match ⇒ Object
10 11 12 |
# File 'lib/spotify/music/importer/collection_match.rb', line 10 def full_match name_match && album_match end |
#name_match ⇒ Object
14 15 16 |
# File 'lib/spotify/music/importer/collection_match.rb', line 14 def name_match @collection_record.name == @spotify_match.name end |