21 lines
479 B
Plaintext
21 lines
479 B
Plaintext
// create a class with methods that will be listed
|
|
class Methods
|
|
def static method1()
|
|
return "this is a static method. it will not be printed"
|
|
end
|
|
def method2()
|
|
return "this is not a static method"
|
|
end
|
|
|
|
def operator=(other)
|
|
// operator methods are listed by both their defined name and
|
|
// by their internal name, which in this case is isEqual
|
|
return true
|
|
end
|
|
end
|
|
|
|
// lists all nanoquery and java native methods
|
|
for method in dir(new(Methods))
|
|
println method
|
|
end
|