123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132 |
- <?js
- var data = obj;
- var self = this;
- ?>
- <?js if (data.kind !== 'module' && !data.hideconstructor) { ?>
- <?js if (data.kind === 'class' && data.classdesc) { ?>
- <h2>Constructor</h2>
- <?js } ?>
- <h4 class="name" id="<?js= id ?>"><?js= data.attribs ?><?js
- if(kind === 'class' && name.indexOf('module:') === 0) {
- print('new (require("' + name.slice(7) + '"))');
- } else if(kind === 'class') {
- print('new ' + name);
- } else if(kind === 'event' && data.alias) {
- print(data.alias);
- } else {
- print(name);
- }
- ?><?js= (data.signature || '') ?></h4>
- <?js if (data.summary) { ?>
- <p class="summary usertext"><?js= summary ?></p>
- <?js } ?>
- <?js } ?>
- <?js= this.partial('details.tmpl', data) ?>
- <?js if (data.augments && data.alias && data.alias.indexOf('module:') === 0) { ?>
- <h5 class="h5-extends">Extends:</h5>
- <?js= self.partial('augments.tmpl', data) ?>
- <?js } ?>
- <?js if (kind === 'event' && data.type && data.type.names) {?>
- <h5 class="h5-types">Type:</h5>
- <ul>
- <li>
- <?js= self.partial('type.tmpl', data.type.names) ?>
- </li>
- </ul>
- <?js } ?>
- <?js if (data['this']) { ?>
- <h5 class="h5-this">This:</h5>
- <ul><li><?js= this.linkto(data['this'], data['this']) ?></li></ul>
- <?js } ?>
- <?js if (data.examples && examples.length) { ?>
- <h5 class="h5-examples">Example<?js= examples.length > 1? 's':'' ?></h5>
- <?js= this.partial('examples.tmpl', examples) ?>
- <?js } ?>
- <?js if (data.params && params.length) { ?>
- <h5 class="h5-parameters">Parameters:</h5>
- <?js= this.partial('params.tmpl', params) ?>
- <?js } ?>
- <?js if (data.kind !== 'module' && data.requires && data.requires.length) { ?>
- <h5 class="h5-requires">Requires:</h5>
- <ul><?js data.requires.forEach(function(r) { ?>
- <li><?js= self.linkto(r) ?></li>
- <?js }); ?></ul>
- <?js } ?>
- <?js if (data.fires && fires.length) { ?>
- <h5 class="h5-fires">Fires:</h5>
- <ul><?js fires.forEach(function(f) { ?>
- <li><?js= self.linkto(f) ?></li>
- <?js }); ?></ul>
- <?js } ?>
- <?js if (data.listens && listens.length) { ?>
- <h5 class="h5-listens">Listens to Events:</h5>
- <ul><?js listens.forEach(function(f) { ?>
- <li><?js= self.linkto(f) ?></li>
- <?js }); ?></ul>
- <?js } ?>
- <?js if (data.listeners && listeners.length) { ?>
- <h5 class="h5-listeners">Listeners of This Event:</h5>
- <ul><?js listeners.forEach(function(f) { ?>
- <li><?js= self.linkto(f) ?></li>
- <?js }); ?></ul>
- <?js } ?>
- <?js if (data.modifies && modifies.length) {?>
- <h5 class="h5-modifies">Modifies:</h5>
- <?js if (modifies.length > 1) { ?><ul><?js
- modifies.forEach(function(m) { ?>
- <li><?js= self.partial('modifies.tmpl', m) ?></li>
- <?js });
- ?></ul><?js } else {
- modifies.forEach(function(m) { ?>
- <?js= self.partial('modifies.tmpl', m) ?>
- <?js });
- } } ?>
- <?js if (data.exceptions && exceptions.length) { ?>
- <h5 class="h5-throws">Throws:</h5>
- <?js if (exceptions.length > 1) { ?><ul><?js
- exceptions.forEach(function(r) { ?>
- <li><?js= self.partial('exceptions.tmpl', r) ?></li>
- <?js });
- ?></ul><?js } else {
- exceptions.forEach(function(r) { ?>
- <?js= self.partial('exceptions.tmpl', r) ?>
- <?js });
- } } ?>
- <?js if (data.returns && returns.length) { ?>
- <h5 class="h5-returns">Returns:</h5>
- <?js if (returns.length > 1) { ?><ul><?js
- returns.forEach(function(r) { ?>
- <li><?js= self.partial('returns.tmpl', r) ?></li>
- <?js });
- ?></ul><?js } else {
- returns.forEach(function(r) { ?>
- <?js= self.partial('returns.tmpl', r) ?>
- <?js });
- } } ?>
- <?js if (data.yields && yields.length) { ?>
- <h5 class="h5-yields">Yields:</h5>
- <?js if (yields.length > 1) { ?><ul><?js
- yields.forEach(function(r) { ?>
- <li><?js= self.partial('returns.tmpl', r) ?></li>
- <?js });
- ?></ul><?js } else {
- yields.forEach(function(r) { ?>
- <?js= self.partial('returns.tmpl', r) ?>
- <?js });
- } } ?>
|