/wiki/TagExports.wiki

http://jsdoc-toolkit.googlecode.com/ · Unknown · 35 lines · 25 code · 10 blank · 0 comment · 0 complexity · 019db522f986c76fb2e2eb9173f5fc24 MD5 · raw file

  1. #summary @exports
  2. == The @exports Tag (available since 2.2.0) ==
  3. The `@exports` tag allows you to document any symbol as if it were a different symbol with a different name. This might be useful if you were using an alias to another symbol in your code but wanted to document that alias under the original name.
  4. === Syntax ===
  5. {{{
  6. @exports codedName as documentedName
  7. }}}
  8. * codedName - Required: the name you are using in your code.
  9. * documentedName - Required: the name you want to appear in the documentation.
  10. === Example ===
  11. {{{
  12. /** @namespace */
  13. var mxn = {};
  14. (function() {
  15. /** @exports Map as mxn.Map */
  16. var Map =
  17. /** @constructor */
  18. mxn.Map = function() {
  19. };
  20. /** This will be documented as a method of mxn.Map. */
  21. Map.prototype.doThings = function() {
  22. };
  23. })();
  24. }}}
  25. Multiple exports tags are allowed in one documentation comment. It is a good idea, but not required, to put the documentation comment adjacent to the code where the alias is created.