Beispiel #1
0
#!/usr/bin/env python

from overload import Example

e = Example()

e.doit(); print e
print e.doit(2)
e.doit("Hallo"); print e

print "------"

print e.makeIt("xxx"); print e
print e.makeIt("abc", 2); print e
print e.makeIt("xyz", 3, "abc"); print e

Beispiel #2
0
#!/usr/bin/env python

from overload import Example

e = Example()

e.doit()
print(e)
print(e.doit(2))
e.doit("Hallo")
print(e)

print("------")

print(e.makeIt("xxx"), e)
print(e.makeIt("abc", 2), e)
print(e.makeIt("xyz", 3, "abc"), e)
Beispiel #3
0
#!/usr/bin/env python3

from overload import Example

e = Example()

e.doit()
print(e)
e.doit("Hello")
print(e)

print("---------")
print("{} {}".format(e.makeIt("xxx"), e))
print("{} {}".format(e.makeIt("abc", 2), e))
print("{} {}".format(e.makeIt("xyz", 3, "abc"), e))