You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

task.dvsl 10 kB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396
  1. #*
  2. * DVSL Stylesheet to format the Ant Task documentation.
  3. *#
  4. #set( $relative-path = "." )
  5. #if (false)
  6. #set( $body-bg = '#ffffff' )
  7. #set( $body-fg = '#000000' )
  8. #set( $body-link = '#525D76' )
  9. ##set( $banner-bg = '#EEEEEE')
  10. #set( $banner-fg = '#000000')
  11. #set( $sub-banner-bg = '#828DA6')
  12. #set( $sub-banner-fg = '#ffffff')
  13. ##set( $table-th-bg = '#FFEEEE')
  14. ##set( $table-td-bg = '#FFEEEE')
  15. ##set( $source-color = '#CCFFFF')
  16. #set( $table-th-bg = '#EEEEEE')
  17. #set( $table-td-bg = '#EEEEEE')
  18. #set( $banner-bg = '#a0ddf0')
  19. ##set( $banner-bg = '#525D76')
  20. ##set( $table-th-bg = '#039acc')
  21. ##set( $table-td-bg = '#a0ddf0')
  22. #set( $source-color = '#023264')
  23. #end
  24. #set( $body-bg = '#ffffff' )
  25. #set( $body-fg = '#000000' )
  26. #set( $body-link = '#525D76' )
  27. #set( $banner-bg = '#525D76')
  28. #set( $banner-fg = '#ffffff')
  29. #set( $sub-banner-bg = '#828DA6')
  30. #set( $sub-banner-fg = '#ffffff')
  31. #set( $table-th-bg = '#cccccc')
  32. #set( $table-td-bg = '#eeeeee')
  33. #set( $source-color = '#023264')
  34. #set( $source-font-size = '+0')
  35. ## Double quote for convenience
  36. #set ($qq = '"')
  37. ## Macro to output argument if test evaluates to true
  38. #macro(ifset $test $output)
  39. #if ( $test )$output#end
  40. #end
  41. #match( "task" )
  42. #set( $task_name = $attrib.name )
  43. ## Create task title with first letter in upper case
  44. #set( $task_title = "$task_name.substring(0,1).toUpperCase()$task_name.substring(1)" )
  45. <html>
  46. <head>
  47. <meta http-equiv="Content-Language" content="en-us">
  48. <title>$task_title Task</title>
  49. </head>
  50. <body bgcolor="$body-bg" text="$body-fg" link="$body-link"
  51. alink="$body-link" vlink="$body-link">
  52. <table border="0" width="100%" cellspacing="4">
  53. ## PAGE HEADER
  54. <tr>
  55. <td>
  56. ## JAKARTA LOGO
  57. <a href="http://jakarta.apache.org/">
  58. <img src="http://jakarta.apache.org/images/jakarta-logo.gif"
  59. align="left" alt="The Jakarta Project" border="0"/>
  60. </a>
  61. #if( $project.logo )
  62. #set( $alt = $project.logo )
  63. #set( $home = $project.attribute("href") )
  64. #set( $src = $project.logo.attribute( "href" ) )
  65. ## PROJECT LOGO
  66. <a href="$home">
  67. <img src="$src" align="right" alt="$alt" border="0"/>
  68. </a>
  69. #end
  70. </td>
  71. </tr>
  72. ## HEADER SEPARATOR
  73. <tr>
  74. ##<td colspan="2">
  75. <td>
  76. <hr noshade="" size="1"/>
  77. </td>
  78. </tr>
  79. <tr>
  80. <!-- RIGHT SIDE MAIN BODY -->
  81. <td valign="top" align="left">
  82. $context.applyTemplates("long-description")
  83. $context.applyTemplates("structure/attributes")
  84. $context.applyTemplates("structure/elements")
  85. </td>
  86. </tr>
  87. <!-- FOOTER SEPARATOR -->
  88. <tr>
  89. <td>
  90. <hr noshade="" size="1"/>
  91. </td>
  92. </tr>
  93. <!-- PAGE FOOTER -->
  94. <tr>
  95. <td>
  96. <div align="center"><font color="$body-link" size="-1"><em>
  97. Copyright &#169; 2000-2002, Apache Software Foundation
  98. </em></font></div>
  99. </td>
  100. </tr>
  101. </table>
  102. </body>
  103. </html>
  104. #end
  105. #*
  106. Macro to format a table heading cell
  107. *#
  108. #macro( th $text )
  109. <td bgcolor="$table-th-bg" valign="top" align="left">
  110. <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  111. <b>$text</b></font>
  112. </td>
  113. #end
  114. #*
  115. Macro to format a table body cell
  116. *#
  117. #macro( td $text )
  118. <td bgcolor="$table-td-bg" valign="top" align="left">
  119. <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  120. $text
  121. </font>
  122. </td>
  123. #end
  124. #*
  125. Macro to format a section banner
  126. *#
  127. #macro( section $anchor $name )
  128. <tr><td bgcolor="$banner-bg">
  129. <font color="$banner-fg" face="arial,helvetica.sanserif">
  130. <a name="$anchor">
  131. <strong>$name</strong></a></font>
  132. </td></tr>
  133. #end
  134. #*
  135. Macro to format a subsection banner
  136. *#
  137. #macro( subsection $anchor $name )
  138. <tr><td bgcolor="$sub-banner-bg">
  139. <font color="$sub-banner-fg" face="arial,helvetica.sanserif">
  140. <a name="$anchor">
  141. <strong>$name</strong></a></font>
  142. </td></tr>
  143. #end
  144. #*
  145. Match long-description section
  146. *#
  147. #match( "long-description" )
  148. <table border="0" cellspacing="0" cellpadding="2" width="100%">
  149. <tr><td>&nbsp;</td></tr>
  150. #section($task_name "$task_title Task Description")
  151. <tr><td><blockquote>
  152. $node.value()
  153. </blockquote></td></tr>
  154. </table>
  155. #end
  156. #*
  157. Match structure/attributes section
  158. *#
  159. #match( "structure/attributes" )
  160. <table border="0" cellspacing="0" cellpadding="2" width="100%">
  161. <tr><td>&nbsp;</td></tr>
  162. #section("attributes" "Parameters")
  163. <tr><td><blockquote>
  164. <table>
  165. <tr>
  166. #th("Attribute")
  167. #th("Description")
  168. #th("Type")
  169. </tr>
  170. $context.applyTemplates("*")
  171. </table>
  172. </blockquote></td></tr>
  173. </table>
  174. #end
  175. #*
  176. Match structure/elements section
  177. *#
  178. #match( "structure/elements" )
  179. <table border="0" cellspacing="0" cellpadding="2" width="100%">
  180. <tr><td>&nbsp;</td></tr>
  181. #section("elements" "Parameters as nested elements")
  182. <tr><td><blockquote>
  183. $context.applyTemplates("*")
  184. </blockquote></td></tr>
  185. </table>
  186. #end
  187. #match( "attribute" )
  188. <tr>
  189. #td($attrib.name)
  190. #td($node.description)
  191. #td($attrib.type)
  192. </tr>
  193. #end
  194. #match( "element" )
  195. <table border="0" cellspacing="0" cellpadding="2" width="100%">
  196. #subsection($attrib.name $attrib.name)
  197. <tr><td><blockquote>
  198. $node.description
  199. </blockquote></td></tr>
  200. </table>
  201. #end
  202. #*
  203. * Process a menu for the navigation bar
  204. *#
  205. #match( "menu" )
  206. <tr><td>
  207. <p>
  208. <strong>$attrib.name</strong>
  209. </p>
  210. </td><td>
  211. <ul>
  212. $context.applyTemplates("item")
  213. </ul></td></tr>
  214. #end
  215. #*
  216. * Process a menu item for the navigation bar
  217. *#
  218. #match( "item" )
  219. #if( $attrib.href.endsWith("$outputfilename") && !$attrib.href.startsWith("http"))
  220. <strong>$attrib.name</strong>
  221. #else
  222. #if( $attrib.href.startsWith("http") )
  223. <a href="$attrib.href">$attrib.name</a>
  224. #else
  225. <a href="${relative-path}$attrib.href">$attrib.name</a>
  226. #end
  227. #end
  228. #end
  229. #*
  230. * process a documentation section
  231. *#
  232. #match( "section" )
  233. <table border="0" cellspacing="0" cellpadding="2" width="100%">
  234. <tr><td>&nbsp;</td></tr>
  235. <tr><td bgcolor="$banner-bg">
  236. <font color="$banner-fg" face="arial,helvetica.sanserif">
  237. #if ( $attrib.anchor )
  238. #set( $anchor = $attrib.anchor )
  239. #else
  240. #set( $anchor = $attrib.name )
  241. #end
  242. <a name="$anchor">
  243. <strong>$attrib.name</strong></a></font>
  244. </td></tr>
  245. <tr><td><blockquote>
  246. $context.applyTemplates("*")
  247. </blockquote></td></tr>
  248. </table>
  249. #end
  250. #match( "subsection" )
  251. <table border="0" cellspacing="0" cellpadding="2" width="100%">
  252. <!-- Subsection heading -->
  253. <tr><td bgcolor="$sub-banner-bg">
  254. <font color="$sub-banner-fg" face="arial,helvetica.sanserif">
  255. #if ( $attrib.anchor )
  256. #set( $anchor = $attrib.anchor )
  257. #else
  258. #set( $anchor = $attrib.name )
  259. #end
  260. <a name="$anchor">
  261. <strong>$attrib.name</strong></a></font>
  262. </td></tr>
  263. <!-- Subsection body -->
  264. <tr><td>
  265. $context.applyTemplates("*")
  266. </td></tr>
  267. </table>
  268. #end
  269. #match( "source" )
  270. <div align="left">
  271. <table cellspacing="4" cellpadding="0" border="0">
  272. <tr>
  273. <td bgcolor="$source-color" width="1" height="1">
  274. <img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/>
  275. </td>
  276. <td bgcolor="$source-color" height="1">
  277. <img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/>
  278. </td>
  279. <td bgcolor="$source-color" width="1" height="1">
  280. <img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/>
  281. </td>
  282. </tr>
  283. <tr>
  284. <td bgcolor="$source-color" width="1">
  285. <img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/>
  286. </td>
  287. <td bgcolor="#ffffff" height="1">
  288. <font size="$source-font-size"><pre>$toolbox.htmlescape.getText( $node.value() )</pre></font>
  289. </td>
  290. <td bgcolor="$source-color" width="1">
  291. <img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/>
  292. </td>
  293. </tr>
  294. <tr>
  295. <td bgcolor="$source-color" width="1" height="1">
  296. <img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/>
  297. </td>
  298. <td bgcolor="$source-color" height="1">
  299. <img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/>
  300. </td>
  301. <td bgcolor="$source-color" width="1" height="1">
  302. <img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/>
  303. </td>
  304. </tr>
  305. </table>
  306. </div>
  307. #end
  308. #match("table")
  309. <table>
  310. $context.applyTemplates("*")
  311. </table>
  312. #end
  313. #match("tr")
  314. <tr>
  315. $context.applyTemplates("*")
  316. </tr>
  317. #end
  318. #match( "td" )
  319. <td bgcolor="$table-td-bg" #*
  320. *##ifset($attrib.colspan "colspan=$qq$attrib.colspan$qq ")#*
  321. *##ifset($attrib.rowspan "rowspan=$qq$attrib.rowspan$qq ")#*
  322. *#valign="top" align="left">
  323. <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  324. $node.copy( $node.children() )
  325. </font>
  326. </td>
  327. #end
  328. #match( "th" )
  329. <td bgcolor="$table-th-bg" #*
  330. *##ifset($attrib.colspan "colspan=$qq$attrib.colspan$qq ")#*
  331. *##ifset($attrib.rowspan "rowspan=$qq$attrib.rowspan$qq ")#*
  332. *#valign="top" align="left">
  333. <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  334. <b>$node.copy( $node.children())</b>
  335. </font>
  336. </td>
  337. #end
  338. #match("*")
  339. $node.copy()
  340. #end