# -*- coding: utf-8 -*-
#
# Copyright (c) ZeroC, Inc. All rights reserved.
#
#
# Ice version 3.7.2
#
# <auto-generated>
#
# Generated from file `ServeurIce.ice'
#
# Warning: do not edit this file.
#
# </auto-generated>
#

from sys import version_info as _version_info_
import Ice, IcePy

# Start of module server
_M_server = Ice.openModule('server')
__name__ = 'server'

if 'Musique' not in _M_server.__dict__:
    _M_server.Musique = Ice.createTempClass()
    class Musique(object):
        def __init__(self, id=0, name='', artist=''):
            self.id = id
            self.name = name
            self.artist = artist

        def __hash__(self):
            _h = 0
            _h = 5 * _h + Ice.getHash(self.id)
            _h = 5 * _h + Ice.getHash(self.name)
            _h = 5 * _h + Ice.getHash(self.artist)
            return _h % 0x7fffffff

        def __compare(self, other):
            if other is None:
                return 1
            elif not isinstance(other, _M_server.Musique):
                return NotImplemented
            else:
                if self.id is None or other.id is None:
                    if self.id != other.id:
                        return (-1 if self.id is None else 1)
                else:
                    if self.id < other.id:
                        return -1
                    elif self.id > other.id:
                        return 1
                if self.name is None or other.name is None:
                    if self.name != other.name:
                        return (-1 if self.name is None else 1)
                else:
                    if self.name < other.name:
                        return -1
                    elif self.name > other.name:
                        return 1
                if self.artist is None or other.artist is None:
                    if self.artist != other.artist:
                        return (-1 if self.artist is None else 1)
                else:
                    if self.artist < other.artist:
                        return -1
                    elif self.artist > other.artist:
                        return 1
                return 0

        def __lt__(self, other):
            r = self.__compare(other)
            if r is NotImplemented:
                return r
            else:
                return r < 0

        def __le__(self, other):
            r = self.__compare(other)
            if r is NotImplemented:
                return r
            else:
                return r <= 0

        def __gt__(self, other):
            r = self.__compare(other)
            if r is NotImplemented:
                return r
            else:
                return r > 0

        def __ge__(self, other):
            r = self.__compare(other)
            if r is NotImplemented:
                return r
            else:
                return r >= 0

        def __eq__(self, other):
            r = self.__compare(other)
            if r is NotImplemented:
                return r
            else:
                return r == 0

        def __ne__(self, other):
            r = self.__compare(other)
            if r is NotImplemented:
                return r
            else:
                return r != 0

        def __str__(self):
            return IcePy.stringify(self, _M_server._t_Musique)

        __repr__ = __str__

    _M_server._t_Musique = IcePy.defineStruct('::server::Musique', Musique, (), (
        ('id', (), IcePy._t_int),
        ('name', (), IcePy._t_string),
        ('artist', (), IcePy._t_string)
    ))

    _M_server.Musique = Musique
    del Musique

if '_t_bdd' not in _M_server.__dict__:
    _M_server._t_bdd = IcePy.defineSequence('::server::bdd', (), _M_server._t_Musique)

_M_server._t_ServeurIce = IcePy.defineValue('::server::ServeurIce', Ice.Value, -1, (), False, True, None, ())

