/** * macro rendering a skin * @param name name of skin */ function skin_macro(par) { if ( par && par.name ) { this.renderSkin(par.name); } } /** * macro-wrapper for href-function * @param action name of action to call on this prototype, default main */ function href_macro(par) { return this.href( (par&&par.action)?par.action:"main" ); } /** * macro rendering page head */ function head_macro(par) { var obj = new Object(); obj.path = this.getPath(); var appObj = this.getApplication(); appObj.renderSkin("head",obj); } /** * utility function for head_macro, rendering link to app and to prototype */ function getPath() { var protoObj = this.getDocPrototype(); var str = protoObj.getPath() + "/" + this.getFullName(); return( str ); } /** * macro returning name of file this method resides in */ function location_macro(par) { var f = new File ( this.getLocation() ); return f.getName(); } /** * macro returning the type of this method (Action, Template, Skin, Macro, Function) */ function typename_macro(par) { return this.getTypeName(); } /** * macro returning a link to the prototype page * @param action name of action to call on this prototype, default main */ function prototypehref_macro(par) { return this.getDocPrototype().href( (par&&par.action)?par.action:"main" ) } /** * macro returning the name of the prototype this method belongs to */ function prototypename_macro(par) { return this.getDocPrototype().getName(); } /** * macro returning the comment text of this method * (excluding the tags!) * @param size (optional) text is cutoff after a number of chars */ function comment_macro(par) { var str = this.getComment(); if ( par && par.length && str.length > par.size ) { return ( str.substring(0,par.size) ); } else { return ( str ); } } /** * macro rendering the list of tags */ function tags_macro() { var arr = this.listTags(); var argCt = 0; for ( var i in arr ) { if ( arr[i].getKind()==Packages.helma.doc.DocTag.ARG ) argCt++; res.write( arr[i].render(argCt,this) ); } } /** * macro rendering sequence of arg1, arg2 etc * according to number of arguments in doctags. */ function args_macro() { var ct = this.countTags(Packages.helma.doc.DocTag.ARG); for ( var i=0; i"); var str4 = ""; for ( var i=0; i ' if ( i<100 ) str4+=' '; str4 += arr[i] + "
"; } return ( str4 ); } /** * macro returning the fullname of this method */ function fullname_macro(par) { return this.getFullName(); }