@help and cobra -doc-lib
Posted: Wed May 09, 2012 8:41 am
There is a compile-time Cobra feature called @help, which shows you the interface of a class. Want to see the interface to String in Cobra terms? Then:
The significance of @ is that this is used for compiler directives.
During compilation, each @help creates an HTML file with the Cobra interface to the type as well as handy search links to different sites (Cobra, Stackoverflow, Google, MSDN) and a footer section showing env vars that you can use to customize what @help outputs.
There is also a command line option for Cobra to output docs for a library called "cobra -doc-lib:...". See "cobra -help" for more information. -doc-lib is often in need of maintenance. If you have any problems with it, please report them with specifics so we can improve it.
class X
def main
@help String
# or
s = ''
@help s
The significance of @ is that this is used for compiler directives.
During compilation, each @help creates an HTML file with the Cobra interface to the type as well as handy search links to different sites (Cobra, Stackoverflow, Google, MSDN) and a footer section showing env vars that you can use to customize what @help outputs.
There is also a command line option for Cobra to output docs for a library called "cobra -doc-lib:...". See "cobra -help" for more information. -doc-lib is often in need of maintenance. If you have any problems with it, please report them with specifics so we can improve it.