paste.chapril.org-privatebin/jsdoc_toolkit-2.3.3-beta/app/test/prototype_oblit_constructor.js
2010-05-26 15:34:42 -07:00

24 lines
397 B
JavaScript

/** @constructor */
function Article() {
}
Article.prototype = {
/** @constructor */
Title: function(title) {
/** the value of the Title instance */
this.title = title;
},
init: function(pages) {
/** the value of the pages of the Article instance */
this.pages = pages;
}
}
f = new Article();
f.init("one two three");
t = new f.Title("my title");
print(f.pages);
print(t.title);