# Path: celestia/utility/enum.py
# def enum(*args, **kwargs):
#     enums = dict(zip(args, range(len(args))), **kwargs)
#     enums['map'] = copy.copy(enums)
#     enums['rmap'] = {}
#     for k,v in enums.items():
#         try:
#             enums['rmap'][v] = k
#         except TypeError:
#             pass
#     return type('Enum', (), enums)
# 
# Path: celestia/utility/defaultordereddict.py
# class DefaultOrderedDict(OrderedDict):
#     def __init__(self, default_factory=None, *a, **kw):
#         if (default_factory is not None and
#             not isinstance(default_factory, Callable)):
#             raise TypeError('first argument must be callable')
#         OrderedDict.__init__(self, *a, **kw)
#         self.default_factory = default_factory
# 
#     def __getitem__(self, key):
#         try:
#             return OrderedDict.__getitem__(self, key)
#         except KeyError:
#             return self.__missing__(key)
# 
#     def __missing__(self, key):
#         if self.default_factory is None:
#             raise KeyError(key)
#         self[key] = value = self.default_factory()
#         return value
# 
#     def __reduce__(self):
#         if self.default_factory is None:
#             args = tuple()
#         else:
#             args = self.default_factory,
#         return type(self), args, None, None, self.items()
# 
#     def copy(self):
#         return self.__copy__()
# 
#     def __copy__(self):
#         return type(self)(self.default_factory, self)
# 
#     def __deepcopy__(self, memo):
#         import copy
#         return type(self)(self.default_factory,
#                           copy.deepcopy(self.items()))
# 
#     def __repr__(self):
#         return 'OrderedDefaultDict(%s, %s)' % (self.default_factory,
#                                                OrderedDict.__repr__(self))


from collections import defaultdict, OrderedDict
from .enum import enum
from .defaultordereddict import DefaultOrderedDict
    def _shards(self):
        return min(max(int(self._tag["@PonyShards"].value), 0), 10)

    @property
    def level(self):
        return self._level

    @property
    def exp(self):
        return self._exp

    @property
    def shards(self):
        return self._shards

    @property
    def next_game(self):
        return 'None'

    def __repr__(self):
        return ('%s(ID: %s, Name: %s, Level: %s, Shards: %s, Next Game: %s)'
                % (self.__class__.__name__,
                   self.ID,
                   self.name,
                   self.level,
                   self.shards,
                   self.next_game))


class Pony(StoredItem):

# Path: celestia/utility/enum.py
# def enum(*args, **kwargs):
#     enums = dict(zip(args, range(len(args))), **kwargs)
#     enums['map'] = copy.copy(enums)
#     enums['rmap'] = {}
#     for k,v in enums.items():
#         try:
#             enums['rmap'][v] = k
#         except TypeError:
#             pass
#     return type('Enum', (), enums)
# 
# Path: celestia/utility/defaultordereddict.py
# class DefaultOrderedDict(OrderedDict):
#     def __init__(self, default_factory=None, *a, **kw):
#         if (default_factory is not None and
#             not isinstance(default_factory, Callable)):
#             raise TypeError('first argument must be callable')
#         OrderedDict.__init__(self, *a, **kw)
#         self.default_factory = default_factory
# 
#     def __getitem__(self, key):
#         try:
#             return OrderedDict.__getitem__(self, key)
#         except KeyError:
#             return self.__missing__(key)
# 
#     def __missing__(self, key):
#         if self.default_factory is None:
#             raise KeyError(key)
#         self[key] = value = self.default_factory()
#         return value
# 
#     def __reduce__(self):
#         if self.default_factory is None:
#             args = tuple()
#         else:
#             args = self.default_factory,
#         return type(self), args, None, None, self.items()
# 
#     def copy(self):
#         return self.__copy__()
# 
#     def __copy__(self):
#         return type(self)(self.default_factory, self)
# 
#     def __deepcopy__(self, memo):
#         import copy
#         return type(self)(self.default_factory,
#                           copy.deepcopy(self.items()))
# 
#     def __repr__(self):
#         return 'OrderedDefaultDict(%s, %s)' % (self.default_factory,
#                                                OrderedDict.__repr__(self))


# Path: celestia/utility/utility.py
from collections import defaultdict, OrderedDict
from .enum import enum
from .defaultordereddict import DefaultOrderedDict

    def _shards(self):
        return min(max(int(self._tag["@PonyShards"].value), 0), 10)

    @property
    def level(self):
        return self._level

    @property
    def exp(self):
        return self._exp

    @property
    def shards(self):
        return self._shards

    @property
    def next_game(self):
        return 'None'

    def __repr__(self):
        return ('%s(ID: %s, Name: %s, Level: %s, Shards: %s, Next Game: %s)'
                % (self.__class__.__name__,
                   self.ID,
                   self.name,
                   self.level,
                   self.shards,
                   self.next_game))


class Pony(StoredItem):

    GameTypes = enum(Ball=0, Apple=1, Book=2)