Sha256: c9ae6de6f65f52420b6b42e56d2e1badf550da36b34e1a62aef364f740179a7d

Contents?: true

Size: 1.29 KB

Versions: 10

Compression:

Stored size: 1.29 KB

Contents

JSDOC.PluginManager.registerPlugin(
  "JSDOC.tagSynonyms",
  {
    onDocCommentSrc: function(comment) {
      comment.src = comment.src.replace(/@methodOf\b/i, "@function\n@memberOf");
      comment.src = comment.src.replace(/@fieldOf\b/i, "@field\n@memberOf");
    },
    
    onDocCommentTags: function(comment) {
      for (var i = 0, l = comment.tags.length; i < l; i++) {
        var title = comment.tags[i].title.toLowerCase();
        var syn;
        if ((syn = JSDOC.tagSynonyms.synonyms["="+title])) {
          comment.tags[i].title = syn;
        }
      }
    }
  }
);

new Namespace(
  "JSDOC.tagSynonyms",
  function() {
    JSDOC.tagSynonyms.synonyms = {
      "=member":             "memberOf",
      "=memberof":           "memberOf",
      "=description":        "desc",
      "=exception":          "throws",
      "=argument":           "param",
      "=returns":            "return",
      "=classdescription":   "class",
      "=fileoverview":       "overview",
      "=extends":            "augments",
      "=base":               "augments",
      "=projectdescription": "overview",
      "=classdescription":   "class",
      "=link":               "see",
      "=borrows":            "inherits",
      "=scope":              "lends",
      "=construct":          "constructor"
    }
  }
);

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
sproutcore-0.9.14 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.15 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.17 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.19 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.16 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.18 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.23 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.20 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.22 jsdoc/app/plugins/tagSynonyms.js
sproutcore-0.9.21 jsdoc/app/plugins/tagSynonyms.js