if 'ServeurIcePrx' not in _M_server.__dict__:
    _M_server.ServeurIcePrx = Ice.createTempClass()
    class ServeurIcePrx(Ice.ObjectPrx):

        def ajouterMusique(self, name, context=None):
            return _M_server.ServeurIce._op_ajouterMusique.invoke(self, ((name, ), context))

        def ajouterMusiqueAsync(self, name, context=None):
            return _M_server.ServeurIce._op_ajouterMusique.invokeAsync(self, ((name, ), context))

        def begin_ajouterMusique(self, name, _response=None, _ex=None, _sent=None, context=None):
            return _M_server.ServeurIce._op_ajouterMusique.begin(self, ((name, ), _response, _ex, _sent, context))

        def end_ajouterMusique(self, _r):
            return _M_server.ServeurIce._op_ajouterMusique.end(self, _r)

        def jouerMusique(self, id, context=None):
            return _M_server.ServeurIce._op_jouerMusique.invoke(self, ((id, ), context))

        def jouerMusiqueAsync(self, id, context=None):
            return _M_server.ServeurIce._op_jouerMusique.invokeAsync(self, ((id, ), context))

        def begin_jouerMusique(self, id, _response=None, _ex=None, _sent=None, context=None):
            return _M_server.ServeurIce._op_jouerMusique.begin(self, ((id, ), _response, _ex, _sent, context))

        def end_jouerMusique(self, _r):
            return _M_server.ServeurIce._op_jouerMusique.end(self, _r)

        def stopMusique(self, context=None):
            return _M_server.ServeurIce._op_stopMusique.invoke(self, ((), context))

        def stopMusiqueAsync(self, context=None):
            return _M_server.ServeurIce._op_stopMusique.invokeAsync(self, ((), context))

        def begin_stopMusique(self, _response=None, _ex=None, _sent=None, context=None):
            return _M_server.ServeurIce._op_stopMusique.begin(self, ((), _response, _ex, _sent, context))

        def end_stopMusique(self, _r):
            return _M_server.ServeurIce._op_stopMusique.end(self, _r)

        def display(self, context=None):
            return _M_server.ServeurIce._op_display.invoke(self, ((), context))

        def displayAsync(self, context=None):
            return _M_server.ServeurIce._op_display.invokeAsync(self, ((), context))

        def begin_display(self, _response=None, _ex=None, _sent=None, context=None):
            return _M_server.ServeurIce._op_display.begin(self, ((), _response, _ex, _sent, context))

        def end_display(self, _r):
            return _M_server.ServeurIce._op_display.end(self, _r)

        def getBdd(self, context=None):
            return _M_server.ServeurIce._op_getBdd.invoke(self, ((), context))

        def getBddAsync(self, context=None):
            return _M_server.ServeurIce._op_getBdd.invokeAsync(self, ((), context))

        def begin_getBdd(self, _response=None, _ex=None, _sent=None, context=None):
            return _M_server.ServeurIce._op_getBdd.begin(self, ((), _response, _ex, _sent, context))

        def end_getBdd(self, _r):
            return _M_server.ServeurIce._op_getBdd.end(self, _r)

        @staticmethod
        def checkedCast(proxy, facetOrContext=None, context=None):
            return _M_server.ServeurIcePrx.ice_checkedCast(proxy, '::server::ServeurIce', facetOrContext, context)

        @staticmethod
        def uncheckedCast(proxy, facet=None):
            return _M_server.ServeurIcePrx.ice_uncheckedCast(proxy, facet)

        @staticmethod
        def ice_staticId():
            return '::server::ServeurIce'
    _M_server._t_ServeurIcePrx = IcePy.defineProxy('::server::ServeurIce', ServeurIcePrx)

    _M_server.ServeurIcePrx = ServeurIcePrx
    del ServeurIcePrx

    _M_server.ServeurIce = Ice.createTempClass()
    class ServeurIce(Ice.Object):

        def ice_ids(self, current=None):
            return ('::Ice::Object', '::server::ServeurIce')

        def ice_id(self, current=None):
            return '::server::ServeurIce'

        @staticmethod
        def ice_staticId():
            return '::server::ServeurIce'

        def ajouterMusique(self, name, current=None):
            raise NotImplementedError("servant method 'ajouterMusique' not implemented")

        def jouerMusique(self, id, current=None):
            raise NotImplementedError("servant method 'jouerMusique' not implemented")

        def stopMusique(self, current=None):
            raise NotImplementedError("servant method 'stopMusique' not implemented")

        def display(self, current=None):
            raise NotImplementedError("servant method 'display' not implemented")

        def getBdd(self, current=None):
            raise NotImplementedError("servant method 'getBdd' not implemented")

        def __str__(self):
            return IcePy.stringify(self, _M_server._t_ServeurIceDisp)

        __repr__ = __str__

    _M_server._t_ServeurIceDisp = IcePy.defineClass('::server::ServeurIce', ServeurIce, (), None, ())
    ServeurIce._ice_type = _M_server._t_ServeurIceDisp

    ServeurIce._op_ajouterMusique = IcePy.Operation('ajouterMusique', Ice.OperationMode.Normal, Ice.OperationMode.Normal, False, None, (), (((), IcePy._t_string, False, 0),), (), ((), IcePy._t_bool, False, 0), ())
    ServeurIce._op_jouerMusique = IcePy.Operation('jouerMusique', Ice.OperationMode.Normal, Ice.OperationMode.Normal, False, None, (), (((), IcePy._t_int, False, 0),), (), None, ())
    ServeurIce._op_stopMusique = IcePy.Operation('stopMusique', Ice.OperationMode.Normal, Ice.OperationMode.Normal, False, None, (), (), (), ((), IcePy._t_bool, False, 0), ())
    ServeurIce._op_display = IcePy.Operation('display', Ice.OperationMode.Normal, Ice.OperationMode.Normal, False, None, (), (), (), None, ())
    ServeurIce._op_getBdd = IcePy.Operation('getBdd', Ice.OperationMode.Normal, Ice.OperationMode.Normal, False, None, (), (), (), ((), _M_server._t_bdd, False, 0), ())

    _M_server.ServeurIce = ServeurIce
    del ServeurIce

# End of module server
