/tags/jsdoc_toolkit-2.4.0/jsdoc-toolkit/app/plugins/tagParamConfig.js
JavaScript | 31 lines | 29 code | 1 blank | 1 comment | 15 complexity | a02d3943642513eb2541f3212e15bd6e MD5 | raw file
- JSDOC.PluginManager.registerPlugin(
- "JSDOC.tagParamConfig",
- {
- onDocCommentTags: function(comment) {
- var currentParam = null;
- var tags = comment.tags;
- for (var i = 0, l = tags.length; i < l; i++) {
-
- if (tags[i].title == "param") {
- if (tags[i].name.indexOf(".") == -1) {
- currentParam = i;
- }
- }
- else if (tags[i].title == "config") {
- tags[i].title = "param";
- if (currentParam == null) {
- tags[i].name = "arguments"+"."+tags[i].name;
- }
- else if (tags[i].name.indexOf(tags[currentParam].name+".") != 0) {
- tags[i].name = tags[currentParam].name+"."+tags[i].name;
- }
- currentParam != null
- //tags[currentParam].properties.push(tags[i]);
- }
- else {
- currentParam = null;
- }
- }
- }
- }
- );