comparison mxtool/mx.py @ 14907:7683ad455d81

mx: fix post processing of javadoc for jdk8
author Bernhard Urban <bernhard.urban@jku.at>
date Mon, 31 Mar 2014 20:28:34 +0200
parents 7dfc0e9fd45a
children 2d1cc640512c
comparison
equal deleted inserted replaced
14906:f3a5036cc13c 14907:7683ad455d81
3674 windowTitle = [] 3674 windowTitle = []
3675 if stdDoclet: 3675 if stdDoclet:
3676 windowTitle = ['-windowtitle', p.name + ' javadoc'] 3676 windowTitle = ['-windowtitle', p.name + ' javadoc']
3677 try: 3677 try:
3678 log('Generating {2} for {0} in {1}'.format(p.name, out, docDir)) 3678 log('Generating {2} for {0} in {1}'.format(p.name, out, docDir))
3679 run([java(p.javaCompliance).javadoc, memory, 3679 run([java().javadoc, memory,
3680 '-XDignore.symbol.file', 3680 '-XDignore.symbol.file',
3681 '-classpath', cp, 3681 '-classpath', cp,
3682 '-quiet', 3682 '-quiet',
3683 '-d', out, 3683 '-d', out,
3684 '-overview', overviewFile, 3684 '-overview', overviewFile,
3765 3765
3766 chunk1 = Chunk(content, """<div class="header"> 3766 chunk1 = Chunk(content, """<div class="header">
3767 <div class="subTitle"> 3767 <div class="subTitle">
3768 <div class="block">""", """</div> 3768 <div class="block">""", """</div>
3769 </div> 3769 </div>
3770 <p>See: <a href="#overview_description">Description</a></p> 3770 <p>See: <a href="#overview.description">Description</a></p>
3771 </div>""") 3771 </div>""")
3772 3772
3773 chunk2 = Chunk(content, """<div class="footer"><a name="overview_description"> 3773 chunk2 = Chunk(content, """<div class="contentContainer"><a name="overview.description">
3774 <!-- --> 3774 <!-- -->
3775 </a> 3775 </a>
3776 <div class="subTitle">
3777 <div class="block">""", """</div> 3776 <div class="block">""", """</div>
3778 </div>
3779 </div> 3777 </div>
3780 <!-- ======= START OF BOTTOM NAVBAR ====== -->""") 3778 <!-- ======= START OF BOTTOM NAVBAR ====== -->""")
3781 3779
3782 assert chunk1.text, 'Could not find header section in ' + path 3780 assert chunk1.text, 'Could not find header section in ' + path
3783 assert chunk2.text, 'Could not find footer section in ' + path 3781 assert chunk2.text, 'Could not find footer section in ' + path
3800 # This uses scraping and so will break if the relevant content produced by javadoc changes in any way! 3798 # This uses scraping and so will break if the relevant content produced by javadoc changes in any way!
3801 with open(path) as fp: 3799 with open(path) as fp:
3802 content = fp.read() 3800 content = fp.read()
3803 3801
3804 chunk1 = Chunk(content, """<div class="header"> 3802 chunk1 = Chunk(content, """<div class="header">
3805 <h1 title="Package" class="title">Package""", """<p>See:&nbsp;<a href="#package_description">Description</a></p> 3803 <h1 title="Package" class="title">Package""", """<p>See:&nbsp;<a href="#package.description">Description</a></p>
3806 </div>""") 3804 </div>""")
3807 3805
3808 chunk2 = Chunk(content, """<a name="package_description"> 3806 chunk2 = Chunk(content, """<a name="package.description">
3809 <!-- --> 3807 <!-- -->
3810 </a>""", """</div> 3808 </a>""", """</div>
3811 </div> 3809 </div>
3812 <!-- ======= START OF BOTTOM NAVBAR ====== -->""") 3810 <!-- ======= START OF BOTTOM NAVBAR ====== -->""")
3813 3811