示例#1
0
文件: sadserver.py 项目: diacus/celda
    def __init__( self ):

        Node.__init__(self)
        self.__neighfrag = self._dbase.selectvirtualspaces()
        self.__neighidas = self._dbase.selectvirtualspaces()

        self._funcs[Message.SAVESTREAM]   = ServerHandler.processfile
        self._funcs[Message.SAVEFRAGMENT] = ServerHandler.processfragment
        self._funcs[Message.SAVEBLOCK]    = ServerHandler.processblock
        self._funcs[Message.LOADSTREAM]   = notimplementedfunction
        self._funcs[Message.LOADFRAGMENT] = notimplementedfunction
        self._funcs[Message.LOADBLOCK]    = notimplementedfunction
示例#2
0
文件: sadproxy.py 项目: diacus/celda
    def __init__(self):
        """
        Constructor class
        """

        Node.__init__(self)

        self._funcs[Message.SAVESTREAM]   = ProxyHandler.storestream
        self._funcs[Message.LISTFILES]    = ProxyHandler.listfiles
        self._funcs[Message.LISTSERVS]    = ProxyHandler.listservices
        self._funcs[Message.CONNECT]      = ProxyHandler.connect
        self._funcs[Message.LOADSTREAM]   = ProxyHandler.loadstream
        self._funcs[Message.ADDUSER]      = notimplementedfunction
        self._funcs[Message.DISUSER]      = notimplementedfunction
        self._funcs[Message.ADDGROUP]     = notimplementedfunction
        self._funcs[Message.DELGROUP]     = notimplementedfunction
        self._funcs[Message.ADDNODE]      = notimplementedfunction