This might seem very trivial, but I cannot figure this out. In OOP language like c#, I can pass instance of self type to a function. For example,
class Edge
{
void F(Edge e){
// Do something here.
}
}
Here function F takes an argument of type Edge, to which it belongs.
However, I am unable to do this in python.
class Edge:
def f(self, that: Edge):
pass
I get an error,
NameError: name 'Edge' is not defined
Can anyone point out how to get this working?
Thank you.