from typing import ClassVar
from modules.database.tools.neontology.basenode import BaseNode

class CCBaseNode(BaseNode):
    __primarylabel__: ClassVar[str] = ''
    __primaryproperty__: ClassVar[str] = 'uuid_string'
    uuid_string: str
    node_storage_path: str

    def to_dict(self):
        return {
            "__primarylabel__": self.__primarylabel__,
            "uuid_string": self.uuid_string,
            "node_storage_path": self.node_storage_path,
        }
    
class UserBaseNode(CCBaseNode):
    __primarylabel__: ClassVar[str] = ''
    cc_username: str
    user_email: str
    user_db_name: str
    user_name: str
    user_type: str

    def to_dict(self):
        return {
            "__primarylabel__": self.__primarylabel__,
            "uuid_string": self.uuid_string,
            "node_storage_path": self.node_storage_path,
            "cc_username": self.cc_username,
            "user_db_name": self.user_db_name,
            "user_email": self.user_email,
            "user_name": self.user_name,
            "user_type": self.user_type,
        }

class WorkerBaseNode(CCBaseNode):
    __primarylabel__: ClassVar[str] = ''
    worker_name: str
    worker_email: str
    worker_db_name: str
    worker_type: str
    def to_dict(self):
        return {
            "__primarylabel__": self.__primarylabel__,
            "uuid_string": self.uuid_string,
            "node_storage_path": self.node_storage_path,
            "worker_name": self.worker_name,
            "worker_email": self.worker_email,
            "worker_db_name": self.worker_db_name,
            "worker_type": self.worker_type,
        }
