diff --git a/docs/args/index.mustache b/docs/args/index.mustache index 5d1c2a90..07ae870f 100644 --- a/docs/args/index.mustache +++ b/docs/args/index.mustache @@ -309,7 +309,7 @@ project: "linkNatives": "true", "attributesEmit": "true", "paths": [ - "./lib" + "lib/**" ], "outdir": "./output/api" } diff --git a/lib/utils.js b/lib/utils.js index 328a409e..e5f22b41 100644 --- a/lib/utils.js +++ b/lib/utils.js @@ -6,6 +6,7 @@ 'use strict'; var path = require('path'), + glob = require('glob'), minimatch = require('minimatch'), fs = require('graceful-fs'); @@ -336,119 +337,23 @@ YUI.add('utils', function (Y) { Y.getProjectData = getProjectData; - - /** - * Walks the tree from this dir and returns all the subdirs - * @method getDirs - * @param {String} dir The dir to begin at - * @return {Array} The array of directories.. - */ - var getDirs = function (dir) { - var dirs = fs.readdirSync(dir), - paths = []; - - dirs.forEach(function (d) { - var _dir = path.join(dir, d), - stat = fs.lstatSync(_dir); - - if (stat.isDirectory()) { - if (_dir.indexOf('.') !== 0) { - paths = [].concat(paths, _dir, getDirs(_dir)); - } - } - }); - - return paths; - }; - - Y.getDirs = getDirs; - /** - * Make sure all the paths passed are directories and that they are not in the ignore list. + * globpaths and ignore are both arrays of globs or a globstring. They should resolve to the actual files + * you want yuidoc to parse. * @method validatePaths - * @param {Array} paths The array of paths to validate - * @param {String} [ignore=false] A string to call `.indexOf` on a path to determine if it should be ignored + * @param {Array} globpaths The array of globs to expand and validate + * @param {String} [ignore=false] array of globs to expand and filter paths array by */ - var validatePaths = function (paths, ignore) { - var newpaths = []; - //Shortcut the *, . & ./ shortcuts that shall globbing fixes for us - if (paths === '*' || paths === '.' || paths === './') { - paths = [process.cwd()]; - } - - // Ensure that we always have an array of some kind. - paths = paths || []; - if (!Y.Lang.isArray(paths)) { - paths = [paths]; - } - paths.forEach(function (validatePath) { - var glob = validatePath || ''; - - if (process.platform === 'win32') { - glob = validatePath.replace(/\//g, '\\\\'); - } - - var glob_paths = getDirs('.'), - is_globbed = false; - - glob_paths.forEach(function (dir) { - //Don't scan things in node_modules - if (dir.indexOf('node_modules') > -1) { - return; - } - if (minimatch(dir, glob, { - period: true - })) { - newpaths.push(dir); - is_globbed = true; - } - }); - - if (!is_globbed && (Y.Files.isDirectory(glob))) { - //If minimatch fails, check to see if it's a relative directory - // if it is, add it directly - newpaths.push(glob); - } - }); - - paths = newpaths; - paths.forEach(function (newPath) { - try { - if (!Y.Files.isDirectory(newPath)) { - throw ('Path not a directory: ' + newPath); - } - } catch (e) { - throw new Error(e.message); - } - }); - - if (!paths || !paths.forEach) { - throw ('Paths should be an array of paths'); - } - - if (ignore) { - if (!(ignore instanceof Array)) { - ignore = [ignore]; - } - var p = [], - shouldIgnore = false; - - paths.forEach(function (v) { - shouldIgnore = false; - ignore.forEach(function (i) { - if (!shouldIgnore && v.indexOf(i) !== -1) { - shouldIgnore = true; - } - }); - if (!shouldIgnore) { - p.push(v); - } + var validatePaths = function(globpaths, ignore) { + ignore = [].concat(ignore || []); + return [].concat(globpaths || process.cwd()) + .reduce(function(filepaths, globpath){ return filepaths.concat(glob.sync(globpath)); }, []) + .filter(function(filepath){ + return !ignore.filter(function(ignoreGlob){ return minimatch(filepath, ignoreGlob); }).length; + }) + .filter(function(filepath, i, filepaths){ + return !filepaths.slice(i + 1).filter(function(filepath2){ return filepath === filepath2; }).length; }); - paths = p; - } - - paths = paths.sort(); - return paths; }; Y.validatePaths = validatePaths; diff --git a/lib/yuidoc.js b/lib/yuidoc.js index 3c6cc91a..188eb0e8 100755 --- a/lib/yuidoc.js +++ b/lib/yuidoc.js @@ -86,13 +86,6 @@ YUI.add('yuidoc', function (Y) { * @private */ this.filemap = {}; - /** - * Holder for the list of directories we are processing. - * @property dirmap - * @type Object - * @private - */ - this.dirmap = {}; /** * Internal holder for configuration options. @@ -138,87 +131,30 @@ YUI.add('yuidoc', function (Y) { }, /** - * Walks the paths and parses the directory contents - * @method walk - * @private - */ - walk: function () { - Y.each(this.options.paths, function (dir) { - this.parsedir(dir); - }, this); - }, - - /** - * Walks the passed directory and grabs all the files recursively. - * @method parsedir - * @param {String} dir The directory to parse the contents of. - * @private - */ - parsedir: function (dir) { - if (!Y.Files.isDirectory(dir)) { - throw ('Can not find directory: ' + dir); - } - - var allfiles = fs.readdirSync(dir), - stats, - files = [], - fullpath, self = this; - - if (dir in self.options.excludes) { - return; - } - - allfiles = allfiles.sort(); - - Y.each(allfiles, function (filename) { - if (!(filename in self.options.excludes)) { - fullpath = path.join(dir, filename); - - stats = fs.statSync(fullpath); - - if (stats.isDirectory() && !self.options.norecurse) { - self.parsedir(fullpath); - } else { - files.push(filename); - } - } - }); - - if (!(dir in self.options.excludes)) { - this.parsefiles(dir, files); - } - }, - - /** - * Gathers all the file data and populates the filemap and dirmap hashes. + * Gathers all the file data and populates the filemap and. * @method parsefiles - * @param {String} dir The directory to start from. * @param {Array} files List of files to parse. * @private */ - parsefiles: function (dir, files) { + parsefiles: function (files) { var self = this; files = files.sort(); Y.each(files, function (filename) { var ext = path.extname(filename), - text, - fullpath; + text; if (ext) { if (ext in self.options.extensions) { - fullpath = path.join(dir, filename); - - if (Y.Files.exists(fullpath)) { + if (Y.Files.exists(filename)) { self.filecount++; - text = fs.readFileSync(fullpath, Y.charset); + text = fs.readFileSync(filename, Y.charset); - self.filemap[fullpath] = text.replace(/\r?\n|\r/g, '\n'); - self.dirmap[fullpath] = dir; - self.getSelleck(fullpath); + self.filemap[filename] = text.replace(/\r?\n|\r/g, '\n'); + self.getSelleck(filename); } else { - Y.log('File skipped: ' + fullpath, 'warn', 'yuidoc'); + Y.log('File skipped: ' + filename, 'warn', 'yuidoc'); } } } @@ -390,12 +326,11 @@ YUI.add('yuidoc', function (Y) { this.starttime = new Date().getTime(); this._processConfig(); - this.walk(); + this.parsefiles(this.options.paths); var json = this.writeJSON(new Y.DocParser({ syntaxtype: this.options.syntaxtype, - filemap: this.filemap, - dirmap: this.dirmap + filemap: this.filemap }).parse()); if (this.options.lint) { diff --git a/output/api/classes/CLI.html b/output/api/classes/CLI.html index 834b8357..d85cb22a 100644 --- a/output/api/classes/CLI.html +++ b/output/api/classes/CLI.html @@ -17,7 +17,7 @@

- API Docs for: 0.7.0 + API Docs for: 0.8.0
@@ -91,7 +91,7 @@

CLI Class

- Defined in: lib/cli.js:9 + Defined in: lib/cli.js:10
Module: yuidoc diff --git a/output/api/classes/DocBuilder.html b/output/api/classes/DocBuilder.html index 9bd3325e..5e5e268e 100644 --- a/output/api/classes/DocBuilder.html +++ b/output/api/classes/DocBuilder.html @@ -17,7 +17,7 @@

- API Docs for: 0.7.0 + API Docs for: 0.8.0
@@ -91,7 +91,7 @@

DocBuilder Class

- Defined in: lib/builder.js:12 + Defined in: lib/builder.js:14
Module: yuidoc @@ -299,7 +299,7 @@

_addHelpers

Defined in - lib/builder.js:123 + lib/builder.js:125

@@ -357,7 +357,7 @@

_inlineCode

Defined in - lib/builder.js:773 + lib/builder.js:775

@@ -416,7 +416,7 @@

_mixExternal

Defined in - lib/builder.js:325 + lib/builder.js:327

@@ -458,7 +458,7 @@

_parseCode

Defined in - lib/builder.js:760 + lib/builder.js:762

@@ -528,7 +528,7 @@

_parseCrossLink

Defined in - lib/builder.js:165 + lib/builder.js:167

@@ -609,7 +609,7 @@

addFoundAt

Defined in - lib/builder.js:631 + lib/builder.js:633

@@ -675,7 +675,7 @@

augmentData

Defined in - lib/builder.js:647 + lib/builder.js:649

@@ -739,7 +739,7 @@

compile

Defined in - lib/builder.js:1618 + lib/builder.js:1650

@@ -796,7 +796,7 @@

filterFileName

Defined in - lib/builder.js:1605 + lib/builder.js:1637

@@ -858,7 +858,7 @@

getProjectMeta

Defined in - lib/builder.js:461 + lib/builder.js:463

@@ -910,7 +910,7 @@

hasProperty

Defined in - lib/builder.js:1026 + lib/builder.js:1048

@@ -983,7 +983,7 @@

makeDirs

Defined in - lib/builder.js:707 + lib/builder.js:709

@@ -1041,7 +1041,7 @@

markdown

Defined in - lib/builder.js:140 + lib/builder.js:142

@@ -1110,7 +1110,7 @@

mergeExtends

Defined in - lib/builder.js:1050 + lib/builder.js:1072

@@ -1187,7 +1187,7 @@

mixExternal

Defined in - lib/builder.js:373 + lib/builder.js:375

@@ -1235,7 +1235,7 @@

nameSort

- Number + Number @@ -1247,7 +1247,7 @@

nameSort

Defined in - lib/builder.js:1432 + lib/builder.js:1459

@@ -1292,7 +1292,7 @@

Parameters:

Returns:

- Number: + Number:

1, -1 or 0 for sorting.

@@ -1325,7 +1325,7 @@

NATIVES_LINKER

Defined in - lib/builder.js:311 + lib/builder.js:313

@@ -1391,7 +1391,7 @@

populateClasses

Defined in - lib/builder.js:504 + lib/builder.js:506

@@ -1457,7 +1457,7 @@

populateFiles

Defined in - lib/builder.js:574 + lib/builder.js:576

@@ -1523,7 +1523,7 @@

populateModules

Defined in - lib/builder.js:528 + lib/builder.js:530

@@ -1598,7 +1598,7 @@

render

Defined in - lib/builder.js:792 + lib/builder.js:794

@@ -1720,7 +1720,7 @@

renderAPIMeta

Defined in - lib/builder.js:1572 + lib/builder.js:1604

@@ -1786,7 +1786,7 @@

renderClass

Defined in - lib/builder.js:1102 + lib/builder.js:1124

@@ -1862,7 +1862,7 @@

renderFile

Defined in - lib/builder.js:1505 + lib/builder.js:1532

@@ -1938,7 +1938,7 @@

renderIndex

Defined in - lib/builder.js:848 + lib/builder.js:850

@@ -2014,7 +2014,7 @@

renderModule

Defined in - lib/builder.js:899 + lib/builder.js:911

@@ -2091,7 +2091,7 @@

writeAPIMeta

Defined in - lib/builder.js:1559 + lib/builder.js:1591

@@ -2145,7 +2145,7 @@

writeClasses

Defined in - lib/builder.js:1389 + lib/builder.js:1416

@@ -2221,7 +2221,7 @@

writeFiles

Defined in - lib/builder.js:1455 + lib/builder.js:1482

@@ -2297,7 +2297,7 @@

writeIndex

Defined in - lib/builder.js:873 + lib/builder.js:885

@@ -2373,7 +2373,7 @@

writeModules

Defined in - lib/builder.js:983 + lib/builder.js:1005

@@ -2435,7 +2435,7 @@

Properties

_mergeCounter

- Number + Number private @@ -2445,7 +2445,7 @@

_mergeCounter

Defined in - lib/builder.js:1043 + lib/builder.js:1065

@@ -2471,7 +2471,7 @@

_meta

Defined in - lib/builder.js:454 + lib/builder.js:456

@@ -2487,7 +2487,7 @@

_meta

files

- Number + Number @@ -2496,7 +2496,7 @@

files

Defined in - lib/builder.js:448 + lib/builder.js:450

@@ -2521,7 +2521,7 @@

NATIVES

Defined in - lib/builder.js:272 + lib/builder.js:274

diff --git a/output/api/classes/DocParser.html b/output/api/classes/DocParser.html index 04ca6cc0..48b5d9ec 100644 --- a/output/api/classes/DocParser.html +++ b/output/api/classes/DocParser.html @@ -17,7 +17,7 @@

- API Docs for: 0.7.0 + API Docs for: 0.8.0
@@ -90,11 +90,11 @@

DocParser Class

- Extends Base + Extends Base
- Defined in: lib/docparser.js:749 + Defined in: lib/docparser.js:750
Module: yuidoc @@ -132,7 +132,7 @@

DocParser

Defined in - lib/docparser.js:749 + lib/docparser.js:750

@@ -648,8 +648,8 @@

_addAttrs

Inherited from - AttributeCore: - attribute/js/AttributeCore.js:854 + AttributeCore: + attribute/js/AttributeCore.js:854

@@ -732,8 +732,8 @@

_addLazyAttr

Inherited from - AttributeCore: - attribute/js/AttributeCore.js:360 + AttributeCore: + attribute/js/AttributeCore.js:360

@@ -800,8 +800,8 @@

_addOutOfOrder

Inherited from - AttributeCore: - attribute/js/AttributeCore.js:527 + AttributeCore: + attribute/js/AttributeCore.js:527

@@ -881,8 +881,8 @@

_aggregateAttrs

Inherited from - BaseCore: - base/js/BaseCore.js:618 + BaseCore: + base/js/BaseCore.js:618

@@ -942,8 +942,8 @@

_attrCfgHash

Inherited from - BaseCore: - base/js/BaseCore.js:581 + BaseCore: + base/js/BaseCore.js:581

@@ -974,8 +974,8 @@

_baseDestroy

Inherited from - BaseCore: - base/js/BaseCore.js:364 + BaseCore: + base/js/BaseCore.js:364

@@ -1005,8 +1005,8 @@

_baseInit

Inherited from - BaseCore: - base/js/BaseCore.js:336 + BaseCore: + base/js/BaseCore.js:336

@@ -1042,8 +1042,8 @@

_cloneDefaultValue

Inherited from - BaseCore: - base/js/BaseCore.js:592 + BaseCore: + base/js/BaseCore.js:592

@@ -1099,8 +1099,8 @@

_defAttrChangeFn

Inherited from - AttributeObservable: - attribute/js/AttributeObservable.js:185 + AttributeObservable: + attribute/js/AttributeObservable.js:185

@@ -1117,7 +1117,7 @@

Parameters:

  • e - EventFacade + EventFacade
    @@ -1162,8 +1162,8 @@

    _defDestroyFn

    Inherited from - BaseObservable: - base/js/BaseObservable.js:202 + BaseObservable: + base/js/BaseObservable.js:202

    @@ -1180,7 +1180,7 @@

    Parameters:

    • e - EventFacade + EventFacade
      @@ -1215,8 +1215,8 @@

      _defInitFn

      Inherited from - BaseObservable: - base/js/BaseObservable.js:190 + BaseObservable: + base/js/BaseObservable.js:190

      @@ -1233,7 +1233,7 @@

      Parameters:

      • e - EventFacade + EventFacade
        @@ -1263,8 +1263,8 @@

        _destroyHierarchy

        Inherited from - BaseCore: - base/js/BaseCore.js:782 + BaseCore: + base/js/BaseCore.js:782

        @@ -1307,8 +1307,8 @@

        _filterAdHocAttrs

        Inherited from - BaseCore: - base/js/BaseCore.js:470 + BaseCore: + base/js/BaseCore.js:470

        @@ -1396,8 +1396,8 @@

        _fireAttrChange

        Inherited from - AttributeObservable: - attribute/js/AttributeObservable.js:120 + AttributeObservable: + attribute/js/AttributeObservable.js:120

        @@ -1505,8 +1505,8 @@

        _getAttr

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:564 + AttributeCore: + attribute/js/AttributeCore.js:564

        @@ -1572,8 +1572,8 @@

        _getAttrCfg

        Inherited from - AttributeExtras: - attribute/js/AttributeExtras.js:125 + AttributeExtras: + attribute/js/AttributeExtras.js:125

        @@ -1632,8 +1632,8 @@

        _getAttrCfgs

        Inherited from - BaseCore: - base/js/BaseCore.js:394 + BaseCore: + base/js/BaseCore.js:394

        @@ -1689,8 +1689,8 @@

        _getAttrInitVal

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:963 + AttributeCore: + attribute/js/AttributeCore.js:963

        @@ -1776,8 +1776,8 @@

        _getAttrs

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:792 + AttributeCore: + attribute/js/AttributeCore.js:792

        @@ -1835,8 +1835,8 @@

        _getClasses

        Inherited from - BaseCore: - base/js/BaseCore.js:378 + BaseCore: + base/js/BaseCore.js:378

        @@ -1885,8 +1885,8 @@

        _getFullType

        Inherited from - EventTarget: - event-custom/js/event-target.js:564 + EventTarget: + event-custom/js/event-target.js:564

        @@ -1954,8 +1954,8 @@

        _getInstanceAttrCfgs

        Inherited from - BaseCore: - base/js/BaseCore.js:411 + BaseCore: + base/js/BaseCore.js:411

        @@ -2025,8 +2025,8 @@

        _getStateVal

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:618 + AttributeCore: + attribute/js/AttributeCore.js:618

        @@ -2093,8 +2093,8 @@

        _getType

        Inherited from - EventTarget: - event-custom/js/event-target.js:36 + EventTarget: + event-custom/js/event-target.js:36

        @@ -2135,8 +2135,8 @@

        _hasPotentialSubscribers

        Inherited from - EventTarget: - event-custom/js/event-facade.js:643 + EventTarget: + event-custom/js/event-facade.js:643

        @@ -2202,8 +2202,8 @@

        _initAttrHost

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:140 + AttributeCore: + attribute/js/AttributeCore.js:140

        @@ -2272,11 +2272,11 @@

        _initAttribute

        Inherited from - + BaseObservable but overwritten in - base/js/BaseCore.js:309 + base/js/BaseCore.js:309

        @@ -2318,8 +2318,8 @@

        _initAttrs

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:1029 + AttributeCore: + attribute/js/AttributeCore.js:1029

        @@ -2394,8 +2394,8 @@

        _initBase

        Inherited from - BaseCore: - base/js/BaseCore.js:274 + BaseCore: + base/js/BaseCore.js:274

        @@ -2447,8 +2447,8 @@

        _initHierarchy

        Inherited from - BaseCore: - base/js/BaseCore.js:702 + BaseCore: + base/js/BaseCore.js:702

        @@ -2497,8 +2497,8 @@

        _initHierarchyData

        Inherited from - BaseCore: - base/js/BaseCore.js:500 + BaseCore: + base/js/BaseCore.js:500

        @@ -2539,8 +2539,8 @@

        _isLazyAttr

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:347 + AttributeCore: + attribute/js/AttributeCore.js:347

        @@ -2607,8 +2607,8 @@

        _monitor

        Inherited from - EventTarget: - event-custom/js/event-target.js:636 + EventTarget: + event-custom/js/event-target.js:636

        @@ -2642,7 +2642,7 @@

        Parameters:

      • eventType - String | CustomEvent + String | CustomEvent
        @@ -2691,8 +2691,8 @@

        _normAttrVals

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:915 + AttributeCore: + attribute/js/AttributeCore.js:915

        @@ -2749,8 +2749,8 @@

        _parseType

        Inherited from - EventTarget: - event-custom/js/event-target.js:52 + EventTarget: + event-custom/js/event-target.js:52

        @@ -2788,8 +2788,8 @@

        _preInitEventCfg

        Inherited from - BaseObservable: - base/js/BaseObservable.js:110 + BaseObservable: + base/js/BaseObservable.js:110

        @@ -2848,8 +2848,8 @@

        _protectAttrs

        - CustomEvent + CustomEvent @@ -2922,8 +2922,8 @@

        _publish

        Inherited from - EventTarget: - event-custom/js/event-target.js:588 + EventTarget: + event-custom/js/event-target.js:588

        @@ -2977,7 +2977,7 @@

        Parameters:

        Returns:

        - CustomEvent: + CustomEvent: The published event. If called without etOpts or ceOpts, this will be the default CustomEvent instance, and can be configured independently.
        @@ -3010,7 +3010,7 @@

        _resolveFor

        Defined in - lib/docparser.js:1033 + lib/docparser.js:1034

        @@ -3083,11 +3083,11 @@

        _set

        Inherited from - + AttributeObservable but overwritten in - attribute/js/AttributeCore.js:405 + attribute/js/AttributeCore.js:405

        @@ -3181,8 +3181,8 @@

        _setAttr

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:421 + AttributeCore: + attribute/js/AttributeCore.js:421

        @@ -3283,11 +3283,11 @@

        _setAttrs

        Inherited from - + AttributeObservable but overwritten in - attribute/js/AttributeCore.js:760 + attribute/js/AttributeCore.js:760

        @@ -3376,8 +3376,8 @@

        _setAttrVal

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:658 + AttributeCore: + attribute/js/AttributeCore.js:658

        @@ -3494,8 +3494,8 @@

        _setStateVal

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:640 + AttributeCore: + attribute/js/AttributeCore.js:640

        @@ -3567,8 +3567,8 @@

        addAttr

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:157 + AttributeCore: + attribute/js/AttributeCore.js:157

        @@ -3741,8 +3741,8 @@

        addAttrs

        Inherited from - AttributeCore: - attribute/js/AttributeCore.js:823 + AttributeCore: + attribute/js/AttributeCore.js:823

        @@ -3830,8 +3830,8 @@

        addTarget

        Inherited from - EventTarget: - event-custom/js/event-facade.js:496 + EventTarget: + event-custom/js/event-facade.js:496

        @@ -3854,7 +3854,7 @@

        Parameters:

        • o - EventTarget + EventTarget
          @@ -3889,7 +3889,7 @@

          after

          - EventHandle + EventHandle @@ -3900,8 +3900,8 @@

          after

          Inherited from - EventTarget: - event-custom/js/event-target.js:812 + EventTarget: + event-custom/js/event-target.js:812

          @@ -3968,7 +3968,7 @@

          Parameters:

          Returns:

          - EventHandle: + EventHandle: A subscription handle capable of detaching the subscription
          @@ -3999,8 +3999,8 @@

          attrAdded

          Inherited from - AttributeCore: - attribute/js/AttributeCore.js:319 + AttributeCore: + attribute/js/AttributeCore.js:319

          @@ -4057,8 +4057,8 @@

          before

          Inherited from - EventTarget: - event-custom/js/event-target.js:849 + EventTarget: + event-custom/js/event-target.js:849

          @@ -4112,8 +4112,8 @@

          bubble

          Inherited from - EventTarget: - event-custom/js/event-facade.js:554 + EventTarget: + event-custom/js/event-facade.js:554

          @@ -4130,7 +4130,7 @@

          Parameters:

          • evt - CustomEvent + CustomEvent
            @@ -4158,7 +4158,7 @@

            destroy

            () - BaseCore + BaseCore @@ -4170,11 +4170,11 @@

            destroy

            Inherited from - + BaseObservable but overwritten in - base/js/BaseCore.js:352 + base/js/BaseCore.js:352

            @@ -4190,7 +4190,7 @@

            destroy

            Returns:

            - BaseCore: + BaseCore: A reference to this object
            @@ -4215,7 +4215,7 @@

            detach

            - EventTarget + EventTarget @@ -4226,8 +4226,8 @@

            detach

            Inherited from - EventTarget: - event-custom/js/event-target.js:356 + EventTarget: + event-custom/js/event-target.js:356

            @@ -4287,7 +4287,7 @@

            Parameters:

            Returns:

            - EventTarget: + EventTarget: the host
            @@ -4314,8 +4314,8 @@

            detachAll

            Inherited from - EventTarget: - event-custom/js/event-target.js:479 + EventTarget: + event-custom/js/event-target.js:479

            @@ -4375,7 +4375,7 @@

            extract

            Defined in - lib/docparser.js:1206 + lib/docparser.js:1203

            @@ -4460,8 +4460,8 @@

            fire

            Inherited from - EventTarget: - event-custom/js/event-target.js:673 + EventTarget: + event-custom/js/event-target.js:673

            @@ -4553,8 +4553,8 @@

            get

            Inherited from - AttributeCore: - attribute/js/AttributeCore.js:331 + AttributeCore: + attribute/js/AttributeCore.js:331

            @@ -4619,8 +4619,8 @@

            getAttrs

            - CustomEvent + CustomEvent @@ -4686,8 +4686,8 @@

            getEvent

            Inherited from - EventTarget: - event-custom/js/event-target.js:793 + EventTarget: + event-custom/js/event-target.js:793

            @@ -4730,7 +4730,7 @@

            Parameters:

            Returns:

            - CustomEvent: + CustomEvent: the custom event or null
            @@ -4754,8 +4754,8 @@

            getTargets

            Inherited from - EventTarget: - event-custom/js/event-facade.js:523 + EventTarget: + event-custom/js/event-facade.js:523

            @@ -4804,7 +4804,7 @@

            handlecomment

            Defined in - lib/docparser.js:1128 + lib/docparser.js:1125

            @@ -4887,7 +4887,7 @@

            implodeString

            Defined in - lib/docparser.js:38 + lib/docparser.js:40

            @@ -4954,7 +4954,7 @@

            implodeString

            Defined in - lib/docparser.js:48 + lib/docparser.js:50

            @@ -5008,7 +5008,7 @@

            init

            - BaseCore + BaseCore @@ -5020,11 +5020,11 @@

            init

            Inherited from - + BaseObservable but overwritten in - base/js/BaseCore.js:319 + base/js/BaseCore.js:319

            @@ -5057,7 +5057,7 @@

            Parameters:

            Returns:

            - BaseCore: + BaseCore: A reference to this object
            @@ -5087,8 +5087,8 @@

            modifyAttr

            - EventHandle + EventHandle @@ -5179,8 +5179,8 @@

            on

            Inherited from - EventTarget: - event-custom/js/event-target.js:188 + EventTarget: + event-custom/js/event-target.js:188

            @@ -5272,7 +5272,7 @@

            Parameters:

            Returns:

            - EventHandle: + EventHandle: A subscription handle capable of detaching that subscription
            @@ -5301,7 +5301,7 @@

            once

            - EventHandle + EventHandle @@ -5312,8 +5312,8 @@

            once

            Inherited from - EventTarget: - event-custom/js/event-target.js:124 + EventTarget: + event-custom/js/event-target.js:124

            @@ -5379,7 +5379,7 @@

            Parameters:

            Returns:

            - EventHandle: + EventHandle: A subscription handle capable of detaching the subscription
            @@ -5408,7 +5408,7 @@

            onceAfter

            - EventHandle + EventHandle @@ -5419,8 +5419,8 @@

            onceAfter

            Inherited from - EventTarget: - event-custom/js/event-target.js:146 + EventTarget: + event-custom/js/event-target.js:146

            @@ -5486,7 +5486,7 @@

            Parameters:

            Returns:

            - EventHandle: + EventHandle: A subscription handle capable of detaching that subscription
            @@ -5521,7 +5521,7 @@

            parse

            Defined in - lib/docparser.js:1448 + lib/docparser.js:1445

            @@ -5601,8 +5601,8 @@

            parseType

            Inherited from - EventTarget: - event-custom/js/event-target.js:168 + EventTarget: + event-custom/js/event-target.js:168

            @@ -5682,7 +5682,7 @@

            processblock

            Defined in - lib/docparser.js:1261 + lib/docparser.js:1258

            @@ -5730,7 +5730,7 @@

            publish

            - CustomEvent + CustomEvent @@ -5741,8 +5741,8 @@

            publish

            Inherited from - EventTarget: - event-custom/js/event-target.js:503 + EventTarget: + event-custom/js/event-target.js:503

            @@ -5959,7 +5959,7 @@

            Parameters:

            Returns:

            - CustomEvent: + CustomEvent: the custom event
            @@ -5986,8 +5986,8 @@

            removeAttr

            Inherited from - AttributeExtras: - attribute/js/AttributeExtras.js:90 + AttributeExtras: + attribute/js/AttributeExtras.js:90

            @@ -6039,8 +6039,8 @@

            removeTarget

            Inherited from - EventTarget: - event-custom/js/event-facade.js:533 + EventTarget: + event-custom/js/event-facade.js:533

            @@ -6057,7 +6057,7 @@

            Parameters:

            • o - EventTarget + EventTarget
              @@ -6095,8 +6095,8 @@

              reset

              Inherited from - AttributeExtras: - attribute/js/AttributeExtras.js:100 + AttributeExtras: + attribute/js/AttributeExtras.js:100

              @@ -6166,11 +6166,11 @@

              set

              Inherited from - + AttributeObservable but overwritten in - attribute/js/AttributeCore.js:388 + attribute/js/AttributeCore.js:388

              @@ -6259,11 +6259,11 @@

              setAttrs

              Inherited from - + AttributeObservable but overwritten in - attribute/js/AttributeCore.js:747 + attribute/js/AttributeCore.js:747

              @@ -6338,7 +6338,7 @@

              stringlog

              Defined in - lib/docparser.js:11 + lib/docparser.js:13

              @@ -6396,8 +6396,8 @@

              subscribe

              Inherited from - EventTarget: - event-custom/js/event-target.js:346 + EventTarget: + event-custom/js/event-target.js:346

              @@ -6430,8 +6430,8 @@

              toString

              Inherited from - BaseCore: - base/js/BaseCore.js:815 + BaseCore: + base/js/BaseCore.js:815

              @@ -6479,7 +6479,7 @@

              transform

              Defined in - lib/docparser.js:1334 + lib/docparser.js:1331

              @@ -6548,7 +6548,7 @@

              unindent

              Defined in - lib/docparser.js:1107 + lib/docparser.js:1104

              @@ -6608,8 +6608,8 @@

              unsubscribe

              Inherited from - EventTarget: - event-custom/js/event-target.js:469 + EventTarget: + event-custom/js/event-target.js:469

              @@ -6646,8 +6646,8 @@

              unsubscribeAll

              Inherited from - EventTarget: - event-custom/js/event-target.js:490 + EventTarget: + event-custom/js/event-target.js:490

              @@ -6697,8 +6697,8 @@

              _allowAdHocAttrs

              Inherited from - BaseCore: - base/js/BaseCore.js:155 + BaseCore: + base/js/BaseCore.js:155

              @@ -6729,7 +6729,7 @@

              CORRECTIONS

              Defined in - lib/docparser.js:186 + lib/docparser.js:188

              @@ -6755,7 +6755,7 @@

              DIGESTERS

              Defined in - lib/docparser.js:209 + lib/docparser.js:211

              @@ -6784,7 +6784,7 @@

              IGNORE_TAGLIST

              Defined in - lib/docparser.js:174 + lib/docparser.js:176

              @@ -6810,8 +6810,8 @@

              name

              Inherited from - BaseCore: - base/js/BaseCore.js:297 + BaseCore: + base/js/BaseCore.js:297

              Deprecated: Use this.constructor.NAME

              @@ -6837,7 +6837,7 @@

              TAGLIST

              Defined in - lib/docparser.js:94 + lib/docparser.js:96

              @@ -6873,7 +6873,7 @@

              currentclass

              Defined in - lib/docparser.js:993 + lib/docparser.js:994

              @@ -6902,7 +6902,7 @@

              Parameters:

              • e - EventFacade + EventFacade
                An Event Facade object with the following @@ -6952,7 +6952,7 @@

                currentfile

                Defined in - lib/docparser.js:837 + lib/docparser.js:838

                @@ -6981,7 +6981,7 @@

                Parameters:

                • e - EventFacade + EventFacade
                  An Event Facade object with the following @@ -7031,7 +7031,7 @@

                  currentmodule

                  Defined in - lib/docparser.js:894 + lib/docparser.js:895

                  @@ -7060,7 +7060,7 @@

                  Parameters:

                  • e - EventFacade + EventFacade
                    An Event Facade object with the following @@ -7110,7 +7110,7 @@

                    currentsubmodule

                    Defined in - lib/docparser.js:953 + lib/docparser.js:954

                    @@ -7139,7 +7139,7 @@

                    Parameters:

                    • e - EventFacade + EventFacade
                      An Event Facade object with the following @@ -7189,8 +7189,8 @@

                      destroyed

                      Inherited from - BaseCore: - base/js/BaseCore.js:212 + BaseCore: + base/js/BaseCore.js:212

                      @@ -7220,7 +7220,7 @@

                      Parameters:

                      • e - EventFacade + EventFacade
                        An Event Facade object with the following @@ -7270,7 +7270,7 @@

                        digesters

                        Defined in - lib/docparser.js:777 + lib/docparser.js:778

                        @@ -7309,7 +7309,7 @@

                        Parameters:

                        • e - EventFacade + EventFacade
                          An Event Facade object with the following @@ -7359,7 +7359,7 @@

                          dirmap

                          Defined in - lib/docparser.js:827 + lib/docparser.js:828

                          @@ -7390,7 +7390,7 @@

                          Parameters:

                          • e - EventFacade + EventFacade
                            An Event Facade object with the following @@ -7440,7 +7440,7 @@

                            emitters

                            Defined in - lib/docparser.js:799 + lib/docparser.js:800

                            @@ -7470,7 +7470,7 @@

                            Parameters:

                            • e - EventFacade + EventFacade
                              An Event Facade object with the following @@ -7520,7 +7520,7 @@

                              filemap

                              Defined in - lib/docparser.js:819 + lib/docparser.js:820

                              @@ -7549,7 +7549,7 @@

                              Parameters:

                              • e - EventFacade + EventFacade
                                An Event Facade object with the following @@ -7599,8 +7599,8 @@

                                initialized

                                Inherited from - BaseCore: - base/js/BaseCore.js:198 + BaseCore: + base/js/BaseCore.js:198

                                @@ -7630,7 +7630,7 @@

                                Parameters:

                                • e - EventFacade + EventFacade
                                  An Event Facade object with the following @@ -7680,7 +7680,7 @@

                                  mainmodule

                                  Defined in - lib/docparser.js:858 + lib/docparser.js:859

                                  @@ -7709,7 +7709,7 @@

                                  Parameters:

                                  • e - EventFacade + EventFacade
                                    An Event Facade object with the following @@ -7759,7 +7759,7 @@

                                    syntaxtype

                                    Defined in - lib/docparser.js:810 + lib/docparser.js:811

                                    @@ -7788,7 +7788,7 @@

                                    Parameters:

                                    • e - EventFacade + EventFacade
                                      An Event Facade object with the following @@ -7838,8 +7838,8 @@

                                      destroy

                                      Inherited from - BaseObservable: - base/js/BaseObservable.js:163 + BaseObservable: + base/js/BaseObservable.js:163

                                      @@ -7865,7 +7865,7 @@

                                      Event Payload:

                                      • e - EventFacade + EventFacade
                                        @@ -7888,8 +7888,8 @@

                                        init

                                        Inherited from - BaseObservable: - base/js/BaseObservable.js:62 + BaseObservable: + base/js/BaseObservable.js:62

                                        @@ -7914,7 +7914,7 @@

                                        Event Payload:

                                        • e - EventFacade + EventFacade
                                          diff --git a/output/api/classes/DocView.html b/output/api/classes/DocView.html index 7d2ded15..8f0da498 100644 --- a/output/api/classes/DocView.html +++ b/output/api/classes/DocView.html @@ -17,7 +17,7 @@

                                          - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                        @@ -91,7 +91,7 @@

                                        DocView Class

                                        - Defined in: lib/docview.js:14 + Defined in: lib/docview.js:16
                                        Module: yuidoc @@ -100,7 +100,7 @@

                                        DocView Class

                                        -

                                        View class borrowed from Selleck
                                        +

                                        View class borrowed from Selleck The view class is a handlebars template helper.

                                        @@ -131,7 +131,7 @@

                                        DocView

                                        Defined in - lib/docview.js:14 + lib/docview.js:16

                                        @@ -224,7 +224,7 @@

                                        htmlTitle

                                        Defined in - lib/docview.js:28 + lib/docview.js:30

                                        @@ -255,7 +255,7 @@

                                        title

                                        Defined in - lib/docview.js:47 + lib/docview.js:49

                                        diff --git a/output/api/classes/Files.html b/output/api/classes/Files.html index a0cd6558..edaf4f35 100644 --- a/output/api/classes/Files.html +++ b/output/api/classes/Files.html @@ -17,7 +17,7 @@

                                        - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                        @@ -91,7 +91,7 @@

                                        Files Class

                                        - Defined in: lib/files.js:8 + Defined in: lib/files.js:10
                                        Module: yuidoc @@ -208,7 +208,7 @@

                                        copyAssets

                                        Defined in - lib/files.js:368 + lib/files.js:369

                                        @@ -226,7 +226,7 @@

                                        Parameters:

                                        • from - Path + Path
                                          @@ -237,7 +237,7 @@

                                          Parameters:

                                        • dest - Path + Path
                                          @@ -304,7 +304,7 @@

                                          copyDirectory

                                          Defined in - lib/files.js:37 + lib/files.js:39

                                          @@ -322,7 +322,7 @@

                                          Parameters:

                                          • source - Path + Path
                                            @@ -333,7 +333,7 @@

                                            Parameters:

                                          • dest - Path + Path
                                            @@ -402,7 +402,7 @@

                                            copyFile

                                            Defined in - lib/files.js:127 + lib/files.js:128

                                            @@ -420,7 +420,7 @@

                                            Parameters:

                                            • source - Path + Path
                                              @@ -431,7 +431,7 @@

                                              Parameters:

                                            • dest - Path + Path
                                              @@ -512,7 +512,7 @@

                                              copyPath

                                              Defined in - lib/files.js:180 + lib/files.js:181

                                              @@ -621,7 +621,7 @@

                                              deletePath

                                              Defined in - lib/files.js:226 + lib/files.js:227

                                              @@ -680,7 +680,7 @@

                                              getJSON

                                              Defined in - lib/files.js:416 + lib/files.js:417

                                              @@ -698,7 +698,7 @@

                                              Parameters:

                                              • filename - Path + Path
                                                @@ -749,7 +749,7 @@

                                                isDirectory

                                                Defined in - lib/files.js:251 + lib/files.js:252

                                                @@ -767,7 +767,7 @@

                                                Parameters:

                                                • path - Path + Path
                                                  @@ -830,7 +830,7 @@

                                                  isFile

                                                  Defined in - lib/files.js:282 + lib/files.js:283

                                                  @@ -848,7 +848,7 @@

                                                  Parameters:

                                                  • path - Path + Path
                                                    @@ -908,7 +908,7 @@

                                                    isSymbolicLink

                                                    Defined in - lib/files.js:311 + lib/files.js:312

                                                    @@ -926,7 +926,7 @@

                                                    Parameters:

                                                    • path - Path + Path
                                                      @@ -974,7 +974,7 @@

                                                      lstatSync

                                                      Defined in - lib/files.js:325 + lib/files.js:326

                                                      @@ -1041,7 +1041,7 @@

                                                      statSync

                                                      Defined in - lib/files.js:347 + lib/files.js:348

                                                      @@ -1111,7 +1111,7 @@

                                                      writeFile

                                                      Defined in - lib/files.js:431 + lib/files.js:432

                                                      @@ -1129,7 +1129,7 @@

                                                      Parameters:

                                                      • file - Path + Path
                                                        diff --git a/output/api/classes/Help.html b/output/api/classes/Help.html index b832c3df..ad547b5d 100644 --- a/output/api/classes/Help.html +++ b/output/api/classes/Help.html @@ -17,7 +17,7 @@

                                                        - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                      @@ -91,7 +91,7 @@

                                                      Help Class

                                                      - Defined in: lib/help.js:8 + Defined in: lib/help.js:10
                                                      Module: yuidoc @@ -167,7 +167,7 @@

                                                      renderHelp

                                                      Defined in - lib/help.js:61 + lib/help.js:63

                                                      @@ -207,7 +207,7 @@

                                                      showHelp

                                                      Defined in - lib/help.js:71 + lib/help.js:73

                                                      @@ -240,7 +240,7 @@

                                                      help

                                                      Defined in - lib/help.js:14 + lib/help.js:16

                                                      diff --git a/output/api/classes/Main.html b/output/api/classes/Main.html index 30ef7662..6f0237a8 100644 --- a/output/api/classes/Main.html +++ b/output/api/classes/Main.html @@ -17,7 +17,7 @@

                                                      - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                      @@ -91,7 +91,7 @@

                                                      Main Class

                                                      - Defined in: lib/index.js:7 + Defined in: lib/index.js:8
                                                      Module: yuidoc @@ -101,7 +101,7 @@

                                                      Main Class

                                                      Module creates the YUI instance with the required modules, uses them and exports the Y to be used -by the CLI class or by extenders: require('yuidocjs');
                                                      +by the CLI class or by extenders: require('yuidocjs'); You can use it like this:

                                                      var options = {
                                                           paths: [ './lib' ],
                                                      diff --git a/output/api/classes/Options.html b/output/api/classes/Options.html
                                                      index 5175702f..4854a48e 100644
                                                      --- a/output/api/classes/Options.html
                                                      +++ b/output/api/classes/Options.html
                                                      @@ -17,7 +17,7 @@
                                                                       

                                                      - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                      @@ -91,7 +91,7 @@

                                                      Options Class

                                                      - Defined in: lib/options.js:10 + Defined in: lib/options.js:12
                                                      Module: yuidoc @@ -158,7 +158,7 @@

                                                      Options

                                                      Defined in - lib/options.js:16 + lib/options.js:18

                                                      diff --git a/output/api/classes/Server.html b/output/api/classes/Server.html index afd64256..a47fc80a 100644 --- a/output/api/classes/Server.html +++ b/output/api/classes/Server.html @@ -17,7 +17,7 @@

                                                      - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                      @@ -91,7 +91,7 @@

                                                      Server Class

                                                      - Defined in: lib/server.js:9 + Defined in: lib/server.js:13
                                                      Module: yuidoc @@ -197,7 +197,7 @@

                                                      clazz

                                                      Defined in - lib/server.js:136 + lib/server.js:140

                                                      @@ -265,7 +265,7 @@

                                                      files

                                                      Defined in - lib/server.js:110 + lib/server.js:114

                                                      @@ -333,7 +333,7 @@

                                                      home

                                                      Defined in - lib/server.js:168 + lib/server.js:172

                                                      @@ -392,7 +392,7 @@

                                                      init

                                                      Defined in - lib/server.js:180 + lib/server.js:184

                                                      @@ -432,7 +432,7 @@

                                                      modules

                                                      Defined in - lib/server.js:152 + lib/server.js:156

                                                      @@ -503,7 +503,7 @@

                                                      parse

                                                      Defined in - lib/server.js:22 + lib/server.js:26

                                                      @@ -573,7 +573,7 @@

                                                      routes

                                                      Defined in - lib/server.js:40 + lib/server.js:44

                                                      @@ -610,7 +610,7 @@

                                                      start

                                                      Defined in - lib/server.js:198 + lib/server.js:200

                                                      @@ -660,7 +660,7 @@

                                                      _externalData

                                                      Defined in - lib/server.js:15 + lib/server.js:19

                                                      diff --git a/output/api/classes/Utils.html b/output/api/classes/Utils.html index 4fbe5bda..941fdb38 100644 --- a/output/api/classes/Utils.html +++ b/output/api/classes/Utils.html @@ -17,7 +17,7 @@

                                                      - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                      @@ -91,7 +91,7 @@

                                                      Utils Class

                                                      - Defined in: lib/utils.js:10 + Defined in: lib/utils.js:13
                                                      Module: yuidoc @@ -127,10 +127,6 @@

                                                      Methods

                                                    • fixType -
                                                    • -
                                                    • - getDirs -
                                                    • getLayouts @@ -202,7 +198,7 @@

                                                      escapeHTML

                                                      Defined in - lib/utils.js:30 + lib/utils.js:33

                                                      @@ -268,7 +264,7 @@

                                                      fixType

                                                      Defined in - lib/utils.js:453 + lib/utils.js:361

                                                      @@ -309,72 +305,6 @@

                                                      Returns:

                                                      -
                                                      -
                                                      -

                                                      getDirs

                                                      - -
                                                      - (
                                                        -
                                                      • - dir -
                                                      • -
                                                      ) -
                                                      - - - Array - - - - - - - - -
                                                      -

                                                      - Defined in - lib/utils.js:339 -

                                                      - - - -
                                                      - -
                                                      -

                                                      Walks the tree from this dir and returns all the subdirs

                                                      - -
                                                      - -
                                                      -

                                                      Parameters:

                                                      - -
                                                        -
                                                      • - dir - String - - -
                                                        -

                                                        The dir to begin at

                                                        - -
                                                        - -
                                                      • -
                                                      -
                                                      - -
                                                      -

                                                      Returns:

                                                      - -
                                                      - Array: -

                                                      The array of directories..

                                                      - -
                                                      -
                                                      - -

                                                      getLayouts

                                                      @@ -400,7 +330,7 @@

                                                      getLayouts

                                                      Defined in - lib/utils.js:64 + lib/utils.js:67

                                                      @@ -467,7 +397,7 @@

                                                      getPage

                                                      Defined in - lib/utils.js:77 + lib/utils.js:80

                                                      @@ -533,7 +463,7 @@

                                                      getPages

                                                      Defined in - lib/utils.js:92 + lib/utils.js:95

                                                      @@ -601,7 +531,7 @@

                                                      getPartials

                                                      Defined in - lib/utils.js:125 + lib/utils.js:128

                                                      @@ -650,7 +580,7 @@

                                                      getProjectData

                                                      (
                                                      • - [dir=process.cwd()] + [directory=process.cwd()]
                                                      )
                                                      @@ -665,7 +595,7 @@

                                                      getProjectData

                                                      Defined in - lib/utils.js:225 + lib/utils.js:228

                                                      @@ -682,8 +612,8 @@

                                                      Parameters:

                                                      • - [dir=process.cwd()] - Path + [directory=process.cwd()] + Path optional @@ -726,7 +656,7 @@

                                                        prepare

                                                        Defined in - lib/utils.js:139 + lib/utils.js:142

                                                        @@ -827,7 +757,7 @@

                                                        unindent

                                                        Defined in - lib/utils.js:43 + lib/utils.js:46

                                                        @@ -878,7 +808,7 @@

                                                        validatePaths

                                                        (
                                                        • - paths + globpaths
                                                        • [ignore=false] @@ -896,7 +826,7 @@

                                                          validatePaths

                                                          Defined in - lib/utils.js:365 + lib/utils.js:340

                                                          @@ -904,7 +834,8 @@

                                                          validatePaths

                                                          -

                                                          Make sure all the paths passed are directories and that they are not in the ignore list.

                                                          +

                                                          globpaths and ignore are both arrays of globs or a globstring. They should resolve to the actual files +you want yuidoc to parse.

                                                          @@ -913,12 +844,12 @@

                                                          Parameters:

                                                          • - paths + globpaths Array
                                                            -

                                                            The array of paths to validate

                                                            +

                                                            The array of globs to expand and validate

                                                            @@ -930,7 +861,7 @@

                                                            Parameters:

                                                            -

                                                            A string to call .indexOf on a path to determine if it should be ignored

                                                            +

                                                            array of globs to expand and filter paths array by

                                                            @@ -965,7 +896,7 @@

                                                            webpath

                                                            Defined in - lib/utils.js:475 + lib/utils.js:383

                                                            diff --git a/output/api/classes/YUIDoc.html b/output/api/classes/YUIDoc.html index e2c6846b..2561d44c 100644 --- a/output/api/classes/YUIDoc.html +++ b/output/api/classes/YUIDoc.html @@ -17,7 +17,7 @@

                                                            - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                        @@ -91,7 +91,7 @@

                                                        YUIDoc Class

                                                        - Defined in: lib/yuidoc.js:49 + Defined in: lib/yuidoc.js:51
                                                        Module: yuidoc @@ -134,7 +134,7 @@

                                                        YUIDoc

                                                        Defined in - lib/yuidoc.js:49 + lib/yuidoc.js:51

                                                        @@ -191,10 +191,6 @@

                                                        Methods

                                                      • _setDefaultExcludes -
                                                      • -
                                                      • - parsedir -
                                                      • parsefiles @@ -207,10 +203,6 @@

                                                        Methods

                                                      • runPreprocessors -
                                                      • -
                                                      • - walk -
                                                      • writeJSON @@ -223,10 +215,6 @@

                                                        Methods

                                                        Properties

                                                          -
                                                        • - dirmap - -
                                                        • endtime @@ -280,7 +268,7 @@

                                                          _processConfig

                                                          Defined in - lib/yuidoc.js:127 + lib/yuidoc.js:122

                                                          @@ -312,7 +300,7 @@

                                                          _setDefaultExcludes

                                                          Defined in - lib/yuidoc.js:112 + lib/yuidoc.js:107

                                                          @@ -327,70 +315,12 @@

                                                          _setDefaultExcludes

                                                          -
                                                          -
                                                          -

                                                          parsedir

                                                          - -
                                                          - (
                                                            -
                                                          • - dir -
                                                          • -
                                                          ) -
                                                          - - - - private - - - - - -
                                                          -

                                                          - Defined in - lib/yuidoc.js:149 -

                                                          - - - -
                                                          - -
                                                          -

                                                          Walks the passed directory and grabs all the files recursively.

                                                          - -
                                                          - -
                                                          -

                                                          Parameters:

                                                          - -
                                                            -
                                                          • - dir - String - - -
                                                            -

                                                            The directory to parse the contents of.

                                                            - -
                                                            - -
                                                          • -
                                                          -
                                                          - - -

                                                          parsefiles

                                                          (
                                                            -
                                                          • - dir -
                                                          • files
                                                          • @@ -408,7 +338,7 @@

                                                            parsefiles

                                                            Defined in - lib/yuidoc.js:190 + lib/yuidoc.js:133

                                                            @@ -416,7 +346,7 @@

                                                            parsefiles

                                                            -

                                                            Gathers all the file data and populates the filemap and dirmap hashes.

                                                            +

                                                            Gathers all the file data and populates the filemap and.

                                                            @@ -424,17 +354,6 @@

                                                            parsefiles

                                                            Parameters:

                                                              -
                                                            • - dir - String - - -
                                                              -

                                                              The directory to start from.

                                                              - -
                                                              - -
                                                            • files Array @@ -470,7 +389,7 @@

                                                              run

                                                              Defined in - lib/yuidoc.js:376 + lib/yuidoc.js:314

                                                              @@ -514,7 +433,7 @@

                                                              runPreprocessors

                                                              Defined in - lib/yuidoc.js:248 + lib/yuidoc.js:186

                                                              @@ -539,38 +458,6 @@

                                                              Returns:

                                                              -
                                                              -
                                                              -

                                                              walk

                                                              - - () - - - - private - - - - - -
                                                              -

                                                              - Defined in - lib/yuidoc.js:138 -

                                                              - - - -
                                                              - -
                                                              -

                                                              Walks the paths and parses the directory contents

                                                              - -
                                                              - - - -

                                                              writeJSON

                                                              @@ -597,7 +484,7 @@

                                                              writeJSON

                                                              Defined in - lib/yuidoc.js:287 + lib/yuidoc.js:225

                                                              @@ -645,32 +532,6 @@

                                                              Returns:

                                                              Properties

                                                              -
                                                              -

                                                              dirmap

                                                              - Object - - - private - - - -
                                                              -

                                                              - Defined in - lib/yuidoc.js:87 -

                                                              - - -
                                                              - -
                                                              -

                                                              Holder for the list of directories we are processing.

                                                              - -
                                                              - - - -

                                                              endtime

                                                              Timestamp @@ -682,7 +543,7 @@

                                                              endtime

                                                              Defined in - lib/yuidoc.js:404 + lib/yuidoc.js:341

                                                              @@ -708,7 +569,7 @@

                                                              filecount

                                                              Defined in - lib/yuidoc.js:66 + lib/yuidoc.js:68

                                                              @@ -734,7 +595,7 @@

                                                              filemap

                                                              Defined in - lib/yuidoc.js:80 + lib/yuidoc.js:82

                                                              @@ -760,7 +621,7 @@

                                                              OPTIONS

                                                              Defined in - lib/yuidoc.js:29 + lib/yuidoc.js:31

                                                              @@ -786,7 +647,7 @@

                                                              options

                                                              Defined in - lib/yuidoc.js:95 + lib/yuidoc.js:90

                                                              @@ -812,7 +673,7 @@

                                                              selleck

                                                              Defined in - lib/yuidoc.js:73 + lib/yuidoc.js:75

                                                              @@ -837,7 +698,7 @@

                                                              starttime

                                                              Defined in - lib/yuidoc.js:382 + lib/yuidoc.js:320

                                                              diff --git a/output/api/data.json b/output/api/data.json index 8f622a2f..a450d03d 100644 --- a/output/api/data.json +++ b/output/api/data.json @@ -2,7 +2,7 @@ "project": { "name": "yuidoc-root", "description": "YUIDoc, YUI's JavaScript Documentation engine.", - "version": "0.7.0" + "version": "0.8.0" }, "files": { "lib/builder.js": { @@ -142,7 +142,7 @@ "namespaces": {}, "tag": "main", "file": "lib/yuidoc.js", - "line": 49, + "line": 51, "description": "This is the __module__ description for the `YUIDoc` module.\n\n var options = {\n paths: [ './lib' ],\n outdir: './out'\n };\n\n var Y = require('yuidocjs');\n var json = (new Y.YUIDoc(options)).run();", "itemtype": "main" } @@ -158,7 +158,7 @@ "extension_for": [], "module": "yuidoc", "file": "lib/builder.js", - "line": 12, + "line": 14, "description": "Takes the `JSON` data from the `DocParser` class, creates and parses markdown and handlebars\nbased templates to generate static HTML content" }, "CLI": { @@ -172,7 +172,7 @@ "module": "yuidoc", "namespace": "", "file": "lib/cli.js", - "line": 9, + "line": 10, "description": "Parses the arguments, creates the options and passes them to `Y.YUIDoc` and then `Y.DocBuilder`." }, "DocParser": { @@ -186,7 +186,7 @@ "module": "yuidoc", "namespace": "", "file": "lib/docparser.js", - "line": 749, + "line": 750, "description": "The doc parser accepts a **map** of files to file content.\nOnce `parse()` is called, various properties will be populated\nwith the parsers data (aggregated in the `'data'` property).", "extends": "Base", "is_constructor": 1, @@ -209,8 +209,8 @@ "module": "yuidoc", "namespace": "", "file": "lib/docview.js", - "line": 14, - "description": "View class borrowed from [Selleck](https://github.com/rgrove/selleck) \nThe view class is a **`handlebars`** template helper.", + "line": 16, + "description": "View class borrowed from [Selleck](https://github.com/rgrove/selleck)\nThe view class is a **`handlebars`** template helper.", "is_constructor": 1, "params": [ { @@ -236,7 +236,7 @@ "module": "yuidoc", "namespace": "", "file": "lib/files.js", - "line": 8, + "line": 10, "description": "Ported fileutils methods from [Selleck](http://github.com/rgrove/selleck)" }, "Help": { @@ -250,7 +250,7 @@ "module": "yuidoc", "namespace": "", "file": "lib/help.js", - "line": 8, + "line": 10, "description": "Shows the help text" }, "Main": { @@ -264,8 +264,8 @@ "module": "yuidoc", "namespace": "", "file": "lib/index.js", - "line": 7, - "description": "Module creates the YUI instance with the required modules, uses them and exports the **Y** to be used\nby the _CLI class_ or by extenders: `require('yuidocjs');` \nYou can use it like this: \n\n var options = {\n paths: [ './lib' ],\n outdir: './out'\n };\n\n var Y = require('yuidocjs');\n var json = (new Y.YUIDoc(options)).run();", + "line": 8, + "description": "Module creates the YUI instance with the required modules, uses them and exports the **Y** to be used\nby the _CLI class_ or by extenders: `require('yuidocjs');`\nYou can use it like this:\n\n var options = {\n paths: [ './lib' ],\n outdir: './out'\n };\n\n var Y = require('yuidocjs');\n var json = (new Y.YUIDoc(options)).run();", "exports": "{YUI} Y A YUI instance" }, "Options": { @@ -279,7 +279,7 @@ "module": "yuidoc", "namespace": "", "file": "lib/options.js", - "line": 10, + "line": 12, "description": "Handles argument parsing" }, "Server": { @@ -293,7 +293,7 @@ "module": "yuidoc", "namespace": "", "file": "lib/server.js", - "line": 9, + "line": 13, "description": "Provides the `--server` server option for YUIDoc" }, "Utils": { @@ -307,7 +307,7 @@ "module": "yuidoc", "namespace": "", "file": "lib/utils.js", - "line": 10, + "line": 13, "description": "Utilities Class" }, "YUIDoc": { @@ -321,7 +321,7 @@ "module": "yuidoc", "namespace": "", "file": "lib/yuidoc.js", - "line": 49, + "line": 51, "description": "YUIDoc main class\n\n var options = {\n paths: [ './lib' ],\n outdir: './out'\n };\n\n var Y = require('yuidoc');\n var json = (new Y.YUIDoc(options)).run();", "mainName": "yuidoc", "tag": "main", @@ -345,7 +345,7 @@ }, { "file": "lib/builder.js", - "line": 123, + "line": 125, "description": "Register a `Y.Handlebars` helper method", "itemtype": "method", "name": "_addHelpers", @@ -361,7 +361,7 @@ }, { "file": "lib/builder.js", - "line": 140, + "line": 142, "description": "Wrapper around the Markdown parser so it can be normalized or even side stepped", "itemtype": "method", "name": "markdown", @@ -383,7 +383,7 @@ }, { "file": "lib/builder.js", - "line": 165, + "line": 167, "description": "Parse the item to be cross linked and return an HREF linked to the item", "itemtype": "method", "name": "_parseCrossLink", @@ -414,7 +414,7 @@ }, { "file": "lib/builder.js", - "line": 272, + "line": 274, "description": "List of native types to cross link to MDN", "itemtype": "property", "name": "NATIVES", @@ -424,7 +424,7 @@ }, { "file": "lib/builder.js", - "line": 311, + "line": 313, "description": "Function to link an external type uses `NATIVES` object", "itemtype": "method", "name": "NATIVES_LINKER", @@ -446,7 +446,7 @@ }, { "file": "lib/builder.js", - "line": 325, + "line": 327, "description": "Mixes the various external data soures together into the local data, augmenting\nit with flags.", "itemtype": "method", "name": "_mixExternal", @@ -457,7 +457,7 @@ }, { "file": "lib/builder.js", - "line": 373, + "line": 375, "description": "Fetches the remote data and fires the callback when it's all complete", "itemtype": "method", "name": "mixExternal", @@ -474,7 +474,7 @@ }, { "file": "lib/builder.js", - "line": 448, + "line": 450, "description": "File counter", "itemtype": "property", "name": "files", @@ -484,7 +484,7 @@ }, { "file": "lib/builder.js", - "line": 454, + "line": 456, "description": "Holder for project meta data", "itemtype": "property", "name": "_meta", @@ -496,7 +496,7 @@ }, { "file": "lib/builder.js", - "line": 461, + "line": 463, "description": "Prep the meta data to be fed to Selleck", "itemtype": "method", "name": "getProjectMeta", @@ -509,7 +509,7 @@ }, { "file": "lib/builder.js", - "line": 504, + "line": 506, "description": "Populate the meta data for classes", "itemtype": "method", "name": "populateClasses", @@ -529,7 +529,7 @@ }, { "file": "lib/builder.js", - "line": 528, + "line": 530, "description": "Populate the meta data for modules", "itemtype": "method", "name": "populateModules", @@ -549,7 +549,7 @@ }, { "file": "lib/builder.js", - "line": 574, + "line": 576, "description": "Populate the meta data for files", "itemtype": "method", "name": "populateFiles", @@ -569,7 +569,7 @@ }, { "file": "lib/builder.js", - "line": 631, + "line": 633, "description": "Parses file and line number from an item object and build's an HREF", "itemtype": "method", "name": "addFoundAt", @@ -589,7 +589,7 @@ }, { "file": "lib/builder.js", - "line": 647, + "line": 649, "description": "Augments the **DocParser** meta data to provide default values for certain keys as well as parses all descriptions\nwith the `Markdown Parser`", "itemtype": "method", "name": "augmentData", @@ -609,7 +609,7 @@ }, { "file": "lib/builder.js", - "line": 707, + "line": 709, "description": "Makes the default directories needed", "itemtype": "method", "name": "makeDirs", @@ -625,7 +625,7 @@ }, { "file": "lib/builder.js", - "line": 760, + "line": 762, "description": "Parses `
                                                              ` tags and adds the __prettyprint__ `className` to them",
                                                                           "itemtype": "method",
                                                                           "name": "_parseCode",
                                                              @@ -647,7 +647,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 773,
                                                              +            "line": 775,
                                                                           "description": "Ported from [Selleck](https://github.com/rgrove/selleck), this handles ```'s in fields\n       that are not parsed by the **Markdown** parser.",
                                                                           "itemtype": "method",
                                                                           "name": "_inlineCode",
                                                              @@ -669,7 +669,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 792,
                                                              +            "line": 794,
                                                                           "description": "Ported from [Selleck](https://github.com/rgrove/selleck)\n       Renders the handlebars templates with the default View class.",
                                                                           "itemtype": "method",
                                                                           "name": "render",
                                                              @@ -721,7 +721,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 848,
                                                              +            "line": 850,
                                                                           "description": "Render the index file",
                                                                           "itemtype": "method",
                                                                           "name": "renderIndex",
                                                              @@ -749,7 +749,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 873,
                                                              +            "line": 885,
                                                                           "description": "Generates the index.html file",
                                                                           "itemtype": "method",
                                                                           "name": "writeIndex",
                                                              @@ -777,7 +777,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 899,
                                                              +            "line": 911,
                                                                           "description": "Render a module",
                                                                           "itemtype": "method",
                                                                           "name": "renderModule",
                                                              @@ -805,7 +805,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 983,
                                                              +            "line": 1005,
                                                                           "description": "Generates the module files under \"out\"/modules/",
                                                                           "itemtype": "method",
                                                                           "name": "writeModules",
                                                              @@ -833,7 +833,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1026,
                                                              +            "line": 1048,
                                                                           "description": "Checks an array of items (class items) to see if an item is in that list",
                                                                           "itemtype": "method",
                                                                           "name": "hasProperty",
                                                              @@ -857,7 +857,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1043,
                                                              +            "line": 1065,
                                                                           "description": "Counter for stepping into merges",
                                                                           "access": "private",
                                                                           "tagname": "",
                                                              @@ -869,7 +869,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1050,
                                                              +            "line": 1072,
                                                                           "description": "Merge superclass data into a child class",
                                                                           "itemtype": "method",
                                                                           "name": "mergeExtends",
                                                              @@ -895,7 +895,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1102,
                                                              +            "line": 1124,
                                                                           "description": "Render the class file",
                                                                           "itemtype": "method",
                                                                           "name": "renderClass",
                                                              @@ -923,7 +923,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1389,
                                                              +            "line": 1416,
                                                                           "description": "Generates the class files under \"out\"/classes/",
                                                                           "itemtype": "method",
                                                                           "name": "writeClasses",
                                                              @@ -951,7 +951,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1432,
                                                              +            "line": 1459,
                                                                           "description": "Sort method of array of objects with a property called __name__",
                                                                           "itemtype": "method",
                                                                           "name": "nameSort",
                                                              @@ -976,7 +976,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1455,
                                                              +            "line": 1482,
                                                                           "description": "Generates the syntax files under `\"out\"/files/`",
                                                                           "itemtype": "method",
                                                                           "name": "writeFiles",
                                                              @@ -1004,7 +1004,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1505,
                                                              +            "line": 1532,
                                                                           "description": "Render the source file",
                                                                           "itemtype": "method",
                                                                           "name": "renderFile",
                                                              @@ -1032,7 +1032,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1559,
                                                              +            "line": 1591,
                                                                           "description": "Write the API meta data used for the AutoComplete widget",
                                                                           "itemtype": "method",
                                                                           "name": "writeAPIMeta",
                                                              @@ -1049,7 +1049,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1572,
                                                              +            "line": 1604,
                                                                           "description": "Render the API meta and return the JavaScript",
                                                                           "itemtype": "method",
                                                                           "name": "renderAPIMeta",
                                                              @@ -1073,7 +1073,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1605,
                                                              +            "line": 1637,
                                                                           "description": "Normalizes a file path to a writable filename:\n\n   var path = 'lib/file.js';\n   returns 'lib_file.js';",
                                                                           "itemtype": "method",
                                                                           "name": "filterFileName",
                                                              @@ -1093,7 +1093,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/builder.js",
                                                              -            "line": 1618,
                                                              +            "line": 1650,
                                                                           "description": "Compiles the templates from the meta-data provided by DocParser",
                                                                           "itemtype": "method",
                                                                           "name": "compile",
                                                              @@ -1109,7 +1109,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/cli.js",
                                                              -            "line": 3,
                                                              +            "line": 4,
                                                                           "description": "Copyright (c) 2011, Yahoo! Inc. All rights reserved.\nCode licensed under the BSD License:\nhttps://github.com/yui/yuidoc/blob/master/LICENSE",
                                                                           "class": "CLI",
                                                                           "module": "yuidoc"
                                                              @@ -1123,7 +1123,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 11,
                                                              +            "line": 13,
                                                                           "description": "Parses the JSON data and formats it into a nice log string for\nfilename and line number: `/file/name.js:123`",
                                                                           "itemtype": "method",
                                                                           "name": "stringlog",
                                                              @@ -1145,7 +1145,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 38,
                                                              +            "line": 40,
                                                                           "description": "Flatten a string, remove all line breaks and replace them with a token",
                                                                           "itemtype": "method",
                                                                           "name": "implodeString",
                                                              @@ -1167,7 +1167,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 48,
                                                              +            "line": 50,
                                                                           "description": "Un-flatten a string, replace tokens injected with `implodeString`",
                                                                           "itemtype": "method",
                                                                           "name": "implodeString",
                                                              @@ -1189,7 +1189,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 94,
                                                              +            "line": 96,
                                                                           "description": "A list of known tags.  This populates a member variable\nduring initialization, and will be updated if additional\ndigesters are added.",
                                                                           "itemtype": "property",
                                                                           "name": "TAGLIST",
                                                              @@ -1200,7 +1200,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 174,
                                                              +            "line": 176,
                                                                           "description": "A list of ignored tags. These tags should be ignored because there is\nlikely to be used for purposes other than JSDoc tags in JavaScript comments.",
                                                                           "itemtype": "property",
                                                                           "name": "IGNORE_TAGLIST",
                                                              @@ -1211,7 +1211,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 186,
                                                              +            "line": 188,
                                                                           "description": "Common errors will get scrubbed instead of being ignored.",
                                                                           "itemtype": "property",
                                                                           "name": "CORRECTIONS",
                                                              @@ -1222,7 +1222,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 209,
                                                              +            "line": 211,
                                                                           "description": "A map of the default tag processors, keyed by the\ntag name.  Multiple tags can use the same digester\nby supplying the string name that points to the\nimplementation rather than a function.",
                                                                           "itemtype": "property",
                                                                           "name": "DIGESTERS",
                                                              @@ -1233,7 +1233,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 777,
                                                              +            "line": 778,
                                                                           "description": "Digesters process the tag/text pairs found in a\ncomment block.  They are looked up by tag name.\nThe digester gets the tagname, the value, the\ntarget object to apply values to, and the full\nblock that is being processed.  Digesters can\nbe declared as strings instead of a function --\nin that case, the program will try to look up\nthe key listed and use the function there instead\n(it is an alias).  Digesters can return a host\nobject in the case the tag defines a new key\nblock type (modules/classes/methods/events/properties)",
                                                                           "itemtype": "attribute",
                                                                           "name": "digesters",
                                                              @@ -1242,7 +1242,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 799,
                                                              +            "line": 800,
                                                                           "description": "Emitters will be schemas for the types of payloads\nthe parser will emit.  Not implemented.",
                                                                           "itemtype": "attribute",
                                                                           "name": "emitters",
                                                              @@ -1251,7 +1251,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 810,
                                                              +            "line": 811,
                                                                           "description": "Comment syntax type.",
                                                                           "itemtype": "attribute",
                                                                           "name": "syntaxtype",
                                                              @@ -1261,7 +1261,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 819,
                                                              +            "line": 820,
                                                                           "description": "The map of file names to file content.",
                                                                           "itemtype": "attribute",
                                                                           "name": "filemap",
                                                              @@ -1270,7 +1270,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 827,
                                                              +            "line": 828,
                                                                           "description": "A map of file names to directory name.  Provided in\ncase this needs to be used to reset the module name\nappropriately -- currently not used",
                                                                           "itemtype": "attribute",
                                                                           "name": "dirmap",
                                                              @@ -1279,7 +1279,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 837,
                                                              +            "line": 838,
                                                                           "description": "The file currently being parsed",
                                                                           "itemtype": "attribute",
                                                                           "name": "currentfile",
                                                              @@ -1289,7 +1289,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 858,
                                                              +            "line": 859,
                                                                           "description": "The main documentation block for the module itself.",
                                                                           "itemtype": "attribute",
                                                                           "name": "mainmodule",
                                                              @@ -1299,7 +1299,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 894,
                                                              +            "line": 895,
                                                                           "description": "The module currently being parsed",
                                                                           "itemtype": "attribute",
                                                                           "name": "currentmodule",
                                                              @@ -1309,7 +1309,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 953,
                                                              +            "line": 954,
                                                                           "description": "The submodule currently being parsed",
                                                                           "itemtype": "attribute",
                                                                           "name": "currentsubmodule",
                                                              @@ -1319,7 +1319,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 993,
                                                              +            "line": 994,
                                                                           "description": "The class currently being parsed",
                                                                           "itemtype": "attribute",
                                                                           "name": "currentclass",
                                                              @@ -1329,7 +1329,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 1033,
                                                              +            "line": 1034,
                                                                           "description": "Takes a non-namespaced classname and resolves it to a namespace (to support `@for`)",
                                                                           "access": "private",
                                                                           "tagname": "",
                                                              @@ -1351,7 +1351,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 1107,
                                                              +            "line": 1104,
                                                                           "description": "Normalizes the initial indentation of the given _content_ so that the first line\nis unindented, and all other lines are unindented to the same degree as the\nfirst line. So if the first line has four spaces at the beginning, then all\nlines will be unindented four spaces. Ported from [Selleck](https://github.com/rgrove/selleck)",
                                                                           "itemtype": "method",
                                                                           "name": "unindent",
                                                              @@ -1373,7 +1373,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 1128,
                                                              +            "line": 1125,
                                                                           "description": "Transforms a JavaDoc style comment block (less the start and end of it)\ninto a list of tag/text pairs. The leading space and '*' are removed,\nbut the remaining whitespace is preserved so that the output should be\nfriendly for both markdown and html parsers.",
                                                                           "itemtype": "method",
                                                                           "name": "handlecomment",
                                                              @@ -1399,7 +1399,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 1206,
                                                              +            "line": 1203,
                                                                           "description": "Accepts a map of filenames to file content.  Returns\na map of filenames to an array of API comment block\ntext.  This expects the comment to start with / **\non its own line, and end with * / on its own\nline.  Override this function to provide an\nalternative comment parser.",
                                                                           "itemtype": "method",
                                                                           "name": "extract",
                                                              @@ -1424,7 +1424,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 1261,
                                                              +            "line": 1258,
                                                                           "description": "Processes all the tags in a single comment block",
                                                                           "itemtype": "method",
                                                                           "name": "processblock",
                                                              @@ -1440,7 +1440,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 1334,
                                                              +            "line": 1331,
                                                                           "description": "Transforms a map of filenames to arrays of comment blocks into a\nJSON structure that represents the entire processed API doc info\nand relationships between elements for the entire project.",
                                                                           "itemtype": "method",
                                                                           "name": "transform",
                                                              @@ -1460,7 +1460,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docparser.js",
                                                              -            "line": 1448,
                                                              +            "line": 1445,
                                                                           "description": "Extracts and transforms the filemap provided to constructor",
                                                                           "itemtype": "method",
                                                                           "name": "parse",
                                                              @@ -1492,7 +1492,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docview.js",
                                                              -            "line": 28,
                                                              +            "line": 30,
                                                                           "description": "**Mustache** `lambda` method for setting the HTML title",
                                                                           "itemtype": "method",
                                                                           "name": "htmlTitle",
                                                              @@ -1501,7 +1501,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/docview.js",
                                                              -            "line": 47,
                                                              +            "line": 49,
                                                                           "description": "**Mustache** `lambda` method for setting the title",
                                                                           "itemtype": "method",
                                                                           "name": "title",
                                                              @@ -1517,7 +1517,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 37,
                                                              +            "line": 39,
                                                                           "description": "Copy a directory from one location to another",
                                                                           "itemtype": "method",
                                                                           "name": "copyDirectory",
                                                              @@ -1550,7 +1550,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 127,
                                                              +            "line": 128,
                                                                           "description": "Copy a file from one location to another",
                                                                           "itemtype": "method",
                                                                           "name": "copyFile",
                                                              @@ -1590,7 +1590,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 180,
                                                              +            "line": 181,
                                                                           "description": "If _source_ is a file, copies it to _dest_. If it's a directory, recursively\ncopies it and all files and directories it contains to _dest_.\n\nNote that when attempting to copy a file into a directory, you should specify\nthe full path to the new file (including the new filename). Otherwise, it will\nbe interpreted as an attempt to copy the _source_ file *over* the _dest_\ndirectory instead of *into* it.\n\nKnown issues:\n- Doesn't preserve ownership or permissions on copied files/directories.",
                                                                           "itemtype": "method",
                                                                           "name": "copyPath",
                                                              @@ -1630,7 +1630,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 226,
                                                              +            "line": 227,
                                                                           "description": "If _path_ is a file, deletes it. If _path_ is a directory, recursively deletes\nit and all files and directories it contains.\n\nThis method is synchronous.",
                                                                           "itemtype": "method",
                                                                           "name": "deletePath",
                                                              @@ -1646,7 +1646,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 251,
                                                              +            "line": 252,
                                                                           "description": "Check to see if this is a directory",
                                                                           "itemtype": "method",
                                                                           "name": "isDirectory",
                                                              @@ -1673,7 +1673,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 282,
                                                              +            "line": 283,
                                                                           "description": "Check to see if this is a File",
                                                                           "itemtype": "method",
                                                                           "name": "isFile",
                                                              @@ -1700,7 +1700,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 311,
                                                              +            "line": 312,
                                                                           "description": "Check to see if this is a SymLink",
                                                                           "itemtype": "method",
                                                                           "name": "isSymbolicLink",
                                                              @@ -1720,7 +1720,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 325,
                                                              +            "line": 326,
                                                                           "description": "Like `fs.lstatSync()`, but returns `null` instead of throwing when _path_\ndoesn't exist. Will still throw on other types of errors.",
                                                                           "itemtype": "method",
                                                                           "name": "lstatSync",
                                                              @@ -1740,7 +1740,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 347,
                                                              +            "line": 348,
                                                                           "description": "Like `fs.statSync()`, but returns `null` instead of throwing when _path_\ndoesn't exist. Will still throw on other types of errors.",
                                                                           "itemtype": "method",
                                                                           "name": "statSync",
                                                              @@ -1760,7 +1760,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 368,
                                                              +            "line": 369,
                                                                           "description": "Copy the theme assets directory",
                                                                           "itemtype": "method",
                                                                           "name": "copyAssets",
                                                              @@ -1791,7 +1791,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 416,
                                                              +            "line": 417,
                                                                           "description": "Helper method for getting JSON data from a local file",
                                                                           "itemtype": "method",
                                                                           "name": "getJSON",
                                                              @@ -1811,7 +1811,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/files.js",
                                                              -            "line": 431,
                                                              +            "line": 432,
                                                                           "description": "Helper method for writing files to disk. It wraps the NodeJS file API",
                                                                           "itemtype": "method",
                                                                           "name": "writeFile",
                                                              @@ -1845,7 +1845,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/help.js",
                                                              -            "line": 14,
                                                              +            "line": 16,
                                                                           "description": "The help text to display",
                                                                           "access": "private",
                                                                           "tagname": "",
                                                              @@ -1857,7 +1857,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/help.js",
                                                              -            "line": 61,
                                                              +            "line": 63,
                                                                           "description": "Render the help message as a string",
                                                                           "itemtype": "method",
                                                                           "name": "renderHelp",
                                                              @@ -1870,7 +1870,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/help.js",
                                                              -            "line": 71,
                                                              +            "line": 73,
                                                                           "description": "Display the help message, write it to the screen and exit",
                                                                           "itemtype": "method",
                                                                           "name": "showHelp",
                                                              @@ -1893,7 +1893,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/options.js",
                                                              -            "line": 16,
                                                              +            "line": 18,
                                                                           "description": "Parses arguments and returns an Object of config options",
                                                                           "itemtype": "method",
                                                                           "name": "Options",
                                                              @@ -1927,7 +1927,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 15,
                                                              +            "line": 19,
                                                                           "description": "Cache for external mixed in data.",
                                                                           "itemtype": "property",
                                                                           "name": "_externalData",
                                                              @@ -1939,7 +1939,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 22,
                                                              +            "line": 26,
                                                                           "description": "Middleware to parse the API docs per request",
                                                                           "itemtype": "method",
                                                                           "name": "parse",
                                                              @@ -1965,7 +1965,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 40,
                                                              +            "line": 44,
                                                                           "description": "Create the routes used to serve YUIDoc files dynamically",
                                                                           "itemtype": "method",
                                                                           "name": "routes",
                                                              @@ -1974,7 +1974,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 110,
                                                              +            "line": 114,
                                                                           "description": "`/files` endpoint",
                                                                           "itemtype": "method",
                                                                           "name": "files",
                                                              @@ -1995,7 +1995,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 136,
                                                              +            "line": 140,
                                                                           "description": "`/classes` endpoint",
                                                                           "itemtype": "method",
                                                                           "name": "clazz",
                                                              @@ -2016,7 +2016,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 152,
                                                              +            "line": 156,
                                                                           "description": "`/modules` endpoint",
                                                                           "itemtype": "method",
                                                                           "name": "modules",
                                                              @@ -2037,7 +2037,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 168,
                                                              +            "line": 172,
                                                                           "description": "`/` endpoint",
                                                                           "itemtype": "method",
                                                                           "name": "home",
                                                              @@ -2058,7 +2058,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 180,
                                                              +            "line": 184,
                                                                           "description": "Creates the Express server and prep's YUI for serving",
                                                                           "itemtype": "method",
                                                                           "name": "init",
                                                              @@ -2067,7 +2067,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/server.js",
                                                              -            "line": 198,
                                                              +            "line": 200,
                                                                           "description": "Start the server with the supplied options.",
                                                                           "itemtype": "method",
                                                                           "name": "start",
                                                              @@ -2090,7 +2090,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 30,
                                                              +            "line": 33,
                                                                           "description": "Escapes HTML characters in _html_.",
                                                                           "itemtype": "method",
                                                                           "name": "escapeHTML",
                                                              @@ -2110,7 +2110,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 43,
                                                              +            "line": 46,
                                                                           "description": "Normalizes the initial indentation of the given _content_ so that the first line\nis unindented, and all other lines are unindented to the same degree as the\nfirst line. So if the first line has four spaces at the beginning, then all\nlines will be unindented four spaces.",
                                                                           "itemtype": "method",
                                                                           "name": "unindent",
                                                              @@ -2132,7 +2132,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 64,
                                                              +            "line": 67,
                                                                           "description": "Like `getPages()`, but returns only the files under the `layout/` subdirectory\nof the specified _dir_.",
                                                                           "itemtype": "method",
                                                                           "name": "getLayouts",
                                                              @@ -2152,7 +2152,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 77,
                                                              +            "line": 80,
                                                                           "description": "Loads and returns the content of the specified page file.",
                                                                           "itemtype": "method",
                                                                           "name": "getPage",
                                                              @@ -2172,7 +2172,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 92,
                                                              +            "line": 95,
                                                                           "description": "Loads pages (files with a `.handlebars` extension) in the specified directory and\nreturns an object containing a mapping of page names (the part of the filename)\npreceding the `.handlebars` extension) to page content.",
                                                                           "itemtype": "method",
                                                                           "name": "getPages",
                                                              @@ -2192,7 +2192,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 125,
                                                              +            "line": 128,
                                                                           "description": "Like `getPages()`, but returns only the files under the `partial/` subdirectory\nof the specified _dir_.",
                                                                           "itemtype": "method",
                                                                           "name": "getPartials",
                                                              @@ -2212,7 +2212,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 139,
                                                              +            "line": 142,
                                                                           "description": "Mix/merge/munge data into the template.",
                                                                           "itemtype": "method",
                                                                           "name": "prepare",
                                                              @@ -2250,13 +2250,13 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 225,
                                                              +            "line": 228,
                                                                           "description": "Walk the directory tree to locate the yuidoc.json file.",
                                                                           "itemtype": "method",
                                                                           "name": "getProjectData",
                                                                           "params": [
                                                                               {
                                                              -                    "name": "dir",
                                                              +                    "name": "directory",
                                                                                   "description": "The directory to start from",
                                                                                   "type": "Path",
                                                                                   "optional": true,
                                                              @@ -2268,39 +2268,19 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 339,
                                                              -            "description": "Walks the tree from this dir and returns all the subdirs",
                                                              -            "itemtype": "method",
                                                              -            "name": "getDirs",
                                                              -            "params": [
                                                              -                {
                                                              -                    "name": "dir",
                                                              -                    "description": "The dir to begin at",
                                                              -                    "type": "String"
                                                              -                }
                                                              -            ],
                                                              -            "return": {
                                                              -                "description": "The array of directories..",
                                                              -                "type": "Array"
                                                              -            },
                                                              -            "class": "Utils",
                                                              -            "module": "yuidoc"
                                                              -        },
                                                              -        {
                                                              -            "file": "lib/utils.js",
                                                              -            "line": 365,
                                                              -            "description": "Make sure all the paths passed are directories and that they are not in the ignore list.",
                                                              +            "line": 340,
                                                              +            "description": "globpaths and ignore are both arrays of globs or a globstring. They should resolve to the actual files\nyou want yuidoc to parse.",
                                                                           "itemtype": "method",
                                                                           "name": "validatePaths",
                                                                           "params": [
                                                                               {
                                                              -                    "name": "paths",
                                                              -                    "description": "The array of paths to validate",
                                                              +                    "name": "globpaths",
                                                              +                    "description": "The array of globs to expand and validate",
                                                                                   "type": "Array"
                                                                               },
                                                                               {
                                                                                   "name": "ignore",
                                                              -                    "description": "A string to call `.indexOf` on a path to determine if it should be ignored",
                                                              +                    "description": "array of globs to expand and filter paths array by",
                                                                                   "type": "String",
                                                                                   "optional": true,
                                                                                   "optdefault": "false"
                                                              @@ -2311,7 +2291,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 453,
                                                              +            "line": 361,
                                                                           "description": "Takes a type string and converts it to a \"First letter upper cased\" type. e.g. `(string -> String, object -> Object)`",
                                                                           "itemtype": "method",
                                                                           "name": "fixType",
                                                              @@ -2331,7 +2311,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/utils.js",
                                                              -            "line": 475,
                                                              +            "line": 383,
                                                                           "description": "Produces a normalized web path by joining all the parts and normalizing the\nfilesystem-like path into web compatible url.\nSupports relative and absolute paths.\nCourtesy of [Mojito's utils](https://github.com/yahoo/mojito/)",
                                                                           "itemtype": "method",
                                                                           "name": "webpath",
                                                              @@ -2358,7 +2338,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 29,
                                                              +            "line": 31,
                                                                           "description": "The default list of configuration options",
                                                                           "itemtype": "property",
                                                                           "name": "OPTIONS",
                                                              @@ -2369,7 +2349,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 66,
                                                              +            "line": 68,
                                                                           "description": "Holds the number of files that we are processing.",
                                                                           "itemtype": "property",
                                                                           "name": "filecount",
                                                              @@ -2381,7 +2361,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 73,
                                                              +            "line": 75,
                                                                           "description": "Hash map of dirnames to selleck config options.",
                                                                           "itemtype": "property",
                                                                           "name": "selleck",
                                                              @@ -2393,7 +2373,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 80,
                                                              +            "line": 82,
                                                                           "description": "Holder for the list of files we are processing.",
                                                                           "itemtype": "property",
                                                                           "name": "filemap",
                                                              @@ -2405,19 +2385,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 87,
                                                              -            "description": "Holder for the list of directories we are processing.",
                                                              -            "itemtype": "property",
                                                              -            "name": "dirmap",
                                                              -            "type": "Object",
                                                              -            "access": "private",
                                                              -            "tagname": "",
                                                              -            "class": "YUIDoc",
                                                              -            "module": "yuidoc"
                                                              -        },
                                                              -        {
                                                              -            "file": "lib/yuidoc.js",
                                                              -            "line": 95,
                                                              +            "line": 90,
                                                                           "description": "Internal holder for configuration options.",
                                                                           "itemtype": "property",
                                                                           "name": "options",
                                                              @@ -2429,7 +2397,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 112,
                                                              +            "line": 107,
                                                                           "description": "Always exclude these directories",
                                                                           "itemtype": "method",
                                                                           "name": "_setDefaultExcludes",
                                                              @@ -2440,7 +2408,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 127,
                                                              +            "line": 122,
                                                                           "description": "Does post process on self.options.",
                                                                           "itemtype": "method",
                                                                           "name": "_processConfig",
                                                              @@ -2451,45 +2419,11 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 138,
                                                              -            "description": "Walks the paths and parses the directory contents",
                                                              -            "itemtype": "method",
                                                              -            "name": "walk",
                                                              -            "access": "private",
                                                              -            "tagname": "",
                                                              -            "class": "YUIDoc",
                                                              -            "module": "yuidoc"
                                                              -        },
                                                              -        {
                                                              -            "file": "lib/yuidoc.js",
                                                              -            "line": 149,
                                                              -            "description": "Walks the passed directory and grabs all the files recursively.",
                                                              -            "itemtype": "method",
                                                              -            "name": "parsedir",
                                                              -            "params": [
                                                              -                {
                                                              -                    "name": "dir",
                                                              -                    "description": "The directory to parse the contents of.",
                                                              -                    "type": "String"
                                                              -                }
                                                              -            ],
                                                              -            "access": "private",
                                                              -            "tagname": "",
                                                              -            "class": "YUIDoc",
                                                              -            "module": "yuidoc"
                                                              -        },
                                                              -        {
                                                              -            "file": "lib/yuidoc.js",
                                                              -            "line": 190,
                                                              -            "description": "Gathers all the file data and populates the filemap and dirmap hashes.",
                                                              +            "line": 133,
                                                              +            "description": "Gathers all the file data and populates the filemap and.",
                                                                           "itemtype": "method",
                                                                           "name": "parsefiles",
                                                                           "params": [
                                                              -                {
                                                              -                    "name": "dir",
                                                              -                    "description": "The directory to start from.",
                                                              -                    "type": "String"
                                                              -                },
                                                                               {
                                                                                   "name": "files",
                                                                                   "description": "List of files to parse.",
                                                              @@ -2503,8 +2437,8 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 248,
                                                              -            "description": "Applies preprocessors to the data tree. \nThis function first clones the data and operates on the clone.",
                                                              +            "line": 186,
                                                              +            "description": "Applies preprocessors to the data tree.\nThis function first clones the data and operates on the clone.",
                                                                           "itemtype": "method",
                                                                           "name": "runPreprocessors",
                                                                           "access": "private",
                                                              @@ -2518,7 +2452,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 287,
                                                              +            "line": 225,
                                                                           "description": "Writes the parser JSON data to disk.\nApplies preprocessors, if any.",
                                                                           "itemtype": "method",
                                                                           "name": "writeJSON",
                                                              @@ -2540,7 +2474,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 376,
                                                              +            "line": 314,
                                                                           "description": "Process the config, walk the file tree and write out the JSON data.",
                                                                           "itemtype": "method",
                                                                           "name": "run",
                                                              @@ -2553,7 +2487,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 382,
                                                              +            "line": 320,
                                                                           "description": "Timestamp holder so we know when YUIDoc started the parse process.",
                                                                           "itemtype": "property",
                                                                           "name": "starttime",
                                                              @@ -2563,7 +2497,7 @@
                                                                       },
                                                                       {
                                                                           "file": "lib/yuidoc.js",
                                                              -            "line": 404,
                                                              +            "line": 341,
                                                                           "description": "Timestamp holder so we know when YUIDoc has finished the parse process.",
                                                                           "itemtype": "property",
                                                                           "name": "endtime",
                                                              @@ -2575,7 +2509,7 @@
                                                                   "warnings": [
                                                                       {
                                                                           "message": "unknown tag: exports",
                                                              -            "line": " lib/index.js:7"
                                                              +            "line": " lib/index.js:8"
                                                                       },
                                                                       {
                                                                           "message": "Missing item type\nCopyright (c) 2011, Yahoo! Inc. All rights reserved.\nCode licensed under the BSD License:\nhttps://github.com/yui/yuidoc/blob/master/LICENSE",
                                                              @@ -2583,7 +2517,7 @@
                                                                       },
                                                                       {
                                                                           "message": "Missing item type\nCopyright (c) 2011, Yahoo! Inc. All rights reserved.\nCode licensed under the BSD License:\nhttps://github.com/yui/yuidoc/blob/master/LICENSE",
                                                              -            "line": " lib/cli.js:3"
                                                              +            "line": " lib/cli.js:4"
                                                                       },
                                                                       {
                                                                           "message": "Missing item type\nCopyright (c) 2011, Yahoo! Inc. All rights reserved.\nCode licensed under the BSD License:\nhttps://github.com/yui/yuidoc/blob/master/LICENSE",
                                                              diff --git a/output/api/files/lib_builder.js.html b/output/api/files/lib_builder.js.html
                                                              index d8dcdd84..89e86b7d 100644
                                                              --- a/output/api/files/lib_builder.js.html
                                                              +++ b/output/api/files/lib_builder.js.html
                                                              @@ -17,7 +17,7 @@
                                                                               

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,11 +95,13 @@

                                                              File: lib/builder.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ -var MarkdownIt = require('markdown-it'), - fs = require('graceful-fs'), - noop = function () {}, - path = require('path'), - TEMPLATE; +'use strict'; + +var MarkdownIt = require('markdown-it'); +var fs = require('graceful-fs'); +var noop = function () {}; +var path = require('path'); +var TEMPLATE; /** * Takes the `JSON` data from the `DocParser` class, creates and parses markdown and handlebars @@ -155,7 +157,7 @@

                                                              File: lib/builder.js

                                                              this.files = 0; var self = this; - Y.Handlebars.registerHelper('crossLink', function (item, options) { + Y.Handlebars.registerHelper('crossLink', function (item, helperOptions) { var str = ''; if (!item) { item = ''; @@ -169,16 +171,16 @@

                                                              File: lib/builder.js

                                                              }); str = p.join(' | '); } else { - str = self._parseCrossLink.call(self, item, false, options.fn(this)); + str = self._parseCrossLink.call(self, item, false, helperOptions.fn(this)); } return str; }); - Y.Handlebars.registerHelper('crossLinkModule', function (item, options) { + Y.Handlebars.registerHelper('crossLinkModule', function (item, helperOptions) { var str = item; if (self.data.modules[item]) { - var content = options.fn(this); - if (content === "") { + var content = helperOptions.fn(this); + if (content === '') { content = item; } str = '<a href="../modules/' + item.replace(/\//g, '_') + @@ -243,7 +245,7 @@

                                                              File: lib/builder.js

                                                              try { // markdown-it auto-escapes quotation marks (and unfortunately // does not expose the escaping function) - html = html.replace(/&quot;/g, "\""); + html = html.replace(/&quot;/g, '"'); html = (Y.Handlebars.compile(html))({}); } catch (hError) { //Remove all the extra escapes @@ -455,8 +457,8 @@

                                                              File: lib/builder.js

                                                              } }); } - if (item["return"]) { - item["return"].type = fixType(item["return"].type); + if (item.return) { + item.return.type = fixType(item.return.type); } self.data.classitems.push(item); }); @@ -506,13 +508,13 @@

                                                              File: lib/builder.js

                                                              on: { complete: stack.add(function (id, e) { Y.log('Received: ' + i, 'info', 'builder'); - var data = JSON.parse(e.responseText); - data.base = base; + var parsedData = JSON.parse(e.responseText); + parsedData.base = base; //self.options.externalData = Y.mix(self.options.externalData || {}, data); if (!self.options.externalData) { self.options.externalData = []; } - self.options.externalData.push(data); + self.options.externalData.push(parsedData); }) } }); @@ -807,13 +809,13 @@

                                                              File: lib/builder.js

                                                              if (self.options.dumpview) { dirs.push('json'); } - var writeRedirect = function (dir, file, cb) { + var writeRedirect = function (dir, file, cbWriteRedirect) { Y.Files.exists(file, function (x) { if (x) { var out = path.join(dir, 'index.html'); fs.createReadStream(file).pipe(fs.createWriteStream(out)); } - cb(); + cbWriteRedirect(); }); }; var defaultIndex = path.join(themeDir, 'assets', 'index.html'); @@ -823,7 +825,7 @@

                                                              File: lib/builder.js

                                                              var dir = path.join(self.options.outdir, d); Y.Files.exists(dir, stack.add(function (x) { if (!x) { - fs.mkdir(dir, 0777, stack.add(function () { + fs.mkdir(dir, '0777', stack.add(function () { writeRedirect(dir, defaultIndex, stack.add(noop)); })); } else { @@ -843,7 +845,7 @@

                                                              File: lib/builder.js

                                                              if (!url) { return null; } - if (url.indexOf("://") >= 0) { + if (url.indexOf('://') >= 0) { return url; } return path.join(opts.meta.projectRoot, url); @@ -911,8 +913,8 @@

                                                              File: lib/builder.js

                                                              var parts = Y.merge(partials || {}, { layout_content: source }); - Y.each(parts, function (source, name) { - Y.Handlebars.registerPartial(name, source); + Y.each(parts, function (partialsSource, name) { + Y.Handlebars.registerPartial(name, partialsSource); }); if (!TEMPLATE || !this.cacheTemplates) { @@ -948,6 +950,11 @@

                                                              File: lib/builder.js

                                                              var self = this; Y.prepare([DEFAULT_THEME, themeDir], self.getProjectMeta(), function (err, opts) { + if (err) { + Y.log(err, 'error', 'builder'); + cb(err); + return; + } opts.meta.title = self.data.project.name; opts.meta.projectRoot = './'; opts.meta.projectAssets = './assets'; @@ -956,7 +963,12 @@

                                                              File: lib/builder.js

                                                              opts = self.populateModules(opts); var view = new Y.DocView(opts.meta); - self.render('{{>index}}', view, opts.layouts.main, opts.partials, function (err, html) { + self.render('{{>index}}', view, opts.layouts.main, opts.partials, function (renderErr, html) { + if (renderErr) { + Y.log(renderErr, 'error', 'builder'); + cb(renderErr); + return; + } self.files++; cb(html, view); }); @@ -1002,6 +1014,11 @@

                                                              File: lib/builder.js

                                                              data.displayName = data.name; data.name = self.filterFileName(data.name); Y.prepare([DEFAULT_THEME, themeDir], self.getProjectMeta(), function (err, opts) { + if (err) { + Y.log(err, 'error', 'builder'); + cb(err); + return; + } opts.meta = Y.merge(opts.meta, data); //opts.meta.htmlTitle = v.name + ': ' + self.data.project.name; @@ -1061,7 +1078,12 @@

                                                              File: lib/builder.js

                                                              var view = new Y.DocView(opts.meta); var mainLayout = opts.layouts[layout]; - self.render('{{>module}}', view, mainLayout, opts.partials, stack.add(function (err, html) { + self.render('{{>module}}', view, mainLayout, opts.partials, stack.add(function (renderErr, html) { + if (renderErr) { + Y.log(renderErr, 'error', 'builder'); + cb(renderErr); + return; + } self.files++; stack.html = html; stack.view = view; @@ -1241,51 +1263,51 @@

                                                              File: lib/builder.js

                                                              } var classItems = []; - self.data.classitems.forEach(function (i) { - if (i.class === data.name) { - classItems.push(i); + self.data.classitems.forEach(function (classItem) { + if (classItem.class === data.name) { + classItems.push(classItem); } }); classItems = self.mergeExtends(data, classItems, true); if (data.is_constructor) { - var i = Y.mix({}, data); - i = self.augmentData(i); - i.paramsList = []; - if (i.params) { - i.params.forEach(function (p) { + var constructor = Y.mix({}, data); + constructor = self.augmentData(constructor); + constructor.paramsList = []; + if (constructor.params) { + constructor.params.forEach(function (p) { var name = p.name; if (p.optional) { name = '[' + name + ((p.optdefault) ? '=' + p.optdefault : '') + ']'; } - i.paramsList.push(name); + constructor.paramsList.push(name); }); } //i.methodDescription = self._parseCode(markdown(i.description)); - i.hasAccessType = i.access; - i.hasParams = i.paramsList.length; - if (i.paramsList.length) { - i.paramsList = i.paramsList.join(', '); + constructor.hasAccessType = constructor.access; + constructor.hasParams = constructor.paramsList.length; + if (constructor.paramsList.length) { + constructor.paramsList = constructor.paramsList.join(', '); } else { - i.paramsList = ' '; + constructor.paramsList = ' '; } - i.returnType = ' '; - if (i["return"]) { - i.hasReturn = true; - i.returnType = i["return"].type; + constructor.returnType = ' '; + if (constructor.return) { + constructor.hasReturn = true; + constructor.returnType = constructor.return.type; } //console.error(i); - opts.meta.is_constructor = [i]; - if (i.example && i.example.length) { - if (i.example.forEach) { - var e = ''; - i.example.forEach(function (v) { - e += self._parseCode(self.markdown(v)); + opts.meta.is_constructor = [constructor]; + if (constructor.example && constructor.example.length) { + if (constructor.example.forEach) { + var example = ''; + constructor.example.forEach(function (v) { + example += self._parseCode(self.markdown(v)); }); - i.example = e; + constructor.example = example; } else { - i.example = self._parseCode(self.markdown(i.example)); + constructor.example = self._parseCode(self.markdown(constructor.example)); } } } @@ -1325,9 +1347,9 @@

                                                              File: lib/builder.js

                                                              i.paramsList = ' '; } i.returnType = ' '; - if (i["return"]) { + if (i.return) { i.hasReturn = true; - i.returnType = i["return"].type; + i.returnType = i.return.type; } // If this item is provided by a module other @@ -1466,7 +1488,12 @@

                                                              File: lib/builder.js

                                                              var view = new Y.DocView(opts.meta); var mainLayout = opts.layouts[layout]; - self.render('{{>classes}}', view, mainLayout, opts.partials, stack.add(function (err, html) { + self.render('{{>classes}}', view, mainLayout, opts.partials, stack.add(function (renderErr, html) { + if (renderErr) { + Y.log(renderErr, 'error', 'builder'); + cb(renderErr); + return; + } self.files++; stack.html = html; stack.view = view; @@ -1625,10 +1652,10 @@

                                                              File: lib/builder.js

                                                              opts = self.populateFiles(opts); opts.meta.fileName = data.name; - fs.readFile(opts.meta.fileName, Y.charset, Y.rbind(function (err, str, opts, data) { - if (err) { - Y.log(err, 'error', 'builder'); - cb(err); + fs.readFile(opts.meta.fileName, Y.charset, Y.rbind(function (readErr, str, readOpts, readData) { + if (readErr) { + Y.log(readErr, 'error', 'builder'); + cb(readErr); return; } @@ -1636,12 +1663,17 @@

                                                              File: lib/builder.js

                                                              str = str.replace(/\t/g, self.options.tabspace); } - opts.meta.fileData = str; - var view = new Y.DocView(opts.meta, 'index'); - var mainLayout = opts.layouts[layout]; - self.render('{{>files}}', view, mainLayout, opts.partials, function (err, html) { + readOpts.meta.fileData = str; + var view = new Y.DocView(readOpts.meta, 'index'); + var mainLayout = readOpts.layouts[layout]; + self.render('{{>files}}', view, mainLayout, readOpts.partials, function (renderErr, html) { + if (renderErr) { + Y.log(renderErr, 'error', 'builder'); + cb(renderErr); + return; + } self.files++; - cb(html, view, data); + cb(html, view, readData); }); }, this, opts, data)); @@ -1721,7 +1753,7 @@

                                                              File: lib/builder.js

                                                              self.makeDirs(function () { Y.log('Copying Assets', 'info', 'builder'); if (!Y.Files.isDirectory(path.join(self.options.outdir, 'assets'))) { - fs.mkdirSync(path.join(self.options.outdir, 'assets'), 0777); + fs.mkdirSync(path.join(self.options.outdir, 'assets'), '0777'); } Y.Files.copyAssets([ path.join(DEFAULT_THEME, 'assets'), diff --git a/output/api/files/lib_cli.js.html b/output/api/files/lib_cli.js.html index 9e496224..caa4a5ca 100644 --- a/output/api/files/lib_cli.js.html +++ b/output/api/files/lib_cli.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -91,6 +91,7 @@

                                                              File: lib/cli.js

                                                               #!/usr/bin/env node
                                                              +'use strict';
                                                               
                                                               /**
                                                                * Copyright (c) 2011, Yahoo! Inc. All rights reserved.
                                                              @@ -104,7 +105,6 @@ 

                                                              File: lib/cli.js

                                                              * @module yuidoc */ -/*global Y:true */ var Y = require('./index'); var options = Y.Options(Y.Array(process.argv, 2)); @@ -127,7 +127,7 @@

                                                              File: lib/cli.js

                                                              } else { var json = (new Y.YUIDoc(options)).run(); if (json === null) { - return; + throw new Error('Running YUIDoc returns null.'); } options = Y.Project.mix(json, options); diff --git a/output/api/files/lib_docparser.js.html b/output/api/files/lib_docparser.js.html index 588e723a..89cbad45 100644 --- a/output/api/files/lib_docparser.js.html +++ b/output/api/files/lib_docparser.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,6 +95,8 @@

                                                              File: lib/docparser.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ +'use strict'; + YUI.add('docparser', function (Y) { var Lang = Y.Lang, @@ -193,74 +195,74 @@

                                                              File: lib/docparser.js

                                                              * @for DocParser */ TAGLIST = [ - "async", // bool, custom events can fire the listeners in a setTimeout - "author", // author best for projects and modules, but can be used anywhere // multi - "attribute", // YUI attributes -- get/set with change notification, etc - "beta", // module maturity identifier - "broadcast", // bool, events - "bubbles", // custom events that bubble - "category", // modules can be in multiple categories - "chainable", // methods that return the host object - "class", // pseudo class - "conditional", // conditional module - "config", // a config param (not an attribute, so no change events) - "const", // not standardized yet, converts to final property - "constructs", // factory methods (not yet used) - "constructor", // this is a constructor - "contributor", // like author - "default", // property/attribute default value - "deprecated", // please specify what to use instead - "description", // can also be free text at the beginning of a comment is - "emitfacade", // bool, YUI custom event can have a dom-like event facade - "event", // YUI custom event - "evil", // uses eval - "extension", // this is an extension for [entity] - "extensionfor", // this is an extension for [entity] - "extension_for",// this is an extension for [entity] - "example", // 0..n code snippets. snippets can also be embedded in the desc - "experimental", // module maturity identifier - "extends", // pseudo inheritance - "file", // file name (used by the parser) - "final", // not meant to be changed - "fireonce", // bool, YUI custom event config allows - "for", // used to change class context - "global", // declare your globals - "icon", // project icon(s) - "in", // indicates module this lives in (obsolete now) - "initonly", // attribute writeonce value - "injects", // injects {HTML|script|CSS} - "knownissue", // 0..n known issues for your consumption - "line", // line number for the comment block (used by the parser) - "method", // a method - "module", // YUI module name - "main", // Description for the module - "namespace", // Y.namespace, used to fully qualify class names - "optional", // For optional attributes - "required", // For required attributes - "param", // member param - "plugin", // this is a plugin for [entityl] - "preventable", // YUI custom events can be preventable ala DOM events - "private", // > access - "project", // project definition, one per source tree allowed - "property", // a regular-ole property - "protected", // > access - "public", // > access - "queuable", // bool, events - "readonly", // YUI attribute config - "requires", // YUI module requirements - "return", // {type} return desc -- returns is converted to this - "see", // 0..n things to look at - "since", // when it was introduced - "static", // static - "submodule", // YUI submodule - "throws", // {execption type} description - "title", // this should be something for the project description - "todo", // 0..n things to revisit eventually (hopefully) - "type", // the var type - "url", // project url(s) - "uses", // 0..n compents mixed (usually, via augment) into the prototype - "value", // the value of a constant - "writeonce" // YUI attribute config + 'async', // bool, custom events can fire the listeners in a setTimeout + 'author', // author best for projects and modules, but can be used anywhere // multi + 'attribute', // YUI attributes -- get/set with change notification, etc + 'beta', // module maturity identifier + 'broadcast', // bool, events + 'bubbles', // custom events that bubble + 'category', // modules can be in multiple categories + 'chainable', // methods that return the host object + 'class', // pseudo class + 'conditional', // conditional module + 'config', // a config param (not an attribute, so no change events) + 'const', // not standardized yet, converts to final property + 'constructs', // factory methods (not yet used) + 'constructor', // this is a constructor + 'contributor', // like author + 'default', // property/attribute default value + 'deprecated', // please specify what to use instead + 'description', // can also be free text at the beginning of a comment is + 'emitfacade', // bool, YUI custom event can have a dom-like event facade + 'event', // YUI custom event + 'evil', // uses eval + 'extension', // this is an extension for [entity] + 'extensionfor', // this is an extension for [entity] + 'extension_for',// this is an extension for [entity] + 'example', // 0..n code snippets. snippets can also be embedded in the desc + 'experimental', // module maturity identifier + 'extends', // pseudo inheritance + 'file', // file name (used by the parser) + 'final', // not meant to be changed + 'fireonce', // bool, YUI custom event config allows + 'for', // used to change class context + 'global', // declare your globals + 'icon', // project icon(s) + 'in', // indicates module this lives in (obsolete now) + 'initonly', // attribute writeonce value + 'injects', // injects {HTML|script|CSS} + 'knownissue', // 0..n known issues for your consumption + 'line', // line number for the comment block (used by the parser) + 'method', // a method + 'module', // YUI module name + 'main', // Description for the module + 'namespace', // Y.namespace, used to fully qualify class names + 'optional', // For optional attributes + 'required', // For required attributes + 'param', // member param + 'plugin', // this is a plugin for [entityl] + 'preventable', // YUI custom events can be preventable ala DOM events + 'private', // > access + 'project', // project definition, one per source tree allowed + 'property', // a regular-ole property + 'protected', // > access + 'public', // > access + 'queuable', // bool, events + 'readonly', // YUI attribute config + 'requires', // YUI module requirements + 'return', // {type} return desc -- returns is converted to this + 'see', // 0..n things to look at + 'since', // when it was introduced + 'static', // static + 'submodule', // YUI submodule + 'throws', // {execption type} description + 'title', // this should be something for the project description + 'todo', // 0..n things to revisit eventually (hopefully) + 'type', // the var type + 'url', // project url(s) + 'uses', // 0..n compents mixed (usually, via augment) into the prototype + 'value', // the value of a constant + 'writeonce' // YUI attribute config ], /** @@ -272,7 +274,7 @@

                                                              File: lib/docparser.js

                                                              * @for DocParser */ IGNORE_TAGLIST = [ - "media" + 'media' ], /** @@ -482,7 +484,7 @@

                                                              File: lib/docparser.js

                                                              // @returns {type} description // methods // @injects {HTML|CSS|script} description // can be used by anthing that has an optional {type} and a description - 'return': function (tagname, value, target, block) { + 'return': function (tagname, value, target) { var desc = implodeString(trim(value)), type, @@ -511,7 +513,7 @@

                                                              File: lib/docparser.js

                                                              'injects': 'return', // trying to overwrite the constructor value is a bad idea - 'constructor': function (tagname, value, target, block) { + 'constructor': function (tagname, value, target) { target.is_constructor = 1; }, @@ -549,7 +551,7 @@

                                                              File: lib/docparser.js

                                                              }, //Setting the description for the module.. - 'main': function (tagname, value, target, block) { + 'main': function (tagname, value, target) { var o = target; o.mainName = value; o.tag = tagname; @@ -559,13 +561,13 @@

                                                              File: lib/docparser.js

                                                              }, // accepts a single project definition for the source tree - 'project': function (tagname, value, target, block) { + 'project': function () { return this.project; }, // A key bock type for declaring submodules. subsequent class and // member blocks will be assigned to this submodule. - 'submodule': function (tagname, value, target, block) { + 'submodule': function (tagname, value) { //console.log('Setting current submodule: ', value, 'on class'); this.set(CURRENT_SUBMODULE, value); var host = this.modules[value], @@ -629,11 +631,10 @@

                                                              File: lib/docparser.js

                                                              }, // change 'const' to final property - 'const': function (tagname, value, target, block) { + 'const': function (tagname, value, target) { target.itemtype = 'property'; target.name = value; - /*jshint sub:true */ - target['final'] = ''; + target.final = ''; }, // supported classitems @@ -671,7 +672,7 @@

                                                              File: lib/docparser.js

                                                              'event': 'property', // access fields - 'public': function (tagname, value, target, block) { + 'public': function (tagname, value, target) { target.access = tagname; target.tagname = value; }, @@ -680,7 +681,7 @@

                                                              File: lib/docparser.js

                                                              'inner': 'public', // tags that can have multiple occurances in a single block - 'todo': function (tagname, value, target, block) { + 'todo': function (tagname, value, target) { if (!Lang.isArray(target[tagname])) { target[tagname] = []; } @@ -697,7 +698,7 @@

                                                              File: lib/docparser.js

                                                              }); }, 'extension_for': 'extensionfor', - 'extensionfor': function (tagname, value, target, block) { + 'extensionfor': function (tagname, value) { if (this.classes[this.get(CURRENT_CLASS)]) { this.classes[this.get(CURRENT_CLASS)].extension_for.push(value); } @@ -727,7 +728,7 @@

                                                              File: lib/docparser.js

                                                              'category': 'todo', 'unimplemented': 'todo', - genericValueTag: function (tagname, value, target, block) { + genericValueTag: function (tagname, value, target) { target[tagname] = value; }, @@ -735,7 +736,7 @@

                                                              File: lib/docparser.js

                                                              'contributor': 'genericValueTag', 'since': 'genericValueTag', - 'deprecated': function (tagname, value, target, block) { + 'deprecated': function (tagname, value, target) { target.deprecated = true; if (typeof value === 'string' && value.length) { @@ -744,7 +745,7 @@

                                                              File: lib/docparser.js

                                                              }, // updates the current namespace - 'namespace': function (tagname, value, target, block) { + 'namespace': function (tagname, value) { this.set(CURRENT_NAMESPACE, value); if (value === '') { //Shortcut this if namespace is an empty string. @@ -812,7 +813,7 @@

                                                              File: lib/docparser.js

                                                              // updates the current class only (doesn't create // a new class definition) - 'for': function (tagname, value, target, block) { + 'for': function (tagname, value) { var ns, file, mod; value = this._resolveFor(value); @@ -848,7 +849,7 @@

                                                              File: lib/docparser.js

                                                              * @param {Object} o the config object * @module yuidoc */ - DocParser = function (o) { + DocParser = function () { this.digesters = Y.merge(DocParser.DIGESTERS); this.knowntags = Y.Array.hash(DocParser.TAGLIST); DocParser.superclass.constructor.apply(this, arguments); @@ -1007,7 +1008,7 @@

                                                              File: lib/docparser.js

                                                              clazz = this.classes[this.get(CURRENT_CLASS)]; if (clazz) { - //Handles case where @module comes after @class in a new directory of files + //Handles case where @module comes after @class in a new directory of files if (clazz.module !== val) { if (this.modules[clazz.module]) { delete this.modules[clazz.module].submodules[clazz.submodule]; @@ -1146,7 +1147,7 @@

                                                              File: lib/docparser.js

                                                              this.warnings = []; var self = this; - self.after('currentfileChange', function (e) { + self.after('currentfileChange', function () { /* * File changed, so we reset class and submodule. * You should use @for if you want to reference another class @@ -1168,16 +1169,12 @@

                                                              File: lib/docparser.js

                                                              self.after('currentsubmoduleChange', function (e) { var mod = e.newVal, - classes = self.classes, - parent; + classes = self.classes; if (mod) { - parent = self.modules[mod].module; Y.each(classes, function (clazz) { if (!(clazz.submodule)) { - //if ((!clazz.module) || clazz.module == parent) { if (!clazz.module) { - //console.log('Adding Submodule: ', mod, ' to', clazz.module, 'with parent', parent); clazz.submodule = mod; } } @@ -1188,8 +1185,8 @@

                                                              File: lib/docparser.js

                                                              self.after('currentclassChange', function (e) { var clazz = e.newVal; Y.each(self.classitems, function (item) { - if (!(item["class"])) { - item["class"] = clazz; + if (!(item.class)) { + item.class = clazz; } }); // Y.log(self.classitems); @@ -1408,7 +1405,7 @@

                                                              File: lib/docparser.js

                                                              Y.mix(host, target); } else { this.classitems.push(target); - target['class'] = this.get(CURRENT_CLASS); + target.class = this.get(CURRENT_CLASS); target.module = this.get(CURRENT_MODULE); host = this.get(CURRENT_SUBMODULE); diff --git a/output/api/files/lib_docview.js.html b/output/api/files/lib_docview.js.html index 66acc4d1..3bc7c5fb 100644 --- a/output/api/files/lib_docview.js.html +++ b/output/api/files/lib_docview.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,6 +95,8 @@

                                                              File: lib/docview.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ +'use strict'; + YUI.add('docview', function (Y) { /* @@ -104,7 +106,7 @@

                                                              File: lib/docview.js

                                                              */ /** - View class borrowed from [Selleck](https://github.com/rgrove/selleck) + View class borrowed from [Selleck](https://github.com/rgrove/selleck) The view class is a **`handlebars`** template helper. @class DocView @constructor diff --git a/output/api/files/lib_files.js.html b/output/api/files/lib_files.js.html index c85cb2a5..c2363353 100644 --- a/output/api/files/lib_files.js.html +++ b/output/api/files/lib_files.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,6 +95,8 @@

                                                              File: lib/files.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ +'use strict'; + YUI.add('files', function (Y) { /** @@ -111,9 +113,9 @@

                                                              File: lib/files.js

                                                              Licensed under the BSD License. */ - var fs = require('graceful-fs'), - fsPath = require('path'), - useFS = (fs.exists) ? fs : fsPath; + var fs = require('graceful-fs'); + var fsPath = require('path'); + var useFS = (fs.exists) ? fs : fsPath; function exists(file, cb) { @@ -150,7 +152,7 @@

                                                              File: lib/files.js

                                                              } if (!stats.isDirectory()) { - return callback(new Error("Source is not a directory: " + source)); + return callback(new Error('Source is not a directory: ' + source)); } fs.lstat(dest, afterDestStat); @@ -162,20 +164,20 @@

                                                              File: lib/files.js

                                                              } if (stats) { - // If the destination is a file or a link, either delete it or + // If the destination is a file or a link, either delete it or // bubble an error if overwrite isn't true. if (stats.isFile() || stats.isSymbolicLink()) { if (overwrite) { deletePath(dest); // TODO: make this async } else { - callback(new Error("Destination already exists: " + dest)); - return; + callback(new Error('Destination already exists: ' + dest)); + return undefined; } } afterMkDir(); } else { - fs.mkdir(dest, 0755, afterMkDir); + fs.mkdir(dest, '0755', afterMkDir); } } @@ -199,10 +201,9 @@

                                                              File: lib/files.js

                                                              } while ((filename = files.shift())) { - /*jshint loopfunc:true */ - copyPath(fsPath.join(source, filename), fsPath.join(dest, filename), overwrite, function (err) { - if (err) { - return callback(err); + copyPath(fsPath.join(source, filename), fsPath.join(dest, filename), overwrite, function (copyPathErr) { + if (copyPathErr) { + return callback(copyPathErr); } pending -= 1; @@ -239,28 +240,28 @@

                                                              File: lib/files.js

                                                              } if (!sourceStats.isFile()) { - return callback(new Error("Source is not a file: " + source)); + return callback(new Error('Source is not a file: ' + source)); } - fs.lstat(dest, function (err, destStats) { + fs.lstat(dest, function (destStatsErr, destStats) { var rs; - if (err && err.code !== 'ENOENT') { - return callback(err); + if (destStatsErr && destStatsErr.code !== 'ENOENT') { + return callback(destStatsErr); } if (destStats) { if (overwrite) { deletePath(dest); // TODO: make this async } else { - callback(new Error("Destination already exists: " + dest)); - return; + callback(new Error('Destination already exists: ' + dest)); + return undefined; } } rs = fs.createReadStream(source); rs.pipe(fs.createWriteStream(dest, { - mode: 0655 + mode: '0655' })); rs.on('end', callback); }); @@ -299,7 +300,7 @@

                                                              File: lib/files.js

                                                              } if (!sourceStats) { - callback(new Error("Source not found: " + source)); + callback(new Error('Source not found: ' + source)); return; } @@ -308,7 +309,7 @@

                                                              File: lib/files.js

                                                              } else if (sourceStats.isDirectory()) { copyDirectory(source, dest, overwrite, callback); } else { - callback(new Error("Source is neither a file nor a directory: " + source)); + callback(new Error('Source is neither a file nor a directory: ' + source)); } } Y.Files.copyPath = copyPath; @@ -532,9 +533,9 @@

                                                              File: lib/files.js

                                                              var out, args = arguments, flags = { - flags: "w", + flags: 'w', encoding: Y.charset, - mode: 0644 + mode: '0644' }; if (cb) { diff --git a/output/api/files/lib_help.js.html b/output/api/files/lib_help.js.html index b16dab51..a8f410a9 100644 --- a/output/api/files/lib_help.js.html +++ b/output/api/files/lib_help.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,6 +95,8 @@

                                                              File: lib/help.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ +'use strict'; + YUI.add('help', function (Y) { /** @@ -110,44 +112,44 @@

                                                              File: lib/help.js

                                                              * @type Array */ var help = [ - "", - "YUI Doc generates API documentation from a modified JavaDoc syntax.", - "", - "Current version ({VERSION})", - "", - "Usage: yuidoc <options> <input path>", - "", - "Common Options:", - " -c, --config, --configfile <filename> A JSON config file to provide configuration data.", - " You can also create a yuidoc.json file and place it", - " anywhere under your source tree and YUI Doc will find it", - " and use it.", - " -e, --extension <comma sep list of file extensions> The list of file extensions to parse ", - " for api documentation. (defaults to .js)", - " -x, --exclude <comma sep list of directories> Directories to exclude from parsing ", - " (defaults to '.DS_Store,.svn,CVS,.git,build_rollup_tmp,build_tmp')", - " -v, --version Show the current YUIDoc version", - " --project-version Set the doc version for the template", - " -N, --no-color Turn off terminal colors (for automation)", - " -C, --no-code Turn off code generation (don't include source files in output)", - " -n, --norecurse Do not recurse directories (default is to recurse)", - " --no-sort Do not alphabetical sorting of attributes, events, methods, and properties", - " -S, --selleck Look for Selleck component data and attach to API meta data", - " -V, --view Dump the Handlebars.js view data instead of writing template files", - " -p, --parse-only Only parse the API docs and create the JSON data, do not render templates", - " -o, --outdir <directory path> Path to put the generated files (defaults to ./out)", - " -t, --themedir <directory path> Path to a custom theme directory containing Handlebars templates", - " -H, --helpers <comma separated list of paths to files> Require these file and add Handlebars helpers. See docs for more information", - " --charset CHARSET Use this as the default charset for all file operations. Defaults to 'utf8'", - " -h, --help Show this help", - " -q, --quiet Supress logging output", - " -T, --theme <simple|default> Choose one of the built in themes (default is default)", - " --syntaxtype <js|coffee> Choose comment syntax type (default is js)", - " --server <port> Fire up the YUIDoc server for faster API doc developement. Pass optional port to listen on. (default is 3000)", - " --lint Lint your docs, will print parser warnings and exit code 1 if there are any", - "", - " <input path> Supply a list of paths (shell globbing is handy here)", - "", + '', + 'YUI Doc generates API documentation from a modified JavaDoc syntax.', + '', + 'Current version ({VERSION})', + '', + 'Usage: yuidoc <options> <input path>', + '', + 'Common Options:', + ' -c, --config, --configfile <filename> A JSON config file to provide configuration data.', + ' You can also create a yuidoc.json file and place it', + ' anywhere under your source tree and YUI Doc will find it', + ' and use it.', + ' -e, --extension <comma sep list of file extensions> The list of file extensions to parse ', + ' for api documentation. (defaults to .js)', + ' -x, --exclude <comma sep list of directories> Directories to exclude from parsing ', + ' (defaults to \'.DS_Store,.svn,CVS,.git,build_rollup_tmp,build_tmp\')', + ' -v, --version Show the current YUIDoc version', + ' --project-version Set the doc version for the template', + ' -N, --no-color Turn off terminal colors (for automation)', + ' -C, --no-code Turn off code generation (don\'t include source files in output)', + ' -n, --norecurse Do not recurse directories (default is to recurse)', + ' --no-sort Do not alphabetical sorting of attributes, events, methods, and properties', + ' -S, --selleck Look for Selleck component data and attach to API meta data', + ' -V, --view Dump the Handlebars.js view data instead of writing template files', + ' -p, --parse-only Only parse the API docs and create the JSON data, do not render templates', + ' -o, --outdir <directory path> Path to put the generated files (defaults to ./out)', + ' -t, --themedir <directory path> Path to a custom theme directory containing Handlebars templates', + ' -H, --helpers <comma separated list of paths to files> Require these file and add Handlebars helpers. See docs for more information', + ' --charset CHARSET Use this as the default charset for all file operations. Defaults to \'utf8\'', + ' -h, --help Show this help', + ' -q, --quiet Supress logging output', + ' -T, --theme <simple|default> Choose one of the built in themes (default is default)', + ' --syntaxtype <js|coffee> Choose comment syntax type (default is js)', + ' --server <port> Fire up the YUIDoc server for faster API doc developement. Pass optional port to listen on. (default is 3000)', + ' --lint Lint your docs, will print parser warnings and exit code 1 if there are any', + '', + ' <input path> Supply a list of paths (shell globbing is handy here)', + '' ].join('\n'); /** diff --git a/output/api/files/lib_index.js.html b/output/api/files/lib_index.js.html index b9507ca2..0c54f907 100644 --- a/output/api/files/lib_index.js.html +++ b/output/api/files/lib_index.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,11 +95,12 @@

                                                              File: lib/index.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ -/*global YUI:true, Y:true */ +'use strict'; + /** Module creates the YUI instance with the required modules, uses them and exports the **Y** to be used -by the _CLI class_ or by extenders: `require('yuidocjs');` -You can use it like this: +by the _CLI class_ or by extenders: `require('yuidocjs');` +You can use it like this: var options = { paths: [ './lib' ], @@ -123,10 +124,10 @@

                                                              File: lib/index.js

                                                              } }); -var YUI = require('yui' + (debug ? '/debug' : '')).YUI, - path = require('path'), - fs = require('graceful-fs'), - metaPath = path.join(__dirname, '../', 'package.json'); +var YUI = require('yui' + (debug ? '/debug' : '')).YUI; +var path = require('path'); +var fs = require('graceful-fs'); +var metaPath = path.join(__dirname, '../', 'package.json'); function log (message, level) { if (!message || !level || typeof console[level] !== 'function') { diff --git a/output/api/files/lib_options.js.html b/output/api/files/lib_options.js.html index 577ee987..2553f693 100644 --- a/output/api/files/lib_options.js.html +++ b/output/api/files/lib_options.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,6 +95,8 @@

                                                              File: lib/options.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ +'use strict'; + YUI.add('options', function (Y) { var path = require('path'); @@ -127,75 +129,75 @@

                                                              File: lib/options.js

                                                              options.writeJSON = false; options.quiet = true; break; - case "--debug": + case '--debug': Y.applyConfig({ debug: true, filter: 'debug' }); break; - case "--charset": + case '--charset': Y.charset = args.shift() || 'utf8'; Y.log('Setting default charset to ' + Y.charset, 'yuidoc', 'warn'); break; - case "-c": - case "--config": - case "--configfile": + case '-c': + case '--config': + case '--configfile': options.configfile = args.shift(); break; - case "-e": - case "--extension": + case '-e': + case '--extension': options.extension = args.shift(); break; - case "-x": - case "--exclude": + case '-x': + case '--exclude': options.exclude = args.shift(); break; - case "-v": - case "--version": + case '-v': + case '--version': console.error(Y.packageInfo.version); process.exit(1); break; - case "--project-version": + case '--project-version': options.version = args.shift(); break; - case "-N": - case "--no-color": + case '-N': + case '--no-color': Y.config.useColor = false; options.nocolor = true; break; - case "-D": - case "--no-delete-out": + case '-D': + case '--no-delete-out': options.nodeleteout = true; break; - case "-C": - case "--no-code": + case '-C': + case '--no-code': options.nocode = true; break; - case "-n": - case "--norecurse": + case '-n': + case '--norecurse': options.norecurse = true; break; - case "-S": - case "--selleck": + case '-S': + case '--selleck': options.selleck = true; break; - case "-V": - case "--view": + case '-V': + case '--view': options.dumpview = true; break; - case "-p": - case "--parse-only": + case '-p': + case '--parse-only': options.parseOnly = true; break; - case "-o": - case "--outdir": + case '-o': + case '--outdir': options.outdir = args.shift(); break; - case "-t": - case "--themedir": + case '-t': + case '--themedir': options.themedir = args.shift(); break; - case "--server": + case '--server': options.server = true; var a = args.shift(); var p = parseInt(a, 10); @@ -208,12 +210,12 @@

                                                              File: lib/options.js

                                                              options.port = p; } break; - case "-h": - case "--help": + case '-h': + case '--help': Y.showHelp(); break; - case "-H": - case "--helpers": + case '-H': + case '--helpers': var list = args.shift(); if (list) { options.helpers = list.split(','); @@ -221,19 +223,19 @@

                                                              File: lib/options.js

                                                              throw ('Failed to pass a helper file.'); } break; - case "-T": - case "--theme": + case '-T': + case '--theme': var theme = args.shift(); options.themedir = path.join(__dirname, '../', 'themes', theme); break; - case "-q": - case "--quiet": + case '-q': + case '--quiet': options.quiet = true; break; - case "--syntaxtype": + case '--syntaxtype': options.syntaxtype = args.shift(); break; - case "--tab-to-space": + case '--tab-to-space': options.tabtospace = parseInt(args.shift(), 10); if (typeof options.tabtospace === 'number') { options.tabspace = ''; @@ -242,7 +244,7 @@

                                                              File: lib/options.js

                                                              } } break; - case "--no-sort": + case '--no-sort': options.dontsortfields = true; break; default: diff --git a/output/api/files/lib_project.js.html b/output/api/files/lib_project.js.html index b2d9f395..44064c8b 100644 --- a/output/api/files/lib_project.js.html +++ b/output/api/files/lib_project.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,6 +95,8 @@

                                                              File: lib/project.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ +'use strict'; + YUI.add('project', function (Y) { Y.Project = { diff --git a/output/api/files/lib_server.js.html b/output/api/files/lib_server.js.html index b04325ea..caf96eec 100644 --- a/output/api/files/lib_server.js.html +++ b/output/api/files/lib_server.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,233 +95,235 @@

                                                              File: lib/server.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ +'use strict'; + +var path = require('path'); +var express = require('express'); + YUI.add('server', function (Y) { - var path = require('path'), + /** + * Provides the `--server` server option for YUIDoc + * @class Server + * @module yuidoc + */ + var Server = { /** - * Provides the `--server` server option for YUIDoc - * @class Server - * @module yuidoc + * Cache for external mixed in data. + * @property _externalData + * @private + * @type Object */ - Server = { - /** - * Cache for external mixed in data. - * @property _externalData - * @private - * @type Object - */ - _externalData: null, - /** - * Middleware to parse the API docs per request - * @method parse - * @param {Request} req Express request object - * @param {Response} res Express response object - * @param {Function} next Express next callback - */ - parse: function (req, res, next) { - var json = (new Y.YUIDoc(Server.options)).run(); - Server.options = Y.Project.mix(json, Server.options); - Server.builder = new Y.DocBuilder(Server.options, json); - if (Server._externalData) { - Server.options.externalData = Server._externalData; - Server.builder._mixExternal(); - } + _externalData: null, + /** + * Middleware to parse the API docs per request + * @method parse + * @param {Request} req Express request object + * @param {Response} res Express response object + * @param {Function} next Express next callback + */ + parse: function (req, res, next) { + var json = (new Y.YUIDoc(Server.options)).run(); + Server.options = Y.Project.mix(json, Server.options); + Server.builder = new Y.DocBuilder(Server.options, json); + if (Server._externalData) { + Server.options.externalData = Server._externalData; + Server.builder._mixExternal(); + } - next(); - }, - /** - * Create the routes used to serve YUIDoc files dynamically - * @method routes - */ - routes: function () { - var app = Server.app; - - app.get('/', Server.parse, function (req, res) { - Server.home(req, res); - }); - app.get('/api.js', function (req, res) { - Server.builder.renderAPIMeta(function (js) { - res.contentType('.js'); - res.send(js); - }); + next(); + }, + /** + * Create the routes used to serve YUIDoc files dynamically + * @method routes + */ + routes: function () { + var app = Server.app; + + app.get('/', Server.parse, function (req, res) { + Server.home(req, res); + }); + app.get('/api.js', function (req, res) { + Server.builder.renderAPIMeta(function (js) { + res.contentType('.js'); + res.send(js); }); + }); - app.get('/classes/:class.html', Server.parse, function (req, res, next) { - Server.clazz(req, res, next); - }); + app.get('/classes/:class.html', Server.parse, function (req, res, next) { + Server.clazz(req, res, next); + }); - app.get('/modules/:module.html', Server.parse, function (req, res, next) { - Server.module(req, res, next); - }); + app.get('/modules/:module.html', Server.parse, function (req, res, next) { + Server.module(req, res, next); + }); - app.get('/files/:file.html', Server.parse, function (req, res, next) { - Server.files(req, res, next); - }); + app.get('/files/:file.html', Server.parse, function (req, res, next) { + Server.files(req, res, next); + }); - //These routes are special catch routes.. + //These routes are special catch routes.. - app.get('//api.js', function (req, res) { - res.redirect('/api.js'); - }); - app.get('//classes/:class.html', Server.parse, function (req, res, next) { - Server.clazz(req, res, next); - }); + app.get('//api.js', function (req, res) { + res.redirect('/api.js'); + }); + app.get('//classes/:class.html', Server.parse, function (req, res, next) { + Server.clazz(req, res, next); + }); - app.get('//modules/:module.html', Server.parse, function (req, res, next) { - Server.module(req, res, next); - }); + app.get('//modules/:module.html', Server.parse, function (req, res, next) { + Server.module(req, res, next); + }); - app.get('//files/:file.html', Server.parse, function (req, res, next) { - Server.files(req, res, next); - }); + app.get('//files/:file.html', Server.parse, function (req, res, next) { + Server.files(req, res, next); + }); - app.get('*', function (req, res) { - var type = req.url.split('/')[1], - html = ['<h1>Item Not Found in internal meta-data</h1>']; + app.get('*', function (req, res) { + var type = req.url.split('/')[1], + html = ['<h1>Item Not Found in internal meta-data</h1>']; - if (type === 'class') { - type = 'classes'; - } - if (Server.builder && Server.builder.data && Server.builder.data[type]) { - if (Object.keys(Server.builder.data[type]).length) { - html.push('<p>But I know about these? Misname your module?</p>'); - html.push('<ul>'); - Object.keys(Server.builder.data[type]).forEach(function (item) { - html.push('<li><a href="../' + path.dirname(req.url) + '/' + item + '.html">' + item + '</a></li>'); - }); - html.push('</ul>'); - } + if (type === 'class') { + type = 'classes'; + } + if (Server.builder && Server.builder.data && Server.builder.data[type]) { + if (Object.keys(Server.builder.data[type]).length) { + html.push('<p>But I know about these? Misname your module?</p>'); + html.push('<ul>'); + Object.keys(Server.builder.data[type]).forEach(function (item) { + html.push('<li><a href="../' + path.dirname(req.url) + '/' + item + '.html">' + item + '</a></li>'); + }); + html.push('</ul>'); } + } - res.status(404).send(html.join('\n')); - }); + res.status(404).send(html.join('\n')); + }); - }, - /** - * `/files` endpoint - * @method files - * @param {Request} req Express request object - * @param {Response} res Express response object - */ - files: function (req, res, next) { - var fileName = req.params.file, - data; - Object.keys(Server.builder.data.files).forEach(function (file) { - if (fileName === Server.builder.filterFileName(file)) { - data = Server.builder.data.files[file]; - } - }); - - if (!data) { - return next(); + }, + /** + * `/files` endpoint + * @method files + * @param {Request} req Express request object + * @param {Response} res Express response object + */ + files: function (req, res, next) { + var fileName = req.params.file, + data; + Object.keys(Server.builder.data.files).forEach(function (file) { + if (fileName === Server.builder.filterFileName(file)) { + data = Server.builder.data.files[file]; } + }); - Y.log('Serving /files/' + data.name, 'info', 'server'); - - - Server.builder.renderFile(function (html) { - res.send(html); - }, data, (req.xhr ? 'xhr' : 'main')); - }, - /** - * `/classes` endpoint - * @method clazz - * @param {Request} req Express request object - * @param {Response} res Express response object - */ - clazz: function (req, res, next) { - var className = req.params['class']; - Y.log('Serving /classes/' + className + '.html', 'info', 'server'); - if (!Server.builder.data.classes[className]) { - return next(); - } - Server.builder.renderClass(function (html) { - res.send(html); - }, Server.builder.data.classes[className], (req.xhr ? 'xhr' : 'main')); - }, - /** - * `/modules` endpoint - * @method modules - * @param {Request} req Express request object - * @param {Response} res Express response object - */ - module: function (req, res, next) { - var modName = req.params.module; - Y.log('Serving /modules/' + modName + '.html', 'info', 'server'); - if (!Server.builder.data.modules[modName]) { - return next(); - } - Server.builder.renderModule(function (html) { - res.send(html); - }, Server.builder.data.modules[modName], (req.xhr ? 'xhr' : 'main')); - }, - /** - * `/` endpoint - * @method home - * @param {Request} req Express request object - * @param {Response} res Express response object - */ - home: function (req, res, next) { - Y.log('Serving index.html', 'info', 'server'); - Server.builder.renderIndex(function (html) { - res.send(html); - }); - }, - /** - * Creates the Express server and prep's YUI for serving - * @method init - */ - init: function () { - var express = require('express'), - path = require('path'), - stat; - - Server.app = express(); - //console.log(Server.options); - stat = Server.options.themedir || path.join(__dirname, '../', 'themes', 'default'); - Server.app.use(express.static(stat)); - Server.routes(); - Server.app.listen(Server.options.port); - - Y.log('Starting server: http:/' + '/127.0.0.1:' + Server.options.port, 'info', 'server'); - }, - /** - * Start the server with the supplied options. - * @method start - * @param {Object} options Server options - */ - start: function (options) { - options = Y.Project.init(options); - Server.options = options; - - Server.options.cacheTemplates = false; //Don't cache the Handlebars templates - Server.options.writeJSON = false; //Don't write the JSON file out - - Y.config.logExclude.yuidoc = true; - Y.config.logExclude.docparser = true; - Y.config.logExclude.builder = true; - - if (Server.options.external) { - Y.log('Fetching external data, this may take a minute', 'warn', 'server'); - var json, builder; - - json = (new Y.YUIDoc(Server.options)).run(); - Server.options = Y.Project.mix(json, Server.options); - - builder = new Y.DocBuilder(Server.options, json); - builder.mixExternal(function () { - Y.log('External data fetched, launching server..', 'info', 'server'); - Server._externalData = builder.options.externalData; - Server.init(); - }); - - } else { + if (!data) { + return next(); + } + + Y.log('Serving /files/' + data.name, 'info', 'server'); + + + Server.builder.renderFile(function (html) { + res.send(html); + }, data, (req.xhr ? 'xhr' : 'main')); + }, + /** + * `/classes` endpoint + * @method clazz + * @param {Request} req Express request object + * @param {Response} res Express response object + */ + clazz: function (req, res, next) { + var className = req.params.class; + Y.log('Serving /classes/' + className + '.html', 'info', 'server'); + if (!Server.builder.data.classes[className]) { + return next(); + } + Server.builder.renderClass(function (html) { + res.send(html); + }, Server.builder.data.classes[className], (req.xhr ? 'xhr' : 'main')); + }, + /** + * `/modules` endpoint + * @method modules + * @param {Request} req Express request object + * @param {Response} res Express response object + */ + module: function (req, res, next) { + var modName = req.params.module; + Y.log('Serving /modules/' + modName + '.html', 'info', 'server'); + if (!Server.builder.data.modules[modName]) { + return next(); + } + Server.builder.renderModule(function (html) { + res.send(html); + }, Server.builder.data.modules[modName], (req.xhr ? 'xhr' : 'main')); + }, + /** + * `/` endpoint + * @method home + * @param {Request} req Express request object + * @param {Response} res Express response object + */ + home: function (req, res) { + Y.log('Serving index.html', 'info', 'server'); + Server.builder.renderIndex(function (html) { + res.send(html); + }); + }, + /** + * Creates the Express server and prep's YUI for serving + * @method init + */ + init: function () { + var stat; + + Server.app = express(); + //console.log(Server.options); + stat = Server.options.themedir || path.join(__dirname, '../', 'themes', 'default'); + Server.app.use(express.static(stat)); + Server.routes(); + Server.app.listen(Server.options.port); + + Y.log('Starting server: http:/' + '/127.0.0.1:' + Server.options.port, 'info', 'server'); + }, + /** + * Start the server with the supplied options. + * @method start + * @param {Object} options Server options + */ + start: function (options) { + options = Y.Project.init(options); + Server.options = options; + + Server.options.cacheTemplates = false; //Don't cache the Handlebars templates + Server.options.writeJSON = false; //Don't write the JSON file out + + Y.config.logExclude.yuidoc = true; + Y.config.logExclude.docparser = true; + Y.config.logExclude.builder = true; + + if (Server.options.external) { + Y.log('Fetching external data, this may take a minute', 'warn', 'server'); + var json, builder; + + json = (new Y.YUIDoc(Server.options)).run(); + Server.options = Y.Project.mix(json, Server.options); + + builder = new Y.DocBuilder(Server.options, json); + builder.mixExternal(function () { + Y.log('External data fetched, launching server..', 'info', 'server'); + Server._externalData = builder.options.externalData; Server.init(); - } + }); + + } else { + Server.init(); } - }; + } + }; Y.Server = Server; }); diff --git a/output/api/files/lib_utils.js.html b/output/api/files/lib_utils.js.html index 1101dcf8..52b306c0 100644 --- a/output/api/files/lib_utils.js.html +++ b/output/api/files/lib_utils.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                              @@ -95,7 +95,10 @@

                                                              File: lib/utils.js

                                                              * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ +'use strict'; + var path = require('path'), + glob = require('glob'), minimatch = require('minimatch'), fs = require('graceful-fs'); @@ -114,7 +117,7 @@

                                                              File: lib/utils.js

                                                              '<': '&lt;', '>': '&gt;', '"': '&quot;', - "'": '&#x27;', + '\'': '&#x27;', '/': '&#x2F;', '`': '&#x60;' }; @@ -317,18 +320,17 @@

                                                              File: lib/utils.js

                                                              /** * Walk the directory tree to locate the yuidoc.json file. * @method getProjectData - * @param {Path} [dir=process.cwd()] The directory to start from + * @param {Path} [directory=process.cwd()] The directory to start from */ - var getProjectData = function (dir) { - var dirs = [dir || process.cwd()]; + var getProjectData = function (directory) { + var dirs = [directory || process.cwd()]; var projectData, packageData; var dirCount = 0; - // keep looping until + // keep looping until // * data is found // * there are no more dirs to process // * we abort due to failsafe while (dirs.length && !projectData) { - /*jshint loopfunc:true */ if (dirCount++ > 5000) { Y.log('Scanned ' + dirCount + ' directories looking for a yuidoc.json file, something is probably wrong here..', 'error', 'yuidoc'); process.exit(1); @@ -427,117 +429,23 @@

                                                              File: lib/utils.js

                                                              Y.getProjectData = getProjectData; - - /** - * Walks the tree from this dir and returns all the subdirs - * @method getDirs - * @param {String} dir The dir to begin at - * @return {Array} The array of directories.. - */ - var getDirs = function (dir) { - var dirs = fs.readdirSync(dir), - paths = []; - - dirs.forEach(function (d) { - var _dir = path.join(dir, d), - stat = fs.lstatSync(_dir); - - if (stat.isDirectory()) { - if (_dir.indexOf('.') !== 0) { - paths = [].concat(paths, _dir, getDirs(_dir)); - } - } - }); - - return paths; - }; - - Y.getDirs = getDirs; - /** - * Make sure all the paths passed are directories and that they are not in the ignore list. + * globpaths and ignore are both arrays of globs or a globstring. They should resolve to the actual files + * you want yuidoc to parse. * @method validatePaths - * @param {Array} paths The array of paths to validate - * @param {String} [ignore=false] A string to call `.indexOf` on a path to determine if it should be ignored + * @param {Array} globpaths The array of globs to expand and validate + * @param {String} [ignore=false] array of globs to expand and filter paths array by */ - var validatePaths = function (paths, ignore) { - var newpaths = []; - //Shortcut the *, . & ./ shortcuts that shall globbing fixes for us - if (paths === '*' || paths === '.' || paths === './') { - paths = [process.cwd()]; - } - - // Ensure that we always have an array of some kind. - paths = paths || []; - if (!Y.Lang.isArray(paths)) { - paths = [paths]; - } - paths.forEach(function (path) { - var glob = path || ''; - - if (process.platform === 'win32') { - glob = path.replace(/\//g, '\\\\'); - } - - var glob_paths = getDirs('.'), - is_globbed = false; - - glob_paths.forEach(function (dir) { - //Don't scan things in node_modules - if (dir.indexOf('node_modules') > -1) { - return; - } - if (minimatch(dir, glob, { - period: true - })) { - newpaths.push(dir); - is_globbed = true; - } + var validatePaths = function(globpaths, ignore) { + ignore = [].concat(ignore || []); + return [].concat(globpaths || process.cwd()) + .reduce(function(filepaths, globpath){ return filepaths.concat(glob.sync(globpath)); }, []) + .filter(function(filepath){ + return !ignore.filter(function(ignoreGlob){ return minimatch(filepath, ignoreGlob); }).length; + }) + .filter(function(filepath, i, filepaths){ + return !filepaths.slice(i + 1).filter(function(filepath2){ return filepath === filepath2; }).length; }); - - if (!is_globbed && (Y.Files.isDirectory(glob))) { - //If minimatch fails, check to see if it's a relative directory - // if it is, add it directly - newpaths.push(glob); - } - }); - - paths = newpaths; - paths.forEach(function (p) { - try { - if (!Y.Files.isDirectory(p)) { - throw ('Path not a directory: ' + p); - } - } catch (e) {} - }); - - if (!paths || !paths.forEach) { - throw ('Paths should be an array of paths'); - } - - if (ignore) { - if (!(ignore instanceof Array)) { - ignore = [ignore]; - } - var p = [], - shouldIgnore = false; - - paths.forEach(function (v) { - shouldIgnore = false; - ignore.forEach(function (i) { - if (!shouldIgnore && v.indexOf(i) !== -1) { - shouldIgnore = true; - } - }); - if (!shouldIgnore) { - p.push(v); - } - }); - paths = p; - } - - paths = paths.sort(); - return paths; }; Y.validatePaths = validatePaths; @@ -574,7 +482,7 @@

                                                              File: lib/utils.js

                                                              * @param {Array|String*} url the list of parts to be joined and normalized * @return {String} The joined and normalized url **/ - function webpath(url) { + function webpath() { var args = [].concat.apply([], arguments), parts = path.join.apply(path, args).split(/[\\\/]/); return parts.join('/'); diff --git a/output/api/files/lib_yuidoc.js.html b/output/api/files/lib_yuidoc.js.html index 543b6d39..1533aacc 100644 --- a/output/api/files/lib_yuidoc.js.html +++ b/output/api/files/lib_yuidoc.js.html @@ -17,7 +17,7 @@

                                                              - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                          @@ -95,9 +95,11 @@

                                                          File: lib/yuidoc.js

                                                          * Code licensed under the BSD License: * https://github.com/yui/yuidoc/blob/master/LICENSE */ -var fs = require('graceful-fs'), - rimraf = require('rimraf'), - path = require('path'); +'use strict'; + +var fs = require('graceful-fs'); +var rimraf = require('rimraf'); +var path = require('path'); /** This is the __module__ description for the `YUIDoc` module. @@ -148,7 +150,7 @@

                                                          File: lib/yuidoc.js

                                                          var Y = require('yuidoc'); var json = (new Y.YUIDoc(options)).run(); - + * @class YUIDoc * @module yuidoc * @constructor @@ -176,13 +178,6 @@

                                                          File: lib/yuidoc.js

                                                          * @private */ this.filemap = {}; - /** - * Holder for the list of directories we are processing. - * @property dirmap - * @type Object - * @private - */ - this.dirmap = {}; /** * Internal holder for configuration options. @@ -228,87 +223,30 @@

                                                          File: lib/yuidoc.js

                                                          }, /** - * Walks the paths and parses the directory contents - * @method walk - * @private - */ - walk: function () { - Y.each(this.options.paths, function (dir) { - this.parsedir(dir); - }, this); - }, - - /** - * Walks the passed directory and grabs all the files recursively. - * @method parsedir - * @param {String} dir The directory to parse the contents of. - * @private - */ - parsedir: function (dir) { - if (!Y.Files.isDirectory(dir)) { - throw ('Can not find directory: ' + dir); - } - - var allfiles = fs.readdirSync(dir), - stats, - files = [], - fullpath, self = this; - - if (dir in self.options.excludes) { - return; - } - - allfiles = allfiles.sort(); - - Y.each(allfiles, function (filename) { - if (!(filename in self.options.excludes)) { - fullpath = path.join(dir, filename); - - stats = fs.statSync(fullpath); - - if (stats.isDirectory() && !self.options.norecurse) { - self.parsedir(fullpath); - } else { - files.push(filename); - } - } - }); - - if (!(dir in self.options.excludes)) { - this.parsefiles(dir, files); - } - }, - - /** - * Gathers all the file data and populates the filemap and dirmap hashes. + * Gathers all the file data and populates the filemap and. * @method parsefiles - * @param {String} dir The directory to start from. * @param {Array} files List of files to parse. * @private */ - parsefiles: function (dir, files) { + parsefiles: function (files) { var self = this; files = files.sort(); Y.each(files, function (filename) { var ext = path.extname(filename), - text, - fullpath; + text; if (ext) { if (ext in self.options.extensions) { - fullpath = path.join(dir, filename); - - if (Y.Files.exists(fullpath)) { + if (Y.Files.exists(filename)) { self.filecount++; - text = fs.readFileSync(fullpath, Y.charset); + text = fs.readFileSync(filename, Y.charset); - self.filemap[fullpath] = text.replace(/\r?\n|\r/g, '\n'); - self.dirmap[fullpath] = dir; - self.getSelleck(fullpath); + self.filemap[filename] = text.replace(/\r?\n|\r/g, '\n'); + self.getSelleck(filename); } else { - Y.log('File skipped: ' + fullpath, 'warn', 'yuidoc'); + Y.log('File skipped: ' + filename, 'warn', 'yuidoc'); } } } @@ -338,8 +276,8 @@

                                                          File: lib/yuidoc.js

                                                          }, /** - * Applies preprocessors to the data tree. - * This function first clones the data and operates on the clone. + * Applies preprocessors to the data tree. + * This function first clones the data and operates on the clone. * @method runPreprocessors * @private * @return {Object} The mutated data @@ -349,14 +287,14 @@

                                                          File: lib/yuidoc.js

                                                          preprocessors, preprocessorsRelativeTo; - // We will try to load the preprocessors as npm modules, but we will also + // We will try to load the preprocessors as npm modules, but we will also // search for them relative to the process working directory. - // The latter is consistent with how other paths are treated by yuidoc, + // The latter is consistent with how other paths are treated by yuidoc, // such as the config options 'paths' and 'outdir'. preprocessorsRelativeTo = process.cwd(); if (self.options.preprocessor) { - data=JSON.parse(JSON.stringify(data)); + data = JSON.parse(JSON.stringify(data)); preprocessors = [].concat(self.options.preprocessor); @@ -397,9 +335,9 @@

                                                          File: lib/yuidoc.js

                                                          data = this.runPreprocessors(data); if (self.selleck && self.options.selleck && data.files && data.modules) { - Object.keys(self.selleck).forEach(function (file) { + Object.keys(self.selleck).forEach(function (selleckFile) { Object.keys(data.files).forEach(function (f) { - if (file === f) { + if (selleckFile === f) { var mods = data.files[f].modules; if (mods) { Object.keys(mods).forEach(function (mod) { @@ -407,7 +345,7 @@

                                                          File: lib/yuidoc.js

                                                          if (!data.modules[mod].extra) { data.modules[mod].extra = {}; } - data.modules[mod].extra.selleck = self.selleck[file]; + data.modules[mod].extra.selleck = self.selleck[selleckFile]; } }); } @@ -432,16 +370,16 @@

                                                          File: lib/yuidoc.js

                                                          if (!Y.Files.exists(self.options.outdir)) { Y.log('Making out dir: ' + self.options.outdir, 'info', 'yuidoc'); try { - fs.mkdirSync(self.options.outdir, 0777); + fs.mkdirSync(self.options.outdir, '0777'); } catch (e) { Y.log('Outdir creation failed', 'warn', 'yuidoc'); } } out = fs.createWriteStream(file, { - flags: "w", + flags: 'w', encoding: Y.charset, - mode: 0644 + mode: '0644' }); out.write(JSON.stringify(data, null, 4)); out.end(); @@ -480,12 +418,11 @@

                                                          File: lib/yuidoc.js

                                                          this.starttime = new Date().getTime(); this._processConfig(); - this.walk(); + this.parsefiles(this.options.paths); var json = this.writeJSON(new Y.DocParser({ syntaxtype: this.options.syntaxtype, - filemap: this.filemap, - dirmap: this.dirmap + filemap: this.filemap }).parse()); if (this.options.lint) { diff --git a/output/api/index.html b/output/api/index.html index 1bd40dcc..ec82223c 100644 --- a/output/api/index.html +++ b/output/api/index.html @@ -17,7 +17,7 @@

                                                          - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                          diff --git a/output/api/modules/yuidoc.html b/output/api/modules/yuidoc.html index aa7dea32..bb24871b 100644 --- a/output/api/modules/yuidoc.html +++ b/output/api/modules/yuidoc.html @@ -17,7 +17,7 @@

                                                          - API Docs for: 0.7.0 + API Docs for: 0.8.0
                                                          @@ -91,7 +91,7 @@

                                                          yuidoc Module

                                                          - Defined in: lib/yuidoc.js:49 + Defined in: lib/yuidoc.js:51
                                                          diff --git a/output/args/index.html b/output/args/index.html index 1ceb9266..d1771ff8 100644 --- a/output/args/index.html +++ b/output/args/index.html @@ -365,7 +365,7 @@

                                                          Example: YUIDoc API

                                                          "linkNatives": "true", "attributesEmit": "true", "paths": [ - "./lib" + "lib/**" ], "outdir": "./output/api" } diff --git a/package.json b/package.json index 116adff2..3b2ad102 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "yuidocjs", - "version": "0.7.0", + "version": "0.8.0", "description": "YUIDoc, YUI's JavaScript Documentation engine.", "author": "Dav Glass ", "bugs": { @@ -71,6 +71,7 @@ }, "dependencies": { "express": "^4.12.3", + "glob": "^5.0.7", "graceful-fs": "2.x", "markdown-it": "^4.1.0", "minimatch": "^2.0.1", @@ -108,7 +109,7 @@ "linkNatives": "true", "attributesEmit": "true", "paths": [ - "./lib" + "lib/**" ], "outdir": "./output/api" }