detab files to eliminate mixed spaces/tabs

this fixes a JSHint error that cannot be suppressed.
This commit is contained in:
Jeff Williams 2012-07-03 18:40:15 -07:00
parent ee858cc894
commit a54b51e276
2 changed files with 139 additions and 139 deletions

View File

@ -1,8 +1,8 @@
/** /**
@overview Schema for validating JSON produced by JSDoc Toolkit. @overview Schema for validating JSON produced by JSDoc Toolkit.
@author Michael Mathews <micmath@gmail.com> @author Michael Mathews <micmath@gmail.com>
@license Apache License 2.0 - See file 'LICENSE.md' in this project. @license Apache License 2.0 - See file 'LICENSE.md' in this project.
@see <http://tools.ietf.org/html/draft-zyp-json-schema-02> @see <http://tools.ietf.org/html/draft-zyp-json-schema-02>
*/ */
exports.jsdocSchema = { exports.jsdocSchema = {
@ -11,9 +11,9 @@ exports.jsdocSchema = {
"type": "array", "type": "array",
"items": { "items": {
"type": "object", "type": "object",
"additionalProperties": false, "additionalProperties": false,
"properties": { "properties": {
"author": { "author": {
"type": ["string", "array"], "type": ["string", "array"],
"optional": true, "optional": true,
"items": { "items": {
@ -62,10 +62,10 @@ exports.jsdocSchema = {
"type": "string" "type": "string"
} }
}, },
"deprecated": { // is usage of this symbol deprecated? "deprecated": { // is usage of this symbol deprecated?
"type": ["string", "boolean"], "type": ["string", "boolean"],
"optional": true "optional": true
}, },
"scope": { // how is this symbol attached to it's enclosing scope? "scope": { // how is this symbol attached to it's enclosing scope?
"type": "string", "type": "string",
"maxItems": 1, "maxItems": 1,
@ -98,7 +98,7 @@ exports.jsdocSchema = {
} }
}, },
"implements": { "implements": {
"type": ["string", "array"], "type": ["string", "array"],
"optional": true, "optional": true,
"items": { "items": {
"type": "string" "type": "string"
@ -137,40 +137,40 @@ exports.jsdocSchema = {
} }
}, },
"exception" : { "exception" : {
"optional": true, "optional": true,
"type": "object", "type": "object",
"properties": { "properties": {
"type": { // what is the type of the value thrown? "type": { // what is the type of the value thrown?
"type": "array", "type": "array",
"optional": true, "optional": true,
"items": { "items": {
"type": "string" "type": "string"
} }
}, },
"description": { // a description of the thrown value "description": { // a description of the thrown value
"type": "string", "type": "string",
"optional": true "optional": true
} }
}, },
"additionalProperties": false "additionalProperties": false
}, },
"returns" : { "returns" : {
"optional": true, "optional": true,
"type": "object", "type": "object",
"properties": { "properties": {
"type": { // what is the type of the value returned? "type": { // what is the type of the value returned?
"type": ["string", "array"], "type": ["string", "array"],
"optional": true, "optional": true,
"items": { "items": {
"type": "string" "type": "string"
} }
}, },
"description": { // a description of the returned value "description": { // a description of the returned value
"type": "string", "type": "string",
"optional": true "optional": true
} }
}, },
"additionalProperties": false "additionalProperties": false
}, },
"param" : { // are there function parameters associated with this doc? "param" : { // are there function parameters associated with this doc?
"type": "array", "type": "array",
@ -207,11 +207,11 @@ exports.jsdocSchema = {
"optional": true "optional": true
} }
}, },
"additionalProperties": false "additionalProperties": false
} }
}, },
"thisobj": { "thisobj": {
"type": ["string", "array"], "type": ["string", "array"],
"optional": true, "optional": true,
"items": { "items": {
"type": "string" "type": "string"
@ -237,18 +237,18 @@ exports.jsdocSchema = {
"optional": true, "optional": true,
"maxItems": 1, "maxItems": 1,
"properties": { "properties": {
"file": { // what is the name of the file this doc appears in? "file": { // what is the name of the file this doc appears in?
"type": "string", "type": "string",
"optional": true, "optional": true,
"maxItems": 1 "maxItems": 1
}, },
"line": { // on what line of the file does this doc appear? "line": { // on what line of the file does this doc appear?
"type": "number", "type": "number",
"optional": true, "optional": true,
"maxItems": 1 "maxItems": 1
} }
}, },
"additionalProperties": false "additionalProperties": false
} }
} }
} }
@ -258,51 +258,51 @@ exports.jsdocSchema = {
"optional": true, "optional": true,
"maxItems": 1, "maxItems": 1,
"properties": { "properties": {
"project": { // to what project does this doc belong? "project": { // to what project does this doc belong?
"type": "object", "type": "object",
"optional": true, "optional": true,
"maxItems": 1, "maxItems": 1,
"properties": { "properties": {
"name": { // the name of the project "name": { // the name of the project
"type": "string", "type": "string",
"maxItems": 1 "maxItems": 1
}, },
"uri": { // the URI of the project "uri": { // the URI of the project
"type": "string", "type": "string",
"maxItems": 1, "maxItems": 1,
"format": "uri" "format": "uri"
}, },
"version": { // the version of the project "version": { // the version of the project
"type": "string", "type": "string",
"maxItems": 1 "maxItems": 1
}, },
"lang": { // the programming language used in the project "lang": { // the programming language used in the project
"type": "string", "type": "string",
"maxItems": 1 "maxItems": 1
} }
}, },
"additionalProperties": false "additionalProperties": false
}, },
"generated": { // some information about the running of the doc generator "generated": { // some information about the running of the doc generator
"type": "object", "type": "object",
"optional": true, "optional": true,
"maxItems": 1, "maxItems": 1,
"properties": { "properties": {
"date": { // on what date and time was the doc generated? "date": { // on what date and time was the doc generated?
"type": "string", "type": "string",
"maxItems": 1, "maxItems": 1,
"optional": true, "optional": true,
"format": "date-time" "format": "date-time"
}, },
"parser": { // what tool was used to generate the doc? "parser": { // what tool was used to generate the doc?
"type": "string", "type": "string",
"maxItems": 1, "maxItems": 1,
"optional": true "optional": true
} }
}, },
"additionalProperties": false "additionalProperties": false
} }
} }
} }
} }
}; };

