Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
J
jsduck
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
extjs
jsduck
Commits
3bfd2949
Commit
3bfd2949
authored
14 years ago
by
Rene Saarsoo
Browse files
Options
Downloads
Patches
Plain Diff
Replaced JsDuck with self in static method names.
parent
c0a0acf9
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lib/jsduck.rb
+6
-6
6 additions, 6 deletions
lib/jsduck.rb
with
6 additions
and
6 deletions
lib/jsduck.rb
+
6
−
6
View file @
3bfd2949
...
...
@@ -14,7 +14,7 @@ require 'fileutils'
require
'pp'
module
JsDuck
def
JsDuck
.
parse
(
input
)
def
self
.
parse
(
input
)
doc_parser
=
DocParser
.
new
merger
=
Merger
.
new
documentation
=
[]
...
...
@@ -38,7 +38,7 @@ module JsDuck
# Given array of filenames, parses all files and returns array of
# documented items in all of those files.
def
JsDuck
.
parse_files
(
filenames
,
verbose
)
def
self
.
parse_files
(
filenames
,
verbose
)
docs
=
[]
filenames
.
each
do
|
name
|
puts
"Parsing
#{
name
}
..."
if
verbose
...
...
@@ -49,7 +49,7 @@ module JsDuck
# Filters out class-documentations, converting them to Class objects.
# For each other type, prints a warning message and discards it
def
JsDuck
.
filter_classes
(
docs
)
def
self
.
filter_classes
(
docs
)
classes
=
[]
docs
.
each
do
|
d
|
if
d
[
:tagname
]
==
:class
...
...
@@ -61,7 +61,7 @@ module JsDuck
classes
end
def
JsDuck
.
print_debug
(
docs
)
def
self
.
print_debug
(
docs
)
docs
.
each
do
|
doc
|
puts
(
doc
[
:name
]
||
"?"
)
+
":"
if
doc
[
:tagname
]
==
:class
...
...
@@ -76,14 +76,14 @@ module JsDuck
# Given array of doc-objects, generates namespace tree and writes in
# in JSON form into a file.
def
JsDuck
.
write_tree
(
filename
,
docs
)
def
self
.
write_tree
(
filename
,
docs
)
js
=
"Docs.classData = "
+
JSON
.
generate
(
Tree
.
new
.
create
(
docs
)
)
+
";"
js
+=
"Docs.icons = {};"
File
.
open
(
filename
,
'w'
)
{
|
f
|
f
.
write
(
js
)
}
end
# Writes documentation page for each class
def
JsDuck
.
write_pages
(
path
,
docs
,
verbose
)
def
self
.
write_pages
(
path
,
docs
,
verbose
)
docs
.
each
do
|
cls
|
filename
=
path
+
"/"
+
cls
[
:name
]
+
".html"
puts
"Writing to
#{
filename
}
..."
if
verbose
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment