summaryrefslogtreecommitdiff
path: root/nephilim/song.py
diff options
context:
space:
mode:
authorAnton Khirnov <wyskas@gmail.com>2009-05-05 19:05:45 +0200
committerAnton Khirnov <wyskas@gmail.com>2009-05-05 19:05:45 +0200
commit369d3dbed4c8ee6a62f41d23361961542ced3240 (patch)
treeca8a7cc8eaf93fb4ba31da510aa58f908a0c3262 /nephilim/song.py
parenta0e422fc5ec3a6ee7b3d41061157f6041f704219 (diff)
song: 100l - add __ne__ operator.
Diffstat (limited to 'nephilim/song.py')
-rw-r--r--nephilim/song.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/nephilim/song.py b/nephilim/song.py
index df111cd..d2221ec 100644
--- a/nephilim/song.py
+++ b/nephilim/song.py
@@ -55,6 +55,11 @@ class Song:
return NotImplemented
return self._data['file'] == other._data['file']
+ def __ne__(self, other):
+ if not isinstance(other, Song):
+ return NotImplemented
+ return self._data['file'] != other._data['file']
+
def id(self):
"""Get the song's playlist ID. (-1 if not in playlist)."""
return self.tag('id', -1)