View File

@ -1,15 +1,15 @@
/** /**
@overview @overview
@author Michael Mathews <micmath@gmail.com> @author Michael Mathews <micmath@gmail.com>
@license Apache License 2.0 - See file 'LICENSE.md' in this project. @license Apache License 2.0 - See file 'LICENSE.md' in this project.
*/ */
/** /**
Functionality related to JSDoc tags. Functionality related to JSDoc tags.
@module jsdoc/tag @module jsdoc/tag
@requires jsdoc/tag/dictionary @requires jsdoc/tag/dictionary
@requires jsdoc/tag/validator @requires jsdoc/tag/validator
@requires jsdoc/tag/type @requires jsdoc/tag/type
*/ */
@ -105,40 +105,40 @@ exports.Tag = function(tagTitle, tagBody, meta) {
} }
function trim(text, newlines) { function trim(text, newlines) {
if (!text) { return ''; } if (!text) { return ''; }
if (newlines) { if (newlines) {
return text.replace(/^[\n\r\f]+|[\n\r\f]+$/g, ''); return text.replace(/^[\n\r\f]+|[\n\r\f]+$/g, '');
} }
else { else {
return text.replace(/^\s+|\s+$/g, ''); return text.replace(/^\s+|\s+$/g, '');
} }
} }
/** /**
Parse the parameter name and parameter desc from the tag text. Parse the parameter name and parameter desc from the tag text.
@inner @inner
@method parseParamText @method parseParamText
@memberof module:jsdoc/tag @memberof module:jsdoc/tag
@param {string} tagText @param {string} tagText
@returns {Array.<string, string, boolean, boolean>} [pname, pdesc, poptional, pdefault]. @returns {Array.<string, string, boolean, boolean>} [pname, pdesc, poptional, pdefault].
*/ */
function parseParamText(tagText) { function parseParamText(tagText) {
var pname, pdesc, poptional, pdefault; var pname, pdesc, poptional, pdefault;
// like: pname, pname pdesc, or name - pdesc // like: pname, pname pdesc, or name - pdesc
tagText.match(/^(\[[^\]]+\]|\S+)((?:\s*\-\s*|\s+)(\S[\s\S]*))?$/); tagText.match(/^(\[[^\]]+\]|\S+)((?:\s*\-\s*|\s+)(\S[\s\S]*))?$/);
pname = RegExp.$1; pname = RegExp.$1;
pdesc = RegExp.$3; pdesc = RegExp.$3;
if ( /^\[\s*(.+?)\s*\]$/.test(pname) ) { if ( /^\[\s*(.+?)\s*\]$/.test(pname) ) {
pname = RegExp.$1; pname = RegExp.$1;
poptional = true; poptional = true;
if ( /^(.+?)\s*=\s*(.+)$/.test(pname) ) { if ( /^(.+?)\s*=\s*(.+)$/.test(pname) ) {
pname = RegExp.$1; pname = RegExp.$1;
pdefault = RegExp.$2; pdefault = RegExp.$2;
} }
} }
return [pname, pdesc, poptional, pdefault]; return [pname, pdesc, poptional, pdefault];
} }