add tag class for media

This commit is contained in:
blacktwin 2019-11-11 09:32:55 -05:00
parent e6548649c8
commit 65bb149d7d

View file

@ -419,6 +419,25 @@ class Label(MediaTag):
FILTER = 'label'
@utils.registerPlexObject
class Tag(MediaTag):
""" Represents a single tag media tag.
Attributes:
TAG (str): 'tag'
FILTER (str): 'tag'
"""
TAG = 'Tag'
FILTER = 'tag'
def _loadData(self, data):
self._data = data
self.id = cast(int, data.attrib.get('id', 0))
self.filter = data.attrib.get('filter')
self.tag = data.attrib.get('tag')
self.title = self.tag
@utils.registerPlexObject
class Country(MediaTag):
""" Represents a single Country media tag.