remove useless function

This commit is contained in:
Jeff Williams 2014-12-01 20:10:24 -08:00
parent b5c4e202d9
commit 1865e51d0a

View File

@ -77,19 +77,24 @@ function unwrap(docletSrc) {
return docletSrc;
}
function split(docletSrc) {
var tagSrcs = [];
/**
* Convert the raw source of the doclet comment into an array of pseudo-Tag objects.
* @private
*/
function toTags(docletSrc) {
var parsedTag;
var tagData = [];
var tagText;
var tagTitle;
// split out the basic tags, keep surrounding whitespace
// like: @tagTitle tagBody
docletSrc
.replace(/^(\s*)@(\S)/gm, '$1\\@$2') // replace splitter ats with an arbitrary sequence
.split('\\@') // then split on that arbitrary sequence
// replace splitter ats with an arbitrary sequence
.replace(/^(\s*)@(\S)/gm, '$1\\@$2')
// then split on that arbitrary sequence
.split('\\@')
.forEach(function($) {
var parsedTag;
var tagText;
var tagTitle;
if ($) {
parsedTag = $.match(/^(\S+)(:?\s+(\S[\s\S]*))?/);
@ -99,7 +104,7 @@ function split(docletSrc) {
tagText = parsedTag[2];
if (tagTitle) {
tagSrcs.push({
tagData.push({
title: tagTitle,
text: tagText
});
@ -108,22 +113,7 @@ function split(docletSrc) {
}
});
return tagSrcs;
}
/**
* Convert the raw source of the doclet comment into an array of Tag objects.
* @private
*/
function toTags(docletSrc) {
var tags = [];
var tagSrcs = split(docletSrc);
for (var i = 0, l = tagSrcs.length; i < l; i++) {
tags.push({ title: tagSrcs[i].title, text: tagSrcs[i].text });
}
return tags;
return tagData;
}
function fixDescription(docletSrc) {