Phlip
8/15/2008 1:52:00 PM
Patrick Li wrote:
> What would you guys say is the best way of creating a helper method?
>
> module MyModule
> def myMethod
> #bla bla
> end
> end
>
> def helperMethod
> #a helper method whose existence should not be known outside of this
> file
> end
>
> helperMethod() shouldn't be visible from anywhere outside this file.
Can you put helperMethod inside MyModule, and make it private? I don't know if
the language supports that.
And you may want to consider unit tests as more important than static type
checking, to keep a program on track...
--
Phlip