class Namer (object):
def __init__(self, arg):
self.arg = arg
A = Namer("A")
B = Namer("B")
C = Namer("C")
print(A.arg)
print(B.arg)
print(C.arg)
class FrameIt(object):
def __init__(self, content):
#Namer.__init__(self, arg) #<-----------?
#super().__init__(self, arg) #<-----------?
self.content = content
#super().__init__() #<-------------------?
def framed (self):
print(self.content)
X = FrameIt(A)
Y = FrameIt(B)
Z = FrameIt(C)
print("\n")
X.content() #<----------- access properties?
Y.content()
Z.content()
print("\n")
X.framed() #<------------ access method output?
Generates output, like this:
TypeError: 'Namer' object is not callable
How to get to the good stuff in the instance?
Any help much appreciated.