from Tree import Node
q = Node(p)
El problema con el código es que me sale este mensaje:
'Node' is not callable This inspection highlights attempts to call objects which are not callable, like, for example, tuples.
Esto no me deja acceder a los métodos de la clase Node
class Node:
txt = 0
izq = None
der = None
def __init__(self, txt):
self.txt = txt
self.izq = None
self.der = None
#Setters
def setTxt(self, ntxt):
self.txt = ntxt
def setIzq(self, nIzq):
self.izq = nIzq
def setDer(self, nDer):
self.der = nDer
#Getters
def getTxt(self):
return self.txt
def getIzq(self):
return self.izq
def getDer(self):
return self.der