# -*- coding: utf-8 -*-

from PyQt4.QtCore import QObject


class UserBaseInfo(QObject):
    def __init__(self):
        super(UserBaseInfo,self).__init__()
        self.serverIp = ""
        self.name = ""
        self.password = ""


class LoginUserInfo(QObject):
    _instance = 0
    def __init__(self,userInfo):
        super(LoginUserInfo,self).__init__()
        self.userInfo = userInfo

    @classmethod
    def instance(cls, userInfo=None):
        if (cls._instance == 0):
            cls._instance = LoginUserInfo(userInfo)

        return cls._instance
    
    
    def getUserInfo(self):
        return self.userInfo
    
    
    def setUserInfo(self, baseInfo):
        self.userInfo = baseInfo
        
        


        
        
        
    