From langel at redhat.com Mon Feb 2 06:49:57 2009 From: langel at redhat.com (Lillian Angel) Date: Mon, 02 Feb 2009 09:49:57 -0500 Subject: IcedTea6 1.4 Released! Message-ID: <49870815.6080106@redhat.com> We are proud to announce the release of IcedTea6 1.4. The IcedTea6 project provides a harness to build the source code from OpenJDK6 (http://openjdk.java.net) using Free Software build tools. What's New? ----------------- - Updated to OpenJDK b14 build. - Security fixes for: CVE-2008-5360 - Temporary files have guessable file names. CVE-2008-5350 - Allows to list files within the user home directory. CVE-2008-5348 - Denial-Of-Service in kerberos authentication. CVE-2008-5359 - Buffer overflow in image processing. CVE-2008-5351 - UTF-8 decoder accepts non-shortest form sequences. CVE-2008-5356 - Font processing vulnerability. CVE-2008-5353 - Calendar object deserialization allows privilege escalation. CVE-2008-5354 - Privilege escalation in command line applications. CVE-2008-5357 - Truetype Font processing vulnerability. CVE-2008-5352 - Jar200 Decompression buffer overflow. CVE-2008-5358 - Buffer Overflow in GIF image processing. - Upgraded to new OpenJDK7 Hotspot 14. The old OpenJDK6 Hotspot 11 can still be configured --with-hotspot-build=original but future versions will drop support for the old version and only support HS14. Zero and Shark have been forward ported to HS14 (from HS12). - XRender pipeline support: Java2D are noticably faster and running over a remote X connection feels like it is all local. Build by default (disable with --disable-xrender). Runtime enabled by running java -Dsun.java2d.xrender=True (default is to use the old X renderer for now). - IcedTeaPlugin now supports HTTPS sites and adds a user prompt for untrusted https certificates. - Use the ALSA 'default' device. Makes Java play nicer with PulseAudio. - VisualVM integration has been removed. - Gervill soft synthesizer integration updated to latest CVS version. - Integrated jtreg upgraded to 4_0-src-b02-15_oct_2008. - make check runs much faster now. jtreg -samevm support has been integrated into the langtools and jdk subsystems. Please package the test/jtreg-summary.log file with your distribution package so end users can compare the test results. - Shark (--enable-shark) now builds on 64 bit platforms, but is a pre-alpha technology preview and not recommended for use. - Better support for bootstrapping with different jar programs (supporting -J options). - If --with-pkgversion isn't given the short mercurial rev node version will be used. Package distributors are encouraged to build packages with --with-pkgversion to uniquely identify their distribution version number when java -version is run to help distribution specific bug reporting. - Various freetype font, pisces renderer and awt X window size fixes to fix visual anomalies. - Build fixes for gcc 4.3 and 4.4-pre-release. - Added support for building against a specific openjdk src dir or hg revision (--with-openjdk-src-dir or --with-hg-revision). - Many other Plugin, Zero, Shark and PulseAudio bug fixes. - Build clean up. - Several plugin bug and build fixes: (http://icedtea.classpath.org/bugzilla/ and https://bugzilla.redhat.com/). ----------------- The tarball and nosrc RPM can be downloaded here: http://icedtea.classpath.org/download/fedora/java-1.6.0-openjdk-1.6.0.0-10.b14.fc11.nosrc.rpm http://icedtea.classpath.org/download/source/icedtea6-1.4.tar.gz The following people helped with this release: Gary Benson, Deepak Bhole, Andrew Haley, Andrew John Hughes, Ioana Ivan, Matthias Klose, Omair Majid, Christian Thalinger, Mark Wielaard, Lillian Angel We would also like to thank the bug reporters and testers! To get started: $ hg clone http://icedtea.classpath.org/hg/icedtea6 $ cd icedtea6 Full build requirements and instructions are in INSTALL: $ ./configure $ make The new package has been built into Fedora 10 and Fedora 11 (rawhide) and should appear in the yum repositories in a couple of days. From ekrichardson at gmail.com Tue Feb 3 00:47:56 2009 From: ekrichardson at gmail.com (Eric Richardson) Date: Tue, 3 Feb 2009 00:47:56 -0800 Subject: Updated Icedtea7 Problem MacOSX PPC In-Reply-To: <20090130150057.GE3205@redhat.com> References: <860cb0120901272357u2c50ce95sb36b08a25483052e@mail.gmail.com> <20090128081320.GA3207@redhat.com> <860cb0120901280904u72c8206akf5c3096f853dd789@mail.gmail.com> <860cb0120901282359v1aa27138tb4115fa1b338d3aa@mail.gmail.com> <20090129102048.GB3213@redhat.com> <860cb0120901291021t46badee1tb5ec33ca444e72ec@mail.gmail.com> <20090130150057.GE3205@redhat.com> Message-ID: <860cb0120902030047q39dd9460y33285d9fd7325546@mail.gmail.com> Gary, On Fri, Jan 30, 2009 at 7:00 AM, Gary Benson wrote: > Eric Richardson wrote: > > > I guess Icedtea works from scratch on other platforms without > > errors/stopping? > > It does, however, as you saw, the only operating systems in IcedTea's > acinclude.m4 are Linux and Solaris, so it doesn't look like anybody > tried building on those yet. I saw you patched it to include "darwin", > but should it not have been patched to say "bsd"? This would be better for darwin only? Then maybe Defs-bsd.gmk might get included? diff -r 52b6f4605e43 acinclude.m4 --- a/acinclude.m4 Tue Jan 27 02:27:28 2009 +0000 +++ b/acinclude.m4 Mon Feb 02 21:53:16 2009 -0800 @@ -77,6 +77,10 @@ BUILD_OS_DIR=solaris OS_PATH=/opt/SunStudioExpress/bin:/opt/SUNWpro/bin:/usr/gnu/bin ;; + *darwin*) + BUILD_OS_DIR=bsd + OS_PATH= + ;; *) AC_MSG_ERROR([unsupported operating system ${host_os}]) ;; Given how much further along Michael is it might be worth trying his > approach. He may be able to supply you with updated patches, for > instance. When I was looking at the binary plugs list on the open-jdk site I saw the i386 libs and thought these were not going to work for PowerPC. Is this correct? Also, all I have right now is the jdk1.5 from Apple to work with on this platform. > Cheers, > Gary > > -- > http://gbenson.net/ > Thanks, Eric -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20090203/bfa0b5a3/attachment.html From ekrichardson at gmail.com Tue Feb 3 01:01:04 2009 From: ekrichardson at gmail.com (Eric Richardson) Date: Tue, 3 Feb 2009 01:01:04 -0800 Subject: IcedTea Bootstrap Process In-Reply-To: <20090129101436.GA3213@redhat.com> References: <17c6771e0901132035s2588f275s8a7e8e2997241ed6@mail.gmail.com> <20090129101436.GA3213@redhat.com> Message-ID: <860cb0120902030101y661feea2sb8e744e32eba6b57@mail.gmail.com> On Thu, Jan 29, 2009 at 2:14 AM, Gary Benson wrote: > Michael Franz wrote: > > I have made some pretty good progress (I think) on building IcedTea6 > > using Apple's Java 5. I have 'grep'ed all over and cannot figure > > out where this error message is coming from. > > > > (cd > > > /Users/mfranz/developer/icedtea/icedtea6/openjdk-ecj/control/build/bsd-i586/classes > > && /Users/mfranz/developer/icedtea/icedtea6/bootstrap/jdk1.6.0/bin/jar xf > > > /Users/mfranz/developer/icedtea/icedtea6/bootstrap/jdk1.7.0/jre/lib/rt-closed.jar > > > @/Users/mfranz/developer/icedtea/icedtea6/openjdk-ecj/control/build/bsd-i586/tmp/java/plugs/jmf.clist) > > BinaryPlugs import completed: Wed Jan 28 20:31:33 EST 2009 > > make[4]: *** No rule to make target > > > `/Users/mfranz/developer/icedtea/icedtea6/openjdk-ecj/control/build/bsd-i586/hotspot/import/jre/lib/i386/server/libjvm.so', > > needed by > > > `/Users/mfranz/developer/icedtea/icedtea6/openjdk-ecj/control/build/bsd-i586/lib/i386/server/libjvm.so'. > > Stop. > > make[3]: *** [all] Error 1 > > make[2]: *** [all] Error 1 > > make[1]: *** [jdk-build] Error 2 > > make: *** [stamps/icedtea-ecj.stamp] Error 2 > > > > Somewhere it does not know that the shared libs end in .dylib. The > > directory in question has: > > Xusage.txt > > libjsig.dylib > > libjvm.dylib > > > > I was able to get past this step by make sym links to of libjvm.dylib to > > libjvm.so. > > Check out openjdk/jdk/make/common/shared/Platform.gmk: > > 467 # Unix type settings (same for all unix platforms) > 468 ifneq ($(PLATFORM), windows) > ... > 478 # The suffix applied to runtime libraries > 479 LIBRARY_SUFFIX = so This looks like this is fixed in Icedtea7. 520 # Darwin-specific Overrides ifeq ($(SYSTEM_UNAME),Darwin) # The suffix applied to runtime libraries LIBRARY_SUFFIX = dylib # The suffix applied to link libraries LIB_SUFFIX = dylib endif Eric > > > Cheers, > Gary > > -- > http://gbenson.net/ > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20090203/1223c294/attachment.html From bugzilla-daemon at icedtea.classpath.org Tue Feb 3 03:20:52 2009 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 03 Feb 2009 11:20:52 +0000 Subject: [Bug 291] New: scaron html entity not rendered properly Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=291 Summary: scaron html entity not rendered properly Product: IcedTea Version: unspecified Platform: PC OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: IcedTea AssignedTo: unassigned at icedtea.classpath.org ReportedBy: ripper42 at gmail.com š is a legal html entity and when used in a JLabel with tags, it should be rendered as ? character. With Sun Java this happens. With OpenJDK this does not happen, it is still rendered as š See attachment as a test case. My system (Ubuntu 8.10): $ java -version java version "1.6.0_0" IcedTea6 1.3.1 (6b12-0ubuntu6.1) Runtime Environment (build 1.6.0_0-b12) OpenJDK Server VM (build 1.6.0_0-b12, mixed mode) I don't know if this should be reported in OpenJDK bugtracker instead of here (IcedTea), but I didn't find any OpenJDK bugtracker. And I am really confused which project is which. So please take look at it, thanks. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Tue Feb 3 03:22:07 2009 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 03 Feb 2009 11:22:07 +0000 Subject: [Bug 291] scaron html entity not rendered properly Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=291 ------- Comment #1 from ripper42 at gmail.com 2009-02-03 11:22 ------- Created an attachment (id=157) --> (http://icedtea.classpath.org/bugzilla/attachment.cgi?id=157&action=view) test case -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From bugzilla-daemon at icedtea.classpath.org Tue Feb 3 03:37:27 2009 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 03 Feb 2009 11:37:27 +0000 Subject: [Bug 291] scaron html entity not rendered properly Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=291 ------- Comment #2 from ripper42 at gmail.com 2009-02-03 11:37 ------- The same for Š -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From gnu_andrew at member.fsf.org Tue Feb 3 04:13:56 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:56 +0000 Subject: changeset in /hg/icedtea6: More build fixes for NIO2. Message-ID: changeset 981d5e01b698 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=981d5e01b698 description: More build fixes for NIO2. 2009-01-12 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java: Fix imports. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/ProtocolFamily.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/SocketOption.java: Add missing files. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java: Fix imports. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MembershipKey.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MulticastChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/NetworkChannel.java: Add missing files. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystems.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java: Fix imports. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/EPollPort.java: Add missing file. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java: Fix imports. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/Port.java: Add missing file. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java: Fix imports. * patches/icedtea-nio2.patch: Add missing files to java/nio/FILES_java.gmk diffstat: 43 files changed, 1355 insertions(+), 47 deletions(-) ChangeLog | 55 + overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/ProtocolFamily.java | 40 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/SocketOption.java | 56 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java | 8 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java | 8 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MembershipKey.java | 183 +++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MulticastChannel.java | 216 +++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/NetworkChannel.java | 165 ++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider.java | 8 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystems.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java | 8 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java | 5 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java | 4 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java | 4 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java | 4 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileTypeDetector.java | 5 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java | 4 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java | 4 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java | 3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/EPollPort.java | 361 ++++++++++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java | 6 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/Port.java | 167 ++++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java | 3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java | 4 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java | 4 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java | 4 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java | 5 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java | 7 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java | 5 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java | 5 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java | 9 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java | 4 patches/icedtea-nio2.patch | 11 diffs (truncated from 1917 to 500 lines): diff -r 2257885742d0 -r 981d5e01b698 ChangeLog --- a/ChangeLog Mon Jan 12 21:46:12 2009 +0000 +++ b/ChangeLog Tue Jan 13 16:37:09 2009 +0000 @@ -1,3 +1,58 @@ 2009-01-12 Andrew John Hughes + + * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java: + Fix imports. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/ProtocolFamily.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/SocketOption.java: + Add missing files. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java: + Fix imports. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MembershipKey.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MulticastChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/NetworkChannel.java: + Add missing files. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystems.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java: + Fix imports. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/EPollPort.java: + Add missing file. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java: + Fix imports. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/Port.java: + Add missing file. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java: + Fix imports. + * patches/icedtea-nio2.patch: + Add missing files to java/nio/FILES_java.gmk + 2009-01-12 Andrew John Hughes Initial import of NIO2 code. diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java Mon Jan 12 21:46:12 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java Tue Jan 13 16:37:09 2009 +0000 @@ -25,7 +25,7 @@ package com.sun.nio.file; -import java.nio.file.CopyOption; +import org.classpath.icedtea.java.nio.file.CopyOption; /** * Defines extended copy options supported on some platforms diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java Mon Jan 12 21:46:12 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java Tue Jan 13 16:37:09 2009 +0000 @@ -25,7 +25,7 @@ package com.sun.nio.file; -import java.nio.file.OpenOption; +import org.classpath.icedtea.java.nio.file.OpenOption; /** * Defines extended open options supported on some platforms diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java Mon Jan 12 21:46:12 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java Tue Jan 13 16:37:09 2009 +0000 @@ -25,7 +25,7 @@ package com.sun.nio.file; -import java.nio.file.WatchEvent.Modifier; +import org.classpath.icedtea.java.nio.file.WatchEvent.Modifier; /** * Defines extended watch event modifiers supported on some platforms diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/ProtocolFamily.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/ProtocolFamily.java Tue Jan 13 16:37:09 2009 +0000 @@ -0,0 +1,40 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 2009 Red Hat, Inc. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package org.classpath.icedtea.java.net; + +/** + * Represents a family of communication protocols. + * + * @since 1.7 + */ + +public interface ProtocolFamily { + /** + * Returns the name of the protocol family. + */ + String name(); +} diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/SocketOption.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/SocketOption.java Tue Jan 13 16:37:09 2009 +0000 @@ -0,0 +1,56 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 2009 Red Hat, Inc. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package org.classpath.icedtea.java.net; + +/** + * A socket option associated with a socket. + * + *

In the {@link java.nio.channels channels} package, the {@link + * java.nio.channels.NetworkChannel} interface defines the {@link + * java.nio.channels.NetworkChannel#setOption(SocketOption,Object) setOption} + * and {@link java.nio.channels.NetworkChannel#getOption(SocketOption) getOption} + * methods to set and query the channel's socket options. + * + * @param The type of the socket option value. + * + * @since 1.7 + * + * @see StandardSocketOption + */ + +public interface SocketOption { + + /** + * Returns the name of the socket option. + */ + String name(); + + /** + * Returns the type of the socket option value. + */ + Class type(); +} diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java Mon Jan 12 21:46:12 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java Tue Jan 13 16:37:09 2009 +0000 @@ -26,9 +26,10 @@ package org.classpath.icedtea.java.nio.channels; -import java.nio.channels.spi.AsynchronousChannelProvider; import java.io.IOException; import java.util.concurrent.*; + +import org.classpath.icedtea.java.nio.channels.spi.AsynchronousChannelProvider; /** * A grouping of asynchronous channels for the purpose of resource sharing. diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java Mon Jan 12 21:46:12 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java Tue Jan 13 16:37:09 2009 +0000 @@ -26,14 +26,16 @@ package org.classpath.icedtea.java.nio.channels; -import java.nio.channels.spi.*; import java.util.concurrent.TimeUnit; import java.util.concurrent.Future; import java.io.IOException; -import java.net.SocketOption; import java.net.SocketAddress; -import java.net.ProtocolFamily; import java.nio.ByteBuffer; + +import org.classpath.icedtea.java.net.ProtocolFamily; +import org.classpath.icedtea.java.net.SocketOption; + +import org.classpath.icedtea.java.nio.channels.spi.AsynchronousChannelProvider; /** * An asynchronous channel for datagram-oriented sockets. diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java Mon Jan 12 21:46:12 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java Tue Jan 13 16:37:09 2009 +0000 @@ -26,9 +26,6 @@ package org.classpath.icedtea.java.nio.channels; -import java.nio.file.*; -import java.nio.file.attribute.FileAttribute; -import java.nio.file.spi.*; import java.nio.ByteBuffer; import java.io.IOException; import java.util.concurrent.Future; @@ -36,6 +33,11 @@ import java.util.Set; import java.util.Set; import java.util.HashSet; import java.util.Collections; + +import org.classpath.icedtea.java.nio.file.FileSystemProvider; +import org.classpath.icedtea.java.nio.file.OpenOption; +import org.classpath.icedtea.java.nio.file.Path; +import org.classpath.icedtea.java.nio.file.attribute.FileAttribute; /** * An asynchronous channel for reading, writing, and manipulating a file. diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java Mon Jan 12 21:46:12 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java Tue Jan 13 16:37:09 2009 +0000 @@ -26,11 +26,12 @@ package org.classpath.icedtea.java.nio.channels; -import java.nio.channels.spi.*; import java.net.SocketOption; import java.net.SocketAddress; import java.util.concurrent.Future; import java.io.IOException; + +import org.classpath.icedtea.java.nio.channels.spi.AsynchronousChannelProvider; /** * An asynchronous channel for stream-oriented listening sockets. diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MembershipKey.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MembershipKey.java Tue Jan 13 16:37:09 2009 +0000 @@ -0,0 +1,183 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 2009 Red Hat, Inc. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package org.classpath.icedtea.java.nio.channels; + +import java.net.InetAddress; +import java.net.NetworkInterface; +import java.io.IOException; + +/** + * A token representing the membership of an Internet Protocol (IP) multicast + * group. + * + *

A membership key may represent a membership to receive all datagrams sent + * to the group, or it may be source-specific, meaning that it + * represents a membership that receives only datagrams from a specific source + * address. Whether or not a membership key is source-specific may be determined + * by invoking its {@link #sourceAddress() sourceAddress} method. + * + *

A membership key is valid upon creation and remains valid until the + * membership is dropped by invoking the {@link #drop() drop} method, or + * the channel is closed. The validity of the membership key may be tested + * by invoking its {@link #isValid() isValid} method. + * + *

Where a membership key is not source-specific and the underlying operation + * system supports source filtering, then the {@link #block block} and {@link + * #unblock unblock} methods can be used to block or unblock multicast datagrams + * from particular source addresses. + * + * @see MulticastChannel + * + * @since 1.7 + */ +public abstract class MembershipKey { + + /** + * Initializes a new instance of this class. + */ + protected MembershipKey() { + } + + /** + * Tells whether or not this membership is valid. + * + *

A multicast group membership is valid upon creation and remains + * valid until the membership is dropped by invoking the {@link #drop() drop} + * method, or the channel is closed. + * + * @return {@code true} if this membership key is valid, {@code false} + * otherwise + */ + public abstract boolean isValid(); + + /** + * Drop membership. + * + *

If the membership key represents a membership to receive all datagrams + * then the membership is dropped and the channel will no longer receive any + * datagrams sent to the group. If the membership key is source-specific + * then the channel will no longer receive datagrams sent to the group from + * that source address. + * + *

After membership is dropped it may still be possible to receive + * datagrams sent to the group. This can arise when datagrams are waiting to + * be received in the socket's receive buffer. After membership is dropped + * then the channel may {@link MulticastChannel#join join} the group again + * in which case a new membership key is returned. + * + *

Upon return, this membership object will be {@link #isValid() invalid}. + * If the multicast group membership is already invalid then invoking this + * method has no effect. Once a multicast group membership is invalid, + * it remains invalid forever. + * + * @throws IOException + * If an I/O error occurs + */ + public abstract void drop() throws IOException; + + /** + * Block multicast datagrams from the given source address. + * + *

If this membership key is not source-specific, and the underlying + * operating system supports source filtering, then this method blocks + * multicast datagrams from the given source address. If the given source + * address is already blocked then this method has no effect. + * After a source address is blocked it may still be possible to receive + * datagams from that source. This can arise when datagrams are waiting to + * be received in the socket's receive buffer. + * + * @param source + * The source address to block + * + * @return This membership key + * + * @throws IllegalArgumentException + * If the {@code source} parameter is not a unicast address or + * is not the same address type as the multicast group + * @throws IllegalStateException + * If this membership key is source-specific or is no longer valid + * @throws UnsupportedOperationException + * If the underlying operating system does not support source + * filtering + * @throws IOException + * If an I/O error occurs + */ + public abstract MembershipKey block(InetAddress source) throws IOException; + + /** + * Unblock multicast datagrams from the given source address that was + * previously blocked using the {@link #block(InetAddress) block} method. + * + * @param source + * The source address to unblock + * + * @return This membership key + * + * @throws IllegalStateException + * If the given source address is not currently blocked or the + * membership key is no longer valid + * @throws IOException + * If an I/O error occurs + */ + public abstract MembershipKey unblock(InetAddress source) throws IOException; + + /** + * Returns the channel for which this membership key was created. This + * method will continue to return the channel even after the membership + * becomes {@link #isValid invalid}. + * + * @return the channel + */ + public abstract MulticastChannel channel(); + + /** + * Returns the multicast group for which this membership key was created. + * This method will continue to return the group even after the membership + * becomes {@link #isValid invalid}. + * + * @return the multicast group + */ + public abstract InetAddress group(); + + /** + * Returns the network interface for which this membership key was created. + * This method will continue to return the network interface even after the + * membership becomes {@link #isValid invalid}. + * + * @return the network interface + */ + public abstract NetworkInterface networkInterface(); + + /** + * Returns the source address if this membership key is source-specific, + * or {@code null} if this membership is not source-specific. + * + * @return The source address if this membership key is source-specific, + * otherwise {@code null} + */ + public abstract InetAddress sourceAddress(); +} diff -r 2257885742d0 -r 981d5e01b698 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MulticastChannel.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MulticastChannel.java Tue Jan 13 16:37:09 2009 +0000 @@ -0,0 +1,216 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 2009 Red Hat, Inc. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package org.classpath.icedtea.java.nio.channels; From gnu_andrew at member.fsf.org Tue Feb 3 04:13:55 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:55 +0000 Subject: changeset in /hg/icedtea6: Initial import of NIO2. Message-ID: changeset 2257885742d0 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=2257885742d0 description: Initial import of NIO2. 2009-01-12 Andrew John Hughes Initial import of NIO2 code. * patches/ecj/icedtea-pr261.patch: Moved to general patches. * Makefile.am: Add NIO2 patch. * configure.ac: Add --enable-nio2 option (on by default). * overlays/nio2/openjdk/jdk/make/mkdemo/nio/Makefile, * overlays/nio2/openjdk/jdk/make/mkdemo/nio/ZipFileSystem/Makefile, * overlays/nio2/openjdk/jdk/make/mksample/nio/aio/Makefile, * overlays/nio2/openjdk/jdk/make/mksample/nio/file/Makefile, * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/File.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/FilePermission.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/Inputs.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/Outputs.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousByteChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/Channels.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/CompletionHandler.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileLock.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/package-info.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/package.html, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AccessDeniedException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AccessMode.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AtomicMoveNotSupportedException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedDirectoryStreamException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedFileSystemException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedWatchServiceException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/CopyOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryNotEmptyException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryStream.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryStreamFilters.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileAction.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileAlreadyExistsException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileRef.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileStore.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystem.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemAlreadyExistsException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemNotFoundException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystems.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileTreeWalker.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitResult.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitor.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Files.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/InvalidPathException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/LinkOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/LinkPermission.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NoSuchFileException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NotDirectoryException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NotLinkException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/OpenOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Path.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/PathMatcher.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Paths.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ProviderMismatchException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ProviderNotFoundException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ReadOnlyFileSystemException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SecureDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SimpleFileVisitor.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardCopyOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardOpenOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardWatchEventKind.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchEvent.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchKey.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchService.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Watchable.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntry.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryFlag.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryPermission.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryType.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/Attributes.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributes.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributes.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileAttribute.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileOwnerAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributes.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/GroupPrincipal.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributes.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermission.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermissions.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipal.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipalLookupService.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipalNotFoundException.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/package-info.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/package-info.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/package-info.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/Scanner.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AbstractFuture.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Cancellable.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/CompletedFuture.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/FileLockTable.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Groupable.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Invoker.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/PendingFuture.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ThreadPool.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractPoller.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Globs.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/MimeType.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/NativeBuffer.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/NativeBuffers.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Reflect.java, * overlays/nio2/openjdk/jdk/src/share/sample/nio/aio/EchoServer.java, * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/AclEdit.java, * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Chmod.java, * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Copy.java, * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/DiskUsage.java, * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/FileType.java, * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/WatchDir.java, * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Xdd.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileStore.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNativeDispatcher.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisAclFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileStore.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileSystem.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisNamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisNativeDispatcher.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisWatchService.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileKey.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileModeAttribute.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStoreAttributes.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixMountEntry.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixNativeDispatcher.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUriUtils.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/EPollPort.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/SolarisEventPort.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/UnixAsynchronousSocketChannelImpl.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/GnomeFileTypeDetector.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/LinuxNativeDispatcher.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/LinuxWatchService.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/SolarisNativeDispatcher.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/SolarisWatchService.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/UnixCopyFile.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/UnixNativeDispatcher.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/genSolarisConstants.c, * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/genUnixConstants.c, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/Iocp.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/PendingIoCache.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousFileChannelImpl.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousServerSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/DefaultFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/DefaultFileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/RegistryFileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsConstants.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsException.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributeViews.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributes.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileCopy.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileStore.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystem.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsLinkSupport.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNativeDispatcher.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPath.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPathParser.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPathType.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsSecurity.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsSecurityDescriptor.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsUriSupport.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsUserPrincipals.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsWatchService.java, * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/Iocp.c, * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousFileChannelImpl.c, * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousServerSocketChannelImpl.c, * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousSocketChannelImpl.c, * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/fs/RegistryFileTypeDetector.c, * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/fs/WindowsNativeDispatcher.c, * overlays/nio2/openjdk/jdk/test/demo/nio/ZipFileSystem/Sanity.java, * overlays/nio2/openjdk/jdk/test/demo/nio/ZipFileSystem/sanity.sh, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/io/Inputs/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/AsExecutor.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Attack.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/GroupOfOne.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Identity.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/PrivilegedThreadFactory.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Restart.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Unbounded.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/run_any_task.sh, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/CustomThreadPool.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/Lock.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/MyThreadFactory.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/WithSecurityManager.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/java.policy.allow, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/java.policy.deny, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel/Leaky.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/Channels/Basic2.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/CheckProvider.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/META-INF/services/java.nio.channels.spi.AsynchronousChannelProvider, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/Provider1.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/Provider2.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/custom_provider.sh, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/Filters.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/SecureDS.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/FileStore/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/FileSystem/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/ContentType.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/CreateFileTree.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/ForceLoad.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/META-INF/services/java.nio.file.spi.FileTypeDetector, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/Misc.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/PrintFileTree.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/SimpleFileTypeDetector.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/SkipSiblings.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/TerminateWalk.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/content_type.sh, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/walk_file_tree.sh, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/CopyAndMove.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/DeleteOnClose.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/InterruptCopy.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/Links.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/Misc.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/PathOps.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/SBC.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/TemporaryFiles.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/UriImportExport.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/delete_on_close.sh, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/temporary_files.sh, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/PathMatcher/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/TestUtil.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/FileTreeModifier.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/WithSecurityManager.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/denyAll.policy, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirAndOneLevel.policy, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirAndTree.policy, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirOnly.policy, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/Attributes/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributeView/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributeView/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/FileStoreAttributeView/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView/Basic.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/spi/SetDefaultProvider.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/spi/TestProvider.java: Added. * patches/icedtea-nio2.patch: New patch. * patches/icedtea-pr261.patch: Moved from ecj-specific patches. diffstat: 317 files changed, 69760 insertions(+), 45 deletions(-) ChangeLog | 320 + Makefile.am | 17 configure.ac | 8 overlays/nio2/openjdk/jdk/make/mkdemo/nio/Makefile | 37 overlays/nio2/openjdk/jdk/make/mkdemo/nio/ZipFileSystem/Makefile | 40 overlays/nio2/openjdk/jdk/make/mksample/nio/aio/Makefile | 50 overlays/nio2/openjdk/jdk/make/mksample/nio/file/Makefile | 56 overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java | 43 overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java | 50 overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java | 43 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/File.java | 450 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/FilePermission.java | 852 +++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/Inputs.java | 391 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/Outputs.java | 362 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousByteChannel.java | 206 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannel.java | 118 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java | 316 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java | 705 ++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java | 775 ++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java | 304 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel.java | 671 ++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/Channels.java | 214 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/CompletionHandler.java | 78 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java | 1160 ++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileLock.java | 319 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java | 170 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions | 68 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/package-info.java | 293 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider.java | 278 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/package.html | 46 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AccessDeniedException.java | 69 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AccessMode.java | 50 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AtomicMoveNotSupportedException.java | 57 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedDirectoryStreamException.java | 46 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedFileSystemException.java | 44 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedWatchServiceException.java | 44 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/CopyOption.java | 42 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryNotEmptyException.java | 50 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryStream.java | 139 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryStreamFilters.java | 211 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileAction.java | 65 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileAlreadyExistsException.java | 64 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileRef.java | 425 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileStore.java | 173 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystem.java | 426 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemAlreadyExistsException.java | 54 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemException.java | 126 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemNotFoundException.java | 53 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystems.java | 414 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileTreeWalker.java | 245 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitOption.java | 46 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitResult.java | 63 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitor.java | 176 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Files.java | 404 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/InvalidPathException.java | 131 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/LinkOption.java | 44 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/LinkPermission.java | 108 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NoSuchFileException.java | 64 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NotDirectoryException.java | 50 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NotLinkException.java | 64 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/OpenOption.java | 46 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Path.java | 1573 +++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/PathMatcher.java | 50 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Paths.java | 125 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ProviderMismatchException.java | 54 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ProviderNotFoundException.java | 53 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ReadOnlyFileSystemException.java | 44 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SecureDirectoryStream.java | 325 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SimpleFileVisitor.java | 122 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardCopyOption.java | 48 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardOpenOption.java | 126 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardWatchEventKind.java | 95 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchEvent.java | 117 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchKey.java | 138 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchService.java | 179 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Watchable.java | 128 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntry.java | 395 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryFlag.java | 66 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryPermission.java | 131 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryType.java | 57 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView.java | 212 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AttributeView.java | 119 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/Attributes.java | 713 ++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributeView.java | 185 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributes.java | 164 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributeView.java | 180 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributes.java | 85 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileAttribute.java | 51 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileAttributeView.java | 44 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileOwnerAttributeView.java | 102 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreAttributeView.java | 39 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributeView.java | 95 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributes.java | 67 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/GroupPrincipal.java | 43 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java | 237 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView.java | 197 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributes.java | 78 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermission.java | 87 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermissions.java | 181 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipal.java | 55 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipalLookupService.java | 105 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipalNotFoundException.java | 65 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/package-info.java | 120 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/package-info.java | 116 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java | 522 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java | 435 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileTypeDetector.java | 101 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/package-info.java | 39 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/Scanner.java | 2657 ++++++++++ overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AbstractFuture.java | 63 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java | 349 + overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java | 164 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java | 67 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java | 219 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java | 540 ++ overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Cancellable.java | 39 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/CompletedFuture.java | 113 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/FileLockTable.java | 283 + overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Groupable.java | 35 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Invoker.java | 271 + overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/PendingFuture.java | 257 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java | 410 + overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java | 429 + overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ThreadPool.java | 167 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java | 110 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java | 208 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java | 119 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileTypeDetector.java | 69 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java | 117 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractPoller.java | 290 + overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java | 176 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java | 161 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java | 134 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java | 111 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Globs.java | 155 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/MimeType.java | 73 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/NativeBuffer.java | 87 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/NativeBuffers.java | 140 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java | 443 + overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Reflect.java | 63 overlays/nio2/openjdk/jdk/src/share/sample/nio/aio/EchoServer.java | 165 overlays/nio2/openjdk/jdk/src/share/sample/nio/file/AclEdit.java | 301 + overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Chmod.java | 363 + overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Copy.java | 227 overlays/nio2/openjdk/jdk/src/share/sample/nio/file/DiskUsage.java | 78 overlays/nio2/openjdk/jdk/src/share/sample/nio/file/FileType.java | 62 overlays/nio2/openjdk/jdk/src/share/sample/nio/file/WatchDir.java | 204 overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Xdd.java | 119 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java | 56 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java | 93 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java | 96 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java | 242 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java | 314 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousSocketChannelImpl.java | 678 ++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java | 73 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileTypeDetector.java | 36 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java | 98 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java | 297 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileStore.java | 102 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java | 180 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystemProvider.java | 41 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java | 340 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNativeDispatcher.java | 126 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java | 464 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisAclFileAttributeView.java | 408 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileStore.java | 102 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileSystem.java | 178 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileSystemProvider.java | 41 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisNamedAttributeView.java | 293 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisNativeDispatcher.java | 56 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisWatchService.java | 771 ++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java | 284 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java | 608 ++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java | 267 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java | 113 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java | 392 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java | 307 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileKey.java | 60 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileModeAttribute.java | 84 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java | 277 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStoreAttributes.java | 59 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java | 362 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java | 141 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixMountEntry.java | 82 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixNativeDispatcher.java | 556 ++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java | 1174 ++++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java | 643 ++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUriUtils.java | 216 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java | 175 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/EPollPort.c | 173 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/SolarisEventPort.c | 155 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.c | 47 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/UnixAsynchronousSocketChannelImpl.c | 53 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/GnomeFileTypeDetector.c | 205 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/LinuxNativeDispatcher.c | 160 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/LinuxWatchService.c | 156 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/SolarisNativeDispatcher.c | 70 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/SolarisWatchService.c | 141 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/UnixCopyFile.c | 85 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/UnixNativeDispatcher.c | 1078 ++++ overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/genSolarisConstants.c | 104 overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/genUnixConstants.c | 129 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java | 43 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/Iocp.java | 435 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/PendingIoCache.java | 161 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousChannelProvider.java | 96 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousFileChannelImpl.java | 736 ++ overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousServerSocketChannelImpl.java | 367 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousSocketChannelImpl.java | 911 +++ overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/DefaultFileSystemProvider.java | 38 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/DefaultFileTypeDetector.java | 36 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/RegistryFileTypeDetector.java | 82 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java | 231 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java | 326 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsConstants.java | 191 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsDirectoryStream.java | 225 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsException.java | 109 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributeViews.java | 298 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributes.java | 296 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileCopy.java | 518 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileStore.java | 324 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystem.java | 318 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystemProvider.java | 145 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsLinkSupport.java | 462 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNamedAttributeView.java | 342 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNativeDispatcher.java | 1131 ++++ overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPath.java | 1294 ++++ overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPathParser.java | 225 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPathType.java | 38 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsSecurity.java | 123 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsSecurityDescriptor.java | 392 + overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsUriSupport.java | 167 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsUserPrincipals.java | 169 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsWatchService.java | 581 ++ overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/Iocp.c | 144 overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousFileChannelImpl.c | 132 overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousServerSocketChannelImpl.c | 142 overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousSocketChannelImpl.c | 222 overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/fs/RegistryFileTypeDetector.c | 62 overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/fs/WindowsNativeDispatcher.c | 1328 ++++ overlays/nio2/openjdk/jdk/test/demo/nio/ZipFileSystem/Sanity.java | 168 overlays/nio2/openjdk/jdk/test/demo/nio/ZipFileSystem/sanity.sh | 71 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/io/Inputs/Basic.java | 218 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/AsExecutor.java | 84 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Attack.java | 63 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Basic.java | 261 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/GroupOfOne.java | 137 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Identity.java | 167 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/PrivilegedThreadFactory.java | 50 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Restart.java | 134 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Unbounded.java | 120 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/run_any_task.sh | 52 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel/Basic.java | 377 + overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/Basic.java | 585 ++ overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/CustomThreadPool.java | 67 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/Lock.java | 340 + overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/MyThreadFactory.java | 49 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/Basic.java | 136 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/WithSecurityManager.java | 76 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/java.policy.allow | 3 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/java.policy.deny | 3 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel/Basic.java | 805 +++ overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel/Leaky.java | 104 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/Channels/Basic2.java | 172 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/CheckProvider.java | 38 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/META-INF/services/java.nio.channels.spi.AsynchronousChannelProvider | 1 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/Provider1.java | 62 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/Provider2.java | 62 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/custom_provider.sh | 71 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/Basic.java | 153 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/Filters.java | 241 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/SecureDS.java | 370 + overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/FileStore/Basic.java | 79 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/FileSystem/Basic.java | 82 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/ContentType.java | 91 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/CreateFileTree.java | 96 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/ForceLoad.java | 38 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/META-INF/services/java.nio.file.spi.FileTypeDetector | 1 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/Misc.java | 126 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/PrintFileTree.java | 78 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/SimpleFileTypeDetector.java | 47 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/SkipSiblings.java | 85 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/TerminateWalk.java | 70 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/content_type.sh | 70 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/walk_file_tree.sh | 86 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/CopyAndMove.java | 983 +++ overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/DeleteOnClose.java | 77 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/InterruptCopy.java | 117 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/Links.java | 143 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/Misc.java | 349 + overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/PathOps.java | 646 ++ overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/SBC.java | 468 + overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/TemporaryFiles.java | 76 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/UriImportExport.java | 80 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/delete_on_close.sh | 61 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/temporary_files.sh | 65 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/PathMatcher/Basic.java | 163 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/TestUtil.java | 117 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/Basic.java | 493 + overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/FileTreeModifier.java | 148 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/WithSecurityManager.java | 83 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/denyAll.policy | 3 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirAndOneLevel.policy | 5 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirAndTree.policy | 5 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirOnly.policy | 4 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView/Basic.java | 166 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/Attributes/Basic.java | 254 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributeView/Basic.java | 150 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributeView/Basic.java | 155 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/FileStoreAttributeView/Basic.java | 170 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView/Basic.java | 209 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView/Basic.java | 398 + overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/spi/SetDefaultProvider.java | 44 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/spi/TestProvider.java | 128 patches/ecj/icedtea-pr261.patch | 40 patches/icedtea-nio2.patch | 761 ++ patches/icedtea-pr261.patch | 40 diffs (truncated from 71109 to 500 lines): diff -r e34ba0ba2281 -r 2257885742d0 ChangeLog --- a/ChangeLog Mon Jan 12 17:29:21 2009 +0000 +++ b/ChangeLog Mon Jan 12 21:46:12 2009 +0000 @@ -1,3 +1,323 @@ 2009-01-12 Andrew Haley + + Initial import of NIO2 code. + * patches/ecj/icedtea-pr261.patch: Moved to general patches. + * Makefile.am: Add NIO2 patch. + * configure.ac: Add --enable-nio2 option (on by default). + * overlays/nio2/openjdk/jdk/make/mkdemo/nio/Makefile, + * overlays/nio2/openjdk/jdk/make/mkdemo/nio/ZipFileSystem/Makefile, + * overlays/nio2/openjdk/jdk/make/mksample/nio/aio/Makefile, + * overlays/nio2/openjdk/jdk/make/mksample/nio/file/Makefile, + * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedWatchEventModifier.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/File.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/FilePermission.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/Inputs.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/io/Outputs.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousByteChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/Channels.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/CompletionHandler.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileLock.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/package-info.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/package.html, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AccessDeniedException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AccessMode.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/AtomicMoveNotSupportedException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedDirectoryStreamException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedFileSystemException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ClosedWatchServiceException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/CopyOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryNotEmptyException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/DirectoryStreamFilters.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileAction.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileAlreadyExistsException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileRef.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileStore.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystem.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemAlreadyExistsException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystemNotFoundException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileSystems.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileTreeWalker.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitResult.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitor.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Files.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/InvalidPathException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/LinkOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/LinkPermission.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NoSuchFileException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NotDirectoryException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/NotLinkException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/OpenOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Path.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/PathMatcher.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Paths.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ProviderMismatchException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ProviderNotFoundException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/ReadOnlyFileSystemException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SecureDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SimpleFileVisitor.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardCopyOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardOpenOption.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/StandardWatchEventKind.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchEvent.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchKey.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/WatchService.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Watchable.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntry.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryFlag.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryPermission.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclEntryType.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/Attributes.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileAttribute.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileOwnerAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributes.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/GroupPrincipal.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermission.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermissions.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipal.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipalLookupService.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/UserPrincipalNotFoundException.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/package-info.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/package-info.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/package-info.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/Scanner.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AbstractFuture.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Cancellable.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/CompletedFuture.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/FileLockTable.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Groupable.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Invoker.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/PendingFuture.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ThreadPool.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractPoller.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Globs.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/MimeType.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/NativeBuffer.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/NativeBuffers.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Reflect.java, + * overlays/nio2/openjdk/jdk/src/share/sample/nio/aio/EchoServer.java, + * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/AclEdit.java, + * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Chmod.java, + * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Copy.java, + * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/DiskUsage.java, + * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/FileType.java, + * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/WatchDir.java, + * overlays/nio2/openjdk/jdk/src/share/sample/nio/file/Xdd.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileStore.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNativeDispatcher.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisAclFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileStore.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileSystem.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisNamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisNativeDispatcher.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/SolarisWatchService.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileKey.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileModeAttribute.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStoreAttributes.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixMountEntry.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixNativeDispatcher.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUriUtils.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/EPollPort.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/SolarisEventPort.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/ch/UnixAsynchronousSocketChannelImpl.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/GnomeFileTypeDetector.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/LinuxNativeDispatcher.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/LinuxWatchService.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/SolarisNativeDispatcher.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/SolarisWatchService.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/UnixCopyFile.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/UnixNativeDispatcher.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/genSolarisConstants.c, + * overlays/nio2/openjdk/jdk/src/solaris/native/sun/nio/fs/genUnixConstants.c, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/Iocp.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/PendingIoCache.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousFileChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousServerSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/WindowsAsynchronousSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/DefaultFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/DefaultFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/RegistryFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsConstants.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsException.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributeViews.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileCopy.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileStore.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystem.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsLinkSupport.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNativeDispatcher.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPath.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPathParser.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPathType.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsSecurity.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsSecurityDescriptor.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsUriSupport.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsUserPrincipals.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsWatchService.java, + * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/Iocp.c, + * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousFileChannelImpl.c, + * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousServerSocketChannelImpl.c, + * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/ch/WindowsAsynchronousSocketChannelImpl.c, + * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/fs/RegistryFileTypeDetector.c, + * overlays/nio2/openjdk/jdk/src/windows/native/sun/nio/fs/WindowsNativeDispatcher.c, + * overlays/nio2/openjdk/jdk/test/demo/nio/ZipFileSystem/Sanity.java, + * overlays/nio2/openjdk/jdk/test/demo/nio/ZipFileSystem/sanity.sh, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/io/Inputs/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/AsExecutor.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Attack.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/GroupOfOne.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Identity.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/PrivilegedThreadFactory.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Restart.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/Unbounded.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousChannelGroup/run_any_task.sh, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousDatagramChannel/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/CustomThreadPool.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/Lock.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel/MyThreadFactory.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/WithSecurityManager.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/java.policy.allow, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel/java.policy.deny, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel/Leaky.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/Channels/Basic2.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/CheckProvider.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/META-INF/services/java.nio.channels.spi.AsynchronousChannelProvider, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/Provider1.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/Provider2.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/channels/spi/AsynchronousChannelProvider/custom_provider.sh, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/Filters.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/DirectoryStream/SecureDS.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/FileStore/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/FileSystem/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/ContentType.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/CreateFileTree.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/ForceLoad.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/META-INF/services/java.nio.file.spi.FileTypeDetector, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/Misc.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/PrintFileTree.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/SimpleFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/SkipSiblings.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/TerminateWalk.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/content_type.sh, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Files/walk_file_tree.sh, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/CopyAndMove.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/DeleteOnClose.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/InterruptCopy.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/Links.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/Misc.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/PathOps.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/SBC.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/TemporaryFiles.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/UriImportExport.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/delete_on_close.sh, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/temporary_files.sh, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/PathMatcher/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/TestUtil.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/FileTreeModifier.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/WithSecurityManager.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/denyAll.policy, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirAndOneLevel.policy, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirAndTree.policy, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/WatchService/grantDirOnly.policy, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/Attributes/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/BasicFileAttributeView/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/DosFileAttributeView/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/FileStoreAttributeView/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView/Basic.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/spi/SetDefaultProvider.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/spi/TestProvider.java: Added. + * patches/icedtea-nio2.patch: New patch. + * patches/icedtea-pr261.patch: Moved from ecj-specific patches. + 2009-01-12 Andrew Haley * ports/hotspot/src/share/vm/shark/sharkBlock.cpp (SharkBlock::do_ldc): diff -r e34ba0ba2281 -r 2257885742d0 Makefile.am --- a/Makefile.am Mon Jan 12 17:29:21 2009 +0000 +++ b/Makefile.am Mon Jan 12 21:46:12 2009 +0000 @@ -643,7 +643,8 @@ ICEDTEA_PATCHES += \ patches/icedtea-samejvm-safe.patch \ patches/icedtea-6728542-epoll.patch \ patches/icedtea-io_util-overflow.patch \ - patches/icedtea-cc-interp-jvmti.patch + patches/icedtea-cc-interp-jvmti.patch \ + patches/icedtea-pr261.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ @@ -686,6 +687,10 @@ XRENDER_PATCHES = patches/xrender/icedte XRENDER_PATCHES = patches/xrender/icedtea-???.patch XRENDER_PATCH_FILES = $(sort $(wildcard $(abs_top_srcdir)/$(XRENDER_PATCHES))) ICEDTEA_PATCHES += $(sort $(subst $(abs_top_srcdir)/,,$(XRENDER_PATCH_FILES))) +endif + +if ENABLE_NIO2 +ICEDTEA_PATCHES += patches/icedtea-nio2.patch endif ICEDTEA_PATCHES += \ @@ -883,8 +888,11 @@ clean-patch-fsg: fi stamps/overlay.stamp: stamps/patch.stamp - cp -r $(abs_top_srcdir)/overlays/openjdk/* openjdk/ \ - && touch stamps/overlay.stamp + cp -r $(abs_top_srcdir)/overlays/openjdk/* openjdk/ +if ENABLE_NIO2 + cp -r $(abs_top_srcdir)/overlays/nio2/openjdk/* openjdk/ +endif + touch stamps/overlay.stamp # OpenJDK ecj Source Preparation Targets # ====================================== @@ -927,8 +935,7 @@ ICEDTEA_ECJ_PATCHES = patches/ecj/icedte ICEDTEA_ECJ_PATCHES = patches/ecj/icedtea.patch \ patches/ecj/icedtea-hotspot-$(HSBUILD).patch \ patches/ecj/icedtea-spp.patch \ - patches/ecj/icedtea-jopt.patch \ - patches/ecj/icedtea-pr261.patch + patches/ecj/icedtea-jopt.patch stamps/patch-ecj.stamp: stamps/extract-ecj.stamp mkdir -p stamps; \ diff -r e34ba0ba2281 -r 2257885742d0 configure.ac --- a/configure.ac Mon Jan 12 17:29:21 2009 +0000 +++ b/configure.ac Mon Jan 12 21:46:12 2009 +0000 @@ -148,6 +148,14 @@ AC_ARG_ENABLE([xrender], [ENABLE_XRENDER="${enableval}"], [ENABLE_XRENDER='yes']) AM_CONDITIONAL([ENABLE_XRENDER], [test x$ENABLE_XRENDER = xyes]) AC_MSG_RESULT(${ENABLE_XRENDER}) + +AC_MSG_CHECKING(whether to include NIO2 support) +AC_ARG_ENABLE([nio2], + [AS_HELP_STRING([--disable-nio2], + [Disable inclusion of backported NIO2])], + [ENABLE_XRENDER="${enableval}"], [ENABLE_NIO2='yes']) +AM_CONDITIONAL([ENABLE_NIO2], [test x$ENABLE_NIO2 = xyes]) +AC_MSG_RESULT(${ENABLE_NIO2}) AC_MSG_CHECKING(whether to build VisualVM) AC_ARG_ENABLE([visualvm], diff -r e34ba0ba2281 -r 2257885742d0 overlays/nio2/openjdk/jdk/make/mkdemo/nio/Makefile --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/make/mkdemo/nio/Makefile Mon Jan 12 21:46:12 2009 +0000 @@ -0,0 +1,37 @@ +# +# Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Sun designates this +# particular file as subject to the "Classpath" exception as provided +# by Sun in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, +# CA 95054 USA or visit www.sun.com if you need additional information or +# have any questions. +# + +# +# Makefile for building the NIO demo(s) +# + +BUILDDIR = ../.. +PRODUCT = demos +include $(BUILDDIR)/common/Defs.gmk + +SUBDIRS = ZipFileSystem + +all build clean clobber:: + $(SUBDIRS-loop) diff -r e34ba0ba2281 -r 2257885742d0 overlays/nio2/openjdk/jdk/make/mkdemo/nio/ZipFileSystem/Makefile --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/make/mkdemo/nio/ZipFileSystem/Makefile Mon Jan 12 21:46:12 2009 +0000 @@ -0,0 +1,40 @@ +# +# Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Sun designates this +# particular file as subject to the "Classpath" exception as provided +# by Sun in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. +# +# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, +# CA 95054 USA or visit www.sun.com if you need additional information or +# have any questions. +# + +BUILDDIR = ../../.. +PRODUCT = demo/nio +DEMONAME = ZipFileSystem +include $(BUILDDIR)/common/Defs.gmk + +DEMO_ROOT = $(SHARE_SRC)/demo/nio/$(DEMONAME) +DEMO_TOPFILES = ./README.txt +DEMO_MAINCLASS = $(DEMONAME) +DEMO_DESTDIR = $(DEMODIR)/nio/$(DEMONAME) + +# +# Demo jar building rules. +# +include $(BUILDDIR)/common/Demo.gmk + diff -r e34ba0ba2281 -r 2257885742d0 overlays/nio2/openjdk/jdk/make/mksample/nio/aio/Makefile --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/make/mksample/nio/aio/Makefile Mon Jan 12 21:46:12 2009 +0000 @@ -0,0 +1,50 @@ +# +# Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# This code is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 only, as +# published by the Free Software Foundation. Sun designates this +# particular file as subject to the "Classpath" exception as provided +# by Sun in the LICENSE file that accompanied this code. +# +# This code is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +# version 2 for more details (a copy is included in the LICENSE file that +# accompanied this code). +# +# You should have received a copy of the GNU General Public License version +# 2 along with this work; if not, write to the Free Software Foundation, From gnu_andrew at member.fsf.org Tue Feb 3 04:13:56 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:56 +0000 Subject: changeset in /hg/icedtea6: Merge. Message-ID: changeset b2de95a6931c in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=b2de95a6931c description: Merge. diffstat: 7 files changed, 362 insertions(+), 30 deletions(-) ChangeLog | 13 HACKING | 4 Makefile.am | 2 contrib/jck/compile-native-code.sh | 25 + patches/hotspot/14.0b08/icedtea-6791168.patch | 230 ++++++++++++++++ patches/hotspot/14.0b08/icedtea-hotspot-dispatch.patch | 11 patches/hotspot/14.0b08/icedtea-includedb.patch | 107 ++++++- diffs (478 lines): diff -r 981d5e01b698 -r b2de95a6931c ChangeLog --- a/ChangeLog Tue Jan 13 16:37:09 2009 +0000 +++ b/ChangeLog Tue Jan 13 16:38:40 2009 +0000 @@ -52,6 +52,10 @@ 2009-01-12 Andrew John Hughes + + * contrib/jck/compile-native-code.sh: Build with -m32 or -m64. 2009-01-12 Andrew John Hughes @@ -372,6 +376,15 @@ 2009-01-12 Andrew John Hughes + + * patches/hotspot/14.0b08/icedtea-hotspot-dispatch.patch: Remove, + replaced by ... + * patches/hotspot/14.0b08/icedtea-6791168.patch: New. + * patches/hotspot/14.0b08/icedtea-includedb.patch: Update. + * HACKING: Update for the above. + * Makefile.am: Update for the above. 2009-01-12 Andrew Haley diff -r 981d5e01b698 -r b2de95a6931c HACKING --- a/HACKING Tue Jan 13 16:37:09 2009 +0000 +++ b/HACKING Tue Jan 13 16:38:40 2009 +0000 @@ -80,9 +80,9 @@ The following patches are currently appl * icedtea-cc-interp-jvmti.patch: Disable some JVMTI capabilities which are unsupported or do not work with the C++ interpreter. * icedtea-a11y-property-change.patch: Dont fire PropertyChangeEvent if the property hasnt changed. * icedtea-demo-swingapplet.patch: Add missing html file needed to run the demo. -* icedtea-hotspot-dispatch.patch: Fix build failure with GCC-4.4 (PR 38725). +* icedtea-6791168.patch: Fix build failure with GCC-4.4 (PR 38725) and compiler warnings. * icedtea-no-precompiled.patch: Don't use precompiled header files in hotspot. -* icedtea-includedb.patch: Add missing include. +* icedtea-includedb.patch: Add missing include files. * icedtea-awt-window-size.patch: Fix X11 window size calculation (S6721088). The following patches are only applied to OpenJDK6 in IcedTea6: diff -r 981d5e01b698 -r b2de95a6931c Makefile.am --- a/Makefile.am Tue Jan 13 16:37:09 2009 +0000 +++ b/Makefile.am Tue Jan 13 16:38:40 2009 +0000 @@ -651,7 +651,7 @@ ICEDTEA_PATCHES += \ patches/icedtea-format-warnings.patch \ patches/icedtea-fortify-source.patch \ patches/hotspot/$(HSBUILD)/icedtea-sparc-buildfixes.patch \ - patches/hotspot/$(HSBUILD)/icedtea-hotspot-dispatch.patch \ + patches/hotspot/$(HSBUILD)/icedtea-6791168.patch \ patches/hotspot/$(HSBUILD)/icedtea-includedb.patch endif diff -r 981d5e01b698 -r b2de95a6931c contrib/jck/compile-native-code.sh --- a/contrib/jck/compile-native-code.sh Tue Jan 13 16:37:09 2009 +0000 +++ b/contrib/jck/compile-native-code.sh Tue Jan 13 16:38:40 2009 +0000 @@ -17,6 +17,19 @@ if [ -z $basedir ]; then exit 1 fi +arch=$(uname -m) +case "$arch" in + i?86|ppc) + MFLAG=-m32 + ;; + x86_64|ppc64) + MFLAG=-m64 + ;; + *) + echo 1>&2 "error: unhandled arch '$arch'" + exit 1 +esac + LIBDIR=$basedir/lib RESDIR=$basedir/resources @@ -29,31 +42,31 @@ cp -r $JCKDIR/tests/api/javax_management cp -r $JCKDIR/tests/api/javax_management/loading/data/* $RESDIR chmod -R +w $RESDIR -gcc -fPIC -shared -o $LIBDIR/libjckatr.so -I$JCKDIR \ +gcc $MFLAG -fPIC -shared -o $LIBDIR/libjckatr.so -I$JCKDIR \ $JCKDIR/src/share/lib/atr/jckatr.c -gcc -fPIC -shared -o $LIBDIR/libjckjni.so -I$JCKDIR \ +gcc $MFLAG -fPIC -shared -o $LIBDIR/libjckjni.so -I$JCKDIR \ -I$JCKDIR/src/share/lib/jni/include \ -I$JCKDIR/src/share/lib/jni/include/solaris \ $JCKDIR/src/share/lib/jni/jckjni.c -gcc -fPIC -shared -o $LIBDIR/libjckjvmti.so -I$JCKDIR \ +gcc $MFLAG -fPIC -shared -o $LIBDIR/libjckjvmti.so -I$JCKDIR \ -I$JCKDIR/src/share/lib/jvmti/include \ -I$JCKDIR/src/share/lib/jni/include \ -I$JCKDIR/src/share/lib/jni/include/solaris \ $JCKDIR/src/share/lib/jvmti/jckjvmti.c -gcc -fPIC -shared -o $LIBDIR/libsystemInfo.so \ +gcc $MFLAG -fPIC -shared -o $LIBDIR/libsystemInfo.so \ -I$JCKDIR/src/share/lib/jni/include \ -I$JCKDIR/src/share/lib/jni/include/solaris \ $JCKDIR/tests/api/javax_management/loading/data/archives/src/C/com_sun_management_mbeans_loading_SystemInfoUseNativeLib.c -gcc -fPIC -shared -o $LIBDIR/libjmxlibid.so \ +gcc $MFLAG -fPIC -shared -o $LIBDIR/libjmxlibid.so \ -I$JCKDIR/src/share/lib/jni/include \ -I$JCKDIR/src/share/lib/jni/include/solaris \ $JCKDIR/tests/api/javax_management/loading/data/archives/src/C/com_sun_management_mbeans_loading_GetLibIdFromNativeLib.c -gcc -fPIC -shared -o $LIBDIR/libgenrandom.so \ +gcc $MFLAG -fPIC -shared -o $LIBDIR/libgenrandom.so \ -I$JCKDIR/src/share/lib/jni/include \ -I$JCKDIR/src/share/lib/jni/include/solaris \ $JCKDIR/tests/api/javax_management/loading/data/archives/src/C/com_sun_management_mbeans_loading_RandomGen.c diff -r 981d5e01b698 -r b2de95a6931c patches/hotspot/14.0b08/icedtea-6791168.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/hotspot/14.0b08/icedtea-6791168.patch Tue Jan 13 16:38:40 2009 +0000 @@ -0,0 +1,230 @@ +--- openjdk/hotspot/src/cpu/x86/vm/cppInterpreter_x86.cpp.orig 2009-01-13 10:15:42.000000000 +0000 ++++ openjdk/hotspot/src/cpu/x86/vm/cppInterpreter_x86.cpp 2009-01-13 10:17:05.000000000 +0000 +@@ -594,7 +594,7 @@ + __ call_VM(noreg, CAST_FROM_FN_PTR(address, InterpreterRuntime::frequency_counter_overflow), rax); + + // for c++ interpreter can rsi really be munged? +- __ lea(state, Address(rbp, -sizeof(BytecodeInterpreter))); // restore state ++ __ lea(state, Address(rbp, -(int)sizeof(BytecodeInterpreter))); // restore state + __ movptr(rbx, Address(state, byte_offset_of(BytecodeInterpreter, _method))); // restore method + __ movptr(rdi, Address(state, byte_offset_of(BytecodeInterpreter, _locals))); // get locals pointer + +@@ -658,7 +658,7 @@ + const Address size_of_stack (rbx, methodOopDesc::max_stack_offset()); + // Always give one monitor to allow us to start interp if sync method. + // Any additional monitors need a check when moving the expression stack +- const one_monitor = frame::interpreter_frame_monitor_size() * wordSize; ++ const int one_monitor = frame::interpreter_frame_monitor_size() * wordSize; + __ load_unsigned_word(rax, size_of_stack); // get size of expression stack in words + __ lea(rax, Address(noreg, rax, Interpreter::stackElementScale(), one_monitor)); + __ lea(rax, Address(rax, rdx, Interpreter::stackElementScale(), overhead_size)); +@@ -1829,7 +1829,7 @@ + Label unwind_and_forward; + + // restore state pointer. +- __ lea(state, Address(rbp, -sizeof(BytecodeInterpreter))); ++ __ lea(state, Address(rbp, -(int)sizeof(BytecodeInterpreter))); + + __ movptr(rbx, STATE(_method)); // get method + #ifdef _LP64 +@@ -1877,14 +1877,14 @@ + + // The FPU stack is clean if UseSSE >= 2 but must be cleaned in other cases + if (UseSSE < 2) { +- __ lea(state, Address(rbp, -sizeof(BytecodeInterpreter))); ++ __ lea(state, Address(rbp, -(int)sizeof(BytecodeInterpreter))); + __ movptr(rbx, STATE(_result._to_call._callee)); // get method just executed + __ movl(rcx, Address(rbx, methodOopDesc::result_index_offset())); + __ cmpl(rcx, AbstractInterpreter::BasicType_as_index(T_FLOAT)); // Result stub address array index + __ jcc(Assembler::equal, do_float); + __ cmpl(rcx, AbstractInterpreter::BasicType_as_index(T_DOUBLE)); // Result stub address array index + __ jcc(Assembler::equal, do_double); +-#ifdef COMPILER2 ++#if !defined(_LP64) || defined(COMPILER1) || !defined(COMPILER2) + __ empty_FPU_stack(); + #endif // COMPILER2 + __ jmp(done_conv); +@@ -1928,7 +1928,7 @@ + + // Restore rsi/r13 as compiled code may not preserve it + +- __ lea(state, Address(rbp, -sizeof(BytecodeInterpreter))); ++ __ lea(state, Address(rbp, -(int)sizeof(BytecodeInterpreter))); + + // restore stack to what we had when we left (in case i2c extended it) + +@@ -1942,7 +1942,7 @@ + #else + __ movptr(rcx, STATE(_thread)); // get thread + __ cmpptr(Address(rcx, Thread::pending_exception_offset()), (int32_t)NULL_WORD); +-#endif / __LP64 ++#endif // _LP64 + __ jcc(Assembler::notZero, return_with_exception); + + // get method just executed +--- openjdk/hotspot/src/cpu/x86/vm/frame_x86.inline.hpp.orig 2009-01-13 10:15:42.000000000 +0000 ++++ openjdk/hotspot/src/cpu/x86/vm/frame_x86.inline.hpp 2009-01-13 10:17:05.000000000 +0000 +@@ -139,7 +139,7 @@ + #ifdef CC_INTERP + + inline interpreterState frame::get_interpreterState() const { +- return ((interpreterState)addr_at( -sizeof(BytecodeInterpreter)/wordSize )); ++ return ((interpreterState)addr_at( -((int)sizeof(BytecodeInterpreter))/wordSize )); + } + + inline intptr_t* frame::sender_sp() const { +--- openjdk/hotspot/src/cpu/x86/vm/assembler_x86.cpp.orig 2009-01-13 10:15:42.000000000 +0000 ++++ openjdk/hotspot/src/cpu/x86/vm/assembler_x86.cpp 2009-01-13 10:17:05.000000000 +0000 +@@ -6943,29 +6943,32 @@ + + Label slow_case, done; + +- // x ?<= pi/4 +- fld_d(ExternalAddress((address)&pi_4)); +- fld_s(1); // Stack: X PI/4 X +- fabs(); // Stack: |X| PI/4 X +- fcmp(tmp); +- jcc(Assembler::above, slow_case); +- +- // fastest case: -pi/4 <= x <= pi/4 +- switch(trig) { +- case 's': +- fsin(); +- break; +- case 'c': +- fcos(); +- break; +- case 't': +- ftan(); +- break; +- default: +- assert(false, "bad intrinsic"); +- break; ++ ExternalAddress pi4_adr = (address)&pi_4; ++ if (reachable(pi4_adr)) { ++ // x ?<= pi/4 ++ fld_d(pi4_adr); // ExternalAddress((address)&pi_4)); ++ fld_s(1); // Stack: X PI/4 X ++ fabs(); // Stack: |X| PI/4 X ++ fcmp(tmp); ++ jcc(Assembler::above, slow_case); ++ ++ // fastest case: -pi/4 <= x <= pi/4 ++ switch(trig) { ++ case 's': ++ fsin(); ++ break; ++ case 'c': ++ fcos(); ++ break; ++ case 't': ++ ftan(); ++ break; ++ default: ++ assert(false, "bad intrinsic"); ++ break; ++ } ++ jmp(done); + } +- jmp(done); + + // slow case: runtime call + bind(slow_case); +--- openjdk/hotspot/src/cpu/x86/vm/sharedRuntime_x86_64.cpp.orig 2009-01-13 10:15:42.000000000 +0000 ++++ openjdk/hotspot/src/cpu/x86/vm/sharedRuntime_x86_64.cpp 2009-01-13 10:17:05.000000000 +0000 +@@ -2954,10 +2954,16 @@ + __ pushptr(Address(rcx, 0)); // Save return address + __ enter(); // Save old & set new rbp + __ subptr(rsp, rbx); // Prolog ++#ifdef CC_INTERP ++ __ movptr(Address(rbp, ++ -(sizeof(BytecodeInterpreter)) + in_bytes(byte_offset_of(BytecodeInterpreter, _sender_sp))), ++ sender_sp); // Make it walkable ++#else // CC_INTERP + __ movptr(Address(rbp, frame::interpreter_frame_sender_sp_offset * wordSize), + sender_sp); // Make it walkable + // This value is corrected by layout_activation_impl + __ movptr(Address(rbp, frame::interpreter_frame_last_sp_offset * wordSize), (int32_t)NULL_WORD ); ++#endif // CC_INTERP + __ mov(sender_sp, rsp); // Pass sender_sp to next frame + __ addptr(rsi, wordSize); // Bump array pointer (sizes) + __ addptr(rcx, wordSize); // Bump array pointer (pcs) +--- openjdk/hotspot/src/cpu/x86/vm/bytecodeInterpreter_x86.inline.hpp.orig 2009-01-13 10:15:42.000000000 +0000 ++++ openjdk/hotspot/src/cpu/x86/vm/bytecodeInterpreter_x86.inline.hpp 2009-01-13 10:17:05.000000000 +0000 +@@ -213,7 +213,7 @@ + + inline jint BytecodeInterpreter::VMintDiv(jint op1, jint op2) { + /* it's possible we could catch this special case implicitly */ +- if (op1 == 0x80000000 && op2 == -1) return op1; ++ if ((juint)op1 == 0x80000000 && op2 == -1) return op1; + else return op1 / op2; + } + +@@ -231,7 +231,7 @@ + + inline jint BytecodeInterpreter::VMintRem(jint op1, jint op2) { + /* it's possible we could catch this special case implicitly */ +- if (op1 == 0x80000000 && op2 == -1) return 0; ++ if ((juint)op1 == 0x80000000 && op2 == -1) return 0; + else return op1 % op2; + } + +--- openjdk/hotspot/src/cpu/x86/vm/interp_masm_x86_64.cpp.orig 2009-01-13 10:15:42.000000000 +0000 ++++ openjdk/hotspot/src/cpu/x86/vm/interp_masm_x86_64.cpp 2009-01-13 10:17:05.000000000 +0000 +@@ -30,7 +30,7 @@ + + #ifdef CC_INTERP + void InterpreterMacroAssembler::get_method(Register reg) { +- movptr(reg, Address(rbp, -(sizeof(BytecodeInterpreter) + 2 * wordSize))); ++ movptr(reg, Address(rbp, -((int)sizeof(BytecodeInterpreter) + 2 * wordSize))); + movptr(reg, Address(reg, byte_offset_of(BytecodeInterpreter, _method))); + } + #endif // CC_INTERP +--- openjdk/hotspot/src/share/vm/interpreter/bytecodeInterpreter.cpp.orig 2009-01-13 10:16:45.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/interpreter/bytecodeInterpreter.cpp 2009-01-13 10:17:05.000000000 +0000 +@@ -163,7 +163,7 @@ + #ifdef USELABELS + // Have to do this dispatch this way in C++ because otherwise gcc complains about crossing an + // initialization (which is is the initialization of the table pointer...) +-#define DISPATCH(opcode) goto *dispatch_table[opcode] ++#define DISPATCH(opcode) goto *(void*)dispatch_table[opcode] + #define CONTINUE { \ + opcode = *pc; \ + DO_UPDATE_INSTRUCTION_COUNT(opcode); \ +@@ -341,7 +341,7 @@ + */ + #undef CHECK_NULL + #define CHECK_NULL(obj_) \ +- if ((obj_) == 0) { \ ++ if ((obj_) == NULL) { \ + VM_JAVA_ERROR(vmSymbols::java_lang_NullPointerException(), ""); \ + } + +@@ -1362,7 +1362,7 @@ + + #define NULL_COMPARISON_NOT_OP(name) \ + CASE(_if##name): { \ +- int skip = (!(STACK_OBJECT(-1) == 0)) \ ++ int skip = (!(STACK_OBJECT(-1) == NULL)) \ + ? (int16_t)Bytes::get_Java_u2(pc + 1) : 3; \ + address branch_pc = pc; \ + UPDATE_PC_AND_TOS(skip, -1); \ +@@ -1372,7 +1372,7 @@ + + #define NULL_COMPARISON_OP(name) \ + CASE(_if##name): { \ +- int skip = ((STACK_OBJECT(-1) == 0)) \ ++ int skip = ((STACK_OBJECT(-1) == NULL)) \ + ? (int16_t)Bytes::get_Java_u2(pc + 1) : 3; \ + address branch_pc = pc; \ + UPDATE_PC_AND_TOS(skip, -1); \ +--- openjdk/hotspot/src/share/vm/interpreter/bytecodeInterpreter.hpp.orig 2009-01-13 10:15:42.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/interpreter/bytecodeInterpreter.hpp 2009-01-13 10:17:05.000000000 +0000 +@@ -66,7 +66,6 @@ + friend class InterpreterGenerator; + friend class InterpreterMacroAssembler; + friend class frame; +-friend class SharedRuntime; + friend class VMStructs; + + public: diff -r 981d5e01b698 -r b2de95a6931c patches/hotspot/14.0b08/icedtea-hotspot-dispatch.patch --- a/patches/hotspot/14.0b08/icedtea-hotspot-dispatch.patch Tue Jan 13 16:37:09 2009 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,11 +0,0 @@ ---- openjdk/hotspot/src/share/vm/interpreter/bytecodeInterpreter.cpp.old 2009-01-06 16:16:57.000000000 -0700 -+++ openjdk/hotspot/src/share/vm/interpreter/bytecodeInterpreter.cpp 2009-01-06 16:17:53.000000000 -0700 -@@ -163,7 +163,7 @@ - #ifdef USELABELS - // Have to do this dispatch this way in C++ because otherwise gcc complains about crossing an - // initialization (which is is the initialization of the table pointer...) --#define DISPATCH(opcode) goto *dispatch_table[opcode] -+#define DISPATCH(opcode) goto *(void *)dispatch_table[opcode] - #define CONTINUE { \ - opcode = *pc; \ - DO_UPDATE_INSTRUCTION_COUNT(opcode); \ diff -r 981d5e01b698 -r b2de95a6931c patches/hotspot/14.0b08/icedtea-includedb.patch --- a/patches/hotspot/14.0b08/icedtea-includedb.patch Tue Jan 13 16:37:09 2009 +0000 +++ b/patches/hotspot/14.0b08/icedtea-includedb.patch Tue Jan 13 16:38:40 2009 +0000 @@ -1,10 +1,97 @@ ---- openjdk/hotspot/src/share/vm/includeDB_core.orig 2008-11-21 17:11:18.000000000 -0700 -+++ openjdk/hotspot/src/share/vm/includeDB_core 2009-01-08 14:32:58.000000000 -0700 -@@ -1314,6 +1314,7 @@ - cppInterpreter_.cpp interpreterRuntime.hpp - cppInterpreter_.cpp interpreter.hpp - cppInterpreter_.cpp interpreterGenerator.hpp -+cppInterpreter_.cpp interfaceSupport.hpp - cppInterpreter_.cpp jvmtiExport.hpp - cppInterpreter_.cpp jvmtiThreadState.hpp - cppInterpreter_.cpp methodDataOop.hpp +--- openjdk/hotspot/src/share/vm/includeDB_compiler2.orig 2009-01-13 10:10:44.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/includeDB_compiler2 2009-01-13 10:11:17.000000000 +0000 +@@ -140,6 +140,7 @@ + c2_globals_.hpp macros.hpp + + c2_init_.cpp compile.hpp ++c2_init_.cpp node.hpp + + c2compiler.cpp ad_.hpp + c2compiler.cpp c2compiler.hpp +@@ -839,6 +840,7 @@ + phase.cpp compile.hpp + phase.cpp compileBroker.hpp + phase.cpp nmethod.hpp ++phase.cpp node.hpp + phase.cpp phase.hpp + + phase.hpp port.hpp +--- openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_g1.orig 2009-01-13 10:10:44.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_g1 2009-01-13 10:11:17.000000000 +0000 +@@ -34,6 +34,7 @@ + collectionSetChooser.cpp g1CollectedHeap.hpp + collectionSetChooser.cpp g1CollectorPolicy.hpp + collectionSetChooser.cpp collectionSetChooser.hpp ++collectionSetChooser.cpp space.inline.hpp + + collectionSetChooser.hpp heapRegion.hpp + collectionSetChooser.hpp growableArray.hpp +@@ -44,6 +45,7 @@ + concurrentG1Refine.cpp copy.hpp + concurrentG1Refine.cpp g1CollectedHeap.hpp + concurrentG1Refine.cpp g1RemSet.hpp ++concurrentG1Refine.cpp space.inline.hpp + + concurrentG1Refine.hpp globalDefinitions.hpp + +@@ -264,7 +266,7 @@ + heapRegion.cpp iterator.hpp + heapRegion.cpp oop.inline.hpp + +-heapRegion.hpp space.hpp ++heapRegion.hpp space.inline.hpp + heapRegion.hpp spaceDecorator.hpp + heapRegion.hpp g1BlockOffsetTable.inline.hpp + heapRegion.hpp watermark.hpp +--- openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_parallelScavenge.orig 2009-01-13 10:10:44.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_parallelScavenge 2009-01-13 10:11:17.000000000 +0000 +@@ -306,6 +306,8 @@ + psPermGen.cpp psMarkSweepDecorator.hpp + psPermGen.cpp psParallelCompact.hpp + psPermGen.cpp psPermGen.hpp ++psPermGen.cpp markOop.inline.hpp ++psPermGen.cpp markSweep.inline.hpp + + psPermGen.hpp psOldGen.hpp + +--- openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_concurrentMarkSweep.orig 2009-01-13 10:10:44.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_concurrentMarkSweep 2009-01-13 10:11:17.000000000 +0000 +@@ -28,6 +28,7 @@ + binaryTreeDictionary.cpp binaryTreeDictionary.hpp + binaryTreeDictionary.cpp globals.hpp + binaryTreeDictionary.cpp ostream.hpp ++binaryTreeDictionary.cpp space.inline.hpp + binaryTreeDictionary.cpp spaceDecorator.hpp + + binaryTreeDictionary.hpp freeBlockDictionary.hpp +--- openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_parNew.orig 2009-01-13 10:10:44.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/gc_implementation/includeDB_gc_parNew 2009-01-13 10:11:17.000000000 +0000 +@@ -29,6 +29,8 @@ + asParNewGeneration.cpp cmsAdaptiveSizePolicy.hpp + asParNewGeneration.cpp cmsGCAdaptivePolicyCounters.hpp + asParNewGeneration.cpp defNewGeneration.inline.hpp ++asParNewGeneration.cpp markOop.inline.hpp ++asParNewGeneration.cpp markSweep.inline.hpp + asParNewGeneration.cpp oop.pcgc.inline.hpp + asParNewGeneration.cpp parNewGeneration.hpp + asParNewGeneration.cpp referencePolicy.hpp +@@ -40,7 +42,7 @@ + parCardTableModRefBS.cpp java.hpp + parCardTableModRefBS.cpp mutexLocker.hpp + parCardTableModRefBS.cpp sharedHeap.hpp +-parCardTableModRefBS.cpp space.hpp ++parCardTableModRefBS.cpp space.inline.hpp + parCardTableModRefBS.cpp universe.hpp + parCardTableModRefBS.cpp virtualspace.hpp + +--- openjdk/hotspot/src/share/vm/includeDB_features.orig 2009-01-13 10:10:44.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/includeDB_features 2009-01-13 10:11:17.000000000 +0000 +@@ -59,6 +59,8 @@ + + dump_.cpp assembler_.inline.hpp + dump_.cpp compactingPermGenGen.hpp ++dump_.cpp generation.inline.hpp ++dump_.cpp space.inline.hpp + + forte.cpp collectedHeap.inline.hpp + forte.cpp debugInfoRec.hpp From gnu_andrew at member.fsf.org Tue Feb 3 04:13:56 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:56 +0000 Subject: changeset in /hg/icedtea6: More NIO build fixes. Message-ID: changeset 3f4c11b93ded in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=3f4c11b93ded description: More NIO build fixes. 2009-01-13 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardProtocolFamily.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardSocketOption.java: Added missing files. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileLock.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MulticastChannel.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileTreeWalker.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitor.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Files.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Path.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Paths.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SecureDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SimpleFileVisitor.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/Attributes.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermissions.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileTypeDetector.java: Fixed imports. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/concurrent/ScheduledThreadPoolExecutor.java: Added. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaUtilConcurrentThreadPoolExecutorAccess.java: Added to allow access to private members of java.util.concurrent.ThreadPoolExecutor. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AbstractFuture.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java: Fix imports. * patches/icedtea-nio2.patch: Patch ThreadPoolExecutor to allow access to private variables, add missing files to nio/FILES_java.gmk diffstat: 32 files changed, 1989 insertions(+), 31 deletions(-) ChangeLog | 41 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardProtocolFamily.java | 46 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardSocketOption.java | 370 ++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel.java | 5 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java | 12 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileLock.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MulticastChannel.java | 4 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileTreeWalker.java | 4 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitor.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Files.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Path.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Paths.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SecureDirectoryStream.java | 6 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SimpleFileVisitor.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView.java | 1 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/Attributes.java | 1 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributeView.java | 1 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView.java | 1 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermissions.java | 11 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java | 18 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java | 10 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileTypeDetector.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/concurrent/ScheduledThreadPoolExecutor.java | 1364 ++++++++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaUtilConcurrentThreadPoolExecutorAccess.java | 55 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AbstractFuture.java | 3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java | 3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java | 3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileTypeDetector.java | 2 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java | 1 patches/icedtea-nio2.patch | 35 diffs (truncated from 2405 to 500 lines): diff -r b2de95a6931c -r 3f4c11b93ded ChangeLog --- a/ChangeLog Tue Jan 13 16:38:40 2009 +0000 +++ b/ChangeLog Wed Jan 14 05:27:57 2009 +0000 @@ -1,3 +1,44 @@ 2009-01-12 Andrew John Hughes + + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardProtocolFamily.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardSocketOption.java: + Added missing files. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousSocketChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileLock.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/MulticastChannel.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileTreeWalker.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/FileVisitor.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Files.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Path.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/Paths.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SecureDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/SimpleFileVisitor.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/AclFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/Attributes.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/FileStoreSpaceAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/PosixFilePermissions.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileTypeDetector.java: + Fixed imports. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/concurrent/ScheduledThreadPoolExecutor.java: + Added. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaUtilConcurrentThreadPoolExecutorAccess.java: + Added to allow access to private members of java.util.concurrent.ThreadPoolExecutor. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AbstractFuture.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultAsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/DefaultFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java: + Fix imports. + * patches/icedtea-nio2.patch: + Patch ThreadPoolExecutor to allow access to private variables, add missing files to + nio/FILES_java.gmk + 2009-01-12 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java, diff -r b2de95a6931c -r 3f4c11b93ded overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardProtocolFamily.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardProtocolFamily.java Wed Jan 14 05:27:57 2009 +0000 @@ -0,0 +1,46 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 2009 Red Hat, Inc. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package org.classpath.icedtea.java.net; + +/** + * Defines the standard families of communication protocols. + * + * @since 1.7 + */ + +public enum StandardProtocolFamily implements ProtocolFamily { + + /** + * Internet Protocol Version 4 (IPv4) + */ + INET, + + /** + * Internet Protocol Version 6 (IPv6) + */ + INET6 +} diff -r b2de95a6931c -r 3f4c11b93ded overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardSocketOption.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardSocketOption.java Wed Jan 14 05:27:57 2009 +0000 @@ -0,0 +1,370 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 2009 Red Hat, Inc. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package org.classpath.icedtea.java.net; + +import java.net.NetworkInterface; + +/** + * Defines the standard socket options. + * + *

The {@link SocketOption#name name} of each socket option defined by this + * class is its field name. + * + *

In this release, the socket options defined here are used by {@link + * java.nio.channels.NetworkChannel network} channels in the {@link + * java.nio.channels channels} package. + * + * @since 1.7 + */ + +public final class StandardSocketOption { + private StandardSocketOption() { } + + // -- SOL_SOCKET -- + + /** + * Allow transmission of broadcast datagrams. + * + *

The value of this socket option is a {@code Boolean} that represents + * whether the option is enabled or disabled. The option is specific to + * datagram-oriented sockets sending to {@link java.net.Inet4Address IPv4} + * broadcast addresses. When the socket option is enabled then the socket + * can be used to send broadcast datagrams. + * + *

The initial value of this socket option is {@code FALSE}. The socket + * option may be enabled or disabled at any time. Some operating systems may + * require that the Java virtual machine be started with implementation + * specific privileges to enable this option or send broadcast datagrams. + * + * @see RFC 929: + * Broadcasting Internet Datagrams + * @see DatagramSocket#setBroadcast + */ + public static final SocketOption SO_BROADCAST = + new StdSocketOption("SO_BROADCAST", Boolean.class); + + /** + * Keep connection alive. + * + *

The value of this socket option is a {@code Boolean} that represents + * whether the option is enabled or disabled. When the {@code SO_KEEPALIVE} + * option is enabled the operating system may use a keep-alive + * mechanism to periodically probe the other end of a connection when the + * connection is otherwise idle. The exact semantics of the keep alive + * mechanism is system dependent and therefore unspecified. + * + *

The initial value of this socket option is {@code FALSE}. The socket + * option may be enabled or disabled at any time. + * + * @see RFC 1122 + * Requirements for Internet Hosts -- Communication Layers + * @see Socket#setKeepAlive + */ + public static final SocketOption SO_KEEPALIVE = + new StdSocketOption("SO_KEEPALIVE", Boolean.class); + + /** + * The size of the socket send buffer. + * + *

The value of this socket option is an {@code Integer} that is the + * size of the socket send buffer in bytes. The socket send buffer is an + * output buffer used by the networking implementation. It may need to be + * increased for high-volume connections. The value of the socket option is + * a hint to the implementation to size the buffer and the actual + * size may differ. The socket option can be queried to retrieve the actual + * size. + * + *

For datagram-oriented sockets, the size of the send buffer may limit + * the size of the datagrams that may be sent by the socket. Whether + * datagrams larger than the buffer size are sent or discarded is system + * dependent. + * + *

The initial/default size of the socket send buffer and the range of + * allowable values is system dependent although a negative size is not + * allowed. An attempt to set the socket send buffer to larger than its + * maximum size causes it to be set to its maximum size. + * + *

An implementation allows this socket option to be set before the + * socket is bound or connected. Whether an implementation allows the + * socket send buffer to be changed after the socket is bound is system + * dependent. + * + * @see Socket#setSendBufferSize + */ + public static final SocketOption SO_SNDBUF = + new StdSocketOption("SO_SNDBUF", Integer.class); + + + /** + * The size of the socket receive buffer. + * + *

The value of this socket option is an {@code Integer} that is the + * size of the socket receive buffer in bytes. The socket receive buffer is + * an input buffer used by the networking implementation. It may need to be + * increased for high-volume connections or decreased to limit the possible + * backlog of incoming data. The value of the socket option is a + * hint to the implementation to size the buffer and the actual + * size may differ. + * + *

For datagram-oriented sockets, the size of the receive buffer may + * limit the size of the datagrams that can be received. Whether datagrams + * larger than the buffer size can be received is system dependent. + * Increasing the socket receive buffer may be important for cases where + * datagrams arrive in bursts faster than they can be processed. + * + *

In the case of stream-oriented sockets and the TCP/IP protocol, the + * size of the socket receive buffer may be used when advertising the size + * of the TCP receive window to the remote peer. + * + *

The initial/default size of the socket receive buffer and the range + * of allowable values is system dependent although a negative size is not + * allowed. An attempt to set the socket receive buffer to larger than its + * maximum size causes it to be set to its maximum size. + * + *

An implementation allows this socket option to be set before the + * socket is bound or connected. Whether an implementation allows the + * socket receive buffer to be changed after the socket is bound is system + * dependent. + * + * @see RFC 1323: TCP + * Extensions for High Performance + * @see Socket#setReceiveBufferSize + * @see ServerSocket#setReceiveBufferSize + */ + public static final SocketOption SO_RCVBUF = + new StdSocketOption("SO_RCVBUF", Integer.class); + + /** + * Re-use address. + * + *

The value of this socket option is a {@code Boolean} that represents + * whether the option is enabled or disabled. The exact semantics of this + * socket option are socket type and system dependent. + * + *

In the case of stream-oriented sockets, this socket option will + * usually determine whether the socket can be bound to a socket address + * when a previous connection involving that socket address is in the + * TIME_WAIT state. On implementations where the semantics differ, + * and the socket option is not required to be enabled in order to bind the + * socket when a previous connection is in this state, then the + * implementation may choose to ignore this option. + * + *

For datagram-oriented sockets the socket option is used to allow + * multiple programs bind to the same address. This option should be enabled + * when the socket is to be used for Internet Protocol (IP) multicasting. + * + *

An implementation allows this socket option to be set before the + * socket is bound or connected. Changing the value of this socket option + * after the socket is bound has no effect. The default value of this + * socket option is system dependent. + * + * @see RFC 793: Transmission + * Control Protocol + * @see ServerSocket#setReuseAddress + */ + public static final SocketOption SO_REUSEADDR = + new StdSocketOption("SO_REUSEADDR", Boolean.class); + + /** + * Linger on close if data is present. + * + *

The value of this socket option is an {@code Integer} that controls + * the action taken when unsent data is queued on the socket and a method + * to close the socket is invoked. If the value of the socket option is zero + * or greater, then it represents a timeout value, in seconds, known as the + * linger interval. The linger interval is the timeout for the + * {@code close} method to block while the operating system attempts to + * transmit the unsent data or it decides that it is unable to transmit the + * data. If the value of the socket option is less than zero then the option + * is disabled. In that case the {@code close} method does not wait until + * unsent data is transmitted; if possible the operating system will transmit + * any unsent data before the connection is closed. + * + *

This socket option is intended for use with sockets that are configured + * in {@link java.nio.channels.SelectableChannel#isBlocking() blocking} mode + * only. The behavior of the {@code close} method when this option is + * enabled on a non-blocking socket is not defined. + * + *

The initial value of this socket option is a negative value, meaning + * that the option is disabled. The option may be enabled, or the linger + * interval changed, at any time. The maximum value of the linger interval + * is system dependent. Setting the linger interval to a value that is + * greater than its maximum value causes the linger interval to be set to + * its maximum value. + * + * @see Socket#setSoLinger + */ + public static final SocketOption SO_LINGER = + new StdSocketOption("SO_LINGER", Integer.class); + + + // -- IPPROTO_IP -- + + /** + * The Type of Service (ToS) octet in the Internet Protocol (IP) header. + * + *

The value of this socket option is an {@code Integer} representing + * the value of the ToS octet in IP packets sent by sockets to an {@link + * StandardProtocolFamily#INET IPv4} socket. The interpretation of the ToS + * octet is network specific and is not defined by this class. Further + * information on the ToS octet can be found in RFC 1349 and RFC 2474. The value + * of the socket option is a hint. An implementation may ignore the + * value, or ignore specific values. + * + *

The initial/default value of the TOS field in the ToS octet is + * implementation specific but will typically be {@code 0}. For + * datagram-oriented sockets the option may be configured at any time after + * the socket has been bound. The new value of the octet is used when sending + * subsequent datagrams. It is system dependent whether this option can be + * queried or changed prior to binding the socket. + * + *

The behavior of this socket option on a stream-oriented socket, or an + * {@link StandardProtocolFamily#INET6 IPv6} socket, is not defined in this + * release. + * + * @see DatagramSocket#setTrafficClass + */ + public static final SocketOption IP_TOS = + new StdSocketOption("IP_TOS", Integer.class); + + /** + * The network interface for Internet Protocol (IP) multicast datagrams. + * + *

The value of this socket option is a {@link NetworkInterface} that + * represents the outgoing interface for multicast datagrams sent by the + * datagram-oriented socket. For {@link StandardProtocolFamily#INET6 IPv6} + * sockets then it is system dependent whether setting this option also + * sets the outgoing interface for multlicast datagrams sent to IPv4 + * addresses. + * + *

The initial/default value of this socket option may be {@code null} + * to indicate that outgoing interface will be selected by the operating + * system, typically based on the network routing tables. An implementation + * allows this socket option to be set after the socket is bound. Whether + * the socket option can be queried or changed prior to binding the socket + * is system dependent. + * + * @see java.nio.channels.MulticastChannel + * @see MulticastSocket#setInterface + */ + public static final SocketOption IP_MULTICAST_IF = + new StdSocketOption("IP_MULTICAST_IF", NetworkInterface.class); + + /** + * The time-to-live for Internet Protocol (IP) multicast datagrams. + * + *

The value of this socket option is an {@code Integer} in the range + * 0 <= value <= 255. It is used to control + * the scope of multicast datagrams sent by the datagram-oriented socket. + * In the case of an {@link StandardProtocolFamily#INET IPv4} socket + * the option is the time-to-live (TTL) on multicast datagrams sent by the + * socket. Datagrams with a TTL of zero are not transmitted on the network + * but may be delivered locally. In the case of an {@link + * StandardProtocolFamily#INET6 IPv6} socket the option is the + * hop limit which is number of hops that the datagram can + * pass through before expiring on the network. For IPv6 sockets it is + * system dependent whether the option also sets the time-to-live + * on multicast datagrams sent to IPv4 addresses. + * + *

The initial/default value of the time-to-live setting is typically + * {@code 1}. An implementation allows this socket option to be set after + * the socket is bound. Whether the socket option can be queried or changed + * prior to binding the socket is system dependent. + * + * @see java.nio.channels.MulticastChannel + * @see MulticastSocket#setTimeToLive + */ + public static final SocketOption IP_MULTICAST_TTL = + new StdSocketOption("IP_MULTICAST_TTL", Integer.class); + + /** + * Loopback for Internet Protocol (IP) multicast datagrams. + * + *

The value of this socket option is a {@code Boolean} that controls + * the loopback of multicast datagrams. The value of the socket + * option represents if the option is enabled or disabled. + * + *

The exact semantics of this socket options are system dependent. + * In particular, it is system dependent whether the loopback applies to + * multicast datagrams sent from the socket or received by the socket. + * For {@link StandardProtocolFamily#INET6 IPv6} sockets then it is + * system dependent whether the option also applies to multicast datagrams + * sent to IPv4 addresses. + * + *

The initial/default value of this socket option is {@code TRUE}. An + * implementation allows this socket option to be set after the socket is + * bound. Whether the socket option can be queried or changed prior to + * binding the socket is system dependent. + * + * @see java.nio.channels.MulticastChannel + * @see MulticastSocket#setLoopbackMode + */ + public static final SocketOption IP_MULTICAST_LOOP = + new StdSocketOption("IP_MULTICAST_LOOP", Boolean.class); + + + // -- IPPROTO_TCP -- + + /** + * Disable the Nagle algorithm. + * + *

The value of this socket option is a {@code Boolean} that represents + * whether the option is enabled or disabled. The socket option is specific to + * stream-oriented sockets using the TCP/IP protocol. TCP/IP uses an algorithm + * known as The Nagle Algorithm to coalesce short segments and + * improve network efficiency. + * + *

The default value of this socket option is {@code FALSE}. The + * socket option should only be enabled in cases where it is known that the + * coalescing impacts performance. The socket option may be enabled at any + * time. In other words, the Nagle Algorithm can be disabled. Once the option + * is enabled, it is system dependent whether it can be subsequently + * disabled. If it cannot, then invoking the {@code setOption} method to + * disable the option has no effect. + * + * @see RFC 1122: + * Requirements for Internet Hosts -- Communication Layers + * @see Socket#setTcpNoDelay + */ + public static final SocketOption TCP_NODELAY = + new StdSocketOption("TCP_NODELAY", Boolean.class); + + + private static class StdSocketOption implements SocketOption { + private final String name; + private final Class type; + StdSocketOption(String name, Class type) { + this.name = name; + this.type = type; + } + public String name() { return name; } + public Class type() { return type; } + public String toString() { return name; } + } +} diff -r b2de95a6931c -r 3f4c11b93ded overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java Tue Jan 13 16:38:40 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousFileChannel.java Wed Jan 14 05:27:57 2009 +0000 @@ -34,10 +34,10 @@ import java.util.HashSet; import java.util.HashSet; import java.util.Collections; -import org.classpath.icedtea.java.nio.file.FileSystemProvider; import org.classpath.icedtea.java.nio.file.OpenOption; import org.classpath.icedtea.java.nio.file.Path; import org.classpath.icedtea.java.nio.file.attribute.FileAttribute; +import org.classpath.icedtea.java.nio.file.spi.FileSystemProvider; /** * An asynchronous channel for reading, writing, and manipulating a file. diff -r b2de95a6931c -r 3f4c11b93ded overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java Tue Jan 13 16:38:40 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/AsynchronousServerSocketChannel.java Wed Jan 14 05:27:57 2009 +0000 @@ -26,11 +26,11 @@ package org.classpath.icedtea.java.nio.channels; -import java.net.SocketOption; import java.net.SocketAddress; import java.util.concurrent.Future; import java.io.IOException; +import org.classpath.icedtea.java.net.SocketOption; From gnu_andrew at member.fsf.org Tue Feb 3 04:13:57 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:57 +0000 Subject: changeset in /hg/icedtea6: Add SharedSecrets stuff. Message-ID: changeset 9eb9c1670c99 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=9eb9c1670c99 description: Add SharedSecrets stuff. 2009-01-13 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaIODeleteOnExitAccess.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java: Add missing SharedSecrets files. diffstat: 3 files changed, 135 insertions(+) ChangeLog | 6 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaIODeleteOnExitAccess.java | 43 +++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java | 86 ++++++++++ diffs (150 lines): diff -r 3f4c11b93ded -r 9eb9c1670c99 ChangeLog --- a/ChangeLog Wed Jan 14 05:27:57 2009 +0000 +++ b/ChangeLog Wed Jan 14 05:29:15 2009 +0000 @@ -1,3 +1,9 @@ 2009-01-13 Andrew John Hughes + + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaIODeleteOnExitAccess.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java: + Add missing SharedSecrets files. + 2009-01-13 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardProtocolFamily.java, diff -r 3f4c11b93ded -r 9eb9c1670c99 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaIODeleteOnExitAccess.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaIODeleteOnExitAccess.java Wed Jan 14 05:29:15 2009 +0000 @@ -0,0 +1,43 @@ +/* JavaIODeleteOnExitAccess.java + Copyright (C) 2009 Red Hat, Inc. + +This file is part of IcedTea. + +IcedTea is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License as published by +the Free Software Foundation, version 2. + +IcedTea is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with IcedTea; see the file COPYING. If not, write to +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +Linking this library statically or dynamically with other modules is +making a combined work based on this library. Thus, the terms and +conditions of the GNU General Public License cover the whole +combination. + +As a special exception, the copyright holders of this library give you +permission to link this library with independent modules to produce an +executable, regardless of the license terms of these independent +modules, and to copy and distribute the resulting executable under +terms of your choice, provided that you also meet, for each linked +independent module, the terms and conditions of the license of that +module. An independent module is a module which is not derived from +or based on this library. If you modify this library, you may extend +this exception to your version of the library, but you are not +obligated to do so. If you do not wish to do so, delete this +exception statement from your version. + */ + +package org.classpath.icedtea.misc; + +public interface JavaIODeleteOnExitAccess +{ + void add(String path); +} diff -r 3f4c11b93ded -r 9eb9c1670c99 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java Wed Jan 14 05:29:15 2009 +0000 @@ -0,0 +1,86 @@ +/* SharedSecrets.java + Copyright (C) 2009 Red Hat, Inc. + +This file is part of IcedTea. + +IcedTea is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License as published by +the Free Software Foundation, version 2. + +IcedTea is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with IcedTea; see the file COPYING. If not, write to +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +Linking this library statically or dynamically with other modules is +making a combined work based on this library. Thus, the terms and +conditions of the GNU General Public License cover the whole +combination. + +As a special exception, the copyright holders of this library give you +permission to link this library with independent modules to produce an +executable, regardless of the license terms of these independent +modules, and to copy and distribute the resulting executable under +terms of your choice, provided that you also meet, for each linked +independent module, the terms and conditions of the license of that +module. An independent module is a module which is not derived from +or based on this library. If you modify this library, you may extend +this exception to your version of the library, but you are not +obligated to do so. If you do not wish to do so, delete this +exception statement from your version. + */ + +/** Based on sun.misc.SharedSecrets */ +package org.classpath.icedtea.misc; + +import sun.misc.Unsafe; + +/** A repository of "shared secrets", which are a mechanism for + calling implementation-private methods in another package without + using reflection. A package-private class implements a public + interface and provides the ability to call package-private methods + within that package; the object implementing that interface is + provided through a third package to which access is restricted. + This framework avoids the primary disadvantage of using reflection + for this purpose, namely the loss of compile-time checking. */ + +public class SharedSecrets +{ + private static final Unsafe unsafe = Unsafe.getUnsafe(); + private static JavaIODeleteOnExitAccess javaIODeleteOnExitAccess; + private static JavaUtilConcurrentThreadPoolExecutorAccess javaUtilConcurrentThreadPoolExecutorAccess; + + public static void setJavaIODeleteOnExitAccess(JavaIODeleteOnExitAccess jida) + { + javaIODeleteOnExitAccess = jida; + } + + public static JavaIODeleteOnExitAccess getJavaIODeleteOnExitAccess() + { + if (javaIODeleteOnExitAccess == null) + { + unsafe.ensureClassInitialized(java.io.File.class); + } + return javaIODeleteOnExitAccess; + } + + public static void setJavaUtilConcurrentThreadPoolExecutorAccess(JavaUtilConcurrentThreadPoolExecutorAccess juctpea) + { + javaUtilConcurrentThreadPoolExecutorAccess = juctpea; + } + + public static JavaUtilConcurrentThreadPoolExecutorAccess getJavaUtilConcurrentThreadPoolExecutorAccess() + { + if (javaUtilConcurrentThreadPoolExecutorAccess == null) + { + unsafe.ensureClassInitialized(java.util.concurrent.ThreadPoolExecutor.class); + } + return javaUtilConcurrentThreadPoolExecutorAccess; + } + +} From gnu_andrew at member.fsf.org Tue Feb 3 04:13:57 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:57 +0000 Subject: changeset in /hg/icedtea6: Fix some sun.nio.ch classes. Message-ID: changeset dbdaa8e2cf1f in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=dbdaa8e2cf1f description: Fix some sun.nio.ch classes. 2009-01-14 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: Extend java.nio.channels.FileChannel to minimise code. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/concurrent/ScheduledThreadPoolExecutor.java: Adapted to use the SharedSecrets backdoor. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaUtilConcurrentThreadPoolExecutorAccess.java: Add remaining methods needed for our ScheduledThreadPoolExecutor. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java: Create a ScheduledThreadPoolExecutor directly so ours is used. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java: Refer to AsynchronousFileLockImpl not FileLockImpl. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/FileLockTable.java: Fix imports. * patches/icedtea-nio2.patch: Update implementation of secrets interface. diffstat: 9 files changed, 86 insertions(+), 797 deletions(-) ChangeLog | 18 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java | 774 ---------- overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/concurrent/ScheduledThreadPoolExecutor.java | 25 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaUtilConcurrentThreadPoolExecutorAccess.java | 9 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java | 15 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java | 17 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/FileLockTable.java | 6 patches/icedtea-nio2.patch | 17 diffs (truncated from 1118 to 500 lines): diff -r 9eb9c1670c99 -r dbdaa8e2cf1f ChangeLog --- a/ChangeLog Wed Jan 14 05:29:15 2009 +0000 +++ b/ChangeLog Thu Jan 15 02:31:47 2009 +0000 @@ -1,3 +1,21 @@ 2009-01-13 Andrew John Hughes + + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: + Extend java.nio.channels.FileChannel to minimise code. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/util/concurrent/ScheduledThreadPoolExecutor.java: + Adapted to use the SharedSecrets backdoor. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaUtilConcurrentThreadPoolExecutorAccess.java: + Add remaining methods needed for our ScheduledThreadPoolExecutor. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousChannelGroupImpl.java: + Create a ScheduledThreadPoolExecutor directly so ours is used. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileChannelImpl.java: + Refer to AsynchronousFileLockImpl not FileLockImpl. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/FileLockTable.java: + Fix imports. + * patches/icedtea-nio2.patch: + Update implementation of secrets interface. + 2009-01-13 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaIODeleteOnExitAccess.java, diff -r 9eb9c1670c99 -r dbdaa8e2cf1f overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java Wed Jan 14 05:29:15 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java Thu Jan 15 02:31:47 2009 +0000 @@ -162,8 +162,8 @@ import org.classpath.icedtea.java.nio.fi */ public abstract class FileChannel - extends AbstractInterruptibleChannel - implements SeekableByteChannel, GatheringByteChannel, ScatteringByteChannel + extends java.nio.channels.FileChannel + implements SeekableByteChannel { /** * Initializes a new instance of this class. @@ -288,9 +288,9 @@ public abstract class FileChannel * * @since 1.7 */ - public static FileChannel open(Path file, - Set options, - FileAttribute... attrs) + public static java.nio.channels.FileChannel open(Path file, + Set options, + FileAttribute... attrs) throws IOException { FileSystemProvider provider = file.getFileSystem().provider(); @@ -335,110 +335,13 @@ public abstract class FileChannel * * @since 1.7 */ - public static FileChannel open(Path file, OpenOption... options) + public static java.nio.channels.FileChannel open(Path file, OpenOption... options) throws IOException { Set set = new HashSet(options.length); Collections.addAll(set, options); return open(file, set, NO_ATTRIBUTES); } - - // -- Channel operations -- - - /** - * Reads a sequence of bytes from this channel into the given buffer. - * - *

Bytes are read starting at this channel's current file position, and - * then the file position is updated with the number of bytes actually - * read. Otherwise this method behaves exactly as specified in the {@link - * ReadableByteChannel} interface.

- */ - public abstract int read(ByteBuffer dst) throws IOException; - - /** - * Reads a sequence of bytes from this channel into a subsequence of the - * given buffers. - * - *

Bytes are read starting at this channel's current file position, and - * then the file position is updated with the number of bytes actually - * read. Otherwise this method behaves exactly as specified in the {@link - * ScatteringByteChannel} interface.

- */ - public abstract long read(ByteBuffer[] dsts, int offset, int length) - throws IOException; - - /** - * Reads a sequence of bytes from this channel into the given buffers. - * - *

Bytes are read starting at this channel's current file position, and - * then the file position is updated with the number of bytes actually - * read. Otherwise this method behaves exactly as specified in the {@link - * ScatteringByteChannel} interface.

- */ - public final long read(ByteBuffer[] dsts) throws IOException { - return read(dsts, 0, dsts.length); - } - - /** - * Writes a sequence of bytes to this channel from the given buffer. - * - *

Bytes are written starting at this channel's current file position - * unless the channel is in append mode, in which case the position is - * first advanced to the end of the file. The file is grown, if necessary, - * to accommodate the written bytes, and then the file position is updated - * with the number of bytes actually written. Otherwise this method - * behaves exactly as specified by the {@link WritableByteChannel} - * interface.

- */ - public abstract int write(ByteBuffer src) throws IOException; - - /** - * Writes a sequence of bytes to this channel from a subsequence of the - * given buffers. - * - *

Bytes are written starting at this channel's current file position - * unless the channel is in append mode, in which case the position is - * first advanced to the end of the file. The file is grown, if necessary, - * to accommodate the written bytes, and then the file position is updated - * with the number of bytes actually written. Otherwise this method - * behaves exactly as specified in the {@link GatheringByteChannel} - * interface.

- */ - public abstract long write(ByteBuffer[] srcs, int offset, int length) - throws IOException; - - /** - * Writes a sequence of bytes to this channel from the given buffers. - * - *

Bytes are written starting at this channel's current file position - * unless the channel is in append mode, in which case the position is - * first advanced to the end of the file. The file is grown, if necessary, - * to accommodate the written bytes, and then the file position is updated - * with the number of bytes actually written. Otherwise this method - * behaves exactly as specified in the {@link GatheringByteChannel} - * interface.

- */ - public final long write(ByteBuffer[] srcs) throws IOException { - return write(srcs, 0, srcs.length); - } - - - // -- Other operations -- - - /** - * Returns this channel's file position.

- * - * @return This channel's file position, - * a non-negative integer counting the number of bytes - * from the beginning of the file to the current position - * - * @throws ClosedChannelException - * If this channel is closed - * - * @throws IOException - * If some other I/O error occurs - */ - public abstract long position() throws IOException; /** * Sets this channel's file position. @@ -469,20 +372,6 @@ public abstract class FileChannel public abstract FileChannel position(long newPosition) throws IOException; /** - * Returns the current size of this channel's file.

- * - * @return The current size of this channel's file, - * measured in bytes - * - * @throws ClosedChannelException - * If this channel is closed - * - * @throws IOException - * If some other I/O error occurs - */ - public abstract long size() throws IOException; - - /** * Truncates this channel's file to the given size. * *

If the given size is less than the file's current size then the file @@ -511,656 +400,5 @@ public abstract class FileChannel */ public abstract FileChannel truncate(long size) throws IOException; - /** - * Forces any updates to this channel's file to be written to the storage - * device that contains it. - * - *

If this channel's file resides on a local storage device then when - * this method returns it is guaranteed that all changes made to the file - * since this channel was created, or since this method was last invoked, - * will have been written to that device. This is useful for ensuring that - * critical information is not lost in the event of a system crash. - * - *

If the file does not reside on a local device then no such guarantee - * is made. - * - *

The metaData parameter can be used to limit the number of - * I/O operations that this method is required to perform. Passing - * false for this parameter indicates that only updates to the - * file's content need be written to storage; passing true - * indicates that updates to both the file's content and metadata must be - * written, which generally requires at least one more I/O operation. - * Whether this parameter actually has any effect is dependent upon the - * underlying operating system and is therefore unspecified. - * - *

Invoking this method may cause an I/O operation to occur even if the - * channel was only opened for reading. Some operating systems, for - * example, maintain a last-access time as part of a file's metadata, and - * this time is updated whenever the file is read. Whether or not this is - * actually done is system-dependent and is therefore unspecified. - * - *

This method is only guaranteed to force changes that were made to - * this channel's file via the methods defined in this class. It may or - * may not force changes that were made by modifying the content of a - * {@link MappedByteBuffer mapped byte buffer} obtained by - * invoking the {@link #map map} method. Invoking the {@link - * MappedByteBuffer#force force} method of the mapped byte buffer will - * force changes made to the buffer's content to be written.

- * - * @param metaData - * If true then this method is required to force changes - * to both the file's content and metadata to be written to - * storage; otherwise, it need only force content changes to be - * written - * - * @throws ClosedChannelException - * If this channel is closed - * - * @throws IOException - * If some other I/O error occurs - */ - public abstract void force(boolean metaData) throws IOException; - - /** - * Transfers bytes from this channel's file to the given writable byte - * channel. - * - *

An attempt is made to read up to count bytes starting at - * the given position in this channel's file and write them to the - * target channel. An invocation of this method may or may not transfer - * all of the requested bytes; whether or not it does so depends upon the - * natures and states of the channels. Fewer than the requested number of - * bytes are transferred if this channel's file contains fewer than - * count bytes starting at the given position, or if the - * target channel is non-blocking and it has fewer than count - * bytes free in its output buffer. - * - *

This method does not modify this channel's position. If the given - * position is greater than the file's current size then no bytes are - * transferred. If the target channel has a position then bytes are - * written starting at that position and then the position is incremented - * by the number of bytes written. - * - *

This method is potentially much more efficient than a simple loop - * that reads from this channel and writes to the target channel. Many - * operating systems can transfer bytes directly from the filesystem cache - * to the target channel without actually copying them.

- * - * @param position - * The position within the file at which the transfer is to begin; - * must be non-negative - * - * @param count - * The maximum number of bytes to be transferred; must be - * non-negative - * - * @param target - * The target channel - * - * @return The number of bytes, possibly zero, - * that were actually transferred - * - * @throws IllegalArgumentException - * If the preconditions on the parameters do not hold - * - * @throws NonReadableChannelException - * If this channel was not opened for reading - * - * @throws NonWritableChannelException - * If the target channel was not opened for writing - * - * @throws ClosedChannelException - * If either this channel or the target channel is closed - * - * @throws AsynchronousCloseException - * If another thread closes either channel - * while the transfer is in progress - * - * @throws ClosedByInterruptException - * If another thread interrupts the current thread while the - * transfer is in progress, thereby closing both channels and - * setting the current thread's interrupt status - * - * @throws IOException - * If some other I/O error occurs - */ - public abstract long transferTo(long position, long count, - WritableByteChannel target) - throws IOException; - - /** - * Transfers bytes into this channel's file from the given readable byte - * channel. - * - *

An attempt is made to read up to count bytes from the - * source channel and write them to this channel's file starting at the - * given position. An invocation of this method may or may not - * transfer all of the requested bytes; whether or not it does so depends - * upon the natures and states of the channels. Fewer than the requested - * number of bytes will be transferred if the source channel has fewer than - * count bytes remaining, or if the source channel is non-blocking - * and has fewer than count bytes immediately available in its - * input buffer. - * - *

This method does not modify this channel's position. If the given - * position is greater than the file's current size then no bytes are - * transferred. If the source channel has a position then bytes are read - * starting at that position and then the position is incremented by the - * number of bytes read. - * - *

This method is potentially much more efficient than a simple loop - * that reads from the source channel and writes to this channel. Many - * operating systems can transfer bytes directly from the source channel - * into the filesystem cache without actually copying them.

- * - * @param src - * The source channel - * - * @param position - * The position within the file at which the transfer is to begin; - * must be non-negative - * - * @param count - * The maximum number of bytes to be transferred; must be - * non-negative - * - * @return The number of bytes, possibly zero, - * that were actually transferred - * - * @throws IllegalArgumentException - * If the preconditions on the parameters do not hold - * - * @throws NonReadableChannelException - * If the source channel was not opened for reading - * - * @throws NonWritableChannelException - * If this channel was not opened for writing - * - * @throws ClosedChannelException - * If either this channel or the source channel is closed - * - * @throws AsynchronousCloseException - * If another thread closes either channel - * while the transfer is in progress - * - * @throws ClosedByInterruptException - * If another thread interrupts the current thread while the - * transfer is in progress, thereby closing both channels and - * setting the current thread's interrupt status - * - * @throws IOException - * If some other I/O error occurs - */ - public abstract long transferFrom(ReadableByteChannel src, - long position, long count) - throws IOException; - - /** - * Reads a sequence of bytes from this channel into the given buffer, - * starting at the given file position. - * - *

This method works in the same manner as the {@link - * #read(ByteBuffer)} method, except that bytes are read starting at the - * given file position rather than at the channel's current position. This - * method does not modify this channel's position. If the given position - * is greater than the file's current size then no bytes are read.

- * - * @param dst - * The buffer into which bytes are to be transferred - * - * @param position - * The file position at which the transfer is to begin; - * must be non-negative - * - * @return The number of bytes read, possibly zero, or -1 if the - * given position is greater than or equal to the file's current - * size - * - * @throws IllegalArgumentException - * If the position is negative - * - * @throws NonReadableChannelException - * If this channel was not opened for reading - * - * @throws ClosedChannelException - * If this channel is closed - * - * @throws AsynchronousCloseException - * If another thread closes this channel - * while the read operation is in progress - * - * @throws ClosedByInterruptException - * If another thread interrupts the current thread - * while the read operation is in progress, thereby - * closing the channel and setting the current thread's - * interrupt status - * - * @throws IOException - * If some other I/O error occurs - */ - public abstract int read(ByteBuffer dst, long position) throws IOException; - - /** - * Writes a sequence of bytes to this channel from the given buffer, - * starting at the given file position. - * - *

This method works in the same manner as the {@link - * #write(ByteBuffer)} method, except that bytes are written starting at - * the given file position rather than at the channel's current position. - * This method does not modify this channel's position. If the given - * position is greater than the file's current size then the file will be - * grown to accommodate the new bytes; the values of any bytes between the - * previous end-of-file and the newly-written bytes are unspecified.

- * - * @param src - * The buffer from which bytes are to be transferred - * - * @param position - * The file position at which the transfer is to begin; - * must be non-negative - * - * @return The number of bytes written, possibly zero - * - * @throws IllegalArgumentException - * If the position is negative - * - * @throws NonWritableChannelException - * If this channel was not opened for writing - * - * @throws ClosedChannelException - * If this channel is closed - * - * @throws AsynchronousCloseException - * If another thread closes this channel - * while the write operation is in progress - * - * @throws ClosedByInterruptException - * If another thread interrupts the current thread - * while the write operation is in progress, thereby - * closing the channel and setting the current thread's - * interrupt status - * - * @throws IOException - * If some other I/O error occurs - */ - public abstract int write(ByteBuffer src, long position) throws IOException; - - - // -- Memory-mapped buffers -- - - /** - * A typesafe enumeration for file-mapping modes. - * - * @since 1.4 - * - * @see java.nio.channels.FileChannel#map - */ - public static class MapMode { - - /** - * Mode for a read-only mapping. - */ - public static final MapMode READ_ONLY - = new MapMode("READ_ONLY"); - - /** - * Mode for a read/write mapping. - */ - public static final MapMode READ_WRITE - = new MapMode("READ_WRITE"); - - /** - * Mode for a private (copy-on-write) mapping. - */ - public static final MapMode PRIVATE - = new MapMode("PRIVATE"); - - private final String name; - - private MapMode(String name) { - this.name = name; - } - - /** From gnu_andrew at member.fsf.org Tue Feb 3 04:13:57 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:57 +0000 Subject: changeset in /hg/icedtea6: Merge. Message-ID: changeset 585bc814cee8 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=585bc814cee8 description: Merge. diffstat: 2 files changed, 33 insertions(+), 2 deletions(-) ChangeLog | 8 +++++ rt/net/sourceforge/jnlp/cache/ResourceTracker.java | 27 ++++++++++++++++++-- diffs (69 lines): diff -r dbdaa8e2cf1f -r 585bc814cee8 ChangeLog --- a/ChangeLog Thu Jan 15 02:31:47 2009 +0000 +++ b/ChangeLog Thu Jan 15 02:32:49 2009 +0000 @@ -15,6 +15,14 @@ 2009-01-14 Andrew John Hughes + + * rt/net/sourceforge/jnlp/cache/ResourceTracker.java + (downloadResource): Call getVersionedResourceURL to get the versioned jar. + (initializeResource): Likewise. + (getVersionedResourceURL): New function. Constructs a URL with a + version-id as the query. 2009-01-13 Andrew John Hughes diff -r dbdaa8e2cf1f -r 585bc814cee8 rt/net/sourceforge/jnlp/cache/ResourceTracker.java --- a/rt/net/sourceforge/jnlp/cache/ResourceTracker.java Thu Jan 15 02:31:47 2009 +0000 +++ b/rt/net/sourceforge/jnlp/cache/ResourceTracker.java Thu Jan 15 02:32:49 2009 +0000 @@ -605,7 +605,7 @@ public class ResourceTracker { try { // create out second in case in does not exist - URLConnection con = resource.location.openConnection(); + URLConnection con = getVersionedResourceURL(resource).openConnection(); InputStream in = new BufferedInputStream(con.getInputStream()); OutputStream out = CacheUtil.getOutputStream(resource.location, resource.downloadVersion); byte buf[] = new byte[1024]; @@ -652,7 +652,7 @@ public class ResourceTracker { File localFile = CacheUtil.getCacheFile(resource.location, resource.downloadVersion); // connect - URLConnection connection = resource.location.openConnection(); // this won't change so should be okay unsynchronized + URLConnection connection = getVersionedResourceURL(resource).openConnection(); // this won't change so should be okay unsynchronized int size = connection.getContentLength(); boolean current = CacheUtil.isCurrent(resource.location, resource.requestVersion, connection) && resource.getUpdatePolicy() != UpdatePolicy.FORCE; @@ -696,6 +696,29 @@ public class ResourceTracker { } } + + + private URL getVersionedResourceURL(Resource resource) { + String actualLocation = resource.location.getProtocol() + "://" + + resource.location.getHost(); + if (resource.location.getPort() != -1) { + actualLocation += ":" + resource.location.getPort(); + } + actualLocation += resource.location.getPath(); + if (resource.requestVersion != null + && resource.requestVersion.isVersionId()) { + actualLocation += "?version-id=" + resource.requestVersion; + } + URL versionedURL; + try { + versionedURL = new URL(actualLocation); + } catch (MalformedURLException e) { + return resource.location; + } + return versionedURL; + } + + /** * Pick the next resource to download or initialize. If there * are no more resources requested then one is taken from a From gnu_andrew at member.fsf.org Tue Feb 3 04:13:58 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:58 +0000 Subject: changeset in /hg/icedtea6: Complete sun.nio.ch fixes. Message-ID: changeset f42c98fdd7f4 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=f42c98fdd7f4 description: Complete sun.nio.ch fixes. 2009-01-19 Andrew John Hughes * generated/sun/nio/ch/SocketOptionRegistry.java: * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/DatagramChannel.java: Added (1.7 extensions). * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions: Fix package. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/SelectorProvider.java: Added (1.7 extensions). * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java: Added to provide access to package-private NetworkInterface.getIndex(). * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/CompletedFuture.java: Fixed imports. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ExtendedSocketOption.java: Added. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Invoker.java: Fixed imports. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/OptionKey.java: Added. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/PendingFuture.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ThreadPool.java: Fixed imports. * overlays/nio2/openjdk/jdk/src/share/native/sun/nio/ch/genSocketOptionRegistry.c, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultSelectorProvider.java: Added. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java: Fixed imports. * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/DefaultSelectorProvider.java: Added. * patches/icedtea-nio2.patch: Add hook for SharedSecrets to NetworkInterface, extend sun.nio.ch.{Net,DatagramChannelImpl,SelectorProviderImpl} to handle 1.7 extensions. diffstat: 21 files changed, 1487 insertions(+), 16 deletions(-) ChangeLog | 29 generated/sun/nio/ch/SocketOptionRegistry.java | 83 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/DatagramChannel.java | 223 ++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions | 2 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/SelectorProvider.java | 199 +++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java | 45 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java | 16 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java | 5 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java | 8 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/CompletedFuture.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ExtendedSocketOption.java | 44 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Invoker.java | 5 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/OptionKey.java | 48 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/PendingFuture.java | 4 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java | 14 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ThreadPool.java | 3 overlays/nio2/openjdk/jdk/src/share/native/sun/nio/ch/genSocketOptionRegistry.c | 129 ++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultSelectorProvider.java | 76 + overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java | 3 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/DefaultSelectorProvider.java | 49 patches/icedtea-nio2.patch | 515 +++++++++- diffs (truncated from 1771 to 500 lines): diff -r 585bc814cee8 -r f42c98fdd7f4 ChangeLog --- a/ChangeLog Thu Jan 15 02:32:49 2009 +0000 +++ b/ChangeLog Mon Jan 19 14:23:34 2009 +0000 @@ -1,3 +1,32 @@ 2009-01-14 Andrew John Hughes + + * generated/sun/nio/ch/SocketOptionRegistry.java: + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/DatagramChannel.java: + Added (1.7 extensions). + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions: Fix package. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/SelectorProvider.java: + Added (1.7 extensions). + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java, + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java: + Added to provide access to package-private NetworkInterface.getIndex(). + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/CompletedFuture.java: + Fixed imports. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ExtendedSocketOption.java: Added. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/Invoker.java: Fixed imports. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/OptionKey.java: Added. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/PendingFuture.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousDatagramChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/ThreadPool.java: Fixed imports. + * overlays/nio2/openjdk/jdk/src/share/native/sun/nio/ch/genSocketOptionRegistry.c, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/DefaultSelectorProvider.java: Added. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java: + Fixed imports. + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/ch/DefaultSelectorProvider.java: Added. + * patches/icedtea-nio2.patch: Add hook for SharedSecrets to NetworkInterface, extend + sun.nio.ch.{Net,DatagramChannelImpl,SelectorProviderImpl} to handle 1.7 extensions. + 2009-01-14 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: diff -r 585bc814cee8 -r f42c98fdd7f4 generated/sun/nio/ch/SocketOptionRegistry.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/generated/sun/nio/ch/SocketOptionRegistry.java Mon Jan 19 14:23:34 2009 +0000 @@ -0,0 +1,83 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + * + */ +// AUTOMATICALLY GENERATED FILE - DO NOT EDIT +package sun.nio.ch; +import java.util.Map; +import java.util.HashMap; +import org.classpath.icedtea.java.net.ProtocolFamily; +import org.classpath.icedtea.java.net.StandardProtocolFamily; +import org.classpath.icedtea.java.net.SocketOption; +import org.classpath.icedtea.java.net.StandardSocketOption; +class SocketOptionRegistry { + private SocketOptionRegistry() { } + private static class RegistryKey { + private final SocketOption name; + private final ProtocolFamily family; + RegistryKey(SocketOption name, ProtocolFamily family) { + this.name = name; + this.family = family; + } + public int hashCode() { + return name.hashCode() + family.hashCode(); + } + public boolean equals(Object ob) { + if (ob == null) return false; + if (!(ob instanceof RegistryKey)) return false; + RegistryKey other = (RegistryKey)ob; + if (this.name != other.name) return false; + if (this.family != other.family) return false; + return true; + } + } + private static class LazyInitialization { + static final Map options = options(); + private static Map options() { + Map map = + new HashMap(); + map.put(new RegistryKey(StandardSocketOption.SO_BROADCAST, Net.UNSPEC), new OptionKey(1, 6)); + map.put(new RegistryKey(StandardSocketOption.SO_KEEPALIVE, Net.UNSPEC), new OptionKey(1, 9)); + map.put(new RegistryKey(StandardSocketOption.SO_LINGER, Net.UNSPEC), new OptionKey(1, 13)); + map.put(new RegistryKey(StandardSocketOption.SO_SNDBUF, Net.UNSPEC), new OptionKey(1, 7)); + map.put(new RegistryKey(StandardSocketOption.SO_RCVBUF, Net.UNSPEC), new OptionKey(1, 8)); + map.put(new RegistryKey(StandardSocketOption.SO_REUSEADDR, Net.UNSPEC), new OptionKey(1, 2)); + map.put(new RegistryKey(StandardSocketOption.TCP_NODELAY, Net.UNSPEC), new OptionKey(6, 1)); + map.put(new RegistryKey(StandardSocketOption.IP_TOS, StandardProtocolFamily.INET), new OptionKey(0, 1)); + map.put(new RegistryKey(StandardSocketOption.IP_MULTICAST_IF, StandardProtocolFamily.INET), new OptionKey(0, 32)); + map.put(new RegistryKey(StandardSocketOption.IP_MULTICAST_TTL, StandardProtocolFamily.INET), new OptionKey(0, 33)); + map.put(new RegistryKey(StandardSocketOption.IP_MULTICAST_LOOP, StandardProtocolFamily.INET), new OptionKey(0, 34)); + map.put(new RegistryKey(StandardSocketOption.IP_MULTICAST_IF, StandardProtocolFamily.INET6), new OptionKey(41, 17)); + map.put(new RegistryKey(StandardSocketOption.IP_MULTICAST_TTL, StandardProtocolFamily.INET6), new OptionKey(41, 18)); + map.put(new RegistryKey(StandardSocketOption.IP_MULTICAST_LOOP, StandardProtocolFamily.INET6), new OptionKey(41, 19)); + map.put(new RegistryKey(ExtendedSocketOption.SO_OOBINLINE, Net.UNSPEC), new OptionKey(1, 10)); + return map; + } + } + public static OptionKey findOption(SocketOption name, ProtocolFamily family) { + RegistryKey key = new RegistryKey(name, family); + return LazyInitialization.options.get(key); + } +} diff -r 585bc814cee8 -r f42c98fdd7f4 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/DatagramChannel.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/DatagramChannel.java Mon Jan 19 14:23:34 2009 +0000 @@ -0,0 +1,223 @@ +/* + * Copyright 2000-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 2009 Red Hat, Inc. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package org.classpath.icedtea.java.nio.channels; + +import java.io.IOException; +import java.net.DatagramSocket; +import java.net.SocketAddress; +import java.nio.ByteBuffer; + +import org.classpath.icedtea.java.net.ProtocolFamily; +import org.classpath.icedtea.java.net.SocketOption; + +import org.classpath.icedtea.java.nio.channels.spi.SelectorProvider; + +/** + * A selectable channel for datagram-oriented sockets. + * + *

{@note revised} A datagram channel is created by invoking one of the {@link #open open} methods + * of this class. It is not possible to create a channel for an arbitrary, + * pre-existing datagram socket. A newly-created datagram channel is open but not + * connected. A datagram channel need not be connected in order for the {@link #send + * send} and {@link #receive receive} methods to be used. A datagram channel may be + * connected, by invoking its {@link #connect connect} method, in order to + * avoid the overhead of the security checks are otherwise performed as part of + * every send and receive operation. A datagram channel must be connected in + * order to use the {@link #read(java.nio.ByteBuffer) read} and {@link + * #write(java.nio.ByteBuffer) write} methods, since those methods do not + * accept or return socket addresses. + * + *

Once connected, a datagram channel remains connected until it is + * disconnected or closed. Whether or not a datagram channel is connected may + * be determined by invoking its {@link #isConnected isConnected} method. + * + *

Socket options are configured using the {@link #setOption(SocketOption,Object) + * setOption} method. A datagram channel to an Internet Protocol socket supports + * the following options: + *

+ * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + * + *
Option NameDescription
{@link java.net.StandardSocketOption#SO_SNDBUF SO_SNDBUF} The size of the socket send buffer
{@link java.net.StandardSocketOption#SO_RCVBUF SO_RCVBUF} The size of the socket receive buffer
{@link java.net.StandardSocketOption#SO_REUSEADDR SO_REUSEADDR} Re-use address
{@link java.net.StandardSocketOption#SO_BROADCAST SO_BROADCAST} Allow transmission of broadcast datagrams
{@link java.net.StandardSocketOption#IP_TOS IP_TOS} The Type of Service (ToS) octet in the Internet Protocol (IP) header
{@link java.net.StandardSocketOption#IP_MULTICAST_IF IP_MULTICAST_IF} The network interface for Internet Protocol (IP) multicast datagrams
{@link java.net.StandardSocketOption#IP_MULTICAST_TTL + * IP_MULTICAST_TTL} The time-to-live for Internet Protocol (IP) multicast + * datagrams
{@link java.net.StandardSocketOption#IP_MULTICAST_LOOP + * IP_MULTICAST_LOOP} Loopback for Internet Protocol (IP) multicast datagrams
+ *
+ * Additional (implementation specific) options may also be supported. + * + *

Datagram channels are safe for use by multiple concurrent threads. They + * support concurrent reading and writing, though at most one thread may be + * reading and at most one thread may be writing at any given time.

+ * + * @author Mark Reinhold + * @author JSR-51 Expert Group + * @since 1.4 + * @updated 1.7 + */ + +public abstract class DatagramChannel + extends java.nio.channels.DatagramChannel + implements MulticastChannel +{ + + /** + * Initializes a new instance of this class. + */ + protected DatagramChannel(SelectorProvider provider) { + super(provider); + } + + /** + * Opens a datagram channel. + * + *

The new channel is created by invoking the {@link + * java.nio.channels.spi.SelectorProvider#openDatagramChannel() + * openDatagramChannel} method of the system-wide default {@link + * java.nio.channels.spi.SelectorProvider} object. The channel will not be + * connected.

+ * + * @return A new datagram channel + * + * @throws IOException + * If an I/O error occurs + */ + public static DatagramChannel open() throws IOException { + return SelectorProvider.provider().openDatagramChannel(); + } + + /** + * Opens a datagram channel. + * + *

The {@code family} parameter is used to specify the {@link + * ProtocolFamily}. If the datagram channel is to be used for IP multicasing + * then this should correspond to the address type of the multicast groups + * that this channel will join. + * + *

The new channel is created by invoking the {@link + * java.nio.channels.spi.SelectorProvider#openDatagramChannel(ProtocolFamily) + * openDatagramChannel} method of the system-wide default {@link + * java.nio.channels.spi.SelectorProvider} object. The channel will not be + * connected. + * + * @param family + * The protocol family + * + * @return A new datagram channel + * + * @throws UnsupportedOperationException + * If the specified protocol family is not supported. For example, + * suppose the parameter is specified as {@link + * java.net.StandardProtocolFamily#INET6 StandardProtocolFamily.INET6} + * but IPv6 is not enabled on the platform. + * @throws IOException + * If an I/O error occurs + * + * @since 1.7 + */ + public static DatagramChannel open(ProtocolFamily family) throws IOException { + return SelectorProvider.provider().openDatagramChannel(family); + } + + + // -- Socket-specific operations -- + + /** + * @throws AlreadyBoundException {@inheritDoc} + * @throws UnsupportedAddressTypeException {@inheritDoc} + * @throws ClosedChannelException {@inheritDoc} + * @throws IOException {@inheritDoc} + * @throws SecurityException + * If a security manager has been installed and its {@link + * SecurityManager#checkListen checkListen} method denies the + * operation + * + * @since 1.7 + */ + public abstract DatagramChannel bind(SocketAddress local) + throws IOException; + + /** + * @throws IllegalArgumentException {@inheritDoc} + * @throws ClosedChannelException {@inheritDoc} + * @throws IOException {@inheritDoc} + * + * @since 1.7 + */ + public abstract DatagramChannel setOption(SocketOption name, T value) + throws IOException; + + /** + * {@note new} + * Returns the remote address to which this channel's socket is connected. + * + * @return The remote address; {@code null} if the channel's socket is not + * connected + * + * @throws ClosedChannelException + * If the channel is closed + * @throws IOException + * If an I/O error occurs + * + * @since 1.7 + */ + public abstract SocketAddress getRemoteAddress() throws IOException; + +} diff -r 585bc814cee8 -r f42c98fdd7f4 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions Thu Jan 15 02:32:49 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/exceptions Mon Jan 19 14:23:34 2009 +0000 @@ -25,7 +25,7 @@ # Generated exception classes for java.nio.channels -PACKAGE=java.nio.channels +PACKAGE=org.classpath.icedtea.java.nio.channels # This year should only change if the generated source is modified. COPYRIGHT_YEARS=2000-2007 SINCE=1.7 diff -r 585bc814cee8 -r f42c98fdd7f4 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/SelectorProvider.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/spi/SelectorProvider.java Mon Jan 19 14:23:34 2009 +0000 @@ -0,0 +1,199 @@ +/* + * Copyright 2000-2008 Sun Microsystems, Inc. All Rights Reserved. + * Copyright 2009 Red Hat, Inc. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package org.classpath.icedtea.java.nio.channels.spi; + +import java.io.IOException; + +import java.security.AccessController; +import java.security.PrivilegedAction; + +import java.util.Iterator; +import java.util.ServiceLoader; +import java.util.ServiceConfigurationError; + +import org.classpath.icedtea.java.net.ProtocolFamily; + +import org.classpath.icedtea.java.nio.channels.DatagramChannel; + +/** + * Service-provider class for selectors and selectable channels. + * + *

A selector provider is a concrete subclass of this class that has a + * zero-argument constructor and implements the abstract methods specified + * below. A given invocation of the Java virtual machine maintains a single + * system-wide default provider instance, which is returned by the {@link + * #provider() provider} method. The first invocation of that method will locate + * the default provider as specified below. + * + *

The system-wide default provider is used by the static open + * methods of the {@link java.nio.channels.DatagramChannel#open + * DatagramChannel}, {@link java.nio.channels.Pipe#open Pipe}, {@link + * java.nio.channels.Selector#open Selector}, {@link + * java.nio.channels.ServerSocketChannel#open ServerSocketChannel}, and {@link + * java.nio.channels.SocketChannel#open SocketChannel} classes. It is also + * used by the {@link java.lang.System#inheritedChannel System.inheritedChannel()} + * method. A program may make use of a provider other than the default provider + * by instantiating that provider and then directly invoking the open + * methods defined in this class. + * + *

All of the methods in this class are safe for use by multiple concurrent + * threads.

+ * + * + * @author Mark Reinhold + * @author JSR-51 Expert Group + * @since 1.4 + */ + +public abstract class SelectorProvider + extends java.nio.channels.spi.SelectorProvider { + + private static final Object lock = new Object(); + private static SelectorProvider provider = null; + + /** + * Opens a datagram channel.

+ * + * @return The new channel + */ + public abstract DatagramChannel openDatagramChannel() + throws IOException; + + /** + * {@note new} + * Opens a datagram channel. + * + * @param family + * The protocol family + * + * @return A new datagram channel + * + * @throws UnsupportedOperationException + * If the specified protocol family is not supported + * @throws IOException + * If an I/O error occurs + * + * @since 1.7 + */ + public abstract DatagramChannel openDatagramChannel(ProtocolFamily family) + throws IOException; + + /** + * Returns the system-wide default selector provider for this invocation of + * the Java virtual machine. + * + *

The first invocation of this method locates the default provider + * object as follows:

+ * + *
    + * + *
  1. If the system property + * java.nio.channels.spi.SelectorProvider is defined then it is + * taken to be the fully-qualified name of a concrete provider class. + * The class is loaded and instantiated; if this process fails then an + * unspecified error is thrown.

  2. + * + *
  3. If a provider class has been installed in a jar file that is + * visible to the system class loader, and that jar file contains a + * provider-configuration file named + * java.nio.channels.spi.SelectorProvider in the resource + * directory META-INF/services, then the first class name + * specified in that file is taken. The class is loaded and + * instantiated; if this process fails then an unspecified error is + * thrown.

  4. + * + *
  5. Finally, if no provider has been specified by any of the above + * means then the system-default provider class is instantiated and the + * result is returned.

  6. + * + *
+ * From gnu_andrew at member.fsf.org Tue Feb 3 04:13:58 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:58 +0000 Subject: changeset in /hg/icedtea6: Merge. Message-ID: changeset fb3c68368b7f in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=fb3c68368b7f description: Merge. diffstat: 6 files changed, 41 insertions(+), 38 deletions(-) ChangeLog | 22 ++++++++++++++ HACKING | 1 Makefile.am | 1 patches/icedtea-a11y-property-change.patch | 17 ----------- patches/icedtea-samejvm-safe.patch | 2 - ports/hotspot/src/cpu/zero/vm/globals_zero.hpp | 36 ++++++++++++------------ diffs (140 lines): diff -r f42c98fdd7f4 -r fb3c68368b7f ChangeLog --- a/ChangeLog Mon Jan 19 14:23:34 2009 +0000 +++ b/ChangeLog Mon Jan 19 14:25:02 2009 +0000 @@ -26,6 +26,28 @@ 2009-01-19 Andrew John Hughes + + * patches/icedtea-version.patch (samejvmsafe): Removed the following + directories that contain test that are not samevm safe. + javax/crypto/Cipher (TestGetInstance) + javax/naming (CompareToEqualsTests) + sun/rmi (RmicDefault) + sun/security/util (OidFormat) + sun/security/x509 + (ExtensibleAlgorithmId,EmailAddressEncoding,AllAttribs) + +2009-01-15 Omair Majid + + * patches/icedtea-a11y-property-change.patch: Removed incorrect patch. + * HACKING: Remove above patch. + * Makefile.am (ICEDTEA_PATCHES): Removed patch. + +2009-01-15 Gary Benson + + * ports/hotspot/src/cpu/zero/vm/globals_zero.hpp + (StackShadowPages): Increase for 64-bit builds. 2009-01-14 Andrew John Hughes diff -r f42c98fdd7f4 -r fb3c68368b7f HACKING --- a/HACKING Mon Jan 19 14:23:34 2009 +0000 +++ b/HACKING Mon Jan 19 14:25:02 2009 +0000 @@ -78,7 +78,6 @@ The following patches are currently appl * icedtea-format-warnings.patch: Fix build failures with -Wformat=1. * icedtea-io_util-overflow.patch: Replace some code to correctly handle overflows. (S6788196) * icedtea-cc-interp-jvmti.patch: Disable some JVMTI capabilities which are unsupported or do not work with the C++ interpreter. -* icedtea-a11y-property-change.patch: Dont fire PropertyChangeEvent if the property hasnt changed. * icedtea-demo-swingapplet.patch: Add missing html file needed to run the demo. * icedtea-6791168.patch: Fix build failure with GCC-4.4 (PR 38725) and compiler warnings. * icedtea-no-precompiled.patch: Don't use precompiled header files in hotspot. diff -r f42c98fdd7f4 -r fb3c68368b7f Makefile.am --- a/Makefile.am Mon Jan 19 14:23:34 2009 +0000 +++ b/Makefile.am Mon Jan 19 14:25:02 2009 +0000 @@ -695,7 +695,6 @@ endif ICEDTEA_PATCHES += \ $(DISTRIBUTION_PATCHES) \ - patches/icedtea-a11y-property-change.patch \ patches/icedtea-demo-swingapplet.patch \ patches/icedtea-awt-window-size.patch diff -r f42c98fdd7f4 -r fb3c68368b7f patches/icedtea-a11y-property-change.patch --- a/patches/icedtea-a11y-property-change.patch Mon Jan 19 14:23:34 2009 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,17 +0,0 @@ ---- AccessibleContext.java.orig 2008-12-24 11:33:22.000000000 -0500 -+++ openjdk/jdk/src/share/classes/javax/accessibility/AccessibleContext.java 2008-12-24 11:35:29.000000000 -0500 -@@ -736,6 +736,14 @@ - Object oldValue, - Object newValue) { - if (accessibleChangeSupport != null) { -+ -+ if (oldValue == newValue) { -+ return; -+ } -+ if (oldValue != null && newValue != null && oldValue.equals(newValue)) { -+ return; -+ } -+ - if (newValue instanceof PropertyChangeEvent) { - PropertyChangeEvent pce = (PropertyChangeEvent)newValue; - accessibleChangeSupport.firePropertyChange(pce); diff -r f42c98fdd7f4 -r fb3c68368b7f patches/icedtea-samejvm-safe.patch --- a/patches/icedtea-samejvm-safe.patch Mon Jan 19 14:23:34 2009 +0000 +++ b/patches/icedtea-samejvm-safe.patch Mon Jan 19 14:25:02 2009 +0000 @@ -9,4 +9,4 @@ +# -samejvm mode. Only used if the test root (dir containing this file) is +# given to jtreg and the -samejvm argument is used, ignored otherwise +# (meaning all tests are assumed to be same jvm safe). -+samejvmsafe=com/sun/crypto com/sun/management com/sun/media com/sun/security java/beans/beancontext java/beans/PropertyChangeSupport java/beans/Statement java/beans/VetoableChangeSupport java/lang/Boolean java/lang/Byte java/lang/Double java/lang/Float java/lang/Integer java/lang/Long java/lang/Short java/lang/Math java/lang/StrictMath java/lang/String java/lang/Throwable java/lang/instrument java/math java/net/URI java/net/URLDecoder java/net/URLEncoder java/nio/Buffer java/nio/ByteOrder java/nio/MappedByteBuffer java/nio/channels/Channels java/nio/channels/DatagramChannel java/nio/channels/spi java/security/cert java/security/Provider java/text java/util/jar java/util/zip java/util/Array java/util/BitSet java/util/Collection java/util/List javax/crypto/Cipher javax/imageio javax/management/openmbean javax/naming javax/rmi javax/sound sun/net/www/protocol sun/misc sun/nio sun/rmi sun/security/pkcs11 sun/security/rsa sun/security/util sun/security/x509 sun/util ++samejvmsafe=com/sun/crypto com/sun/management com/sun/media com/sun/security java/beans/beancontext java/beans/PropertyChangeSupport java/beans/Statement java/beans/VetoableChangeSupport java/lang/Boolean java/lang/Byte java/lang/Double java/lang/Float java/lang/Integer java/lang/Long java/lang/Short java/lang/Math java/lang/StrictMath java/lang/String java/lang/Throwable java/lang/instrument java/math java/net/URI java/net/URLDecoder java/net/URLEncoder java/nio/Buffer java/nio/ByteOrder java/nio/MappedByteBuffer java/nio/channels/Channels java/nio/channels/DatagramChannel java/nio/channels/spi java/security/cert java/security/Provider java/text java/util/jar java/util/zip java/util/Array java/util/BitSet java/util/Collection java/util/List javax/imageio javax/management/openmbean javax/rmi javax/sound sun/net/www/protocol sun/misc sun/nio sun/security/pkcs11 sun/security/rsa sun/util diff -r f42c98fdd7f4 -r fb3c68368b7f ports/hotspot/src/cpu/zero/vm/globals_zero.hpp --- a/ports/hotspot/src/cpu/zero/vm/globals_zero.hpp Mon Jan 19 14:23:34 2009 +0000 +++ b/ports/hotspot/src/cpu/zero/vm/globals_zero.hpp Mon Jan 19 14:25:02 2009 +0000 @@ -1,6 +1,6 @@ /* * Copyright 2000-2006 Sun Microsystems, Inc. All Rights Reserved. - * Copyright 2007 Red Hat, Inc. + * Copyright 2007, 2008, 2009 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -28,27 +28,27 @@ // runtime system. See globals.hpp for details of what they do. // -define_pd_global(bool, ConvertSleepToYield, true); -define_pd_global(bool, ShareVtableStubs, true); -define_pd_global(bool, CountInterpCalls, true); -define_pd_global(bool, NeedsDeoptSuspend, false); +define_pd_global(bool, ConvertSleepToYield, true); +define_pd_global(bool, ShareVtableStubs, true); +define_pd_global(bool, CountInterpCalls, true); +define_pd_global(bool, NeedsDeoptSuspend, false); -define_pd_global(bool, ImplicitNullChecks, true); -define_pd_global(bool, UncommonNullCast, true); +define_pd_global(bool, ImplicitNullChecks, true); +define_pd_global(bool, UncommonNullCast, true); -define_pd_global(intx, CodeEntryAlignment, 32); -define_pd_global(uintx, TLABSize, 0); +define_pd_global(intx, CodeEntryAlignment, 32); +define_pd_global(uintx, TLABSize, 0); #ifdef _LP64 -define_pd_global(uintx, NewSize, ScaleForWordSize(2048 * K)); +define_pd_global(uintx, NewSize, ScaleForWordSize(2048 * K)); #else -define_pd_global(uintx, NewSize, ScaleForWordSize(1024 * K)); +define_pd_global(uintx, NewSize, ScaleForWordSize(1024 * K)); #endif // _LP64 -define_pd_global(intx, InlineFrequencyCount, 100); -define_pd_global(intx, PreInflateSpin, 10); +define_pd_global(intx, InlineFrequencyCount, 100); +define_pd_global(intx, PreInflateSpin, 10); -define_pd_global(intx, StackYellowPages, 2); -define_pd_global(intx, StackRedPages, 1); -define_pd_global(intx, StackShadowPages, 3 DEBUG_ONLY(+3)); +define_pd_global(intx, StackYellowPages, 2); +define_pd_global(intx, StackRedPages, 1); +define_pd_global(intx, StackShadowPages, 3 LP64_ONLY(+3) DEBUG_ONLY(+3)); -define_pd_global(bool, RewriteBytecodes, true); -define_pd_global(bool, RewriteFrequentPairs, true); +define_pd_global(bool, RewriteBytecodes, true); +define_pd_global(bool, RewriteFrequentPairs, true); From gnu_andrew at member.fsf.org Tue Feb 3 04:13:58 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:58 +0000 Subject: changeset in /hg/icedtea6: Fix UNIX sun.nio.ch and shared sun.ni... Message-ID: changeset 913512a256bd in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=913512a256bd description: Fix UNIX sun.nio.ch and shared sun.nio.fs classes. 2009-01-19 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java: (getByIndex(int)): New method. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java: Fixed imports. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipKeyImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipRegistry.java: New files. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java: Fix imports, refer to AsynchronousFileLockImpl instead of FileLockImpl. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java: Fix imports and vararg usage. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java: Fix vararg usage. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractPoller.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java: Fix imports. * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java: Fix imports and vararg usage. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/EPollPort.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/Port.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousSocketChannelImpl.java: Fix imports. * patches/icedtea-nio2.patch: Add new classes. (Unsafe.copyMemory(long,long,long)): Backported. (Unsafe.copyMemory(Object,long,Object,long,long)): Backported. (Unsafe.ARRAY_BYTE_BASE_OFFSET): Likewise. (DatagramChannelImpl.bind(SocketAddress)): Likewise. (DatagramChannelImpl.getLocalAddress()): Likewise. (DatagramChannelImpl.getOption(SocketOption)): Likewise. (DatagramChannelImpl.innerJoin(InetAddress,NetworkInterface,InetAddress)): Likewise. (DatagramChannelImpl.join(InetAddress,NetworkInterface)): Likewise. (DatagramChannelImpl.join(InetAddress,NetworkInterface,InetAddress)): Likewise. (DatagramChannelImpl.block(MembershipKeyImpl,InetAddress)): Likewise. (DatagramChannelImpl.unblock(MembershipKeyImpl,InetAddress)): Likewise. (DatagramChannelImpl.drop(MembershipKeyImpl)): Likewise. (Net.getInterface4(FileDescriptor)): Likewise. (Net.getInterface6(FileDescriptor)): Likewise. (Net.inet4FromInt(int)): Likewise. (Net.inet6AsByteArray(InetAddress)): Likewise. (Net.join6(FileDescriptor,byte[],int,byte[])): Likewise. (Net.drop6(FileDescriptor,byte[],int,byte[])): Likewise. (Net.joinOrDrop6(boolean,FileDescriptor,byte[],int,byte[])): Likewise. (Net.block6(FileDescriptor,byte[],int,byte[])): Likewise. (Net.unblock6(FileDescriptor,byte[],int,byte[])): Likewise. (Net.blockOrUnblock6(boolean,FileDescriptor,byte[],int,byte[])): Likewise. (Net.join4(FileDescriptor,int,int,int)): Likewise. (Net.drop4(FileDescriptor,int,int,int)): Likewise. (Net.joinOrDrop4(boolean,FileDescriptor,int,int,int)): Likewise. (Net.block4(FileDescriptor,int,int,int)): Likewise. (Net.unblock4(FileDescriptor,int,int,int)): Likewise. (Net.blockOrUnblock4(boolean,FileDescriptor,int,int,int)): Likewise. (Net.connect(FileDescriptor,InetAddress,int)): Likewise. (Net.connect(ProtocolFamily,FileDescriptor,InetAddress,int)): Likewise. (Net.connect0(boolean,FileDescriptor,InetAddress,int)): Likewise. (FileDispatcher.NO_LOCK)): Likewise. (FileDispatcher.LOCKED)): Likewise. (FileDispatcher.RET_EX_LOCK)): Likewise. (FileDispatcher.INTERRUPTED)): Likewise. (FileDispatcher.size(FileDescriptor)): Likewise. (FileDispatcher.truncate(FileDescriptor, long)): Likewise. (FileDispatcher.force(FileDescriptor, boolean)): Likewise. (FileDispatcher.lock(FileDescriptor, boolean, long, long, boolean)): Likewise. (FileDispatcher.release(FileDescriptor, long, long)): Likewise. (FileDispatcher.force0(FileDescriptor,boolean)): Likewise. (FileDispatcher.truncate0(FileDescriptor, long)): Likewise. (FileDispatcher.size0(FileDescriptor)): Likewise. (FileDispatcher.lock0(FileDescriptor, boolean, long, long, boolean)): Likewise. (FileDispatcher.release0(FileDescriptor, long, long)): Likewise. diffstat: 19 files changed, 1133 insertions(+), 31 deletions(-) ChangeLog | 76 + overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java | 1 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipKeyImpl.java | 224 +++ overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipRegistry.java | 132 ++ overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java | 18 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java | 2 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractPoller.java | 8 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java | 1 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java | 3 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java | 6 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/EPollPort.java | 3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java | 7 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/Port.java | 7 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java | 8 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousSocketChannelImpl.java | 9 patches/icedtea-nio2.patch | 652 +++++++++- diffs (truncated from 1562 to 500 lines): diff -r fb3c68368b7f -r 913512a256bd ChangeLog --- a/ChangeLog Mon Jan 19 14:25:02 2009 +0000 +++ b/ChangeLog Tue Jan 20 00:06:18 2009 +0000 @@ -1,3 +1,79 @@ 2009-01-19 Andrew John Hughes + + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java: + (getByIndex(int)): New method. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java: + Fixed imports. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipKeyImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipRegistry.java: + New files. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java: + Fix imports, refer to AsynchronousFileLockImpl instead of FileLockImpl. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractAclFileAttributeView.java: + Fix imports and vararg usage. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractBasicFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractFileStoreSpaceAttributeView.java: + Fix vararg usage. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractPoller.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchKey.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractWatchService.java: + Fix imports. + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/FileOwnerAttributeViewImpl.java: + Fix imports and vararg usage. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/EPollPort.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/LinuxAsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/Port.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/UnixAsynchronousSocketChannelImpl.java: + Fix imports. + * patches/icedtea-nio2.patch: + Add new classes. + (Unsafe.copyMemory(long,long,long)): Backported. + (Unsafe.copyMemory(Object,long,Object,long,long)): Backported. + (Unsafe.ARRAY_BYTE_BASE_OFFSET): Likewise. + (DatagramChannelImpl.bind(SocketAddress)): Likewise. + (DatagramChannelImpl.getLocalAddress()): Likewise. + (DatagramChannelImpl.getOption(SocketOption)): Likewise. + (DatagramChannelImpl.innerJoin(InetAddress,NetworkInterface,InetAddress)): Likewise. + (DatagramChannelImpl.join(InetAddress,NetworkInterface)): Likewise. + (DatagramChannelImpl.join(InetAddress,NetworkInterface,InetAddress)): Likewise. + (DatagramChannelImpl.block(MembershipKeyImpl,InetAddress)): Likewise. + (DatagramChannelImpl.unblock(MembershipKeyImpl,InetAddress)): Likewise. + (DatagramChannelImpl.drop(MembershipKeyImpl)): Likewise. + (Net.getInterface4(FileDescriptor)): Likewise. + (Net.getInterface6(FileDescriptor)): Likewise. + (Net.inet4FromInt(int)): Likewise. + (Net.inet6AsByteArray(InetAddress)): Likewise. + (Net.join6(FileDescriptor,byte[],int,byte[])): Likewise. + (Net.drop6(FileDescriptor,byte[],int,byte[])): Likewise. + (Net.joinOrDrop6(boolean,FileDescriptor,byte[],int,byte[])): Likewise. + (Net.block6(FileDescriptor,byte[],int,byte[])): Likewise. + (Net.unblock6(FileDescriptor,byte[],int,byte[])): Likewise. + (Net.blockOrUnblock6(boolean,FileDescriptor,byte[],int,byte[])): Likewise. + (Net.join4(FileDescriptor,int,int,int)): Likewise. + (Net.drop4(FileDescriptor,int,int,int)): Likewise. + (Net.joinOrDrop4(boolean,FileDescriptor,int,int,int)): Likewise. + (Net.block4(FileDescriptor,int,int,int)): Likewise. + (Net.unblock4(FileDescriptor,int,int,int)): Likewise. + (Net.blockOrUnblock4(boolean,FileDescriptor,int,int,int)): Likewise. + (Net.connect(FileDescriptor,InetAddress,int)): Likewise. + (Net.connect(ProtocolFamily,FileDescriptor,InetAddress,int)): Likewise. + (Net.connect0(boolean,FileDescriptor,InetAddress,int)): Likewise. + (FileDispatcher.NO_LOCK)): Likewise. + (FileDispatcher.LOCKED)): Likewise. + (FileDispatcher.RET_EX_LOCK)): Likewise. + (FileDispatcher.INTERRUPTED)): Likewise. + (FileDispatcher.size(FileDescriptor)): Likewise. + (FileDispatcher.truncate(FileDescriptor, long)): Likewise. + (FileDispatcher.force(FileDescriptor, boolean)): Likewise. + (FileDispatcher.lock(FileDescriptor, boolean, long, long, boolean)): Likewise. + (FileDispatcher.release(FileDescriptor, long, long)): Likewise. + (FileDispatcher.force0(FileDescriptor,boolean)): Likewise. + (FileDispatcher.truncate0(FileDescriptor, long)): Likewise. + (FileDispatcher.size0(FileDescriptor)): Likewise. + (FileDispatcher.lock0(FileDescriptor, boolean, long, long, boolean)): Likewise. + (FileDispatcher.release0(FileDescriptor, long, long)): Likewise. + 2009-01-19 Andrew John Hughes * generated/sun/nio/ch/SocketOptionRegistry.java: diff -r fb3c68368b7f -r 913512a256bd overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java Mon Jan 19 14:25:02 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java Tue Jan 20 00:06:18 2009 +0000 @@ -42,4 +42,5 @@ public interface JavaNetGetIndexAccess public interface JavaNetGetIndexAccess { int getIndex(NetworkInterface nf); + NetworkInterface getByIndex(int i); } diff -r fb3c68368b7f -r 913512a256bd overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java Mon Jan 19 14:25:02 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousServerSocketChannelImpl.java Tue Jan 20 00:06:18 2009 +0000 @@ -25,11 +25,11 @@ package sun.nio.ch; -import java.nio.channels.*; import java.net.SocketAddress; import java.net.InetSocketAddress; import java.io.FileDescriptor; import java.io.IOException; +import java.nio.channels.ClosedChannelException; import java.util.Set; import java.util.HashSet; import java.util.Collections; diff -r fb3c68368b7f -r 913512a256bd overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipKeyImpl.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipKeyImpl.java Tue Jan 20 00:06:18 2009 +0000 @@ -0,0 +1,224 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package sun.nio.ch; + +import java.net.InetAddress; +import java.net.NetworkInterface; +import java.io.IOException; +import java.util.HashSet; + +import org.classpath.icedtea.java.nio.channels.MembershipKey; +import org.classpath.icedtea.java.nio.channels.MulticastChannel; + +/** + * MembershipKey implementation. + */ + +class MembershipKeyImpl + extends MembershipKey +{ + private final MulticastChannel ch; + private final InetAddress group; + private final NetworkInterface interf; + private final InetAddress source; + + // true when key is valid + private volatile boolean valid = true; + + // lock used when creating or accessing blockedSet + private Object stateLock = new Object(); + + // set of source addresses that are blocked + private HashSet blockedSet; + + private MembershipKeyImpl(MulticastChannel ch, + InetAddress group, + NetworkInterface interf, + InetAddress source) + { + this.ch = ch; + this.group = group; + this.interf = interf; + this.source = source; + } + + /** + * MembershipKey will additional context for IPv4 membership + */ + static class Type4 extends MembershipKeyImpl { + private final int groupAddress; + private final int interfAddress; + private final int sourceAddress; + + Type4(MulticastChannel ch, + InetAddress group, + NetworkInterface interf, + InetAddress source, + int groupAddress, + int interfAddress, + int sourceAddress) + { + super(ch, group, interf, source); + this.groupAddress = groupAddress; + this.interfAddress = interfAddress; + this.sourceAddress = sourceAddress; + } + + int groupAddress() { + return groupAddress; + } + + int interfaceAddress() { + return interfAddress; + } + + int source() { + return sourceAddress; + } + } + + /** + * MembershipKey will additional context for IPv6 membership + */ + static class Type6 extends MembershipKeyImpl { + private final byte[] groupAddress; + private final int index; + private final byte[] sourceAddress; + + Type6(MulticastChannel ch, + InetAddress group, + NetworkInterface interf, + InetAddress source, + byte[] groupAddress, + int index, + byte[] sourceAddress) + { + super(ch, group, interf, source); + this.groupAddress = groupAddress; + this.index = index; + this.sourceAddress = sourceAddress; + } + + byte[] groupAddress() { + return groupAddress; + } + + int index() { + return index; + } + + byte[] source() { + return sourceAddress; + } + } + + public boolean isValid() { + return valid; + } + + // package-private + void invalidate() { + valid = false; + } + + public void drop() throws IOException { + // delegate to channel + ((DatagramChannelImpl)ch).drop(this); + } + + + public MulticastChannel channel() { + return ch; + } + + + public InetAddress group() { + return group; + } + + + public NetworkInterface networkInterface() { + return interf; + } + + + public InetAddress sourceAddress() { + return source; + } + + + public MembershipKey block(InetAddress toBlock) + throws IOException + { + if (source != null) + throw new IllegalStateException("key is source-specific"); + + synchronized (stateLock) { + if ((blockedSet != null) && blockedSet.contains(toBlock)) { + // already blocked, nothing to do + return this; + } + + ((DatagramChannelImpl)ch).block(this, toBlock); + + // created blocked set if required and add source address + if (blockedSet == null) + blockedSet = new HashSet(); + blockedSet.add(toBlock); + } + return this; + } + + + public MembershipKey unblock(InetAddress toUnblock) + throws IOException + { + synchronized (stateLock) { + if ((blockedSet == null) || !blockedSet.contains(toUnblock)) + throw new IllegalStateException("not blocked"); + + ((DatagramChannelImpl)ch).unblock(this, toUnblock); + + blockedSet.remove(toUnblock); + } + return this; + } + + + public String toString() { + StringBuilder sb = new StringBuilder(64); + sb.append('<'); + sb.append(group.getHostAddress()); + sb.append(','); + sb.append(interf.getName()); + if (source != null) { + sb.append(','); + sb.append(source.getHostAddress()); + } + sb.append('>'); + return sb.toString(); + } +} diff -r fb3c68368b7f -r 913512a256bd overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipRegistry.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/MembershipRegistry.java Tue Jan 20 00:06:18 2009 +0000 @@ -0,0 +1,132 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Sun designates this + * particular file as subject to the "Classpath" exception as provided + * by Sun in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, + * CA 95054 USA or visit www.sun.com if you need additional information or + * have any questions. + */ + +package sun.nio.ch; + +import java.net.InetAddress; +import java.net.NetworkInterface; +import java.util.*; + +import org.classpath.icedtea.java.nio.channels.MembershipKey; + +/** + * Simple registry of membership keys for a MulticastChannel. + * + * Instances of this object are not safe by multiple concurrent threads. + */ + +class MembershipRegistry { + + // map multicast group to keys + private Map> groups = null; + + MembershipRegistry() { + } + + /** + * Checks registry for membership of the group on the given + * network interface. + */ + MembershipKey checkMembership(InetAddress group, NetworkInterface interf, + InetAddress source) + { + if (groups != null) { + List keys = groups.get(group); + if (keys != null) { + for (MembershipKeyImpl key: keys) { + if (key.networkInterface().equals(interf)) { + // already a member to receive all packets so return + // existing key or detect conflict + if (source == null) { + if (key.sourceAddress() == null) + return key; + throw new IllegalStateException("Already a member to receive all packets"); + } + + // already have source-specific membership so return key + // or detect conflict + if (key.sourceAddress() == null) + throw new IllegalStateException("Already have source-specific membership"); + if (source.equals(key.sourceAddress())) + return key; + } + } + } + } + return null; + } + + /** + * Add membership to the registry, returning a new membership key. + */ + void add(MembershipKeyImpl key) { + InetAddress group = key.group(); + List keys; + if (groups == null) { + groups = new HashMap>(); + keys = null; + } else { + keys = groups.get(group); + } + if (keys == null) { + keys = new LinkedList(); + groups.put(group, keys); + } + keys.add(key); + } + + /** + * Remove a key from the registry + */ + void remove(MembershipKeyImpl key) { + InetAddress group = key.group(); + List keys = groups.get(group); + if (keys != null) { + Iterator i = keys.iterator(); + while (i.hasNext()) { + if (i.next() == key) { + i.remove(); + break; + } + } + if (keys.isEmpty()) { + groups.remove(group); + } + } + } + + /** + * Invalidate all keys in the registry + */ + void invalidateAll() { + if (groups != null) { + for (InetAddress group: groups.keySet()) { + for (MembershipKeyImpl key: groups.get(group)) { + key.invalidate(); + } + } + } + } +} diff -r fb3c68368b7f -r 913512a256bd overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java Mon Jan 19 14:25:02 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/SimpleAsynchronousFileChannelImpl.java Tue Jan 20 00:06:18 2009 +0000 @@ -25,13 +25,21 @@ package sun.nio.ch; -import java.nio.channels.*; import java.util.concurrent.*; import java.nio.ByteBuffer; +import java.nio.channels.AsynchronousCloseException; +import java.nio.channels.ClosedChannelException; +import java.nio.channels.NonReadableChannelException; +import java.nio.channels.NonWritableChannelException; import java.security.AccessController; import java.security.PrivilegedAction; import java.io.FileDescriptor; import java.io.IOException; + +import org.classpath.icedtea.java.nio.channels.AsynchronousFileChannel; +import org.classpath.icedtea.java.nio.channels.CompletionHandler; +import org.classpath.icedtea.java.nio.channels.FileLock; +import org.classpath.icedtea.java.nio.channels.ShutdownChannelGroupException; /** * "Portable" implementation of AsynchronousFileChannel for use on operating @@ -60,7 +68,7 @@ public class SimpleAsynchronousFileChann } From gnu_andrew at member.fsf.org Tue Feb 3 04:13:59 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:59 +0000 Subject: changeset in /hg/icedtea6: Merge. Message-ID: changeset 721c79ccc804 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=721c79ccc804 description: Merge. diffstat: 18 files changed, 678 insertions(+), 95 deletions(-) ChangeLog | 33 + IcedTeaPlugin.cc | 2 plugin/icedtea/sun/applet/PluginAppletViewer.java | 12 plugin/icedtea/sun/applet/PluginMain.java | 22 rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java | 34 + rt/net/sourceforge/jnlp/security/AccessWarningPane.java | 34 + rt/net/sourceforge/jnlp/security/AppletWarningPane.java | 6 rt/net/sourceforge/jnlp/security/CertWarningPane.java | 27 - rt/net/sourceforge/jnlp/security/CertsInfoPane.java | 4 rt/net/sourceforge/jnlp/security/HttpsCertVerifier.java | 119 +++++ rt/net/sourceforge/jnlp/security/MoreInfoPane.java | 30 - rt/net/sourceforge/jnlp/security/SecurityDialogUI.java | 32 - rt/net/sourceforge/jnlp/security/SecurityWarningDialog.java | 50 +- rt/net/sourceforge/jnlp/security/SingleCertInfoPane.java | 6 rt/net/sourceforge/jnlp/security/VariableX509TrustManager.java | 222 ++++++++++ rt/net/sourceforge/jnlp/security/viewer/CertificatePane.java | 18 rt/net/sourceforge/jnlp/tools/CertVerifier.java | 92 ++++ rt/net/sourceforge/jnlp/tools/JarSigner.java | 30 + diffs (truncated from 1216 to 500 lines): diff -r 913512a256bd -r 721c79ccc804 ChangeLog --- a/ChangeLog Tue Jan 20 00:06:18 2009 +0000 +++ b/ChangeLog Tue Jan 20 09:44:16 2009 +0000 @@ -74,6 +74,39 @@ 2009-01-19 Andrew John Hughes + * IcedTeaPlugin.cc: Add "Java" in the plugin description string. + * plugin/icedtea/sun/applet/PluginAppletViewer.java: Change the way the + image was searched locally. + * plugin/icedtea/sun/applet/PluginMain.java: Install a custom SSL trust + manager. + * rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java: Cache file names + from jars. + * rt/net/sourceforge/jnlp/security/AccessWarningPane.java: Accept + CertVerifier as an additional argument. + * rt/net/sourceforge/jnlp/security/AppletWarningPane.java: Same. + * rt/net/sourceforge/jnlp/security/CertWarningPane.java: Same. + * rt/net/sourceforge/jnlp/security/CertsInfoPane.java: Same. + * rt/net/sourceforge/jnlp/security/HttpsCertVerifier.java: New file. + Implements information gathering functions used by various prompt dialogs. + * rt/net/sourceforge/jnlp/security/MoreInfoPane.java: Accept CertVerifier + as an additional argument. + * rt/net/sourceforge/jnlp/security/SecurityDialogUI.java: Same. + * rt/net/sourceforge/jnlp/security/SecurityWarningDialog.java: Use the new + common CertVerifier interface to gather information. + * rt/net/sourceforge/jnlp/security/SingleCertInfoPane.java: Accept + CertVerifier as an additional argument. + * rt/net/sourceforge/jnlp/security/VariableX509TrustManager.java: + Customized trustmanager that can temporarily trust certificates on the + fly. + * rt/net/sourceforge/jnlp/security/viewer/CertificatePane.java: Accept + CertVerifier as an additional argument. + * rt/net/sourceforge/jnlp/tools/CertVerifier.java: New common interface + that all security related dialogs now query for certificate info (jar and + https). + * rt/net/sourceforge/jnlp/tools/JarSigner.java: Implement the new + CertVerifier verifier interface. + 2009-01-19 Andrew John Hughes * generated/sun/nio/ch/SocketOptionRegistry.java: diff -r 913512a256bd -r 721c79ccc804 IcedTeaPlugin.cc --- a/IcedTeaPlugin.cc Tue Jan 20 00:06:18 2009 +0000 +++ b/IcedTeaPlugin.cc Tue Jan 20 09:44:16 2009 +0000 @@ -275,7 +275,7 @@ inline long get_time_in_s() #define PLUGIN_CHECK(message, result) #endif -#define PLUGIN_NAME "IcedTea Web Browser Plugin" +#define PLUGIN_NAME "IcedTea Java Web Browser Plugin" #define PLUGIN_DESCRIPTION "The " PLUGIN_NAME PLUGIN_VERSION " executes Java applets." #define PLUGIN_MIME_DESC \ "application/x-java-vm:class,jar:IcedTea;" \ diff -r 913512a256bd -r 721c79ccc804 plugin/icedtea/sun/applet/PluginAppletViewer.java --- a/plugin/icedtea/sun/applet/PluginAppletViewer.java Tue Jan 20 00:06:18 2009 +0000 +++ b/plugin/icedtea/sun/applet/PluginAppletViewer.java Tue Jan 20 09:44:16 2009 +0000 @@ -176,7 +176,7 @@ import sun.misc.Ref; AccessController.doPrivileged(new PrivilegedAction() { public Object run() { try { - panel = new NetxPanel(doc, atts, true); + panel = new NetxPanel(doc, atts, false); AppletViewerPanel.debug("Using NetX panel"); PluginDebug.debug(atts.toString()); } catch (Exception ex) { @@ -612,8 +612,14 @@ import sun.misc.Ref; // try to fetch it locally if (panel instanceof NetxPanel) { + URL localURL = null; - localURL = ((NetxPanel) panel).getAppletClassLoader().getResource(originalURL.substring(codeBase.length())); + + String resourceName = originalURL.substring(codeBase.length()); + JNLPClassLoader loader = (JNLPClassLoader) ((NetxPanel) panel).getAppletClassLoader(); + + if (loader.resourceAvailableLocally(resourceName)) + localURL = loader.getResource(resourceName); url = localURL != null ? localURL : url; } @@ -630,7 +636,7 @@ import sun.misc.Ref; return ref; } } catch (Exception e) { - System.err.println("Error occurred wgen trying to fetch image:"); + System.err.println("Error occurred when trying to fetch image:"); e.printStackTrace(); return null; } diff -r 913512a256bd -r 721c79ccc804 plugin/icedtea/sun/applet/PluginMain.java --- a/plugin/icedtea/sun/applet/PluginMain.java Tue Jan 20 00:06:18 2009 +0000 +++ b/plugin/icedtea/sun/applet/PluginMain.java Tue Jan 20 09:44:16 2009 +0000 @@ -33,6 +33,14 @@ import java.net.Socket; import java.net.Socket; import java.util.Enumeration; import java.util.Properties; + +import javax.net.ssl.SSLContext; +import javax.net.ssl.SSLSocketFactory; +import javax.net.ssl.TrustManager; + +import javax.net.ssl.HttpsURLConnection; + +import net.sourceforge.jnlp.security.VariableX509TrustManager; /** * The main entry point into PluginAppletViewer. @@ -152,7 +160,19 @@ public class PluginMain // INSTALL THE PROPERTY LIST System.setProperties(avProps); - // REMIND: Create and install a socket factory! + + try { + SSLSocketFactory sslSocketFactory; + SSLContext context = SSLContext.getInstance("SSL"); + TrustManager[] trust = new TrustManager[] { VariableX509TrustManager.getInstance() }; + context.init(null, trust, null); + sslSocketFactory = context.getSocketFactory(); + + HttpsURLConnection.setDefaultSSLSocketFactory(sslSocketFactory); + } catch (Exception e) { + System.err.println("Unable to set SSLSocketfactory (may _prevent_ access to sites that should be trusted)! Continuing anyway..."); + e.printStackTrace(); + } } static boolean messageAvailable() { diff -r 913512a256bd -r 721c79ccc804 rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java --- a/rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 20 00:06:18 2009 +0000 +++ b/rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java Tue Jan 20 09:44:16 2009 +0000 @@ -29,7 +29,6 @@ import java.security.Permission; import java.security.Permission; import java.security.PermissionCollection; import java.security.Permissions; -import java.security.Policy; import java.security.PrivilegedAction; import java.util.ArrayList; import java.util.Enumeration; @@ -38,6 +37,7 @@ import java.util.List; import java.util.List; import java.util.Map; import java.util.Random; +import java.util.TreeSet; import java.util.Vector; import java.util.jar.JarEntry; import java.util.jar.JarFile; @@ -131,7 +131,11 @@ public class JNLPClassLoader extends URL private boolean signing = false; + /** ArrayList containing jar indexes for various jars available to this classloader */ private ArrayList jarIndexes = new ArrayList(); + + /** File entries in the jar files available to this classloader */ + private TreeSet jarEntries = new TreeSet(); /** * Create a new JNLPClassLoader from the specified file. @@ -478,7 +482,6 @@ public class JNLPClassLoader extends URL // transfer the Jars waitForJars(jars); - for (int i=0; i < jars.size(); i++) { JARDesc jar = (JARDesc) jars.get(i); @@ -488,8 +491,23 @@ public class JNLPClassLoader extends URL File localFile = tracker.getCacheFile(jar.getLocation()); try { URL location = jar.getLocation(); // non-cacheable, use source location - if (localFile != null) + if (localFile != null) { location = localFile.toURL(); // cached file + + // This is really not the best way.. but we need some way for + // PluginAppletViewer::getCachedImageRef() to check if the image + // is available locally, and it cannot use getResources() because + // that prefetches the resource, which confuses MediaTracker.waitForAll() + // which does a wait(), waiting for notification (presumably + // thrown after a resource is fetched). This bug manifests itself + // particularly when using The FileManager applet from Webmin. + + JarFile jarFile = new JarFile(localFile); + Enumeration e = jarFile.entries(); + while (e.hasMoreElements()) + jarEntries.add(((JarEntry) e.nextElement()).getName()); + + } addURL(location); @@ -829,6 +847,16 @@ public class JNLPClassLoader extends URL return resources.elements(); } + + /** + * Returns if the specified resource is available locally from a cached jar + * + * @param s The name of the resource + * @return Whether or not the resource is available locally + */ + public boolean resourceAvailableLocally(String s) { + return jarEntries.contains(s); + } /** * Adds whatever resources have already been downloaded in the diff -r 913512a256bd -r 721c79ccc804 rt/net/sourceforge/jnlp/security/AccessWarningPane.java --- a/rt/net/sourceforge/jnlp/security/AccessWarningPane.java Tue Jan 20 00:06:18 2009 +0000 +++ b/rt/net/sourceforge/jnlp/security/AccessWarningPane.java Tue Jan 20 09:44:16 2009 +0000 @@ -37,14 +37,28 @@ exception statement from your version. package net.sourceforge.jnlp.security; -import java.awt.*; -import javax.swing.*; +import java.awt.BorderLayout; +import java.awt.Color; +import java.awt.Dimension; +import java.awt.FlowLayout; +import java.awt.Font; +import java.awt.GridLayout; +import java.awt.event.ActionEvent; import java.awt.event.ActionListener; -import java.awt.event.ActionEvent; -import java.net.URL; + +import javax.swing.BorderFactory; +import javax.swing.BoxLayout; +import javax.swing.ImageIcon; +import javax.swing.JButton; +import javax.swing.JCheckBox; +import javax.swing.JComponent; +import javax.swing.JLabel; +import javax.swing.JPanel; +import javax.swing.SwingConstants; import net.sourceforge.jnlp.JNLPFile; import net.sourceforge.jnlp.runtime.JNLPRuntime; +import net.sourceforge.jnlp.tools.CertVerifier; /** * Provides the look and feel for a SecurityWarningDialog. These dialogs are @@ -59,12 +73,12 @@ public class AccessWarningPane extends S JCheckBox alwaysAllow; Object[] extras; - public AccessWarningPane(JComponent x) { - super(x); - } - - public AccessWarningPane(JComponent x, Object[] extras) { - super(x); + public AccessWarningPane(JComponent x, CertVerifier certVerifier) { + super(x, certVerifier); + } + + public AccessWarningPane(JComponent x, Object[] extras, CertVerifier certVerifier) { + super(x, certVerifier); this.extras = extras; } diff -r 913512a256bd -r 721c79ccc804 rt/net/sourceforge/jnlp/security/AppletWarningPane.java --- a/rt/net/sourceforge/jnlp/security/AppletWarningPane.java Tue Jan 20 00:06:18 2009 +0000 +++ b/rt/net/sourceforge/jnlp/security/AppletWarningPane.java Tue Jan 20 09:44:16 2009 +0000 @@ -50,10 +50,12 @@ import javax.swing.JLabel; import javax.swing.JLabel; import javax.swing.JPanel; +import net.sourceforge.jnlp.tools.CertVerifier; + public class AppletWarningPane extends SecurityDialogUI { - public AppletWarningPane(JComponent x) { - super(x); + public AppletWarningPane(JComponent x, CertVerifier certVerifier) { + super(x, certVerifier); } protected void installComponents() { diff -r 913512a256bd -r 721c79ccc804 rt/net/sourceforge/jnlp/security/CertWarningPane.java --- a/rt/net/sourceforge/jnlp/security/CertWarningPane.java Tue Jan 20 00:06:18 2009 +0000 +++ b/rt/net/sourceforge/jnlp/security/CertWarningPane.java Tue Jan 20 09:44:16 2009 +0000 @@ -37,18 +37,31 @@ exception statement from your version. package net.sourceforge.jnlp.security; -import java.awt.*; -import javax.swing.*; - - +import java.awt.BorderLayout; +import java.awt.Color; +import java.awt.Dimension; +import java.awt.FlowLayout; +import java.awt.Font; +import java.awt.GridLayout; +import java.awt.event.ActionEvent; import java.awt.event.ActionListener; -import java.awt.event.ActionEvent; import java.security.cert.Certificate; import java.security.cert.X509Certificate; + +import javax.swing.BorderFactory; +import javax.swing.BoxLayout; +import javax.swing.ImageIcon; +import javax.swing.JButton; +import javax.swing.JCheckBox; +import javax.swing.JComponent; +import javax.swing.JLabel; +import javax.swing.JPanel; +import javax.swing.SwingConstants; import net.sourceforge.jnlp.JNLPFile; import net.sourceforge.jnlp.PluginBridge; import net.sourceforge.jnlp.runtime.JNLPRuntime; +import net.sourceforge.jnlp.tools.CertVerifier; import net.sourceforge.jnlp.tools.KeyTool; /** @@ -63,8 +76,8 @@ public class CertWarningPane extends Sec JCheckBox alwaysTrust; - public CertWarningPane(JComponent x) { - super(x); + public CertWarningPane(JComponent x, CertVerifier certVerifier) { + super(x, certVerifier); } /** diff -r 913512a256bd -r 721c79ccc804 rt/net/sourceforge/jnlp/security/CertsInfoPane.java --- a/rt/net/sourceforge/jnlp/security/CertsInfoPane.java Tue Jan 20 00:06:18 2009 +0000 +++ b/rt/net/sourceforge/jnlp/security/CertsInfoPane.java Tue Jan 20 09:44:16 2009 +0000 @@ -76,8 +76,8 @@ public class CertsInfoPane extends Secur private String[] columnNames = { "Field", "Value" }; protected ArrayList certsData; - public CertsInfoPane(JComponent x) { - super(x); + public CertsInfoPane(JComponent x, CertVerifier certVerifier) { + super(x, certVerifier); } /** diff -r 913512a256bd -r 721c79ccc804 rt/net/sourceforge/jnlp/security/HttpsCertVerifier.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/rt/net/sourceforge/jnlp/security/HttpsCertVerifier.java Tue Jan 20 09:44:16 2009 +0000 @@ -0,0 +1,119 @@ +/* VariableX509TrustManager.java + Copyright (C) 2009 Red Hat, Inc. + +This file is part of IcedTea. + +IcedTea is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License as published by +the Free Software Foundation, version 2. + +IcedTea is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with IcedTea; see the file COPYING. If not, write to +the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +Linking this library statically or dynamically with other modules is +making a combined work based on this library. Thus, the terms and +conditions of the GNU General Public License cover the whole +combination. + +As a special exception, the copyright holders of this library give you +permission to link this library with independent modules to produce an +executable, regardless of the license terms of these independent +modules, and to copy and distribute the resulting executable under +terms of your choice, provided that you also meet, for each linked +independent module, the terms and conditions of the license of that +module. An independent module is a module which is not derived from +or based on this library. If you modify this library, you may extend +this exception to your version of the library, but you are not +obligated to do so. If you do not wish to do so, delete this +exception statement from your version. +*/ + +package net.sourceforge.jnlp.security; + +import java.security.cert.CertPath; +import java.security.cert.Certificate; +import java.security.cert.CertificateException; +import java.security.cert.CertificateFactory; +import java.security.cert.X509Certificate; +import java.util.ArrayList; + +import net.sourceforge.jnlp.tools.CertVerifier; + +public class HttpsCertVerifier implements CertVerifier { + + private VariableX509TrustManager tm; + private X509Certificate[] chain; + private String authType; + + public HttpsCertVerifier(VariableX509TrustManager tm, X509Certificate[] chain, String authType) { + this.tm = tm; + this.chain = chain; + this.authType = authType; + } + + public boolean getAlreadyTrustPublisher() { + try { + tm.checkServerTrusted(chain, authType, true); + return true; + } catch (CertificateException ce) { + return false; + } + } + + public ArrayList getCerts() { + + ArrayList list = new ArrayList(); + for (int i=0; i < chain.length; i++) + list.add(chain[i]); + + ArrayList certPaths = new ArrayList(); + + try { + certPaths.add(CertificateFactory.getInstance("X.509").generateCertPath(list)); + } catch (CertificateException ce) { + ce.printStackTrace(); + + // carry on + } + + return certPaths; + } + + public ArrayList getDetails() { + // TODO Auto-generated method stub + return new ArrayList(); + } + + public Certificate getPublisher() { + // TODO Auto-generated method stub + return null; + } + + public Certificate getRoot() { + // TODO Auto-generated method stub + return null; + } + + public boolean getRootInCacerts() { + // TODO Auto-generated method stub + return false; + } + + public boolean hasSigningIssues() { + // TODO Auto-generated method stub + return false; + } + + public boolean noSigningIssues() { + // TODO Auto-generated method stub + return false; + } + +} diff -r 913512a256bd -r 721c79ccc804 rt/net/sourceforge/jnlp/security/MoreInfoPane.java --- a/rt/net/sourceforge/jnlp/security/MoreInfoPane.java Tue Jan 20 00:06:18 2009 +0000 +++ b/rt/net/sourceforge/jnlp/security/MoreInfoPane.java Tue Jan 20 09:44:16 2009 +0000 @@ -37,15 +37,23 @@ exception statement from your version. package net.sourceforge.jnlp.security; -import java.awt.*; -import javax.swing.*; +import java.awt.BorderLayout; +import java.awt.Dimension; +import java.awt.GridLayout; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; +import java.util.ArrayList; -import net.sourceforge.jnlp.runtime.*; +import javax.swing.BorderFactory; +import javax.swing.ImageIcon; +import javax.swing.JButton; +import javax.swing.JComponent; +import javax.swing.JLabel; +import javax.swing.JPanel; +import javax.swing.SwingConstants; -import java.util.ArrayList; -import java.awt.event.ActionListener; From gnu_andrew at member.fsf.org Tue Feb 3 04:13:59 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:59 +0000 Subject: changeset in /hg/icedtea6: Fix remaining Java files and backport... Message-ID: changeset 050b48f42fb3 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=050b48f42fb3 description: Fix remaining Java files and backport Net.c and RESTARTABLE macro. 2009-01-26 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java: Fix imports. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java: Fix imports and use of varargs. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileModeAttribute.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java: Fix imports. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java: Fix imports and use of varargs. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java: Fix imports. * patches/icedtea-nio2.patch: (FileChannelImpl): Fix imports. (Net.c): Patch to new version with new functions. (nio_util.h): Add RESTARTABLE macro. diffstat: 22 files changed, 898 insertions(+), 47 deletions(-) ChangeLog | 75 - overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java | 1 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java | 15 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java | 3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java | 4 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java | 10 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java | 6 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java | 7 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java | 9 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java | 9 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java | 1 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java | 6 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java | 13 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java | 3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileModeAttribute.java | 4 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java | 13 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java | 11 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java | 15 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java | 32 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java | 20 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java | 4 patches/icedtea-nio2.patch | 684 ++++++++++ diffs (truncated from 1408 to 500 lines): diff -r 721c79ccc804 -r 050b48f42fb3 ChangeLog --- a/ChangeLog Tue Jan 20 09:44:16 2009 +0000 +++ b/ChangeLog Mon Jan 26 23:09:32 2009 +0000 @@ -1,4 +1,36 @@ 2009-01-19 Andrew John Hughes +2009-01-26 Andrew John Hughes + + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java: + Fix imports. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java: + Fix imports and use of varargs. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileModeAttribute.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileStore.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystem.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixPath.java: + Fix imports. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixSecureDirectoryStream.java: + Fix imports and use of varargs. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixUserPrincipals.java: + Fix imports. + * patches/icedtea-nio2.patch: + (FileChannelImpl): Fix imports. + (Net.c): Patch to new version with new functions. + (nio_util.h): Add RESTARTABLE macro. + +2009-01-19 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaNetGetIndexAccess.java: (getByIndex(int)): New method. @@ -75,6 +107,7 @@ 2009-01-19 Andrew John Hughes + * IcedTeaPlugin.cc: Add "Java" in the plugin description string. * plugin/icedtea/sun/applet/PluginAppletViewer.java: Change the way the image was searched locally. @@ -107,7 +140,7 @@ 2009-01-19 Deepak Bhole +2009-01-19 Andrew John Hughes * generated/sun/nio/ch/SocketOptionRegistry.java: * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/DatagramChannel.java: @@ -158,7 +191,7 @@ 2009-01-15 Gary Benson +2009-01-14 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: Extend java.nio.channels.FileChannel to minimise code. @@ -184,13 +217,13 @@ 2009-01-13 Omair Majid +2009-01-13 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/JavaIODeleteOnExitAccess.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/misc/SharedSecrets.java: Add missing SharedSecrets files. -2009-01-13 Andrew John Hughes +2009-01-13 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardProtocolFamily.java, * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/net/StandardSocketOption.java: @@ -231,7 +264,7 @@ 2009-01-13 Andrew John Hughes +2009-01-12 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedCopyOption.java, * overlays/nio2/openjdk/jdk/src/share/classes/com/sun/nio/file/ExtendedOpenOption.java, @@ -290,7 +323,7 @@ 2009-01-13 Gary Benson +2009-01-12 Andrew John Hughes Initial import of NIO2 code. * patches/ecj/icedtea-pr261.patch: Moved to general patches. @@ -750,13 +783,13 @@ 2008-12-19 Andrew Haley +2008-12-17 Andrew John Hughes * acinclude.m4: (FIND_RHINO_JAR): Check for js.jar in Gentoo install location too. -2008-12-17 Andrew John Hughes +2008-12-17 Andrew John Hughes * Makefile.am: No need to check again that SYSTEM_GCJ_DIR exists. @@ -769,7 +802,7 @@ 2008-12-17 Andrew John Hughes +2008-12-17 Andrew John Hughes * Makefile.am: Remove use of LIBGCJ_JAR, replacing with @@ -783,7 +816,7 @@ 2008-12-17 Andrew John Hughes +2008-12-17 Andrew John Hughes * Makefile.am: Remove the HotSpot directory while extracting @@ -855,7 +888,7 @@ 2008-12-10 Deepak Bhole +2008-12-09 Andrew John Hughes * Makefile.am: Support use of HGREV. @@ -864,14 +897,14 @@ 2008-12-09 Andrew John Hughes +2008-12-09 Andrew John Hughes * Makefile.am: Properly support --with-openjdk-src-dir. * acinclude.m4: Correct the define for OPENJDK_SRC_DIR. -2008-12-09 Andrew John Hughes +2008-12-09 Andrew John Hughes * Makefile.am: Support downloading from the Mercurial repository. @@ -880,7 +913,7 @@ 2008-12-09 Andrew John Hughes +2008-12-09 Andrew John Hughes * Makefile.am: Make XRender patch wildcard work where @@ -888,7 +921,7 @@ 2008-12-09 Andrew John Hughes +2008-12-09 Andrew John Hughes * Makefile.am: Don't use find to locate the hotspot directory, @@ -957,7 +990,7 @@ 2008-12-04 Matthias Klose +2008-12-04 Andrew John Hughes * Makefile.am: Prefix the call to uname -m with @@ -965,7 +998,7 @@ 2008-12-04 Andrew John Hughes +2008-12-04 Andrew John Hughes * Makefile.am: Prefix make invocations with @@ -1081,7 +1114,7 @@ 2008-12-02 Omair Majid +2008-12-03 Andrew John Hughes Create hierarchical patch space. * patches/icedtea-4486841.patch, @@ -1263,7 +1296,7 @@ 2008-12-02 Lillian Angel +2008-12-02 Andrew John Hughes * patches/icedtea-bytecodeInterpreter.patch, * patches/icedtea-hotspot7-build-fixes.patch: @@ -1282,7 +1315,7 @@ 2008-12-02 Andrew John Hughes +2008-12-01 Andrew John Hughes * patches/icedtea-hotspot-params-cast-size_t.patch, * patches/icedtea-hotspot-use-idx_t.patch, diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java Mon Jan 26 23:09:32 2009 +0000 @@ -27,6 +27,7 @@ package sun.nio.ch; package sun.nio.ch; import java.io.IOException; +import java.nio.channels.Channel; import java.nio.channels.ClosedChannelException; import java.nio.channels.FileChannel; diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/PollingWatchService.java Mon Jan 26 23:09:32 2009 +0000 @@ -25,14 +25,25 @@ package sun.nio.fs; -import java.nio.file.*; -import java.nio.file.attribute.*; import java.security.AccessController; import java.security.PrivilegedAction; import java.security.PrivilegedExceptionAction; import java.security.PrivilegedActionException; import java.io.IOException; import java.util.*; + +import org.classpath.icedtea.java.nio.file.ClosedWatchServiceException; +import org.classpath.icedtea.java.nio.file.DirectoryStream; +import org.classpath.icedtea.java.nio.file.FileRef; +import org.classpath.icedtea.java.nio.file.LinkOption; +import org.classpath.icedtea.java.nio.file.NotDirectoryException; +import org.classpath.icedtea.java.nio.file.Path; +import org.classpath.icedtea.java.nio.file.StandardWatchEventKind; +import org.classpath.icedtea.java.nio.file.WatchEvent; +import org.classpath.icedtea.java.nio.file.WatchKey; + +import org.classpath.icedtea.java.nio.file.attribute.Attributes; +import org.classpath.icedtea.java.nio.file.attribute.BasicFileAttributes; /** * Simple WatchService implementation that uses background thread to poll diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/GnomeFileTypeDetector.java Mon Jan 26 23:09:32 2009 +0000 @@ -25,10 +25,11 @@ package sun.nio.fs; -import java.nio.file.FileRef; import java.io.IOException; import java.security.AccessController; import java.security.PrivilegedAction; + +import org.classpath.icedtea.java.nio.file.FileRef; /** * File type detector that uses the GNOME I/O library or the deprecated diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxDosFileAttributeView.java Mon Jan 26 23:09:32 2009 +0000 @@ -30,6 +30,8 @@ import java.io.IOException; import java.io.IOException; import sun.misc.Unsafe; +import org.classpath.icedtea.java.nio.file.attribute.BasicFileAttributes; +import org.classpath.icedtea.java.nio.file.attribute.DosFileAttributes; import org.classpath.icedtea.java.nio.file.attribute.DosFileAttributeView; import static sun.nio.fs.UnixNativeDispatcher.*; @@ -105,7 +107,7 @@ class LinuxDosFileAttributeView } - public Map readAttributes(String first, String[] rest) + public Map readAttributes(String first, String... rest) throws IOException { AttributesBuilder builder = AttributesBuilder.create(first, rest); diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxFileSystem.java Mon Jan 26 23:09:32 2009 +0000 @@ -25,13 +25,19 @@ package sun.nio.fs; -import java.nio.file.*; -import java.nio.file.attribute.*; import java.io.IOException; import java.util.*; import java.security.AccessController; import sun.security.action.GetPropertyAction; import static sun.nio.fs.LinuxNativeDispatcher.*; + +import org.classpath.icedtea.java.nio.file.FileStore; +import org.classpath.icedtea.java.nio.file.LinkOption; +import org.classpath.icedtea.java.nio.file.WatchService; + +import org.classpath.icedtea.java.nio.file.attribute.DosFileAttributeView; +import org.classpath.icedtea.java.nio.file.attribute.FileAttributeView; +import org.classpath.icedtea.java.nio.file.attribute.NamedAttributeView; /** * Linux implementation of FileSystem diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxNamedAttributeView.java Mon Jan 26 23:09:32 2009 +0000 @@ -25,11 +25,15 @@ package sun.nio.fs; -import java.nio.file.*; import java.nio.ByteBuffer; import java.io.IOException; import java.util.*; import sun.misc.Unsafe; + +import org.classpath.icedtea.java.nio.channels.AsynchronousFileChannel; +import org.classpath.icedtea.java.nio.channels.FileChannel; + +import org.classpath.icedtea.java.nio.file.FileSystemException; import static sun.nio.fs.UnixConstants.*; import static sun.nio.fs.LinuxNativeDispatcher.*; diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/LinuxWatchService.java Mon Jan 26 23:09:32 2009 +0000 @@ -25,12 +25,17 @@ package sun.nio.fs; -import java.nio.file.*; import java.security.AccessController; import java.security.PrivilegedAction; import java.util.*; import java.io.IOException; import sun.misc.Unsafe; + +import org.classpath.icedtea.java.nio.file.NotDirectoryException; +import org.classpath.icedtea.java.nio.file.Path; +import org.classpath.icedtea.java.nio.file.StandardWatchEventKind; +import org.classpath.icedtea.java.nio.file.WatchEvent; +import org.classpath.icedtea.java.nio.file.WatchKey; import static sun.nio.fs.UnixNativeDispatcher.*; import static sun.nio.fs.UnixConstants.*; diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixChannelFactory.java Mon Jan 26 23:09:32 2009 +0000 @@ -25,8 +25,6 @@ package sun.nio.fs; -import java.nio.file.*; -import java.nio.channels.*; import java.io.FileDescriptor; import java.util.Set; @@ -35,6 +33,13 @@ import sun.nio.ch.SimpleAsynchronousFile import sun.nio.ch.SimpleAsynchronousFileChannelImpl; import sun.misc.SharedSecrets; import sun.misc.JavaIOFileDescriptorAccess; + +import org.classpath.icedtea.java.nio.channels.AsynchronousFileChannel; +import org.classpath.icedtea.java.nio.channels.FileChannel; + +import org.classpath.icedtea.java.nio.file.LinkOption; +import org.classpath.icedtea.java.nio.file.OpenOption; +import org.classpath.icedtea.java.nio.file.StandardOpenOption; import static sun.nio.fs.UnixNativeDispatcher.*; import static sun.nio.fs.UnixConstants.*; diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixCopyFile.java Mon Jan 26 23:09:32 2009 +0000 @@ -25,12 +25,19 @@ package sun.nio.fs; -import java.nio.file.*; import java.io.IOException; import java.security.AccessController; import java.security.PrivilegedAction; import java.util.concurrent.ExecutionException; import com.sun.nio.file.ExtendedCopyOption; + +import org.classpath.icedtea.java.nio.file.AtomicMoveNotSupportedException; +import org.classpath.icedtea.java.nio.file.CopyOption; +import org.classpath.icedtea.java.nio.file.DirectoryNotEmptyException; +import org.classpath.icedtea.java.nio.file.FileAlreadyExistsException; +import org.classpath.icedtea.java.nio.file.LinkOption; +import org.classpath.icedtea.java.nio.file.LinkPermission; +import org.classpath.icedtea.java.nio.file.StandardCopyOption; import static sun.nio.fs.UnixNativeDispatcher.*; import static sun.nio.fs.UnixConstants.*; diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixDirectoryStream.java Mon Jan 26 23:09:32 2009 +0000 @@ -32,6 +32,7 @@ import java.io.IOException; import java.io.IOException; import static sun.nio.fs.UnixNativeDispatcher.*; +import org.classpath.icedtea.java.nio.file.ClosedDirectoryStreamException; import org.classpath.icedtea.java.nio.file.DirectoryStream; import org.classpath.icedtea.java.nio.file.Path; diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixException.java Mon Jan 26 23:09:32 2009 +0000 @@ -25,8 +25,12 @@ package sun.nio.fs; -import java.nio.file.*; import java.io.IOException; + +import org.classpath.icedtea.java.nio.file.AccessDeniedException; +import org.classpath.icedtea.java.nio.file.FileAlreadyExistsException; +import org.classpath.icedtea.java.nio.file.FileSystemException; +import org.classpath.icedtea.java.nio.file.NoSuchFileException; /** * Internal exception thrown by native methods when error detected. diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributeViews.java Mon Jan 26 23:09:32 2009 +0000 @@ -29,7 +29,16 @@ import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeUnit; import java.io.IOException; +import org.classpath.icedtea.java.nio.file.ProviderMismatchException; + +import org.classpath.icedtea.java.nio.file.attribute.BasicFileAttributes; +import org.classpath.icedtea.java.nio.file.attribute.BasicFileAttributeView; +import org.classpath.icedtea.java.nio.file.attribute.FileOwnerAttributeView; +import org.classpath.icedtea.java.nio.file.attribute.GroupPrincipal; +import org.classpath.icedtea.java.nio.file.attribute.PosixFileAttributes; import org.classpath.icedtea.java.nio.file.attribute.PosixFileAttributeView; +import org.classpath.icedtea.java.nio.file.attribute.PosixFilePermission; +import org.classpath.icedtea.java.nio.file.attribute.UserPrincipal; import static sun.nio.fs.UnixNativeDispatcher.*; @@ -199,7 +208,7 @@ class UnixFileAttributeViews { } - public Map readAttributes(String first, String[] rest) + public Map readAttributes(String first, String... rest) throws IOException { AttributesBuilder builder = AttributesBuilder.create(first, rest); @@ -349,7 +358,7 @@ class UnixFileAttributeViews { } - public Map readAttributes(String first, String[] rest) + public Map readAttributes(String first, String... rest) throws IOException { AttributesBuilder builder = AttributesBuilder.create(first, rest); diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java Tue Jan 20 09:44:16 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileAttributes.java Mon Jan 26 23:09:32 2009 +0000 @@ -31,6 +31,9 @@ import java.util.HashSet; import org.classpath.icedtea.java.nio.file.attribute.BasicFileAttributes; import org.classpath.icedtea.java.nio.file.attribute.PosixFileAttributes; +import org.classpath.icedtea.java.nio.file.attribute.PosixFilePermission; +import org.classpath.icedtea.java.nio.file.attribute.GroupPrincipal; +import org.classpath.icedtea.java.nio.file.attribute.UserPrincipal; /** * Unix implementation of PosixFileAttributes. diff -r 721c79ccc804 -r 050b48f42fb3 overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileModeAttribute.java From ahughes at redhat.com Tue Feb 3 04:13:59 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:13:59 +0000 Subject: changeset in /hg/icedtea6: Merge. Message-ID: changeset 514ec9ce7cae in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=514ec9ce7cae description: Merge. diffstat: 76 files changed, 1371 insertions(+), 896 deletions(-) .hgtags | 2 ChangeLog | 275 ++++++++++ HACKING | 1 INSTALL | 4 Makefile.am | 211 ------- NEWS | 8 README | 14 acinclude.m4 | 76 -- configure.ac | 35 - patches/icedtea-awt-window-size.patch | 4 patches/icedtea-cc-interp-jvmti.patch | 12 patches/icedtea-visualvm.patch | 26 plugin/icedtea/sun/applet/AppletSecurityContextManager.java | 38 + plugin/icedtea/sun/applet/PluginAppletSecurityContext.java | 3 plugin/icedtea/sun/applet/PluginAppletViewer.java | 39 + plugin/icedtea/sun/applet/PluginCallRequestFactory.java | 38 + plugin/icedtea/sun/applet/PluginClassLoader.java | 38 + plugin/icedtea/sun/applet/PluginDebug.java | 38 + plugin/icedtea/sun/applet/PluginException.java | 38 + plugin/icedtea/sun/applet/PluginMain.java | 37 + plugin/icedtea/sun/applet/PluginMessageConsumer.java | 38 + plugin/icedtea/sun/applet/PluginMessageHandlerWorker.java | 38 + plugin/icedtea/sun/applet/PluginStreamHandler.java | 38 + plugin/icedtea/sun/applet/RequestQueue.java | 40 + ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp | 32 + ports/hotspot/src/cpu/zero/vm/frame_zero.hpp | 8 ports/hotspot/src/cpu/zero/vm/stackPrinter_zero.hpp | 27 ports/hotspot/src/cpu/zero/vm/stack_zero.hpp | 2 ports/hotspot/src/cpu/zero/vm/stubRoutines_zero.cpp | 4 ports/hotspot/src/cpu/zero/vm/stubRoutines_zero.hpp | 4 ports/hotspot/src/os_cpu/linux_zero/vm/thread_linux_zero.hpp | 9 ports/hotspot/src/share/vm/includeDB_shark | 2 ports/hotspot/src/share/vm/shark/llvmHeaders.hpp | 4 ports/hotspot/src/share/vm/shark/sharkBlock.cpp | 25 ports/hotspot/src/share/vm/shark/sharkBuilder.cpp | 24 ports/hotspot/src/share/vm/shark/sharkBuilder.hpp | 98 +++ ports/hotspot/src/share/vm/shark/sharkBytecodeTracer.cpp | 2 ports/hotspot/src/share/vm/shark/sharkEntry.cpp | 24 ports/hotspot/src/share/vm/shark/sharkEntry.hpp | 20 ports/hotspot/src/share/vm/shark/sharkFunction.cpp | 24 ports/hotspot/src/share/vm/shark/sharkFunction.hpp | 2 ports/hotspot/src/share/vm/shark/shark_globals.hpp | 3 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioClip.java | 56 -- pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioMuteControl.java | 73 -- pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioPlaybackLine.java | 45 + pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioPort.java | 59 -- pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java | 52 - pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourcePort.java | 4 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetPort.java | 6 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioVolumeControl.java | 24 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/Stream.java | 17 pulseaudio/src/native/org_classpath_icedtea_pulseaudio_EventLoop.c | 66 -- pulseaudio/src/native/org_classpath_icedtea_pulseaudio_PulseAudioSourcePort.c | 10 pulseaudio/src/native/org_classpath_icedtea_pulseaudio_PulseAudioTargetPort.c | 14 pulseaudio/src/native/org_classpath_icedtea_pulseaudio_Stream.c | 64 ++ pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioClipTest.java | 2 pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLineRawTest.java | 10 pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLineTest.java | 20 pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioSourcePortTest.java | 5 pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioTargetPortTest.java | 5 rt/net/sourceforge/jnlp/DefaultLaunchHandler.java | 2 rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java | 2 rt/net/sourceforge/jnlp/security/AccessWarningPane.java | 1 rt/net/sourceforge/jnlp/security/AppletWarningPane.java | 1 rt/net/sourceforge/jnlp/security/CertVerifier.java | 92 +++ rt/net/sourceforge/jnlp/security/CertWarningPane.java | 39 - rt/net/sourceforge/jnlp/security/HttpsCertVerifier.java | 82 ++ rt/net/sourceforge/jnlp/security/MoreInfoPane.java | 1 rt/net/sourceforge/jnlp/security/SecurityDialogUI.java | 1 rt/net/sourceforge/jnlp/security/SecurityWarningDialog.java | 1 rt/net/sourceforge/jnlp/security/SingleCertInfoPane.java | 1 rt/net/sourceforge/jnlp/security/VariableX509TrustManager.java | 3 rt/net/sourceforge/jnlp/security/viewer/CertificatePane.java | 2 rt/net/sourceforge/jnlp/tools/CertVerifier.java | 92 --- rt/net/sourceforge/jnlp/tools/KeyTool.java | 1 visualvm.desktop | 9 diffs (truncated from 3618 to 500 lines): diff -r 050b48f42fb3 -r 514ec9ce7cae .hgtags --- a/.hgtags Mon Jan 26 23:09:32 2009 +0000 +++ b/.hgtags Mon Jan 26 23:12:40 2009 +0000 @@ -10,3 +10,5 @@ 871b70407a139c6bd42c200762ee1d302b31168f 871b70407a139c6bd42c200762ee1d302b31168f icedtea6-1.2 3ef9c9c4e70b8204b73fa9b88243f49f59c2a23f icedtea6-1.3 be368b1e3c7dca9b4dfe8e8f40be794ecfbef22e icedtea6-1.3.1 +6c02b699206db299c6bc96d97d31808bf84f042a icedtea6-1.4pre +2b1c03c1e9fa88e453da2ca774dc8900227a2e16 icedtea6-1.4 diff -r 050b48f42fb3 -r 514ec9ce7cae ChangeLog --- a/ChangeLog Mon Jan 26 23:09:32 2009 +0000 +++ b/ChangeLog Mon Jan 26 23:12:40 2009 +0000 @@ -29,6 +29,281 @@ 2009-01-26 Andrew John Hughes + + * configure.ac: Updated to pre-1.5 version. + +2009-01-26 Gary Benson + + * ports/hotspot/src/os_cpu/linux_zero/vm/thread_linux_zero.hpp + (JavaThread::has_special_condition_for_native_trans): New method. + * ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp: + (CppInterpreter::native_entry): Correctly handle safepoints + during post-call thread state transition. + +2009-01-22 Gary Benson + + * ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp: + (CppInterpreter::native_entry): Correctly handle asynchronous + exceptions during post-call thread state transition. + +2009-01-22 Omair Majid + Ioana Ivan + + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioClip.java + (start): Return silently if already started. + (stop): Return silently if already stopped. + +2009-01-22 Deepak Bhole + + * plugin/icedtea/sun/applet/PluginAppletSecurityContext.java: Use + Hashtable to store classloaders, instead of HashMap (values cannot be + null in HashTable). + * rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java: Catch CFE in + addition to CNFE. + +2009-01-22 Andrew Haley + + * ports/hotspot/src/cpu/zero/vm/stack_zero.hpp (class + ZeroFrame::FrameType): Set ENTRY_FRAME = 0xCAFEBABE. + + * ports/hotspot/src/share/vm/shark/shark_globals.hpp (SHARK_FLAGS): + Add SharkPrintAsmOf. + + * ports/hotspot/src/share/vm/shark/sharkFunction.hpp: Add comment. + + * ports/hotspot/src/share/vm/shark/sharkFunction.cpp + (SharkFunction::initialize): Set builder()->sharkEntry. + Use fnmatch() instead of strcmp(). + Generate debugging dumps. + * ports/hotspot/src/share/vm/shark/sharkEntry.hpp + (SharkEntry::code_start, code_limit): Rewrite. + (SharkEntry::setBounds): New. + + * ports/hotspot/src/share/vm/shark/sharkBuilder.hpp + (SharkBuilder::pointer_constant): New function. + * ports/hotspot/src/share/vm/shark/sharkBytecodeTracer.cpp + (SharkBytecodeTracer::decode_one_word): + use SharkBuilder::pointer_constant. + * ports/hotspot/src/share/vm/shark/sharkBuilder.cpp + (SharkBuilder::sharkEntry): New. + (SharkBuilder::CreateUnimplemented): use SharkBuilder::pointer_constant. + (SharkBuilder::CreateShouldNotReachHere): Likewise. + (MyJITMemoryManager::endFunctionBody): New method. + * ports/hotspot/src/share/vm/shark/sharkBlock.cpp + (SharkBlock::check_zero): use SharkBuilder::pointer_constant. + (SharkBlock::check_bounds): Likewise. + (SharkBlock::add_safepoint): Likewise. + (SharkBlock::do_new): Likewise. + (SharkBlock::do_monitorexit): Don't check for null monitor. + + * ports/hotspot/src/share/vm/shark/llvmHeaders.hpp: Add + llvm/ExecutionEngine/JITMemoryManager.h, + llvm/Support/CommandLine.h. + * ports/hotspot/src/share/vm/includeDB_shark (sharkBuilder.hpp): + add sharkEntry.hpp. + +2009-01-22 Lillian Angel + + * NEWS: Updated for release candidate. + +2009-01-22 Gary Benson + + * ports/hotspot/src/cpu/zero/vm/frame_zero.hpp: Updated copyright year. + * ports/hotspot/src/cpu/zero/vm/cppInterpreter_zero.cpp: Likewise. + * ports/hotspot/src/cpu/zero/vm/stackPrinter_zero.hpp: Likewise. + * ports/hotspot/src/cpu/zero/vm/stubRoutines_zero.cpp: Likewise. + * ports/hotspot/src/cpu/zero/vm/stubRoutines_zero.hpp: Likewise. + * ports/hotspot/src/share/vm/shark/sharkBlock.cpp: Likewise. + +2009-01-22 Gary Benson + + * ports/hotspot/src/cpu/zero/vm/stackPrinter_zero.hpp + (print_zero_threads): New debug function. + +2009-01-22 Gary Benson + + * patches/icedtea-cc-interp-jvmti.patch: Reenable thread signalling. + +2009-01-21 Omair Majid + + * patches/icedtea-awt-window-size.patch: Update patch. + +2009-01-21 Omair Majid + + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioClip.java: + Remove unused variables volume and muted. + (PulseAudioClip): Remove variable volume. + (open): Remove muteControl, volume and muted. + (native_setVolume): Rename to native_set_volume. + (native_update_volume): New function. + (isMuted): Remove. + (setMuted): Remove. + (setVolume): Rename to setCachedVolume. + (getVolume): Rename to getCachedVolume. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioMuteControl.java: + Remove file. Mute relied on chaning the volume only through the api. That + assumption is invalid as the user can change volume through pulseaudio's + controls. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioPlaybackLine.java + (isMuted): Remove. + (setMuted): Remove. + (native_setVolume): Rename to native_set_volume. + (native_update_volume): New function. + (getVolume): Rename to getCachedVolume. + (setVolume): Rename to setCachedVolume. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioPort.java: + Remove muted and muteControl. Rename volume to cachedVolume. + (PulseAudioPort): Remove muteControl. + (isMuted): Remove function. + (setMuted): Remove. + (native_setVolume): Rename to native_set_volume. + (native_updateVolumeInfo): Rename to native_update_volume. + (setVolume): Rename to setCachedVolume. + (getVolume): Rename to getCachedVolume. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java: + Remove muteControl, muted and volume. + (open): Remove muteControl. + (native_setVolume): Rename to native_set_volume. + (native_update_volume): New function. + (isMuted): Remove. + (setMuted): Remove. + (getVolume): Rename to getCachedVolume. + (setVolume): Rename to setCachedVolume. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourcePort.java + (native_setVolume): Rename to native_set_volume. + (native_updateVolumeInfo): Rename to native_update_volume. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetPort.java + (native_setVolume): Rename to native_set_volume. + (native_updateVolumeInfo): Rename to native_update_volume. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioVolumeControl.java + (setValue): Dont check for mute. + (getValue): Query pulseaudio for any change in volume. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/Stream.java: + New variable cachedVolume. + (native_setVolume): Rename to native_set_volume. + (native_update_volume): New function. + (getCachedVolume): New function. + (setCachedVolume): New function. + (update_channels_and_volume): New function. + * pulseaudio/src/native/org_classpath_icedtea_pulseaudio_EventLoop.c + (sink_input_volume_change_complete): Remove. + (sink_input_change_volume): Remove. + (Java_org_classpath_icedtea_pulseaudio_EventLoop_native_1set_1sink_1volume): + Remove. + * pulseaudio/src/native/org_classpath_icedtea_pulseaudio_PulseAudioSourcePort.c + (Java_org_classpath_icedtea_pulseaudio_PulseAudioSourcePort_native_1updateVolumeInfo): + Rename to + Java_org_classpath_icedtea_pulseaudio_PulseAudioSourcePort_native_1update_1volume. + (Java_org_classpath_icedtea_pulseaudio_PulseAudioSourcePort_native_1setVolume): + Rename to + Java_org_classpath_icedtea_pulseaudio_PulseAudioSourcePort_native_1set_1volume. + * pulseaudio/src/native/org_classpath_icedtea_pulseaudio_PulseAudioTargetPort.c + (Java_org_classpath_icedtea_pulseaudio_PulseAudioTargetPort_native_1updateVolumeInfo): + Rename to + Java_org_classpath_icedtea_pulseaudio_PulseAudioTargetPort_native_1update_1volume. + (Java_org_classpath_icedtea_pulseaudio_PulseAudioTargetPort_native_1setVolume): + Rename to + Java_org_classpath_icedtea_pulseaudio_PulseAudioTargetPort_native_1set_1volume. + * pulseaudio/src/native/org_classpath_icedtea_pulseaudio_Stream.c + (Java_org_classpath_icedtea_pulseaudio_Stream_native_1setVolume): Rename + to Java_org_classpath_icedtea_pulseaudio_Stream_native_1set_1volume. + (get_sink_input_volume_callback): New function. + (Java_org_classpath_icedtea_pulseaudio_Stream_native_1update_1volume): New + function. + + * pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioClipTest.java + (testSupportedControls): Update to not check for MuteControl. + * pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLineRawTest.java + (testVolumeAndMute): Rename to testVolume. Remove test for MuteControl. + * pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLineTest.java + (testVolumeAndMute): Likewise. + (testSupportedControls): Update to not check for MuteControl. + * pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioSourcePortTest.java + (testControls): Update to not check for MuteControl. + * pulseaudio/unittests/org/classpath/icedtea/pulseaudio/PulseAudioTargetPortTest.java + (testControls): Likewise. + +2009-01-21 Lillian Angel + + * plugin/icedtea/sun/applet/AppletSecurityContextManager.java: Added + copyright header. + * plugin/icedtea/sun/applet/PluginAppletViewer.java: Likewise. + * plugin/icedtea/sun/applet/PluginCallRequestFactory.java: Likewise. + * plugin/icedtea/sun/applet/PluginClassLoader.java: Likewise. + * plugin/icedtea/sun/applet/PluginDebug.java: Likewise. + * plugin/icedtea/sun/applet/PluginException.java: Likewise. + * plugin/icedtea/sun/applet/PluginMain.java: Likewise. + * plugin/icedtea/sun/applet/PluginMessageConsumer.java: Likewise. + * plugin/icedtea/sun/applet/PluginMessageHandlerWorker.java: Likewise. + * plugin/icedtea/sun/applet/PluginStreamHandler.java: Likewise. + * plugin/icedtea/sun/applet/RequestQueue.java: Likewise. + +2009-01-21 Lillian Angel + + * rt/net/sourceforge/jnlp/security/CertVerifier.java: Fixed file name + in GPL header. + * rt/net/sourceforge/jnlp/security/HttpsCertVerifier.java: Likewise. + +2009-01-20 Lillian Angel + + * rt/net/sourceforge/jnlp/DefaultLaunchHandler.java: Removed debug + lines. + * rt/net/sourceforge/jnlp/runtime/JNLPClassLoader.java: Likewise. + * rt/net/sourceforge/jnlp/security/AccessWarningPane.java: Updated + imports. + * rt/net/sourceforge/jnlp/security/AppletWarningPane.java: Updated + imports. + * rt/net/sourceforge/jnlp/security/CertWarningPane.java: Updated + imports, added certVerifier global variable. + (CertWarningPane): Initialized certVerifier. + (installComponents): Added checks to determine if certificate is for + an https site, and set the name/publisher/from variables + appropriately. Also, customized warning pane label for https site. + * rt/net/sourceforge/jnlp/security/HttpsCertVerifier.java: + (getDetails): Implemented. + (addToDetails): Likewise. + (R): Likewise. + (getPublisher): Likewise. + (getRoot): Likewise. + (getRootInCacerts): Likewise. + (hasSigningIssues): Likewise. + (noSigningIssues): Likewise. + * rt/net/sourceforge/jnlp/security/MoreInfoPane.java: Fixed imports. + * rt/net/sourceforge/jnlp/security/SecurityDialogUI.java: Fixed + imports. + * rt/net/sourceforge/jnlp/security/SecurityWarningDialog.java: Fixed + imports. + * rt/net/sourceforge/jnlp/security/SingleCertInfoPane.java: Fixed + imports. + * rt/net/sourceforge/jnlp/security/viewer/CertificatePane.java: Fixed + imports. + * rt/net/sourceforge/jnlp/tools/KeyTool.java: Removed debug lines. + * rt/net/sourceforge/jnlp/security/CertVerifier.java: Moved file + below, here. + * rt/net/sourceforge/jnlp/tools/CertVerifier.java: Removed. + * rt/net/sourceforge/jnlp/security/VariableX509TrustManager.java: + Removed debug lines. + +2009-01-20 Lillian Angel + + * HACKING: Removed visualvm patch. + * INSTALL: Updated to remove visualvm notes. + * Makefile.am: Removed building of netbeans and visualvm. + * README: Updated to remove visualvm notes. + * acinclude.m4: Removed options for netbeans and visualvm. + * configure.ac: Likewise. + * patches/icedtea-visualvm.patch: Removed. + * visualvm.desktop: Removed. + +2009-01-20 Matthias Klose + Gary Benson + + * ports/hotspot/src/cpu/zero/vm/stubRoutines_zero.[ch]pp (i486): Rename + to x86. + * ports/hotspot/src/cpu/zero/vm/frame_zero.hpp (fp): Remove PRODUCT + conditional, make the not-PRODUCT bit the default. 2009-01-19 Andrew John Hughes diff -r 050b48f42fb3 -r 514ec9ce7cae HACKING --- a/HACKING Mon Jan 26 23:09:32 2009 +0000 +++ b/HACKING Mon Jan 26 23:12:40 2009 +0000 @@ -54,7 +54,6 @@ The following patches are currently appl * icedtea-tools.patch: Remove DebugHelperHelper and add sources in make/java/awt/Makefile to fix build of jvmti. * icedtea-use-system-tzdata.patch: Use timezone data from the system (PR70/S6593486). * icedtea-version.patch: Replace name and bug URL with IcedTea versions. -* icedtea-visualvm.patch: Patches sources to build with platform8 and profiler3 instead of platform7 and profiler2. * icedtea-webservices.patch: Add applet support. * icedtea-zero-build.patch: Add support for the zero assembler build. * icedtea-shark-build.patch: Add support for building the Shark JIT. diff -r 050b48f42fb3 -r 514ec9ce7cae INSTALL --- a/INSTALL Mon Jan 26 23:09:32 2009 +0000 +++ b/INSTALL Mon Jan 26 23:12:40 2009 +0000 @@ -30,10 +30,6 @@ libjpeg-devel = 6b libjpeg-devel = 6b zlib-devel rhino (can be disabled using --without-rhino) - -For building VisualVM, you will need: -netbeans (harness, platform8, apisupport1, java2, ide9) -jakarta-commons-logging For building the PulseAudio based mixer, you will need pulseaudio-libs-devel >= 0.9.11 diff -r 050b48f42fb3 -r 514ec9ce7cae Makefile.am --- a/Makefile.am Mon Jan 26 23:09:32 2009 +0000 +++ b/Makefile.am Mon Jan 26 23:12:40 2009 +0000 @@ -4,10 +4,6 @@ OPENJDK_VERSION = b14 CACAO_VERSION = 0.99.3 CACAO_MD5SUM = 80de3ad344c1a20c086ec5f1390bd1b8 - -NETBEANS_BASIC_CLUSTER = a7ea855f475fa3a982f094a45c155ab4 -NETBEANS_PROFILER_MD5SUM = ff8e8abc42df6c6749e6b02bcf7bb0a5 -VISUALVM_MD5SUM = 4b55bc623418818793392bb233da2927 if ENABLE_GCJWEBPLUGIN GCJWEBPLUGIN_CLEAN = clean-gcjwebplugin @@ -39,12 +35,6 @@ PULSE_JAVA_NATIVE_SRCDIR = PULSE_JAVA_NATIVE_SRCDIR = PULSE_JAVA_JAVA_SRCDIR = PULSE_JAVA_CLASS_DIR = -endif - -if WITH_VISUALVM -VISUALVM_PATCH = patches/icedtea-visualvm.patch -else -VISUALVM_PATCH = endif if WITH_ALT_HSBUILD @@ -78,8 +68,6 @@ endif endif endif rm -rf cacao - rm -rf visualvm - rm -rf netbeans rm -f jni-common.o install: @@ -93,13 +81,13 @@ install: clean-tools-jar clean-shared-objects \ clean-copy clean-hotspot-tools clean-rt $(GCJWEBPLUGIN_CLEAN) \ $(ICEDTEAPLUGIN_CLEAN) hotspot hotspot-helper clean-extra \ - clean-jtreg clean-jtreg-reports clean-visualvm clean-nbplatform + clean-jtreg clean-jtreg-reports EXTRA_DIST = rt generated \ patches/* \ gcjwebplugin.cc tools-copy contrib ports \ extra overlays \ - javaws.png javaws.desktop visualvm.desktop \ + javaws.png javaws.desktop \ jconsole.desktop policytool.desktop \ test/jtreg \ IcedTeaPlugin.cc \ @@ -316,30 +304,6 @@ else CACAO_SRC_ZIP = cacao-$(CACAO_VERSION).tar.gz endif -NETBEANS_BASIC_CLUSTER_URL = http://nbi.netbeans.org/files/documents/210/2056/ - -if USE_ALT_NETBEANS_BASIC_CLUSTER_SRC_ZIP - NETBEANS_BASIC_CLUSTER_SRC_ZIP = $(ALT_NETBEANS_BASIC_CLUSTER_SRC_ZIP) -else - NETBEANS_BASIC_CLUSTER_SRC_ZIP = netbeans-6.1-200805300101-basic_cluster-src.zip -endif - -NETBEANS_PROFILER_URL = http://icedtea.classpath.org/visualvm/ - -if USE_ALT_NETBEANS_PROFILER_SRC_ZIP - NETBEANS_PROFILER_SRC_ZIP = $(ALT_NETBEANS_PROFILER_SRC_ZIP) -else - NETBEANS_PROFILER_SRC_ZIP = netbeans-profiler-visualvm_preview2.tar.gz -endif - -VISUALVM_URL = http://icedtea.classpath.org/visualvm/ - -if USE_ALT_VISUALVM_SRC_ZIP - VISUALVM_SRC_ZIP = $(ALT_VISUALVM_SRC_ZIP) -else - VISUALVM_SRC_ZIP = visualvm-20081031-src.tar.gz -endif - stamps/hgforest.stamp: if OPENJDK_SRC_DIR_FOUND else @@ -417,46 +381,6 @@ endif endif endif endif -if WITH_VISUALVM -if USE_ALT_NETBEANS_BASIC_CLUSTER_SRC_ZIP -else - if ! echo "$(NETBEANS_BASIC_CLUSTER_MD5SUM) $(NETBEANS_BASIC_CLUSTER_SRC_ZIP)" \ - | $(MD5SUM) --check ; \ - then \ - if [ $(NETBEANS_BASIC_CLUSTER_SRC_ZIP) ] ; \ - then \ - mv $(NETBEANS_BASIC_CLUSTER_SRC_ZIP) $(NETBEANS_BASIC_CLUSTER_SRC_ZIP).old ; \ - fi ; \ - $(WGET) $(NETBEANS_BASIC_CLUSTER_URL)$(NETBEANS_BASIC_CLUSTER_SRC_ZIP) \ - -O $(NETBEANS_BASIC_CLUSTER_SRC_ZIP) ; \ - fi -endif -if USE_ALT_NETBEANS_PROFILER_SRC_ZIP -else - if ! echo "$(NETBEANS_PROFILER_MD5SUM) $(NETBEANS_PROFILER_SRC_ZIP)" \ - | $(MD5SUM) --check ; \ - then \ - if [ $(NETBEANS_PROFILER_SRC_ZIP) ] ; \ - then \ - mv $(NETBEANS_PROFILER_SRC_ZIP) $(NETBEANS_PROFILER_SRC_ZIP).old ; \ - fi ; \ - $(WGET) $(NETBEANS_PROFILER_URL)$(NETBEANS_PROFILER_SRC_ZIP) \ - -O $(NETBEANS_PROFILER_SRC_ZIP) ; \ - fi -endif -if USE_ALT_VISUALVM_SRC_ZIP -else - if ! echo "$(VISUALVM_MD5SUM) $(VISUALVM_SRC_ZIP)" \ - | $(MD5SUM) --check ; \ - then \ - if [ $(VISUALVM_SRC_ZIP) ] ; \ - then \ - mv $(VISUALVM_SRC_ZIP) $(VISUALVM_SRC_ZIP).old ; \ - fi ; \ - $(WGET) $(VISUALVM_URL)$(VISUALVM_SRC_ZIP) -O $(VISUALVM_SRC_ZIP) ; \ - fi -endif -endif mkdir -p stamps touch stamps/download.stamp @@ -468,11 +392,6 @@ clean-download: rm -f $(OPENJDK_SRC_ZIP) if WITH_CACAO rm -f $(CACAO_SRC_ZIP) -endif -if WITH_VISUALVM - rm -f $(VISUALVM_SRC_ZIP) - rm -f $(NETBEANS_PROFILER_SRC_ZIP) - rm -rf $(NETBEANS_BASIC_CLUSTER_SRC_ZIP) endif # Link ports sources into tree @@ -629,7 +548,6 @@ ICEDTEA_PATCHES += \ patches/icedtea-arch.patch \ patches/icedtea-lc_ctype.patch \ patches/icedtea-messageutils.patch \ - $(VISUALVM_PATCH) \ patches/icedtea-javac-debuginfo.patch \ patches/icedtea-xjc.patch \ patches/icedtea-renderer-crossing.patch \ @@ -735,27 +653,6 @@ if !USE_SYSTEM_CACAO ln -s $$dir cacao/cacao ; \ fi endif -endif -if WITH_VISUALVM - if ! test -d visualvm ; \ - then \ - $(TAR) xf $(VISUALVM_SRC_ZIP) ; \ - fi - if ! test -d netbeans ; \ - then \ - mkdir netbeans ; \ - $(TAR) xf $(NETBEANS_PROFILER_SRC_ZIP) -C netbeans ; \ - $(UNZIP) -q $(NETBEANS_BASIC_CLUSTER_SRC_ZIP) nbbuild/* -d netbeans/ ; \ - mv netbeans/profiler/ netbeans/profiler.cvs/ ; \ - $(UNZIP) -q $(NETBEANS_BASIC_CLUSTER_SRC_ZIP) \ - api.java/* api.progress/* apisupport.harness/* editor.mimelookup/* \ - o.jdesktop.layout/* openide.actions/* openide.awt/* \ - openide.dialogs/* openide.execution/* openide.explorer/* \ - openide.filesystems/* openide.io/* openide.loaders/* \ - openide.modules/* openide.nodes/* openide.text/* openide.util/* \ - openide.windows/* options.api/* projectapi/* queries/* java.platform/* \ - -d netbeans/ ; \ - fi endif if [ ! -e $(abs_top_builddir)/generated ]; then \ cp -a $(abs_top_srcdir)/generated $(abs_top_builddir); \ @@ -1126,7 +1023,7 @@ stamps/icedtea.stamp: stamps/bootstrap-d stamps/hotspot-tools.stamp stamps/plugs.stamp \ stamps/ports.stamp stamps/patch.stamp stamps/overlay.stamp \ From ahughes at redhat.com Tue Feb 3 04:14:00 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:14:00 +0000 Subject: changeset in /hg/icedtea6: Add a few additional fixes discovered... Message-ID: changeset 8e91de51da9e in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=8e91de51da9e description: Add a few additional fixes discovered when doing a full build. 2009-01-27 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: (positionSBC(long)): Renamed from position(long). (truncateSBC(long)): Likewise. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java: Same as for FileChannel, prevents conflict with versions in java.nio.channel.FileChannel. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java, * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java: Add missing imports. * patches/icedtea-nio2.patch: (FileChannelImpl.positionSBC(long)): Added, simply calls position(long). (FileChannelImpl.truncateSBC(long)): Likewise. diffstat: 6 files changed, 51 insertions(+), 8 deletions(-) ChangeLog | 14 +++++ overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java | 4 - overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java | 4 - overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java | 10 +++- overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java | 3 - patches/icedtea-nio2.patch | 24 +++++++++- diffs (140 lines): diff -r 514ec9ce7cae -r 8e91de51da9e ChangeLog --- a/ChangeLog Mon Jan 26 23:12:40 2009 +0000 +++ b/ChangeLog Tue Jan 27 11:54:08 2009 +0000 @@ -1,3 +1,17 @@ 2009-01-26 Andrew John Hughes + + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: + (positionSBC(long)): Renamed from position(long). + (truncateSBC(long)): Likewise. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java: + Same as for FileChannel, prevents conflict with versions in java.nio.channel.FileChannel. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java, + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java: + Add missing imports. + * patches/icedtea-nio2.patch: + (FileChannelImpl.positionSBC(long)): Added, simply calls position(long). + (FileChannelImpl.truncateSBC(long)): Likewise. + 2009-01-26 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/ch/AsynchronousFileLockImpl.java, diff -r 514ec9ce7cae -r 8e91de51da9e overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java Mon Jan 26 23:12:40 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java Tue Jan 27 11:54:08 2009 +0000 @@ -369,7 +369,7 @@ public abstract class FileChannel * @throws IOException * If some other I/O error occurs */ - public abstract FileChannel position(long newPosition) throws IOException; + public abstract FileChannel positionSBC(long newPosition) throws IOException; /** * Truncates this channel's file to the given size. @@ -398,7 +398,7 @@ public abstract class FileChannel * @throws IOException * If some other I/O error occurs */ - public abstract FileChannel truncate(long size) throws IOException; + public abstract FileChannel truncateSBC(long size) throws IOException; } diff -r 514ec9ce7cae -r 8e91de51da9e overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java Mon Jan 26 23:12:40 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/SeekableByteChannel.java Tue Jan 27 11:54:08 2009 +0000 @@ -124,7 +124,7 @@ public interface SeekableByteChannel * @throws IOException * If some other I/O error occurs */ - SeekableByteChannel position(long newPosition) throws IOException; + SeekableByteChannel positionSBC(long newPosition) throws IOException; /** * Returns the current size of entity to which this channel is connected. @@ -166,5 +166,5 @@ public interface SeekableByteChannel * @throws IOException * If some other I/O error occurs */ - SeekableByteChannel truncate(long size) throws IOException; + SeekableByteChannel truncateSBC(long size) throws IOException; } diff -r 514ec9ce7cae -r 8e91de51da9e overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java Mon Jan 26 23:12:40 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisAsynchronousChannelProvider.java Tue Jan 27 11:54:08 2009 +0000 @@ -25,10 +25,16 @@ package sun.nio.ch; -import java.nio.channels.*; import java.util.concurrent.ExecutorService; -import java.net.ProtocolFamily; import java.io.IOException; + +import org.classpath.icedtea.java.net.ProtocolFamily; + +import org.classpath.icedtea.java.nio.channels.AsynchronousChannelGroup; +import org.classpath.icedtea.java.nio.channels.AsynchronousDatagramChannel; +import org.classpath.icedtea.java.nio.channels.AsynchronousSocketChannel; +import org.classpath.icedtea.java.nio.channels.AsynchronousServerSocketChannel; +import org.classpath.icedtea.java.nio.channels.IllegalChannelGroupException; import org.classpath.icedtea.java.nio.channels.spi.AsynchronousChannelProvider; diff -r 514ec9ce7cae -r 8e91de51da9e overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java --- a/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java Mon Jan 26 23:12:40 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/ch/SolarisEventPort.java Tue Jan 27 11:54:08 2009 +0000 @@ -25,10 +25,11 @@ package sun.nio.ch; -import java.nio.channels.spi.AsynchronousChannelProvider; import java.util.concurrent.RejectedExecutionException; import java.io.IOException; import sun.misc.Unsafe; + +import org.classpath.icedtea.java.nio.channels.spi.AsynchronousChannelProvider; /** * AsynchronousChannelGroup implementation based on the Solaris 10 event port diff -r 514ec9ce7cae -r 8e91de51da9e patches/icedtea-nio2.patch --- a/patches/icedtea-nio2.patch Mon Jan 26 23:12:40 2009 +0000 +++ b/patches/icedtea-nio2.patch Tue Jan 27 11:54:08 2009 +0000 @@ -1372,7 +1372,7 @@ diff -Nru openjdk.orig/jdk/src/share/cla } diff -Nru openjdk.orig/jdk/src/share/classes/sun/nio/ch/FileChannelImpl.java openjdk/jdk/src/share/classes/sun/nio/ch/FileChannelImpl.java --- openjdk.orig/jdk/src/share/classes/sun/nio/ch/FileChannelImpl.java 2009-01-20 13:37:15.000000000 +0000 -+++ openjdk/jdk/src/share/classes/sun/nio/ch/FileChannelImpl.java 2009-01-20 13:45:52.000000000 +0000 ++++ openjdk/jdk/src/share/classes/sun/nio/ch/FileChannelImpl.java 2009-01-27 02:33:08.000000000 +0000 @@ -32,8 +32,15 @@ import java.io.IOException; import java.nio.ByteBuffer; @@ -1399,6 +1399,28 @@ diff -Nru openjdk.orig/jdk/src/share/cla public class FileChannelImpl extends FileChannel +@@ -316,6 +324,10 @@ + } + } + ++ public FileChannel positionSBC(long newPosition) throws IOException { ++ return position(newPosition); ++ } ++ + public long size() throws IOException { + ensureOpen(); + synchronized (positionLock) { +@@ -386,6 +398,10 @@ + } + } + ++ public FileChannel truncateSBC(long size) throws IOException { ++ return truncate(size); ++ } ++ + public void force(boolean metaData) throws IOException { + ensureOpen(); + int rv = -1; diff -Nru openjdk.orig/jdk/src/share/classes/sun/nio/ch/Net.java openjdk/jdk/src/share/classes/sun/nio/ch/Net.java --- openjdk.orig/jdk/src/share/classes/sun/nio/ch/Net.java 2009-01-15 17:37:33.000000000 +0000 +++ openjdk/jdk/src/share/classes/sun/nio/ch/Net.java 2009-01-19 23:21:37.000000000 +0000 From ahughes at redhat.com Tue Feb 3 04:14:01 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:14:01 +0000 Subject: changeset in /hg/icedtea6: Merge. Message-ID: changeset 12c4111a284c in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=12c4111a284c description: Merge. diffstat: 5 files changed, 78 insertions(+), 7 deletions(-) ChangeLog | 21 ++++++++++++++- HACKING | 1 Makefile.am | 3 +- NEWS | 49 +++++++++++++++++++++++++++++++---- patches/icedtea-java2d-dasher.patch | 11 +++++++ diffs (133 lines): diff -r 3cd694b8289b -r 12c4111a284c ChangeLog --- a/ChangeLog Tue Feb 03 12:02:53 2009 +0000 +++ b/ChangeLog Tue Feb 03 12:08:26 2009 +0000 @@ -1,4 +1,4 @@ 2009-01-27 Andrew John Hughes +2009-01-30 Andrew John Hughes * patches/icedtea-nio2.patch: (mapfile-linux): Add new functions in sun.nio.ch.Net. @@ -6,7 +6,26 @@ 2009-01-27 Andrew John Hughes + + * patches/icedtea-java2d-dasher.patch: New patch. Fix interpretation of + dash array elements in BasicStroke. + * Makefile.am (ICEDTEA_PATCHES): Apply the above. + * HACKING: Document the above. +2009-01-28 Lillian Angel + + * NEWS: Updated date. + +2009-01-28 Andrew Haley + + * NEWS: Updated. + +2009-01-28 Mark Wielaard + + * NEWS: Updated for 1.4. + 2009-01-27 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: diff -r 3cd694b8289b -r 12c4111a284c HACKING --- a/HACKING Tue Feb 03 12:02:53 2009 +0000 +++ b/HACKING Tue Feb 03 12:08:26 2009 +0000 @@ -82,6 +82,7 @@ The following patches are currently appl * icedtea-no-precompiled.patch: Don't use precompiled header files in hotspot. * icedtea-includedb.patch: Add missing include files. * icedtea-awt-window-size.patch: Fix X11 window size calculation (S6721088). +* icedtea-java2d-dasher.patch: Fix interpretation of dash array elements in BasicStroke (S6793344). The following patches are only applied to OpenJDK6 in IcedTea6: diff -r 3cd694b8289b -r 12c4111a284c Makefile.am --- a/Makefile.am Tue Feb 03 12:02:53 2009 +0000 +++ b/Makefile.am Tue Feb 03 12:08:26 2009 +0000 @@ -614,7 +614,8 @@ ICEDTEA_PATCHES += \ ICEDTEA_PATCHES += \ $(DISTRIBUTION_PATCHES) \ patches/icedtea-demo-swingapplet.patch \ - patches/icedtea-awt-window-size.patch + patches/icedtea-awt-window-size.patch \ + patches/icedtea-java2d-dasher.patch stamps/extract.stamp: stamps/download.stamp if OPENJDK_SRC_DIR_FOUND diff -r 3cd694b8289b -r 12c4111a284c NEWS --- a/NEWS Tue Feb 03 12:02:53 2009 +0000 +++ b/NEWS Tue Feb 03 12:08:26 2009 +0000 @@ -1,10 +1,49 @@ New in release 1.4 (NOT_YET_RELEASED) -New in release 1.4 (NOT_YET_RELEASED) +New in release 1.4 (2009-01-29) -- Updated to b14 build. -- Upgraded to new Hotspot 14 from 12. +- Security fixes for: + CVE-2008-5360 - Temporary files have guessable file names. + CVE-2008-5350 - Allows to list files within the user home directory. + CVE-2008-5348 - Denial-Of-Service in kerberos authentication. + CVE-2008-5359 - Buffer overflow in image processing. + CVE-2008-5351 - UTF-8 decoder accepts non-shortest form sequences. + CVE-2008-5356 - Font processing vulnerability. + CVE-2008-5353 - Calendar object deserialization allows privilege escalation. + CVE-2008-5354 - Privilege escalation in command line applications. + CVE-2008-5357 - Truetype Font processing vulnerability. + CVE-2008-5352 - Jar200 Decompression buffer overflow. + CVE-2008-5358 - Buffer Overflow in GIF image processing. +- Updated to OpenJDK b14 build. +- Upgraded to new OpenJDK7 Hotspot 14. The old OpenJDK6 Hotspot 11 can + still be configured --with-hotspot-build=original but future versions + will drop support for the old version and only support HS14. Zero + and Shark have been forward ported to HS14 (from HS12). - XRender pipeline support: Java2D are noticably faster and running over a - remote X connection now feels like it is all local. -- Plugin now supports HTTPS sites. + remote X connection feels like it is all local. Build by default + (disable with --disable-xrender). Runtime enabled by running java + -Dsun.java2d.xrender=True (default is to use the old X renderer for now). +- IcedTeaPlugin now supports HTTPS sites and adds a user prompt for + untrusted https certificates. +- Use the ALSA 'default' device. Makes Java play nicer with PulseAudio. +- VisualVM integration has been removed. +- Gervill soft synthesizer integration updated to latest CVS version. +- Integrated jtreg upgraded to 4_0-src-b02-15_oct_2008. +- make check runs much faster now. jtreg -samevm support has been + integrated into the langtools and jdk subsystems. Please package the + test/jtreg-summary.log file with your distribution package so end users + can compare the test results. +- Shark (--enable-shark) now builds on 64 bit platforms, but is a + pre-alpha technology preview and not recommended for use. +- Better support for bootstrapping with different jar programs + (supporting -J options). +- If --with-pkgversion isn't given the short mercurial rev node version + will be used. Package distributors are encouraged to build packages with + --with-pkgversion to uniquely identify their distribution version number + when java -version is run to help distribution specific bug reporting. +- Various freetype font, pisces renderer and awt X window size fixes + to fix visual anomalies. +- Build fixes for gcc 4.3 and 4.4-pre-release. +- Added support for building against a specific openjdk src dir + or hg revision (--with-openjdk-src-dir or --with-hg-revision). - Many other Plugin, Zero, Shark and PulseAudio bug fixes. - Build clean up. diff -r 3cd694b8289b -r 12c4111a284c patches/icedtea-java2d-dasher.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/icedtea-java2d-dasher.patch Tue Feb 03 12:08:26 2009 +0000 @@ -0,0 +1,11 @@ +--- openjdk/jdk/src/share/classes/sun/java2d/pisces/Dasher.java.orig 2009-01-13 12:14:53.000000000 -0500 ++++ openjdk/jdk/src/share/classes/sun/java2d/pisces/Dasher.java 2009-01-13 12:15:09.000000000 -0500 +@@ -120,7 +120,7 @@ + + // Normalize so 0 <= phase < dash[0] + int idx = 0; +- dashOn = false; ++ dashOn = true; + int d; + while (phase >= (d = dash[idx])) { + phase -= d; From ahughes at redhat.com Tue Feb 3 04:14:00 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:14:00 +0000 Subject: changeset in /hg/icedtea6: Final fix to get NIO2 to build. Message-ID: changeset 945a4627e256 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=945a4627e256 description: Final fix to get NIO2 to build. 2009-01-27 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: Use org.classpath.icedtea.java.nio.channels.FileChannel. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java: Likewise. * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/META-INF/services/java.nio.file.spi.FileSystemProvider, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/README.txt, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarEntryInfo.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributes.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipEntryInfo.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileAttributes.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileBasicAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileBasicAttributes.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFilePath.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileStore.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileStream.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileSystem.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipHeaderConstants.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipPathParser.java, * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipUtils.java: Import NIO2 demo and fix imports. * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java: Use org.classpath.icedtea.java.nio.channels.FileChannel. diffstat: 22 files changed, 3725 insertions(+), 6 deletions(-) ChangeLog | 28 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java | 8 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java | 2 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/META-INF/services/java.nio.file.spi.FileSystemProvider | 1 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/README.txt | 29 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarEntryInfo.java | 44 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributeView.java | 76 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributes.java | 57 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipEntryInfo.java | 76 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileAttributeView.java | 154 + overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileAttributes.java | 93 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileBasicAttributeView.java | 187 + overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileBasicAttributes.java | 125 + overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFilePath.java | 1027 ++++++++++ overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileStore.java | 230 ++ overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileStream.java | 166 + overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileSystem.java | 319 +++ overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileSystemProvider.java | 243 ++ overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipHeaderConstants.java | 75 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipPathParser.java | 308 ++ overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipUtils.java | 481 ++++ overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java | 2 diffs (truncated from 3860 to 500 lines): diff -r d57abf1d1d65 -r 945a4627e256 ChangeLog --- a/ChangeLog Tue Jan 27 11:54:55 2009 +0000 +++ b/ChangeLog Wed Jan 28 00:27:48 2009 +0000 @@ -1,3 +1,31 @@ 2009-01-27 Andrew John Hughes + + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: + Use org.classpath.icedtea.java.nio.channels.FileChannel. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java: + Likewise. + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/META-INF/services/java.nio.file.spi.FileSystemProvider, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/README.txt, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarEntryInfo.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipEntryInfo.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileAttributes.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileBasicAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileBasicAttributes.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFilePath.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileStore.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileStream.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileSystem.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipHeaderConstants.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipPathParser.java, + * overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipUtils.java: + Import NIO2 demo and fix imports. + * overlays/nio2/openjdk/jdk/src/solaris/classes/sun/nio/fs/UnixFileSystemProvider.java: + Use org.classpath.icedtea.java.nio.channels.FileChannel. + 2009-01-27 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java Tue Jan 27 11:54:55 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java Wed Jan 28 00:27:48 2009 +0000 @@ -288,9 +288,9 @@ public abstract class FileChannel * * @since 1.7 */ - public static java.nio.channels.FileChannel open(Path file, - Set options, - FileAttribute... attrs) + public static FileChannel open(Path file, + Set options, + FileAttribute... attrs) throws IOException { FileSystemProvider provider = file.getFileSystem().provider(); @@ -335,7 +335,7 @@ public abstract class FileChannel * * @since 1.7 */ - public static java.nio.channels.FileChannel open(Path file, OpenOption... options) + public static FileChannel open(Path file, OpenOption... options) throws IOException { Set set = new HashSet(options.length); diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java Tue Jan 27 11:54:55 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/spi/FileSystemProvider.java Wed Jan 28 00:27:48 2009 +0000 @@ -26,7 +26,6 @@ package org.classpath.icedtea.java.nio.file.spi; -import java.nio.channels.*; import java.net.URI; import java.util.*; import java.util.concurrent.ExecutorService; @@ -35,6 +34,7 @@ import java.io.IOException; import java.io.IOException; import org.classpath.icedtea.java.nio.channels.AsynchronousFileChannel; +import org.classpath.icedtea.java.nio.channels.FileChannel; import org.classpath.icedtea.java.nio.file.FileRef; import org.classpath.icedtea.java.nio.file.FileSystem; import org.classpath.icedtea.java.nio.file.FileSystems; diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/META-INF/services/java.nio.file.spi.FileSystemProvider --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/META-INF/services/java.nio.file.spi.FileSystemProvider Wed Jan 28 00:27:48 2009 +0000 @@ -0,0 +1,1 @@ +com.sun.nio.zipfs.ZipFileSystemProvider \ No newline at end of file diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/README.txt --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/README.txt Wed Jan 28 00:27:48 2009 +0000 @@ -0,0 +1,29 @@ +ZipFileSystem is a file system provider that treats the contents of a zip or +JAR file as a read-only file system. + +To deploy the provider you must copy ZipFileSystem.jar into your extensions +directory or else add /demo/nio/ZipFileSystem/ZipFileSystem.jar +to your class path. + +The factory methods defined by the java.nio.file.FileSystems class can be +used to create a FileSystem, eg: + + // use file type detection + Map env = Collections.emptyMap(); + Path jarfile = Path.get("foo.jar"); + FileSystem fs = FileSystems.newFileSystem(jarfile, env); + +-or + + // locate file system by URI + Map env = Collections.emptyMap(); + URI uri = URI.create("zip:///mydir/foo.jar"); + FileSystem fs = FileSystems.newFileSystem(uri, env); + +Once a FileSystem is created then classes in the java.nio.file package +can be used to access files in the zip/JAR file, eg: + + Path mf = fs.getPath("/META-INF/MANIFEST.MF"); + InputStream in = mf.newInputStream(); + + diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarEntryInfo.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarEntryInfo.java Wed Jan 28 00:27:48 2009 +0000 @@ -0,0 +1,44 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * - Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * - Neither the name of Sun Microsystems nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS + * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +package com.sun.nio.zipfs; + +import java.util.Map; +import java.util.Set; + +public class JarEntryInfo extends ZipEntryInfo { + JarEntryInfo(ZipEntryInfo entry){ + super(entry); + } + + Set> entryAttributs; + Set> manifestMainAttrs; +} diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributeView.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributeView.java Wed Jan 28 00:27:48 2009 +0000 @@ -0,0 +1,76 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * - Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * - Neither the name of Sun Microsystems nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS + * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +package com.sun.nio.zipfs; + +import java.io.IOException; +import java.util.*; + +import org.classpath.icedtea.java.nio.file.FileRef; + +public class JarFileAttributeView extends ZipFileAttributeView { + + /** Creates a new instance of ZipFileAttributeView */ + public JarFileAttributeView(FileRef file) { + super(file); + } + + + public String name() { + return "jar"; + } + + public Object getAttribute(String attribute) throws IOException { + JarFileAttributes jfa = readAttributes(); + if (attribute.equals("manifestAttributes")) { + return jfa.getManifestAttributes(); + } + if (attribute.equals("entryAttributes")) { + return jfa.getEntryAttributes(); + } + return super.readAttributes(attribute); + } + + + public JarFileAttributes readAttributes() + throws IOException { + return new JarFileAttributes(super.getBinding()); + } + + + public Map readAttributes(String first, String... rest) throws IOException { + Map result = new HashMap(); + result.putAll(super.readAttributes(first, rest)); + + // FIXME - add manifest and entry attributes if requested + + return Collections.unmodifiableMap(result); + } +} diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributes.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/JarFileAttributes.java Wed Jan 28 00:27:48 2009 +0000 @@ -0,0 +1,57 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * - Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * - Neither the name of Sun Microsystems nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS + * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +package com.sun.nio.zipfs; + +import java.util.concurrent.*; +import java.io.*; +import java.util.Map; +import java.util.Set; + +import org.classpath.icedtea.java.nio.file.FileRef; + +public class JarFileAttributes extends ZipFileAttributes { + + /** Creates a new instance of ZipFileAttributes */ + public JarFileAttributes(FileRef file) + throws IOException { + super(file); + + } + + public Set> getManifestAttributes() { + return ((JarEntryInfo) ze).manifestMainAttrs; + } + + public Set> getEntryAttributes() { + return ((JarEntryInfo) ze).entryAttributs; + } +} diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipEntryInfo.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipEntryInfo.java Wed Jan 28 00:27:48 2009 +0000 @@ -0,0 +1,76 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * - Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * - Neither the name of Sun Microsystems nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS + * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +package com.sun.nio.zipfs; + +public class ZipEntryInfo { + + byte[] filename; + int compSize; + int size; + byte[] comment; + long crc; + byte[] extraField; + int method; + int extAttrs; + long createTime = -1; + boolean isDirectory; + boolean isOtherFile; + boolean isRegularFile; + boolean isArchiveFile; + long lastAccessTime = -1; + long lastModifiedTime; + long streamOffset; + int versionMadeBy; + ZipEntryInfo(ZipEntryInfo entry){ + this.filename = entry.filename; + this.compSize = entry.compSize; + this.size = entry.size; + this.comment = entry.comment; + this.crc = entry.crc; + this.extraField = entry.extraField; + this.method = entry.method; + this.extAttrs = entry.extAttrs; + this.createTime = entry.createTime; + this.isDirectory = entry.isDirectory; + this.isOtherFile = entry.isOtherFile; + this.isRegularFile = entry.isRegularFile; + this.isArchiveFile = entry.isArchiveFile; + this.lastAccessTime = entry.lastAccessTime; + this.lastModifiedTime = entry.lastModifiedTime; + this.streamOffset = entry.streamOffset; + this.versionMadeBy = entry.versionMadeBy; + + } + ZipEntryInfo(){ + super(); + } +} diff -r d57abf1d1d65 -r 945a4627e256 overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileAttributeView.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/demo/nio/ZipFileSystem/com/sun/nio/zipfs/ZipFileAttributeView.java Wed Jan 28 00:27:48 2009 +0000 @@ -0,0 +1,154 @@ +/* + * Copyright 2007-2008 Sun Microsystems, Inc. All Rights Reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * - Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * - Neither the name of Sun Microsystems nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS + * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +package com.sun.nio.zipfs; + +import java.io.IOException; +import java.util.*; + +import org.classpath.icedtea.java.nio.file.FileRef; + +public class ZipFileAttributeView extends ZipFileBasicAttributeView { + + /** Creates a new instance of ZipFileAttributeView */ + public ZipFileAttributeView(FileRef file) { + super(file); + } + + + public String name() { + return "zip"; + } + + public Object getAttribute(String attribute) throws IOException { + ZipFileAttributes zfa = readAttributes(); + if (attribute.equals("comment")) { + return zfa.comment(); + } + if (attribute.equals("compressedSize")) { + return zfa.compressedSize(); + } + if (attribute.equals("crc")) { + return zfa.crc(); + } + if (attribute.equals("extraField")) { + return zfa.extra(); + } + if (attribute.equals("method")) { + return zfa.method(); + } + if (attribute.equals("fileName")) { + return zfa.name(); + } + if (attribute.equals("isArchiveFile")) { + return zfa.isArchiveFile(); + } + if (attribute.equals("versionMadeBy")) { + return zfa.versionMadeBy(); + } + if (attribute.equals("externalAttrs")) { + return zfa.getExternalAttrs(); + } + return super.getAttribute(attribute); + } + + + public Map readAttributes(String first, String... rest) throws IOException { + int rem = rest.length; + String[] attrs = new String[1 + rem]; + attrs[0] = first; + if (rem > 0) + System.arraycopy(rest, 0, attrs, 1, rem); + Map result = new HashMap(); + result.putAll(super.readAttributes(first, rest)); + ZipFileAttributes zfa = readAttributes(); + boolean added = false; + for (String attr : attrs) { + added = addAttribute(result, attr, "comment",zfa.comment()); + if (added) { + continue; + } + added = addAttribute(result, attr, "compressedSize",zfa.compressedSize()); + if (added) { + continue; + } + added = addAttribute(result, attr, "crc",zfa.crc()); + if (added) { + continue; + } + added = addAttribute(result, attr, "extraField",zfa.extra()); + if (added) { + continue; + } From ahughes at redhat.com Tue Feb 3 04:14:01 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:14:01 +0000 Subject: changeset in /hg/icedtea6: Fix JCK issues with NIO2. Message-ID: changeset 3cd694b8289b in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=3cd694b8289b description: Fix JCK issues with NIO2. 2009-01-27 Andrew John Hughes * patches/icedtea-nio2.patch: (mapfile-linux): Add new functions in sun.nio.ch.Net. (Net.java:setIntOption0(FileDescriptor,boolean,int,int,int)): Renamed to... (Net.java:setIntOption1(FileDescriptor,boolean,int,int,int)): to avoid C collision. (Net.c): Add back java_net_SocketOptions.h, bind0 and connect0 and setIntOption0 and rename existing setIntOption0 to setIntOption1. diffstat: 2 files changed, 122 insertions(+), 33 deletions(-) ChangeLog | 9 ++ patches/icedtea-nio2.patch | 146 ++++++++++++++++++++++++++++++++++---------- diffs (310 lines): diff -r 945a4627e256 -r 3cd694b8289b ChangeLog --- a/ChangeLog Wed Jan 28 00:27:48 2009 +0000 +++ b/ChangeLog Tue Feb 03 12:02:53 2009 +0000 @@ -1,3 +1,12 @@ 2009-01-27 Andrew John Hughes + + * patches/icedtea-nio2.patch: + (mapfile-linux): Add new functions in sun.nio.ch.Net. + (Net.java:setIntOption0(FileDescriptor,boolean,int,int,int)): Renamed to... + (Net.java:setIntOption1(FileDescriptor,boolean,int,int,int)): to avoid C collision. + (Net.c): Add back java_net_SocketOptions.h, bind0 and connect0 and setIntOption0 + and rename existing setIntOption0 to setIntOption1. + 2009-01-27 Andrew John Hughes * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/channels/FileChannel.java: diff -r 945a4627e256 -r 3cd694b8289b patches/icedtea-nio2.patch --- a/patches/icedtea-nio2.patch Wed Jan 28 00:27:48 2009 +0000 +++ b/patches/icedtea-nio2.patch Tue Feb 03 12:02:53 2009 +0000 @@ -601,7 +601,7 @@ diff -Nru openjdk.orig/jdk/make/java/nio .PHONY: sources diff -Nru openjdk.orig/jdk/make/java/nio/mapfile-linux openjdk/jdk/make/java/nio/mapfile-linux --- openjdk.orig/jdk/make/java/nio/mapfile-linux 2009-01-07 22:08:47.000000000 +0000 -+++ openjdk/jdk/make/java/nio/mapfile-linux 2009-01-07 22:15:04.000000000 +0000 ++++ openjdk/jdk/make/java/nio/mapfile-linux 2009-01-29 01:13:17.000000000 +0000 @@ -20,6 +20,14 @@ Java_sun_nio_ch_EPollArrayWrapper_interrupt; Java_sun_nio_ch_EPollArrayWrapper_offsetofData; @@ -617,7 +617,32 @@ diff -Nru openjdk.orig/jdk/make/java/nio Java_sun_nio_ch_FileChannelImpl_close0; Java_sun_nio_ch_FileChannelImpl_force0; Java_sun_nio_ch_FileChannelImpl_initIDs; -@@ -75,6 +83,74 @@ +@@ -63,11 +71,24 @@ + Java_sun_nio_ch_Net_socket0; + Java_sun_nio_ch_Net_bind; + Java_sun_nio_ch_Net_connect; ++ Java_sun_nio_ch_Net_bind0; ++ Java_sun_nio_ch_Net_connect0; ++ Java_sun_nio_ch_Net_listen; + Java_sun_nio_ch_Net_localPort; + Java_sun_nio_ch_Net_localInetAddress; + Java_sun_nio_ch_Net_getIntOption0; + Java_sun_nio_ch_Net_setIntOption0; + Java_sun_nio_ch_Net_initIDs; ++ Java_sun_nio_ch_Net_isIPv6Available0; ++ Java_sun_nio_ch_Net_joinOrDrop4; ++ Java_sun_nio_ch_Net_blockOrUnblock4; ++ Java_sun_nio_ch_Net_joinOrDrop6; ++ Java_sun_nio_ch_Net_blockOrUnblock6; ++ Java_sun_nio_ch_Net_setInterface4; ++ Java_sun_nio_ch_Net_getInterface4; ++ Java_sun_nio_ch_Net_setInterface6; ++ Java_sun_nio_ch_Net_getInterface6; ++ Java_sun_nio_ch_Net_shutdown; + Java_sun_nio_ch_PollArrayWrapper_interrupt; + Java_sun_nio_ch_PollArrayWrapper_poll0; + Java_sun_nio_ch_ServerSocketChannelImpl_accept0; +@@ -75,6 +96,74 @@ Java_sun_nio_ch_ServerSocketChannelImpl_listen; Java_sun_nio_ch_SocketChannelImpl_checkConnect; Java_sun_nio_ch_SocketChannelImpl_shutdown; @@ -1423,7 +1448,7 @@ diff -Nru openjdk.orig/jdk/src/share/cla int rv = -1; diff -Nru openjdk.orig/jdk/src/share/classes/sun/nio/ch/Net.java openjdk/jdk/src/share/classes/sun/nio/ch/Net.java --- openjdk.orig/jdk/src/share/classes/sun/nio/ch/Net.java 2009-01-15 17:37:33.000000000 +0000 -+++ openjdk/jdk/src/share/classes/sun/nio/ch/Net.java 2009-01-19 23:21:37.000000000 +0000 ++++ openjdk/jdk/src/share/classes/sun/nio/ch/Net.java 2009-02-01 00:35:31.000000000 +0000 @@ -30,6 +30,15 @@ import java.net.*; import java.nio.channels.*; @@ -1537,7 +1562,7 @@ diff -Nru openjdk.orig/jdk/src/share/cla + } + + boolean mayNeedConversion = (family == UNSPEC); -+ setIntOption0(fd, mayNeedConversion, key.level(), key.name(), arg); ++ setIntOption1(fd, mayNeedConversion, key.level(), key.name(), arg); + } + + static Object getSocketOption(FileDescriptor fd, ProtocolFamily family, @@ -1569,7 +1594,7 @@ diff -Nru openjdk.orig/jdk/src/share/cla + int level, int opt) + throws IOException; + -+ private static native void setIntOption0(FileDescriptor fd, boolean mayNeedConversion, ++ private static native void setIntOption1(FileDescriptor fd, boolean mayNeedConversion, + int level, int opt, int arg) + throws IOException; + @@ -1920,7 +1945,7 @@ diff -Nru openjdk.orig/jdk/src/solaris/c diff -Nru openjdk.orig/jdk/src/solaris/native/sun/nio/ch/Net.c openjdk/jdk/src/solaris/native/sun/nio/ch/Net.c --- openjdk.orig/jdk/src/solaris/native/sun/nio/ch/Net.c 2009-01-26 20:51:08.000000000 +0000 -+++ openjdk/jdk/src/solaris/native/sun/nio/ch/Net.c 2009-01-26 20:55:17.000000000 +0000 ++++ openjdk/jdk/src/solaris/native/sun/nio/ch/Net.c 2009-02-01 01:24:41.000000000 +0000 @@ -1,5 +1,5 @@ /* - * Copyright 2001-2007 Sun Microsystems, Inc. All Rights Reserved. @@ -1928,11 +1953,8 @@ diff -Nru openjdk.orig/jdk/src/solaris/n * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it -@@ -37,61 +37,171 @@ - #include "net_util.h" - #include "net_util_md.h" - #include "nio_util.h" --#include "java_net_SocketOptions.h" +@@ -40,58 +40,169 @@ + #include "java_net_SocketOptions.h" #include "nio.h" -#ifdef __linux__ @@ -1943,12 +1965,12 @@ diff -Nru openjdk.orig/jdk/src/solaris/n + */ + +#ifdef __solaris__ ++ ++#ifndef IP_BLOCK_SOURCE -#define IPV6_MULTICAST_IF 17 -#ifndef SO_BSDCOMPAT -#define SO_BSDCOMPAT 14 -+#ifndef IP_BLOCK_SOURCE -+ +#define IP_BLOCK_SOURCE 0x15 +#define IP_UNBLOCK_SOURCE 0x16 +#define IP_ADD_SOURCE_MEMBERSHIP 0x17 @@ -2108,19 +2130,19 @@ diff -Nru openjdk.orig/jdk/src/solaris/n JNIEXPORT void JNICALL -Java_sun_nio_ch_Net_bind(JNIEnv *env, jclass clazz, /* ## Needs rest of PSI gunk */ - jobject fdo, jobject ia, int port) -+Java_sun_nio_ch_Net_bind0(JNIEnv *env, jclass clazz, jboolean preferIPv6, -+ jobject fdo, jobject iao, int port) ++Java_sun_nio_ch_Net_bind(JNIEnv *env, jclass clazz, ++ jobject fdo, jobject iao, int port) { SOCKADDR sa; int sa_len = SOCKADDR_LEN; int rv = 0; - if (NET_InetAddressToSockaddr(env, ia, port, (struct sockaddr *)&sa, &sa_len, JNI_TRUE) != 0) { -+ if (NET_InetAddressToSockaddr(env, iao, port, (struct sockaddr *)&sa, &sa_len, preferIPv6) != 0) { ++ if (NET_InetAddressToSockaddr(env, iao, port, (struct sockaddr *)&sa, &sa_len, JNI_TRUE) != 0) { return; } -@@ -101,27 +211,27 @@ +@@ -101,26 +212,53 @@ } } @@ -2135,8 +2157,9 @@ diff -Nru openjdk.orig/jdk/src/solaris/n -Java_sun_nio_ch_Net_connect(JNIEnv *env, jclass clazz, - jobject fdo, jobject iao, jint port, - jint trafficClass) -+Java_sun_nio_ch_Net_connect0(JNIEnv *env, jclass clazz, jboolean preferIPv6, -+ jobject fdo, jobject iao, jint port) ++Java_sun_nio_ch_Net_connect(JNIEnv *env, jclass clazz, ++ jobject fdo, jobject iao, jint port, ++ jint trafficClass) { SOCKADDR sa; int sa_len = SOCKADDR_LEN; @@ -2144,7 +2167,7 @@ diff -Nru openjdk.orig/jdk/src/solaris/n - if (NET_InetAddressToSockaddr(env, iao, port, (struct sockaddr *) &sa, &sa_len, JNI_TRUE) != 0) { + if (NET_InetAddressToSockaddr(env, iao, port, (struct sockaddr *) &sa, -+ &sa_len, preferIPv6) != 0) ++ &sa_len, JNI_TRUE) != 0) + { return IOS_THROWN; } @@ -2153,14 +2176,37 @@ diff -Nru openjdk.orig/jdk/src/solaris/n -#if 0 - if (trafficClass != 0 && ipv6_available()) { /* ## FIX */ - NET_SetTrafficClass((struct sockaddr *)&sa, trafficClass); -- } ++ rv = connect(fdval(env, fdo), (struct sockaddr *)&sa, sa_len); ++ if (rv != 0) { ++ if (errno == EINPROGRESS) { ++ return IOS_UNAVAILABLE; ++ } else if (errno == EINTR) { ++ return IOS_INTERRUPTED; ++ } ++ return handleSocketError(env, errno); ++ } ++ return 1; ++} ++ ++JNIEXPORT jint JNICALL ++Java_sun_nio_ch_Net_connect0(JNIEnv *env, jclass clazz, jboolean preferIPv6, ++ jobject fdo, jobject iao, jint port) ++{ ++ SOCKADDR sa; ++ int sa_len = SOCKADDR_LEN; ++ int rv; ++ ++ if (NET_InetAddressToSockaddr(env, iao, port, (struct sockaddr *) &sa, ++ &sa_len, preferIPv6) != 0) ++ { ++ return IOS_THROWN; + } -#endif -#endif -- + rv = connect(fdval(env, fdo), (struct sockaddr *)&sa, sa_len); if (rv != 0) { - if (errno == EINPROGRESS) { -@@ -138,7 +248,7 @@ +@@ -138,7 +276,7 @@ Java_sun_nio_ch_Net_localPort(JNIEnv *env, jclass clazz, jobject fdo) { SOCKADDR sa; @@ -2169,7 +2215,7 @@ diff -Nru openjdk.orig/jdk/src/solaris/n if (getsockname(fdval(env, fdo), (struct sockaddr *)&sa, &sa_len) < 0) { handleSocketError(env, errno); return -1; -@@ -150,7 +260,7 @@ +@@ -150,7 +288,7 @@ Java_sun_nio_ch_Net_localInetAddress(JNIEnv *env, jclass clazz, jobject fdo) { SOCKADDR sa; @@ -2178,7 +2224,7 @@ diff -Nru openjdk.orig/jdk/src/solaris/n int port; if (getsockname(fdval(env, fdo), (struct sockaddr *)&sa, &sa_len) < 0) { handleSocketError(env, errno); -@@ -159,119 +269,79 @@ +@@ -159,119 +297,115 @@ return NET_SockaddrToInetAddress(env, (struct sockaddr *)&sa, &port); } @@ -2308,12 +2354,46 @@ diff -Nru openjdk.orig/jdk/src/solaris/n } JNIEXPORT void JNICALL --Java_sun_nio_ch_Net_setIntOption0(JNIEnv *env, jclass clazz, -- jobject fdo, jint opt, jint arg) -+Java_sun_nio_ch_Net_setIntOption0(JNIEnv *env, jclass clazz, jobject fdo, -+ jboolean mayNeedConversion, jint level, jint opt, jint arg) + Java_sun_nio_ch_Net_setIntOption0(JNIEnv *env, jclass clazz, + jobject fdo, jint opt, jint arg) { - int klevel, kopt; ++ int klevel, kopt; ++ int result; ++ struct linger linger; ++ void *parg; ++ int arglen; ++ ++ if (NET_MapSocketOption(opt, &klevel, &kopt) < 0) { ++ JNU_ThrowByNameWithLastError(env, ++ JNU_JAVANETPKG "SocketException", ++ "Unsupported socket option"); ++ return; ++ } ++ ++ if (opt == java_net_SocketOptions_SO_LINGER) { ++ parg = (void *)&linger; ++ arglen = sizeof(linger); ++ if (arg >= 0) { ++ linger.l_onoff = 0; ++ linger.l_linger = 0; ++ } ++ } else { ++ parg = (void *)&arg; ++ arglen = sizeof(arg); ++ } ++ ++ if (NET_SetSockOpt(fdval(env, fdo), klevel, kopt, parg, arglen) < 0) { ++ JNU_ThrowByNameWithLastError(env, ++ JNU_JAVANETPKG "SocketException", ++ "sun.nio.ch.Net.setIntOption"); ++ } ++} ++ ++JNIEXPORT void JNICALL ++Java_sun_nio_ch_Net_setIntOption1(JNIEnv *env, jclass clazz, jobject fdo, ++ jboolean mayNeedConversion, jint level, jint opt, jint arg) ++{ int result; struct linger linger; + u_char carg; @@ -2343,7 +2423,7 @@ diff -Nru openjdk.orig/jdk/src/solaris/n parg = (void *)&linger; arglen = sizeof(linger); if (arg >= 0) { -@@ -281,19 +351,199 @@ +@@ -281,19 +415,199 @@ linger.l_onoff = 0; linger.l_linger = 0; } @@ -2475,7 +2555,7 @@ diff -Nru openjdk.orig/jdk/src/solaris/n + } + return 0; +} - ++ +JNIEXPORT void JNICALL +Java_sun_nio_ch_Net_setInterface4(JNIEnv* env, jobject this, jobject fdo, jint interf) +{ @@ -2535,7 +2615,7 @@ diff -Nru openjdk.orig/jdk/src/solaris/n + } + return (jint)index; +} -+ + +JNIEXPORT void JNICALL +Java_sun_nio_ch_Net_shutdown(JNIEnv *env, jclass cl, jobject fdo, jint jhow) +{ From ahughes at redhat.com Tue Feb 3 04:14:00 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 12:14:00 +0000 Subject: changeset in /hg/icedtea6: Merge. Message-ID: changeset d57abf1d1d65 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=d57abf1d1d65 description: Merge. diffstat: 2 files changed, 69 insertions(+), 24 deletions(-) ChangeLog | 5 ports/hotspot/src/os_cpu/linux_zero/vm/orderAccess_linux_zero.inline.hpp | 88 +++++++--- diffs (152 lines): diff -r 8e91de51da9e -r d57abf1d1d65 ChangeLog --- a/ChangeLog Tue Jan 27 11:54:08 2009 +0000 +++ b/ChangeLog Tue Jan 27 11:54:55 2009 +0000 @@ -11,6 +11,11 @@ 2009-01-27 Andrew John Hughes + + * ports/hotspot/src/os_cpu/linux_zero/vm/orderAccess_linux_zero.inline.hpp: + Add memory barriers where needed for PPC. 2009-01-26 Andrew John Hughes diff -r 8e91de51da9e -r d57abf1d1d65 ports/hotspot/src/os_cpu/linux_zero/vm/orderAccess_linux_zero.inline.hpp --- a/ports/hotspot/src/os_cpu/linux_zero/vm/orderAccess_linux_zero.inline.hpp Tue Jan 27 11:54:08 2009 +0000 +++ b/ports/hotspot/src/os_cpu/linux_zero/vm/orderAccess_linux_zero.inline.hpp Tue Jan 27 11:54:55 2009 +0000 @@ -23,6 +23,24 @@ * */ +#ifdef __PPC + +#define READ_MEM_BARRIER __asm __volatile ("isync":::"memory") +#ifdef __NO_LWSYNC__ +#define WRITE_MEM_BARRIER __asm __volatile ("sync":::"memory") +#else +#define WRITE_MEM_BARRIER __asm __volatile ("lwsync":::"memory") +#endif + +#else // PPC + +#define READ_MEM_BARRIER __asm __volatile ("":::"memory") +#define WRITE_MEM_BARRIER __asm __volatile ("":::"memory") + +#endif // PPC + + + inline void OrderAccess::loadload() { acquire(); } inline void OrderAccess::storestore() { release(); } inline void OrderAccess::loadstore() { acquire(); } @@ -30,12 +48,12 @@ inline void OrderAccess::storeload() { inline void OrderAccess::acquire() { - __sync_synchronize(); + READ_MEM_BARRIER; } inline void OrderAccess::release() { - __sync_synchronize(); + WRITE_MEM_BARRIER; } inline void OrderAccess::fence() @@ -43,49 +61,71 @@ inline void OrderAccess::fence() __sync_synchronize(); } -inline jbyte OrderAccess::load_acquire(volatile jbyte* p) { return *p; } -inline jshort OrderAccess::load_acquire(volatile jshort* p) { return *p; } -inline jint OrderAccess::load_acquire(volatile jint* p) { return *p; } +inline jbyte OrderAccess::load_acquire(volatile jbyte* p) { jbyte data = *p; acquire(); return data; } +inline jshort OrderAccess::load_acquire(volatile jshort* p) { jshort data = *p; acquire(); return data; } +inline jint OrderAccess::load_acquire(volatile jint* p) { jint data = *p; acquire(); return data; } inline jlong OrderAccess::load_acquire(volatile jlong* p) { jlong tmp; os::atomic_copy64(p, &tmp); + acquire(); return tmp; } -inline jubyte OrderAccess::load_acquire(volatile jubyte* p) { return *p; } -inline jushort OrderAccess::load_acquire(volatile jushort* p) { return *p; } -inline juint OrderAccess::load_acquire(volatile juint* p) { return *p; } +inline jubyte OrderAccess::load_acquire(volatile jubyte* p) { jubyte data = *p; acquire(); return data; } +inline jushort OrderAccess::load_acquire(volatile jushort* p) { jushort data = *p; acquire(); return data; } +inline juint OrderAccess::load_acquire(volatile juint* p) { juint data = *p; acquire(); return data; } inline julong OrderAccess::load_acquire(volatile julong* p) { julong tmp; os::atomic_copy64(p, &tmp); + acquire(); return tmp; } -inline jfloat OrderAccess::load_acquire(volatile jfloat* p) { return *p; } +inline jfloat OrderAccess::load_acquire(volatile jfloat* p) { jfloat data = *p; acquire(); return data; } inline jdouble OrderAccess::load_acquire(volatile jdouble* p) { jdouble tmp; os::atomic_copy64(p, &tmp); + acquire(); return tmp; } -inline intptr_t OrderAccess::load_ptr_acquire(volatile intptr_t* p) { return *p; } -inline void* OrderAccess::load_ptr_acquire(volatile void* p) { return *(void* volatile *)p; } -inline void* OrderAccess::load_ptr_acquire(const volatile void* p) { return *(void* const volatile *)p; } +inline intptr_t OrderAccess::load_ptr_acquire(volatile intptr_t* p) +{ + intptr_t data = *p; + acquire(); + return data; +} +inline void* OrderAccess::load_ptr_acquire(volatile void* p) +{ + void *data = *(void* volatile *)p; + acquire(); + return data; +} +inline void* OrderAccess::load_ptr_acquire(const volatile void* p) +{ + void *data = *(void* const volatile *)p; + acquire(); + return data; +} -inline void OrderAccess::release_store(volatile jbyte* p, jbyte v) { *p = v; } -inline void OrderAccess::release_store(volatile jshort* p, jshort v) { *p = v; } -inline void OrderAccess::release_store(volatile jint* p, jint v) { *p = v; } -inline void OrderAccess::release_store(volatile jlong* p, jlong v) { os::atomic_copy64(&v, p); } -inline void OrderAccess::release_store(volatile jubyte* p, jubyte v) { *p = v; } -inline void OrderAccess::release_store(volatile jushort* p, jushort v) { *p = v; } -inline void OrderAccess::release_store(volatile juint* p, juint v) { *p = v; } -inline void OrderAccess::release_store(volatile julong* p, julong v) { os::atomic_copy64(&v, p); } -inline void OrderAccess::release_store(volatile jfloat* p, jfloat v) { *p = v; } -inline void OrderAccess::release_store(volatile jdouble* p, jdouble v) { os::atomic_copy64(&v, p); } +inline void OrderAccess::release_store(volatile jbyte* p, jbyte v) { release(); *p = v; } +inline void OrderAccess::release_store(volatile jshort* p, jshort v) { release(); *p = v; } +inline void OrderAccess::release_store(volatile jint* p, jint v) { release(); *p = v; } +inline void OrderAccess::release_store(volatile jlong* p, jlong v) +{ release(); os::atomic_copy64(&v, p); } +inline void OrderAccess::release_store(volatile jubyte* p, jubyte v) { release(); *p = v; } +inline void OrderAccess::release_store(volatile jushort* p, jushort v) { release(); *p = v; } +inline void OrderAccess::release_store(volatile juint* p, juint v) { release(); *p = v; } +inline void OrderAccess::release_store(volatile julong* p, julong v) +{ release(); os::atomic_copy64(&v, p); } +inline void OrderAccess::release_store(volatile jfloat* p, jfloat v) { release(); *p = v; } +inline void OrderAccess::release_store(volatile jdouble* p, jdouble v) +{ release(); os::atomic_copy64(&v, p); } -inline void OrderAccess::release_store_ptr(volatile intptr_t* p, intptr_t v) { *p = v; } -inline void OrderAccess::release_store_ptr(volatile void* p, void* v) { *(void* volatile *)p = v; } +inline void OrderAccess::release_store_ptr(volatile intptr_t* p, intptr_t v) { release(); *p = v; } +inline void OrderAccess::release_store_ptr(volatile void* p, void* v) +{ release(); *(void* volatile *)p = v; } inline void OrderAccess::store_fence(jbyte* p, jbyte v) { *p = v; fence(); } inline void OrderAccess::store_fence(jshort* p, jshort v) { *p = v; fence(); } From gnu_andrew at member.fsf.org Tue Feb 3 07:13:19 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 3 Feb 2009 15:13:19 +0000 Subject: NIO2 support in IcedTea6 Message-ID: <17c6771e0902030713x247ae830t873fa62575e8a697@mail.gmail.com> I've just committed support for NIO2 to IcedTea6. This is enabled by default but may be disabled using --disable-nio2. The majority of support is provided in the overlays subdirectory under a new nio2 tree. In addition, patches/icedtea-nio2.patch adds the necessary support to the Makefiles and some of the native code. To retain compatibility with Java 1.6, the classes are provided under the org.classpath.icedtea package prefix (so the updated java.io.File becomes org.classpath.icedtea.java.io.File and so on). Thus, when compiling NIO2 code against IcedTea6, you will need to add this prefix. When support is ported over to IcedTea7, this extension will be dropped and support added directly to the java.* classes (effectively making it equivalent to the NIO2 tree, but with the ability to use the main OpenJDK7 tarballs and IcedTea extensions). I'll blog about this in more detail shortly with some examples, but feel free to start trying NIO2 and report any issues caused by the backport. More about NIO2 is available here: http://openjdk.java.net/projects/nio/ This work is funded by Red Hat, with the aim of providing early access to NIO2 technologies for users of IcedTea. Happy hacking, -- Andrew :-) IcedTea/OpenJDK Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint: F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From bugzilla-daemon at icedtea.classpath.org Tue Feb 3 07:16:19 2009 From: bugzilla-daemon at icedtea.classpath.org (bugzilla-daemon at icedtea.classpath.org) Date: Tue, 03 Feb 2009 15:16:19 +0000 Subject: [Bug 288] regressions in jdk testsuite with new hotspot Message-ID: http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=288 ------- Comment #1 from gnu_andrew at member.fsf.org 2009-02-03 15:16 ------- I don't recall seeing these failures with IcedTea7. Have you checked against this? It could be the IcedTea7 tests need backporting or some JDI code. -- Configure bugmail: http://icedtea.classpath.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. From ahughes at redhat.com Tue Feb 3 07:42:20 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 15:42:20 +0000 Subject: changeset in /hg/icedtea6: The outputted documentation should be... Message-ID: changeset c38d90386c71 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=c38d90386c71 description: The outputted documentation should be licensed under the GPL but for some reason this only occurs when FCS is not set. This fixes the issue. 2009-02-03 Andrew John Hughes * Makefile.am: Add new patch. * patches/icedtea-doc-headers.patch: Fix licensing of documentation. diffstat: 3 files changed, 56 insertions(+), 1 deletion(-) ChangeLog | 7 +++++ Makefile.am | 3 +- patches/icedtea-doc-headers.patch | 47 +++++++++++++++++++++++++++++++++++++ diffs (78 lines): diff -r 12c4111a284c -r c38d90386c71 ChangeLog --- a/ChangeLog Tue Feb 03 12:08:26 2009 +0000 +++ b/ChangeLog Tue Feb 03 15:41:58 2009 +0000 @@ -1,3 +1,10 @@ 2009-01-30 Andrew John Hughes + + * Makefile.am: + Add new patch. + * patches/icedtea-doc-headers.patch: + Fix licensing of documentation. + 2009-01-30 Andrew John Hughes * patches/icedtea-nio2.patch: diff -r 12c4111a284c -r c38d90386c71 Makefile.am --- a/Makefile.am Tue Feb 03 12:08:26 2009 +0000 +++ b/Makefile.am Tue Feb 03 15:41:58 2009 +0000 @@ -615,7 +615,8 @@ ICEDTEA_PATCHES += \ $(DISTRIBUTION_PATCHES) \ patches/icedtea-demo-swingapplet.patch \ patches/icedtea-awt-window-size.patch \ - patches/icedtea-java2d-dasher.patch + patches/icedtea-java2d-dasher.patch \ + patches/icedtea-doc-headers.patch stamps/extract.stamp: stamps/download.stamp if OPENJDK_SRC_DIR_FOUND diff -r 12c4111a284c -r c38d90386c71 patches/icedtea-doc-headers.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/icedtea-doc-headers.patch Tue Feb 03 15:41:58 2009 +0000 @@ -0,0 +1,47 @@ +diff -Nru openjdk.orig/jdk/make/docs/Makefile openjdk/jdk/make/docs/Makefile +--- openjdk.orig/jdk/make/docs/Makefile 2009-02-03 13:34:38.000000000 +0000 ++++ openjdk/jdk/make/docs/Makefile 2009-02-03 13:37:17.000000000 +0000 +@@ -99,36 +99,20 @@ + + TAGS = $(IGNORED_TAGS:%=-tag %:X) $(TAG_JLS3) + +-ifeq ($(MILESTONE), fcs) +- DOCTITLE_SWITCH = $(JAVADOCTITLE) +- WINDOWTITLE_SWITCH = $(JAVADOCWINDOWTITLE) +- HEADER_SWITCH = $(JAVADOCHEADER) +- TOPOPTION= +- JAVADOCBOTTOM_SWITCH= $(JAVADOCBOTTOM) +- OVERVIEW_OPTION = -overview $(JAVADOCOVERVIEW) +-else +- DOCTITLE_SWITCH = $(JAVADOCTITLE_EARLYACCESS)$(DRAFT) +- WINDOWTITLE_SWITCH = $(JAVADOCWINDOWTITLE)" $(BUILD_NUMBER)" +- HEADER_SWITCH = $(JAVADOCHEADER)$(DRAFT) +- JAVADOCBOTTOM_SWITCH= $(JAVADOCBOTTOM_EARLYACCESS) +- TOPOPTION= -top $(JAVADOCTOP_EARLYACCESS) +- OVERVIEW_OPTION = +-endif ++DOCTITLE_SWITCH = $(JAVADOCTITLE) ++WINDOWTITLE_SWITCH = $(JAVADOCWINDOWTITLE)" $(BUILD_NUMBER)" ++HEADER_SWITCH = $(JAVADOCHEADER) ++TOPOPTION= ++JAVADOCBOTTOM_SWITCH= $(JAVADOCBOTTOM) ++OVERVIEW_OPTION = -overview $(JAVADOCOVERVIEW) + + JAVADOCTITLE = 'Java$(TRADEMARK) Platform, Standard Edition $(JDK_MINOR_VERSION)
API Specification' + JAVADOCWINDOWTITLE = 'Java Platform SE $(JDK_MINOR_VERSION)' + JAVADOCHEADER = 'Java$(TRADEMARK) Platform
Standard Ed. $(JDK_MINOR_VERSION)
' +-JAVADOCBOTTOM = 'Submit a bug or feature
For further API reference and developer documentation, see Java SE Developer Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.

Copyright $(THIS_YEAR) Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.' ++JAVADOCBOTTOM = 'Submit a bug or feature

Copyright $(THIS_YEAR) Sun Microsystems, Inc. All rights reserved. Use is subject to the terms of the GNU General Public License.' + JAVADOCOVERVIEW = $(SHARE_SRC)/classes/overview-core.html + + # +-# Early access top and bottom text (for snapshots, beta and rc) +-# +-JAVADOCTOP_EARLYACCESS = '

Please note that this documentation is not final and is subject to change.
' +-JAVADOCBOTTOM_EARLYACCESS = 'Submit a bug or feature

Copyright $(THIS_YEAR) Sun Microsystems, Inc. All rights reserved. Use is subject to the terms of the GNU General Public License.' +-JAVADOCTITLE_EARLYACCESS = $(subst Specification,Documentation,$(JAVADOCTITLE)) +- +-# + # Variables used by domapidocs target + # + From ahughes at redhat.com Tue Feb 3 12:23:43 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 20:23:43 +0000 Subject: changeset in /hg/icedtea6: Generate documentation for NIO2. Message-ID: changeset 6b1b34af152d in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=6b1b34af152d description: Generate documentation for NIO2. 2009-02-03 Andrew John Hughes * patches/icedtea-nio2.patch: (docs/NON_CORE_PKGS.gmk): Rename NIO to NIO2. (docs/Makefile): Add rule for generating NIO2 docs. diffstat: 2 files changed, 75 insertions(+), 6 deletions(-) ChangeLog | 6 +++ patches/icedtea-nio2.patch | 75 ++++++++++++++++++++++++++++++++++++++++---- diffs (112 lines): diff -r 0c693476e03c -r 6b1b34af152d ChangeLog --- a/ChangeLog Tue Feb 03 16:20:10 2009 +0000 +++ b/ChangeLog Tue Feb 03 20:23:22 2009 +0000 @@ -1,3 +1,9 @@ 2009-02-03 Andrew John Hughes + + * patches/icedtea-nio2.patch: + (docs/NON_CORE_PKGS.gmk): Rename NIO to NIO2. + (docs/Makefile): Add rule for generating NIO2 docs. + 2009-02-03 Andrew John Hughes * Makefile.am: diff -r 0c693476e03c -r 6b1b34af152d patches/icedtea-nio2.patch --- a/patches/icedtea-nio2.patch Tue Feb 03 16:20:10 2009 +0000 +++ b/patches/icedtea-nio2.patch Tue Feb 03 20:23:22 2009 +0000 @@ -9,26 +9,89 @@ diff -Nru openjdk.orig/jdk/make/docs/COR org.jcp.* \ org.w3c.dom.css \ org.w3c.dom.html \ +diff -Nru openjdk.orig/jdk/make/docs/Makefile openjdk/jdk/make/docs/Makefile +--- openjdk.orig/jdk/make/docs/Makefile 2009-02-03 16:20:38.000000000 +0000 ++++ openjdk/jdk/make/docs/Makefile 2009-02-03 19:40:10.000000000 +0000 +@@ -404,6 +404,29 @@ + # TREEAPI_PKGS is located in NON_CORE_PKGS.gmk + + # ++# Variables used by nio2docs target ++# ++ ++NIO2_JAVADOCFLAGS = $(COMMON_JAVADOCFLAGS) \ ++ -encoding ascii \ ++ -d $(NIO2_DOCDIR) \ ++ -sourcepath $(NIO2_SOURCEPATH) \ ++ -splitIndex \ ++ -doctitle $(NIO2_JAVADOCTITLE) \ ++ -windowtitle $(NIO2_JAVADOCWINDOWTITLE) \ ++ -header $(NIO2_JAVADOCHEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ ++ -group $(NIO2_GROUPNAME) $(NIO2_REGEXP) ++NIO2_JAVADOCTITLE = 'NIO2 API' ++NIO2_JAVADOCWINDOWTITLE = 'NIO2 API' ++NIO2_JAVADOCHEADER = 'NIO2 API' ++NIO2_GROUPNAME = "Packages" ++NIO2_REGEXP = "org.classpath.icedtea.*" ++NIO2_DOCDIR = $(DOCSDIR)/jre/api/nio2 ++NIO2_SOURCEPATH = $(TOPDIR)/src/share/classes ++# NIO2_PKGS is located in NON_CORE_PKGS.gmk ++ ++# + # Path where javadoc should find source files for release docs + # + RELEASEDOCS_SRCPATH = "$(SHARE_SRC)/classes$(CLASSPATH_SEPARATOR)$(PLATFORM_SRC)/classes$(CLASSPATH_SEPARATOR)$(GENSRCDIR)$(CLASSPATH_SEPARATOR)$(SHARE_SRC)/doc/stub$(CLASSPATH_SEPARATOR)$(CLOSED_SRC)/share/classes$(CLASSPATH_SEPARATOR)$(IMPORTSRCDIR)" +@@ -429,7 +452,8 @@ + httpserverdocs \ + mgmtdocs \ + attachdocs \ +- jconsoledocs ++ jconsoledocs \ ++ nio2docs + + ifdef LANGTOOLS_DIST + ALL_OTHER_TARGETS += \ +@@ -646,6 +670,14 @@ + $(TREEAPI_LINKOPT) \ + $(TREEAPI_PKGS) + ++.PHONY: nio2docs ++nio2docs: ++ @# ######## api-nio2 ############################ ++ $(RM) -r $(NIO2_DOCDIR) ++ $(MKDIR) -p $(NIO2_DOCDIR) ++ $(JAVADOC_CMD) $(NIO2_JAVADOCFLAGS) \ ++ $(NIO2_PKGS) ++ + # DEBUG TARGET + # List the values defined in the makefile hierarchy, to make sure everything + # is set properly, and to help identify values we can use instead of making new ones. diff -Nru openjdk.orig/jdk/make/docs/NON_CORE_PKGS.gmk openjdk/jdk/make/docs/NON_CORE_PKGS.gmk --- openjdk.orig/jdk/make/docs/NON_CORE_PKGS.gmk 2009-01-07 21:27:46.000000000 +0000 -+++ openjdk/jdk/make/docs/NON_CORE_PKGS.gmk 2009-01-09 21:21:39.000000000 +0000 -@@ -65,6 +65,11 @@ ++++ openjdk/jdk/make/docs/NON_CORE_PKGS.gmk 2009-02-03 16:28:29.000000000 +0000 +@@ -65,6 +65,16 @@ HTTPSERVER_PKGS = com.sun.net.httpserver \ com.sun.net.httpserver.spi -+NIO_PKGS = com.sun.nio.file \ ++NIO2_PKGS = org.classpath.icedtea.java.io \ ++ org.classpath.icedtea.java.net \ ++ org.classpath.icedtea.java.nio.channels \ ++ org.classpath.icedtea.java.nio.channels.spi \ + org.classpath.icedtea.java.nio.file \ + org.classpath.icedtea.java.nio.file.attribute \ -+ org.classpath.icedtea.java.nio.file.spi ++ org.classpath.icedtea.java.nio.file.spi \ ++ org.classpath.icedtea.java.util ++ + DOCLETAPI_PKGS = com.sun.javadoc TAGLETAPI_FILE = com/sun/tools/doclets/Taglet.java -@@ -89,6 +94,7 @@ +@@ -89,6 +99,7 @@ $(MGMT_PKGS) \ $(JAAS_PKGS) \ $(JGSS_PKGS) \ -+ $(NIO_PKGS) \ ++ $(NIO2_PKGS) \ $(OLD_JSSE_PKGS) \ $(HTTPSERVER_PKGS) \ $(SMARTCARDIO_PKGS) From ahughes at redhat.com Tue Feb 3 12:23:42 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 03 Feb 2009 20:23:42 +0000 Subject: changeset in /hg/icedtea6: More documentation fixes; our Bugzill... Message-ID: changeset 0c693476e03c in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=0c693476e03c description: More documentation fixes; our Bugzilla URL is used (as we do for HotSpot crashes) and the same licensing header is used for all docs. 2009-02-03 Andrew John Hughes * Makefile.am: Move doc headers patch above NIO2 patch, as this needs to alter the same file. * patches/icedtea-doc-headers.patch: Add IcedTea bugzilla URL and common licensing to all documentation. diffstat: 3 files changed, 148 insertions(+), 5 deletions(-) ChangeLog | 9 ++ Makefile.am | 6 - patches/icedtea-doc-headers.patch | 138 ++++++++++++++++++++++++++++++++++++- diffs (197 lines): diff -r c38d90386c71 -r 0c693476e03c ChangeLog --- a/ChangeLog Tue Feb 03 15:41:58 2009 +0000 +++ b/ChangeLog Tue Feb 03 16:20:10 2009 +0000 @@ -1,3 +1,12 @@ 2009-02-03 Andrew John Hughes + + * Makefile.am: + Move doc headers patch above NIO2 patch, + as this needs to alter the same file. + * patches/icedtea-doc-headers.patch: + Add IcedTea bugzilla URL and common licensing + to all documentation. + 2009-02-03 Andrew John Hughes * Makefile.am: diff -r c38d90386c71 -r 0c693476e03c Makefile.am --- a/Makefile.am Tue Feb 03 15:41:58 2009 +0000 +++ b/Makefile.am Tue Feb 03 16:20:10 2009 +0000 @@ -562,7 +562,8 @@ ICEDTEA_PATCHES += \ patches/icedtea-6728542-epoll.patch \ patches/icedtea-io_util-overflow.patch \ patches/icedtea-cc-interp-jvmti.patch \ - patches/icedtea-pr261.patch + patches/icedtea-pr261.patch \ + patches/icedtea-doc-headers.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ @@ -615,8 +616,7 @@ ICEDTEA_PATCHES += \ $(DISTRIBUTION_PATCHES) \ patches/icedtea-demo-swingapplet.patch \ patches/icedtea-awt-window-size.patch \ - patches/icedtea-java2d-dasher.patch \ - patches/icedtea-doc-headers.patch + patches/icedtea-java2d-dasher.patch stamps/extract.stamp: stamps/download.stamp if OPENJDK_SRC_DIR_FOUND diff -r c38d90386c71 -r 0c693476e03c patches/icedtea-doc-headers.patch --- a/patches/icedtea-doc-headers.patch Tue Feb 03 15:41:58 2009 +0000 +++ b/patches/icedtea-doc-headers.patch Tue Feb 03 16:20:10 2009 +0000 @@ -1,6 +1,6 @@ diff -Nru openjdk.orig/jdk/make/docs/Mak diff -Nru openjdk.orig/jdk/make/docs/Makefile openjdk/jdk/make/docs/Makefile --- openjdk.orig/jdk/make/docs/Makefile 2009-02-03 13:34:38.000000000 +0000 -+++ openjdk/jdk/make/docs/Makefile 2009-02-03 13:37:17.000000000 +0000 ++++ openjdk/jdk/make/docs/Makefile 2009-02-03 16:11:08.000000000 +0000 @@ -99,36 +99,20 @@ TAGS = $(IGNORED_TAGS:%=-tag %:X) $(TAG_JLS3) @@ -31,7 +31,7 @@ diff -Nru openjdk.orig/jdk/make/docs/Mak JAVADOCWINDOWTITLE = 'Java Platform SE $(JDK_MINOR_VERSION)' JAVADOCHEADER = 'Java$(TRADEMARK) Platform
Standard Ed. $(JDK_MINOR_VERSION)
' -JAVADOCBOTTOM = 'Submit a bug or feature
For further API reference and developer documentation, see Java SE Developer Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.

Copyright $(THIS_YEAR) Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.' -+JAVADOCBOTTOM = 'Submit a bug or feature

Copyright $(THIS_YEAR) Sun Microsystems, Inc. All rights reserved. Use is subject to the terms of the GNU General Public License.' ++JAVADOCBOTTOM = 'Submit a bug or feature

Copyright $(THIS_YEAR) Sun Microsystems, Inc. All rights reserved. Use is subject to the terms of the GNU General Public License.' JAVADOCOVERVIEW = $(SHARE_SRC)/classes/overview-core.html # @@ -45,3 +45,137 @@ diff -Nru openjdk.orig/jdk/make/docs/Mak # Variables used by domapidocs target # +@@ -138,12 +122,11 @@ + -doctitle $(DOMAPI_JAVADOCTITLE) \ + -windowtitle $(DOMAPI_JAVADOCWINDOWTITLE) \ + -header $(DOMAPI_JAVADOCHEADER) \ +- -bottom $(DOMAPI_JAVADOCBOTTOM) \ ++ -bottom $(JAVADOCBOTTOM) \ + -group $(DOMAPI_GROUPNAME) $(DOMAPI_REGEXP) + DOMAPI_JAVADOCTITLE = 'Common DOM API' + DOMAPI_JAVADOCWINDOWTITLE = 'Common DOM API' + DOMAPI_JAVADOCHEADER = 'Common DOM API' +-DOMAPI_JAVADOCBOTTOM = 'Submit a bug or feature
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright $(THIS_YEAR) Sun Microsystems, Inc. 4150 Network Circle
Santa Clara, California, 95054, U.S.A. All Rights Reserved.
' + DOMAPI_GROUPNAME = "Packages" + DOMAPI_REGEXP = "com.sun.java.browser.dom:org.w3c.dom*" + # DOMAPI_PKGS is located in NON_CORE_PKGS.gmk +@@ -157,13 +140,12 @@ + -doctitle $(MIRROR_JAVADOCTITLE) \ + -windowtitle $(MIRROR_JAVADOCWINDOWTITLE) \ + -header $(MIRROR_JAVADOCHEADER) \ +- -bottom $(MIRROR_JAVADOCBOTTOM) \ ++ -bottom $(JAVADOCBOTTOM) \ + -group $(MIRROR_GROUPNAME) $(MIRROR_REGEXP) \ + -overview $(MIRROR_OVERVIEW) + MIRROR_JAVADOCTITLE = 'Mirror API' + MIRROR_JAVADOCWINDOWTITLE = 'Mirror API' + MIRROR_JAVADOCHEADER = 'Mirror API' +-MIRROR_JAVADOCBOTTOM = 'Report a bug or request a feature.
Copyright $(THIS_YEAR) Sun Microsystems, Inc. All Rights Reserved. Use is subject to license terms.
' + MIRROR_GROUPNAME = "Packages" + MIRROR_OVERVIEW = $(IMPORTSRCDIR)/com/sun/mirror/overview.html + MIRROR_REGEXP = "com.sun.mirror.*" +@@ -181,12 +163,11 @@ + -doctitle $(DOCLETAPI_JAVADOCTITLE) \ + -windowtitle $(DOCLETAPI_JAVADOCWINDOWTITLE) \ + -header $(DOCLETAPI_JAVADOCHEADER) \ +- -bottom $(DOCLETAPI_JAVADOCBOTTOM) \ ++ -bottom $(JAVADOCBOTTOM) \ + -group $(DOCLETAPI_GROUPNAME) $(DOCLETAPI_REGEXP) + DOCLETAPI_JAVADOCTITLE = 'Doclet API' + DOCLETAPI_JAVADOCWINDOWTITLE = 'Doclet API' + DOCLETAPI_JAVADOCHEADER = 'Doclet API' +-DOCLETAPI_JAVADOCBOTTOM = 'Submit a bug or feature
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-$(THIS_YEAR) Sun Microsystems, Inc. 4150 Network Circle
Santa Clara, California, 95054, U.S.A. All Rights Reserved.
' + DOCLETAPI_GROUPNAME = "Packages" + DOCLETAPI_REGEXP = "com.sun.javadoc" + DOCLETAPI_LINKOPT = -linkoffline ../../../../api $(DOCSDIR)/api/ +@@ -200,8 +181,7 @@ + -encoding ascii \ + -nonavbar \ + -noindex \ +- -bottom $(TAGLETAPI_JAVADOCBOTTOM) +-TAGLETAPI_JAVADOCBOTTOM = 'Submit a bug or feature
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-$(THIS_YEAR) Sun Microsystems, Inc. 4150 Network Circle
Santa Clara, California, 95054, U.S.A. All Rights Reserved.
' ++ -bottom $(JAVADOCBOTTOM) + # TAGLETAPI_FILE is located in NON_CORE_PKGS.gmk + + # +@@ -218,6 +198,7 @@ + -windowtitle $(JDI_WINDOWTITLE) \ + -doctitle $(JDI_DOCTITLE) \ + -header $(JDI_HEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ + -linkoffline ../../../../api $(DOCSDIR)/api/ \ + -overview $(JPDA_SOURCEPATH)/jdi-overview.html + JDI_WINDOWTITLE = "Java Debug Interface" +@@ -242,6 +223,7 @@ + -windowtitle $(JAAS_WINDOWTITLE) \ + -doctitle $(JAAS_DOCTITLE) \ + -header $(JAAS_JAVADOCHEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ + -linkoffline ../../../../../api $(DOCSDIR)/api/ \ + -overview $(TOPDIR)/src/share/classes/com/sun/security/auth/jaas-overview.html + JAAS_WINDOWTITLE = "Java Authentication and Authorization Service " +@@ -264,6 +246,7 @@ + -windowtitle $(JGSS_WINDOWTITLE) \ + -doctitle $(JGSS_DOCTITLE) \ + -header $(JGSS_JAVADOCHEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ + -linkoffline ../../../../../api $(DOCSDIR)/api/ \ + -overview $(JGSS_SOURCEPATH)/com/sun/security/jgss/jgss-overview.html + +@@ -287,6 +270,7 @@ + -windowtitle $(SMARTCARDIO_WINDOWTITLE) \ + -doctitle $(SMARTCARDIO_DOCTITLE) \ + -header $(SMARTCARDIO_JAVADOCHEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ + -linkoffline ../../../../../api $(DOCSDIR)/api/ + + SMARTCARDIO_WINDOWTITLE = "Java Smart Card I/O" +@@ -309,6 +293,7 @@ + -windowtitle $(HTTPSERVER_WINDOWTITLE) \ + -doctitle $(HTTPSERVER_DOCTITLE) \ + -header $(HTTPSERVER_JAVADOCHEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ + -linkoffline ../../../../../api $(DOCSDIR)/api/ + + HTTPSERVER_WINDOWTITLE = "Java HTTP Server" +@@ -344,6 +329,7 @@ + -windowtitle $(MGMT_WINDOWTITLE) \ + -doctitle $(MGMT_DOCTITLE) \ + -header $(MGMT_HEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ + -linkoffline ../../../../api $(DOCSDIR)/api/ \ + -overview $(MGMT_SOURCEPATH)/com/sun/management/mgmt-overview.html + MGMT_WINDOWTITLE = "Monitoring and Management Interface for the Java Platform" +@@ -365,6 +351,7 @@ + -windowtitle $(ATTACH_WINDOWTITLE) \ + -doctitle $(ATTACH_DOCTITLE) \ + -header $(ATTACH_HEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ + -linkoffline ../../../../api $(DOCSDIR)/api/ + ATTACH_WINDOWTITLE = "Attach API" + ATTACH_DOCTITLE = "Attach API" +@@ -385,6 +372,7 @@ + -windowtitle $(JCONSOLE_WINDOWTITLE) \ + -doctitle $(JCONSOLE_DOCTITLE) \ + -header $(JCONSOLE_HEADER) \ ++ -bottom $(JAVADOCBOTTOM) \ + -linkoffline ../../../../api $(DOCSDIR)/api/ + JCONSOLE_WINDOWTITLE = "JConsole API" + JCONSOLE_DOCTITLE = "JConsole API" +@@ -400,7 +388,7 @@ + -doctitle $(TREEAPI_JAVADOCTITLE) \ + -windowtitle $(TREEAPI_JAVADOCWINDOWTITLE) \ + -header $(TREEAPI_JAVADOCHEADER) \ +- -bottom $(TREEAPI_JAVADOCBOTTOM) \ ++ -bottom $(JAVADOCBOTTOM) \ + -group $(TREEAPI_GROUPNAME) $(TREEAPI_REGEXP) + # + # -overview $(TREEAPI_OVERVIEW) +@@ -408,7 +396,6 @@ + TREEAPI_JAVADOCTITLE = 'Compiler Tree API' + TREEAPI_JAVADOCWINDOWTITLE = 'Compiler Tree API' + TREEAPI_JAVADOCHEADER = 'Compiler Tree API' +-TREEAPI_JAVADOCBOTTOM = 'Report a bug or request a feature.
Copyright $(THIS_YEAR) Sun Microsystems, Inc. All Rights Reserved. Use is subject to license terms.
' + TREEAPI_GROUPNAME = "Packages" + TREEAPI_OVERVIEW = $(SHARE_SRC)/classes/com/sun/source/overview.html + TREEAPI_REGEXP = "com.sun.source.*" From mvfranz at gmail.com Tue Feb 3 18:27:54 2009 From: mvfranz at gmail.com (Michael Franz) Date: Tue, 3 Feb 2009 21:27:54 -0500 Subject: IcedTea 7 Patches for with-project=bsd - A Plan Message-ID: Hi, Taking a different approach to getting IcedTea 7 to compile on OS X, I am trying to get the bsd repo to compile on Linux (Fedora 10). In investigating the patching problems closer, I wonder if this seems like a sound plan. 1. Identify the patches that break 2. move failing patches out of the main patch file into a project specific patch file 3. create equivalent patches for bsd 4. change the patch process to use base patches and then the project specific patches An example of this is icedtea-libraries.patch. There are 8 patches within this file that fail on the bsd repo. I would move these patches into icedtea-libraries-linux.patch (should this be jdk7?) and create bsd specific patches that are then put into icedtea-libraries-bsd.patch. The patch process can then apply the patches in icedtea-libraries.patch and then icedtea-libraries-.patch. On a similar note, I have found that icedtea-libraries.patch and icedtea-linker-options.patch are patching the same line in jdk/make/common/Program.gmk. first - LDFLAGS += -z origin + LDFLAGS += -lz -z origin then - LDFLAGS += -lz -z origin + LDFLAGS += -lz -Wl, -z -Wl,origin Is there a benefit to patching the same line twice (keeping logical changes together)? Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20090203/3754afd2/attachment.html From gbenson at redhat.com Wed Feb 4 02:51:26 2009 From: gbenson at redhat.com (Gary Benson) Date: Wed, 4 Feb 2009 10:51:26 +0000 Subject: IcedTea 7 Patches for with-project=bsd - A Plan In-Reply-To: References: Message-ID: <20090204105125.GA3897@redhat.com> Michael Franz wrote: > Taking a different approach to getting IcedTea 7 to compile on OS X, > I am trying to get the bsd repo to compile on Linux (Fedora 10). In > investigating the patching problems closer, I wonder if this seems > like a sound plan. [snip] That sounds like an excellent plan. It might be better to split them into subdirectories, as Andrew Hughes did with the HotSpot-specific patches, but I'll leave that choice up to you. Cheers, Gary -- http://gbenson.net/ From ahughes at redhat.com Wed Feb 4 03:49:45 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Wed, 04 Feb 2009 11:49:45 +0000 Subject: changeset in /hg/icedtea: Bump to b45. Message-ID: changeset 5a2104fb2256 in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=5a2104fb2256 description: Bump to b45. 2009-02-03 Andrew John Hughes * Makefile.am: Bump to b45. diffstat: 2 files changed, 9 insertions(+), 4 deletions(-) ChangeLog | 5 +++++ Makefile.am | 8 ++++---- diffs (34 lines): diff -r 70396cb4abf8 -r 5a2104fb2256 ChangeLog --- a/ChangeLog Wed Jan 28 22:11:07 2009 +0000 +++ b/ChangeLog Wed Feb 04 11:49:31 2009 +0000 @@ -1,3 +1,8 @@ 2009-01-28 Andrew John Hughes + + * Makefile.am: + Bump to b45. + 2009-01-28 Andrew John Hughes * Makefile.am: diff -r 70396cb4abf8 -r 5a2104fb2256 Makefile.am --- a/Makefile.am Wed Jan 28 22:11:07 2009 +0000 +++ b/Makefile.am Wed Feb 04 11:49:31 2009 +0000 @@ -1,6 +1,6 @@ OPENJDK_DATE = 22_jan_2009 -OPENJDK_DATE = 22_jan_2009 -OPENJDK_MD5SUM = 6d5ce33b6ffa65966675b769b59e3d0c -OPENJDK_VERSION = b44 +OPENJDK_DATE = 29_jan_2009 +OPENJDK_MD5SUM = 0d6ae1ed77b470c9665d069b34a1bc88 +OPENJDK_VERSION = b45 CACAO_VERSION = 0.99.3 CACAO_MD5SUM = 80de3ad344c1a20c086ec5f1390bd1b8 @@ -1899,7 +1899,7 @@ ICEDTEA_PATCHES = \ patches/security/icedtea-6766136.patch \ patches/icedtea-cc-interp-jvmti.patch \ patches/hotspot/$(HSBUILD)/icedtea-6791168.patch \ - patches/hotspot/$(HSBUILD)/icedtea-includedb.patch + patches/hotspot/$(HSBUILD)/icedtea-includedb.patch if WITH_RHINO ICEDTEA_PATCHES += \ From ahughes at redhat.com Wed Feb 4 03:51:32 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Wed, 04 Feb 2009 11:51:32 +0000 Subject: changeset in /hg/icedtea6: Fix warnings that cause build failure... Message-ID: changeset ab71ebb1e8b6 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=ab71ebb1e8b6 description: Fix warnings that cause build failure on gcc 4.3.3. 2009-02-04 Andrew John Hughes * Makefile.am: Add new patch. * patches/hotspot/14.0b08/icedtea-format.patch, Fix warnings that cause the build to fail with GCC 4.3.3. diffstat: 3 files changed, 58 insertions(+), 1 deletion(-) ChangeLog | 8 ++++ Makefile.am | 3 + patches/hotspot/14.0b08/icedtea-format.patch | 48 ++++++++++++++++++++++++++ diffs (80 lines): diff -r 6b1b34af152d -r ab71ebb1e8b6 ChangeLog --- a/ChangeLog Tue Feb 03 20:23:22 2009 +0000 +++ b/ChangeLog Wed Feb 04 11:51:13 2009 +0000 @@ -1,3 +1,11 @@ 2009-02-03 Andrew John Hughes + + * Makefile.am: + Add new patch. + * patches/hotspot/14.0b08/icedtea-format.patch, + Fix warnings that cause the build to fail with + GCC 4.3.3. + 2009-02-03 Andrew John Hughes * patches/icedtea-nio2.patch: diff -r 6b1b34af152d -r ab71ebb1e8b6 Makefile.am --- a/Makefile.am Tue Feb 03 20:23:22 2009 +0000 +++ b/Makefile.am Wed Feb 04 11:51:13 2009 +0000 @@ -616,7 +616,8 @@ ICEDTEA_PATCHES += \ $(DISTRIBUTION_PATCHES) \ patches/icedtea-demo-swingapplet.patch \ patches/icedtea-awt-window-size.patch \ - patches/icedtea-java2d-dasher.patch + patches/icedtea-java2d-dasher.patch \ + patches/hotspot/$(HSBUILD)/icedtea-format.patch stamps/extract.stamp: stamps/download.stamp if OPENJDK_SRC_DIR_FOUND diff -r 6b1b34af152d -r ab71ebb1e8b6 patches/hotspot/14.0b08/icedtea-format.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/hotspot/14.0b08/icedtea-format.patch Wed Feb 04 11:51:13 2009 +0000 @@ -0,0 +1,48 @@ +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/arguments.cpp openjdk/hotspot/src/share/vm/runtime/arguments.cpp +--- openjdk.orig/hotspot/src/share/vm/runtime/arguments.cpp 2009-02-03 18:08:09.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/runtime/arguments.cpp 2009-02-03 18:32:59.000000000 +0000 +@@ -1361,7 +1361,7 @@ + + // Feed the cache size setting into the JDK + char buffer[1024]; +- sprintf(buffer, "java.lang.Integer.IntegerCache.high=%d", AutoBoxCacheMax); ++ sprintf(buffer, "java.lang.Integer.IntegerCache.high=" INTX_FORMAT, AutoBoxCacheMax); + add_property(buffer); + } + if (AggressiveOpts && FLAG_IS_DEFAULT(DoEscapeAnalysis)) { +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/safepoint.cpp openjdk/hotspot/src/share/vm/runtime/safepoint.cpp +--- openjdk.orig/hotspot/src/share/vm/runtime/safepoint.cpp 2009-01-29 15:03:07.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/runtime/safepoint.cpp 2009-02-03 18:30:55.000000000 +0000 +@@ -730,7 +730,7 @@ + if (DieOnSafepointTimeout) { + char msg[1024]; + VM_Operation *op = VMThread::vm_operation(); +- sprintf(msg, "Safepoint sync time longer than %d ms detected when executing %s.", ++ sprintf(msg, "Safepoint sync time longer than " INTX_FORMAT " ms detected when executing %s.", + SafepointTimeoutDelay, + op != NULL ? op->name() : "no vm operation"); + fatal(msg); +diff -Nru openjdk.orig/hotspot/src/share/vm/runtime/synchronizer.cpp openjdk/hotspot/src/share/vm/runtime/synchronizer.cpp +--- openjdk.orig/hotspot/src/share/vm/runtime/synchronizer.cpp 2009-01-29 15:03:07.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/runtime/synchronizer.cpp 2009-02-03 19:32:30.000000000 +0000 +@@ -424,7 +424,7 @@ + // asserts is that error message -- often something about negative array + // indices -- is opaque. + +-#define CTASSERT(x) { int tag[1-(2*!(x))]; printf ("Tag @%X\n", tag); } ++#define CTASSERT(x) { int tag[1-(2*!(x))]; printf ("Tag @%p\n", tag); } + + void ObjectMonitor::ctAsserts() { + CTASSERT(offset_of (ObjectMonitor, _header) == 0); +diff -Nru openjdk.orig/hotspot/src/share/vm/utilities/vmError.cpp openjdk/hotspot/src/share/vm/utilities/vmError.cpp +--- openjdk.orig/hotspot/src/share/vm/utilities/vmError.cpp 2009-02-03 19:10:58.000000000 +0000 ++++ openjdk/hotspot/src/share/vm/utilities/vmError.cpp 2009-02-03 19:29:15.000000000 +0000 +@@ -307,7 +307,7 @@ + + strncpy(buf, file, buflen); + if (len + 10 < buflen) { +- sprintf(buf + len, ":" SIZE_FORMAT, _lineno); ++ sprintf(buf + len, ":%d", _lineno); + } + st->print(" (%s)", buf); + } else { From ahughes at redhat.com Wed Feb 4 04:48:50 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Wed, 04 Feb 2009 12:48:50 +0000 Subject: changeset in /hg/icedtea6: Fix JDk directory macros to drop out ... Message-ID: changeset b0be146027ad in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=b0be146027ad description: Fix JDk directory macros to drop out of the default for loop when the first solution is found. At present, the loop will use the last solution found. This should be more intuitive. 2009-02-04 Andrew John Hughes * acinclude.m4: (AC_CHECK_FOR_GCJ_JDK): Drop out of loop when first solution is found. (AC_CHECK_FOR_OPENJDK): Likewise. (AC_CHECK_FOR_ICEDTEA): Likewise. diffstat: 2 files changed, 20 insertions(+), 3 deletions(-) ChangeLog | 8 ++++++++ acinclude.m4 | 15 ++++++++++++--- diffs (54 lines): diff -r ab71ebb1e8b6 -r b0be146027ad ChangeLog --- a/ChangeLog Wed Feb 04 11:51:13 2009 +0000 +++ b/ChangeLog Wed Feb 04 12:48:30 2009 +0000 @@ -1,3 +1,11 @@ 2009-02-04 Andrew John Hughes + + * acinclude.m4: + (AC_CHECK_FOR_GCJ_JDK): Drop out of loop + when first solution is found. + (AC_CHECK_FOR_OPENJDK): Likewise. + (AC_CHECK_FOR_ICEDTEA): Likewise. + 2009-02-04 Andrew John Hughes * Makefile.am: diff -r ab71ebb1e8b6 -r b0be146027ad acinclude.m4 --- a/acinclude.m4 Wed Feb 04 11:51:13 2009 +0000 +++ b/acinclude.m4 Wed Feb 04 12:48:30 2009 +0000 @@ -944,7 +944,10 @@ AC_DEFUN([AC_CHECK_FOR_GCJ_JDK], ]) if test -z "${SYSTEM_GCJ_DIR}"; then for dir in /usr/lib/jvm/java-gcj /usr/lib/jvm/gcj-jdk /usr/lib/jvm/cacao ; do - test -d $dir && SYSTEM_GCJ_DIR=$dir + if test -d $dir; then + SYSTEM_GCJ_DIR=$dir + break + fi done fi AC_MSG_RESULT(${SYSTEM_GCJ_DIR}) @@ -977,7 +980,10 @@ AC_DEFUN([AC_CHECK_FOR_OPENJDK], ]) if test -z "${SYSTEM_OPENJDK_DIR}"; then for dir in /usr/lib/jvm/java-openjdk /usr/lib/jvm/openjdk ; do - test -d $dir && SYSTEM_OPENJDK_DIR=$dir + if test -d $dir; then + SYSTEM_OPENJDK_DIR=$dir + break + fi done fi AC_MSG_RESULT(${SYSTEM_OPENJDK_DIR}) @@ -1010,7 +1016,10 @@ AC_DEFUN([AC_CHECK_FOR_ICEDTEA], ]) if test -z "${SYSTEM_ICEDTEA_DIR}"; then for dir in /usr/lib/jvm/java-icedtea /usr/lib/jvm/icedtea6 /usr/lib/jvm/java-6-openjdk ; do - test -d $dir && SYSTEM_ICEDTEA_DIR=$dir + if test -d $dir; then + SYSTEM_ICEDTEA_DIR=$dir + break + fi done fi AC_MSG_RESULT(${SYSTEM_ICEDTEA_DIR}) From ahughes at redhat.com Thu Feb 5 11:03:38 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Thu, 05 Feb 2009 19:03:38 +0000 Subject: changeset in /hg/icedtea6: Ensure NIO2 is in sync with the lates... Message-ID: changeset 9923df826001 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=9923df826001 description: Ensure NIO2 is in sync with the latest build drop, b98. 2009-02-05 Andrew John Hughes Ensure the NIO2 code is in sync with the latest build drop, b98. * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsDirectoryStream.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributeViews.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileCopy.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileStore.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystemProvider.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsLinkSupport.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNamedAttributeView.java, * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPath.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/InterruptCopy.java, * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView/Basic.java, diffstat: 16 files changed, 467 insertions(+), 328 deletions(-) ChangeLog | 20 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java | 12 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java | 55 +- overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java | 11 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java | 13 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java | 220 +++++----- overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsDirectoryStream.java | 18 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributeViews.java | 4 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileCopy.java | 21 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileStore.java | 4 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystemProvider.java | 3 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsLinkSupport.java | 16 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNamedAttributeView.java | 18 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPath.java | 220 +++++----- overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/InterruptCopy.java | 4 overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView/Basic.java | 156 +++++-- diffs (truncated from 1256 to 500 lines): diff -r b0be146027ad -r 9923df826001 ChangeLog --- a/ChangeLog Wed Feb 04 12:48:30 2009 +0000 +++ b/ChangeLog Thu Feb 05 19:03:06 2009 +0000 @@ -1,3 +1,23 @@ 2009-02-04 Andrew John Hughes + + Ensure the NIO2 code is in sync with the latest + build drop, b98. + * overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsDirectoryStream.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileAttributeViews.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileCopy.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileStore.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsFileSystemProvider.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsLinkSupport.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsNamedAttributeView.java, + * overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsPath.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/Path/InterruptCopy.java, + * overlays/nio2/openjdk/jdk/test/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView/Basic.java, + 2009-02-04 Andrew John Hughes * acinclude.m4: diff -r b0be146027ad -r 9923df826001 overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java Wed Feb 04 12:48:30 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/org/classpath/icedtea/java/nio/file/attribute/NamedAttributeView.java Thu Feb 05 19:03:06 2009 +0000 @@ -48,9 +48,6 @@ import java.io.IOException; * intended for use where the size of an attribute value is larger than {@link * Integer#MAX_VALUE}. * - *

{@note There has been feedback that the read/write methods should use byte - * arrays instead of ByteBuffers.} - * *

Named attributes may be used in some implementations to store security * related attributes so consequently, in the case of the default provider at * least, all methods that access named attributes require the @@ -64,13 +61,10 @@ import java.io.IOException; *

Where dynamic access to file attributes is required, the {@link * #getAttribute getAttribute} or {@link #readAttributes(String,String[]) * readAttributes(String,String[])} methods may be used to read the attribute - * value as if by invoking the {@link #read read} method. Upon return, the - * buffer's {@link ByteBuffer#position position} is the index of the first - * byte of the attribute value, and its {@link ByteBuffer#limit limit} is - * the index of the first byte that should not be read. The {@link + * value. The attribute value is returned as a byte array (byte[]). The {@link * #setAttribute setAttribute} method may be used to write the value of a - * user-defined/named attribute from a buffer as if by invoking the {@link - * #write write} method. + * user-defined/named attribute from a buffer (as if by invoking the {@link + * #write write} method), or byte array (byte[]). * * @since 1.7 */ diff -r b0be146027ad -r 9923df826001 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java Wed Feb 04 12:48:30 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/AbstractNamedAttributeView.java Thu Feb 05 19:03:06 2009 +0000 @@ -62,18 +62,31 @@ abstract class AbstractNamedAttributeVie public final Object getAttribute(String attribute) throws IOException { - int size = size(attribute); - ByteBuffer buf = ByteBuffer.allocate(size); - read(attribute, buf); - buf.flip(); - return buf; + int size; + try { + size = size(attribute); + } catch (IOException e) { + // not found or some other I/O error + if (list().contains(attribute)) + throw e; + return null; + } + byte[] buf = new byte[size]; + int n = read(attribute, ByteBuffer.wrap(buf)); + return (n == size) ? buf : Arrays.copyOf(buf, n); } public final void setAttribute(String attribute, Object value) throws IOException { - write(attribute, (ByteBuffer)value); + ByteBuffer bb; + if (value instanceof byte[]) { + bb = ByteBuffer.wrap((byte[])value); + } else { + bb = (ByteBuffer)value; + } + write(attribute, bb); } @@ -88,29 +101,23 @@ abstract class AbstractNamedAttributeVie readAll = true; } else { names.add(first); - for (String name: rest) { - if (name.equals("*")) { - readAll = true; - break; - } + } + for (String name: rest) { + if (name.equals("*")) { + readAll = true; + } else { names.add(name); } } - if (readAll) { - names.clear(); - for (String name: list()) { - names.add(name); - } - } + if (readAll) + names = list(); - // allocate buffer for each value and return as map - Map result = new HashMap(); + // read each value and return in map + Map result = new HashMap(); for (String name: names) { - int size = size(name); - ByteBuffer buf = ByteBuffer.allocate(size); - read(name, buf); - result.put(name, buf); - buf.flip(); + Object value = getAttribute(name); + if (value != null) + result.put(name, value); } return result; diff -r b0be146027ad -r 9923df826001 overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java --- a/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java Wed Feb 04 12:48:30 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/share/classes/sun/nio/fs/Cancellable.java Thu Feb 05 19:03:06 2009 +0000 @@ -112,21 +112,24 @@ abstract class Cancellable implements Ru abstract void implRun() throws Throwable; /** - * Invokes the task in its own thread. If this (meaning the current) thread - * is interrupted then an attempt is make to cancel the background task by - * writting bits into the memory location that it is polling. On return, - * the interrupt status for this thread has been cleared. + * Invokes the given task in its own thread. If this (meaning the current) + * thread is interrupted then an attempt is make to cancel the background + * thread by writing into the memory location that it polls cooperatively. */ static void runInterruptibly(Cancellable task) throws ExecutionException { Thread t = new Thread(task); t.start(); + boolean cancelledByInterrupt = false; while (t.isAlive()) { try { t.join(); } catch (InterruptedException e) { + cancelledByInterrupt = true; task.cancel(); } } + if (cancelledByInterrupt) + Thread.currentThread().interrupt(); Throwable exc = task.exception(); if (exc != null) throw new ExecutionException(exc); diff -r b0be146027ad -r 9923df826001 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java --- a/overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java Wed Feb 04 12:48:30 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsAclFileAttributeView.java Thu Feb 05 19:03:06 2009 +0000 @@ -117,8 +117,7 @@ class WindowsAclFileAttributeView // GetFileSecurity does not follow links so when following links we // need the final target - String path = followLinks ? WindowsLinkSupport.getFinalPath(file) : - file.getPathForWin32Calls(); + String path = WindowsLinkSupport.getFinalPath(file, followLinks); NativeBuffer buffer = getFileSecurity(path, OWNER_SECURITY_INFORMATION); try { // get the address of the SID @@ -142,8 +141,7 @@ class WindowsAclFileAttributeView // GetFileSecurity does not follow links so when following links we // need the final target - String path = followLinks ? WindowsLinkSupport.getFinalPath(file) : - file.getPathForWin32Calls(); + String path = WindowsLinkSupport.getFinalPath(file, followLinks); // ALLOW and DENY entries in DACL; // AUDIT entries in SACL (ignore for now as it requires privileges) @@ -170,8 +168,7 @@ class WindowsAclFileAttributeView // SetFileSecurity does not follow links so when following links we // need the final target - String path = followLinks ? WindowsLinkSupport.getFinalPath(file) : - file.getPathForWin32Calls(); + String path = WindowsLinkSupport.getFinalPath(file, followLinks); // ConvertStringSidToSid allocates memory for SID so must invoke // LocalFree to free it when we are done @@ -216,9 +213,7 @@ class WindowsAclFileAttributeView // SetFileSecurity does not follow links so when following links we // need the final target - String path = followLinks ? WindowsLinkSupport.getFinalPath(file) : - file.getPathForWin32Calls(); - + String path = WindowsLinkSupport.getFinalPath(file, followLinks); WindowsSecurityDescriptor sd = WindowsSecurityDescriptor.create(acl); try { SetFileSecurity(path, DACL_SECURITY_INFORMATION, sd.address()); diff -r b0be146027ad -r 9923df826001 overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java --- a/overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java Wed Feb 04 12:48:30 2009 +0000 +++ b/overlays/nio2/openjdk/jdk/src/windows/classes/sun/nio/fs/WindowsChannelFactory.java Thu Feb 05 19:03:06 2009 +0000 @@ -56,7 +56,76 @@ class WindowsChannelFactory { * Do not follow reparse points when opening an existing file. Do not fail * if the file is a reparse point. */ - static final OpenOption NOFOLLOW_REPARSEPOINT = new OpenOption() { }; + static final OpenOption OPEN_REPARSE_POINT = new OpenOption() { }; + + /** + * Represents the flags from a user-supplied set of open options. + */ + private static class Flags { + boolean read; + boolean write; + boolean append; + boolean truncateExisting; + boolean create; + boolean createNew; + boolean deleteOnClose; + boolean sparse; + boolean overlapped; + boolean sync; + boolean dsync; + + // non-standard + boolean shareRead = true; + boolean shareWrite = true; + boolean shareDelete = true; + boolean noFollowLinks; + boolean openReparsePoint; + + static Flags toFlags(Set options) { + Flags flags = new Flags(); + for (OpenOption option: options) { + if (!(option instanceof StandardOpenOption)) { + if (option == ExtendedOpenOption.NOSHARE_READ) { + flags.shareRead = false; + continue; + } + if (option == ExtendedOpenOption.NOSHARE_WRITE) { + flags.shareWrite = false; + continue; + } + if (option == ExtendedOpenOption.NOSHARE_DELETE) { + flags.shareDelete = false; + continue; + } + if (option == LinkOption.NOFOLLOW_LINKS) { + flags.noFollowLinks = true; + continue; + } + if (option == OPEN_REPARSE_POINT) { + flags.openReparsePoint = true; + continue; + } + if (option == null) + throw new NullPointerException(); + throw new UnsupportedOperationException("Unsupported open option"); + } + switch ((StandardOpenOption)option) { + case READ : flags.read = true; break; + case WRITE : flags.write = true; break; + case APPEND : flags.append = true; break; + case TRUNCATE_EXISTING : flags.truncateExisting = true; break; + case CREATE : flags.create = true; break; + case CREATE_NEW : flags.createNew = true; break; + case DELETE_ON_CLOSE : flags.deleteOnClose = true; break; + case SPARSE : flags.sparse = true; break; + case SYNC : flags.sync = true; break; + case DSYNC : flags.dsync = true; break; + default: throw new AssertionError("Should not get here"); + } + } + return flags; + } + } /** * Open/creates file, returning FileChannel to access the file @@ -72,50 +141,25 @@ class WindowsChannelFactory { long pSecurityDescriptor) throws WindowsException { - boolean reading = false; - boolean writing = false; - boolean append = false; - boolean trunc = false; - - // check for invalid flags - for (OpenOption flag: options) { - if (flag == StandardOpenOption.READ) { - reading = true; continue; - } - if (flag == StandardOpenOption.WRITE) { - writing = true; continue; - } - if (flag == StandardOpenOption.APPEND) { - append = true; - writing = true; - continue; - } - if (flag == StandardOpenOption.TRUNCATE_EXISTING) { - trunc = true; continue; - } - if (flag == null) - throw new NullPointerException(); - if (!(flag instanceof StandardOpenOption) && - !(flag instanceof ExtendedOpenOption)) - { - throw new UnsupportedOperationException("Unsupported open option"); - } - } - - // default is reading - if (!reading && !writing) { - reading = true; - } - - // check for invalid combinations - if (reading && append) + Flags flags = Flags.toFlags(options); + + // default is reading; append => writing + if (!flags.read && !flags.write) { + if (flags.append) { + flags.write = true; + } else { + flags.read = true; + } + } + + // validation + if (flags.read && flags.append) throw new IllegalArgumentException("READ + APPEND not allowed"); - if (append && trunc) + if (flags.append && flags.truncateExisting) throw new IllegalArgumentException("APPEND + TRUNCATE_EXISTING not allowed"); - FileDescriptor fdObj = open(pathForWindows, pathToCheck, reading, writing, - append, false, options, pSecurityDescriptor); - return FileChannelImpl.open(fdObj, reading, writing, null); + FileDescriptor fdObj = open(pathForWindows, pathToCheck, flags, pSecurityDescriptor); + return FileChannelImpl.open(fdObj, flags.read, flags.write, null); } /** @@ -135,38 +179,24 @@ class WindowsChannelFactory { ThreadPool pool) throws IOException { - boolean reading = false; - boolean writing = false; - - // check for invalid flags - for (OpenOption flag: options) { - if (flag == StandardOpenOption.READ) { - reading = true; continue; - } - if (flag == StandardOpenOption.WRITE) { - writing = true; continue; - } - if (flag == null) - throw new NullPointerException(); - if (!(flag instanceof StandardOpenOption) && - !(flag instanceof ExtendedOpenOption)) - { - throw new UnsupportedOperationException("Unsupported open option"); - } - if (flag == StandardOpenOption.APPEND) - throw new UnsupportedOperationException("'APPEND' not supported"); - } + Flags flags = Flags.toFlags(options); + + // Overlapped I/O required + flags.overlapped = true; // default is reading - if (!reading && !writing) { - reading = true; - } + if (!flags.read && !flags.write) { + flags.read = true; + } + + // validation + if (flags.append) + throw new UnsupportedOperationException("APPEND not allowed"); // open file for overlapped I/O FileDescriptor fdObj; try { - fdObj = open(pathForWindows, pathToCheck, reading, writing, false, - true, options, pSecurityDescriptor); + fdObj = open(pathForWindows, pathToCheck, flags, pSecurityDescriptor); } catch (WindowsException x) { x.rethrowAsIOException(pathForWindows); return null; @@ -174,7 +204,7 @@ class WindowsChannelFactory { // create the AsynchronousFileChannel try { - return WindowsAsynchronousFileChannelImpl.open(fdObj, reading, writing, pool); + return WindowsAsynchronousFileChannelImpl.open(fdObj, flags.read, flags.write, pool); } catch (IOException x) { // IOException is thrown if the file handle cannot be associated // with the completion port. All we can do is close the file. @@ -190,11 +220,7 @@ class WindowsChannelFactory { */ private static FileDescriptor open(String pathForWindows, String pathToCheck, - boolean reading, - boolean writing, - boolean append, - boolean overlapped, - Set options, + Flags flags, long pSecurityDescriptor) throws WindowsException { @@ -203,30 +229,30 @@ class WindowsChannelFactory { // map options int dwDesiredAccess = 0; - if (reading) + if (flags.read) dwDesiredAccess |= GENERIC_READ; - if (writing) - dwDesiredAccess |= (append) ? FILE_APPEND_DATA : GENERIC_WRITE; + if (flags.write) + dwDesiredAccess |= (flags.append) ? FILE_APPEND_DATA : GENERIC_WRITE; int dwShareMode = 0; - if (!options.contains(ExtendedOpenOption.NOSHARE_READ)) + if (flags.shareRead) dwShareMode |= FILE_SHARE_READ; - if (!options.contains(ExtendedOpenOption.NOSHARE_WRITE)) + if (flags.shareWrite) dwShareMode |= FILE_SHARE_WRITE; - if (!options.contains(ExtendedOpenOption.NOSHARE_DELETE)) + if (flags.shareDelete) dwShareMode |= FILE_SHARE_DELETE; int dwFlagsAndAttributes = FILE_ATTRIBUTE_NORMAL; int dwCreationDisposition = OPEN_EXISTING; - if (writing) { - if (options.contains(StandardOpenOption.CREATE_NEW)) { + if (flags.write) { + if (flags.createNew) { dwCreationDisposition = CREATE_NEW; // force create to fail if file is orphaned reparse point dwFlagsAndAttributes |= FILE_FLAG_OPEN_REPARSE_POINT; } else { - if (options.contains(StandardOpenOption.CREATE)) + if (flags.create) dwCreationDisposition = OPEN_ALWAYS; - if (options.contains(StandardOpenOption.TRUNCATE_EXISTING)) { + if (flags.truncateExisting) { // Windows doesn't have a creation disposition that exactly // corresponds to CREATE + TRUNCATE_EXISTING so we use // the OPEN_ALWAYS mode and then truncate the file. @@ -239,23 +265,21 @@ class WindowsChannelFactory { } } - if (options.contains(StandardOpenOption.DSYNC) || options.contains(StandardOpenOption.SYNC)) + if (flags.dsync || flags.sync) dwFlagsAndAttributes |= FILE_FLAG_WRITE_THROUGH; - if (overlapped) + if (flags.overlapped) dwFlagsAndAttributes |= FILE_FLAG_OVERLAPPED; - - boolean deleteOnClose = options.contains(StandardOpenOption.DELETE_ON_CLOSE); - if (deleteOnClose) + if (flags.deleteOnClose) dwFlagsAndAttributes |= FILE_FLAG_DELETE_ON_CLOSE; // NOFOLLOW_LINKS and NOFOLLOW_REPARSEPOINT mean open reparse point boolean okayToFollowLinks = true; if (dwCreationDisposition != CREATE_NEW && - (options.contains(LinkOption.NOFOLLOW_LINKS) || - options.contains(NOFOLLOW_REPARSEPOINT) || - deleteOnClose)) From ahughes at redhat.com Thu Feb 5 18:04:39 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Fri, 06 Feb 2009 02:04:39 +0000 Subject: changeset in /hg/icedtea6: Depend on overlay.stamp rather than p... Message-ID: changeset d31f7236fd89 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=d31f7236fd89 description: Depend on overlay.stamp rather than patch.stamp. Some targets would not apply overlay.stamp early enough (notably when using --with-icedtea/openjdk). As overlay.stamp depends on patch.stamp, later targets should now depend on overlay.stamp so that they work against the complete IcedTea source tree. ChangeLog: 2009-02-05 Andrew John Hughes * Makefile.am: Depend on overlay.stamp rather than patch.stamp. diffstat: 2 files changed, 8 insertions(+), 4 deletions(-) ChangeLog | 5 +++++ Makefile.am | 7 +++---- diffs (43 lines): diff -r 9923df826001 -r d31f7236fd89 ChangeLog --- a/ChangeLog Thu Feb 05 19:03:06 2009 +0000 +++ b/ChangeLog Fri Feb 06 02:04:22 2009 +0000 @@ -1,3 +1,8 @@ 2009-02-05 Andrew John Hughes + + * Makefile.am: + Depend on overlay.stamp rather than patch.stamp. + 2009-02-05 Andrew John Hughes Ensure the NIO2 code is in sync with the latest diff -r 9923df826001 -r d31f7236fd89 Makefile.am --- a/Makefile.am Thu Feb 05 19:03:06 2009 +0000 +++ b/Makefile.am Fri Feb 06 02:04:22 2009 +0000 @@ -797,7 +797,7 @@ endif # ====================================== # Copy over OpenJDK sources for ecj. -stamps/extract-ecj.stamp: stamps/patch.stamp stamps/overlay.stamp +stamps/extract-ecj.stamp: stamps/overlay.stamp if ! test -d openjdk-ecj ; then \ cp -pPRl openjdk openjdk-ecj ; \ fi @@ -1216,7 +1216,7 @@ ICEDTEA_COPY_DIRS += \ javax/script endif -stamps/copy-source-files.stamp: stamps/patch.stamp +stamps/copy-source-files.stamp: stamps/overlay.stamp for copy_dir in $(ICEDTEA_COPY_DIRS) ; \ do \ mkdir -p rt/$$copy_dir ; \ @@ -1244,8 +1244,7 @@ OPENJDK_SOURCEPATH_DIRS = \ $(SHARE):$(SOLARIS):$(LANGTOOLS):$(JAXP):$(CORBA):$(JAXWS) # tools.jar class files. -stamps/hotspot-tools-copy-source-files.stamp: stamps/patch.stamp \ - stamps/overlay.stamp +stamps/hotspot-tools-copy-source-files.stamp: stamps/overlay.stamp for copy_dir in \ `cat $(abs_top_srcdir)/tools-copy/tools-jdk-copy-files.txt` ; \ do \ From langel at redhat.com Sun Feb 8 04:39:52 2009 From: langel at redhat.com (Lillian Angel) Date: Sun, 08 Feb 2009 12:39:52 +0000 Subject: changeset in /hg/icedtea6: 2009-02-08 Lillian Angel changeset 0a04da4b4d6d in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=0a04da4b4d6d description: 2009-02-08 Lillian Angel * Makefile.am: Updated sed to search for OpenJDK instead of IcedTea6. * patches/icedtea-version.patch: Changed PRODUCT_NAME from IcedTea6 to OpenJDK. diffstat: 3 files changed, 8 insertions(+), 3 deletions(-) ChangeLog | 6 ++++++ Makefile.am | 2 +- patches/icedtea-version.patch | 3 +-- diffs (39 lines): diff -r d31f7236fd89 -r 0a04da4b4d6d ChangeLog --- a/ChangeLog Fri Feb 06 02:04:22 2009 +0000 +++ b/ChangeLog Sun Feb 08 07:39:47 2009 -0500 @@ -1,3 +1,9 @@ 2009-02-05 Andrew John Hughes + + * Makefile.am: Updated sed to search for OpenJDK instead of IcedTea6. + * patches/icedtea-version.patch: Changed PRODUCT_NAME from IcedTea6 to + OpenJDK. + 2009-02-05 Andrew John Hughes * Makefile.am: diff -r d31f7236fd89 -r 0a04da4b4d6d Makefile.am --- a/Makefile.am Fri Feb 06 02:04:22 2009 +0000 +++ b/Makefile.am Sun Feb 08 07:39:47 2009 -0500 @@ -706,7 +706,7 @@ stamps/patch.stamp: stamps/patch-fsg.sta if [ -n "$(PKGVERSION)" ]; then \ icedtea_version="$${icedtea_version} ($(PKGVERSION))" ; \ fi; \ - sed -i "s#IcedTea6#IcedTea6 $${icedtea_version}#" openjdk/jdk/make/common/shared/Defs.gmk + sed -i "s#OpenJDK#OpenJDK $${icedtea_version}#" openjdk/jdk/make/common/shared/Defs.gmk if ENABLE_PLUGIN cp -a $(abs_top_srcdir)/plugin/icedtea/sun/applet/*java openjdk/jdk/src/share/classes/sun/applet/ diff -r d31f7236fd89 -r 0a04da4b4d6d patches/icedtea-version.patch --- a/patches/icedtea-version.patch Fri Feb 06 02:04:22 2009 +0000 +++ b/patches/icedtea-version.patch Sun Feb 08 07:39:47 2009 -0500 @@ -6,9 +6,8 @@ diff -Nru openjdk.orig/jdk/make/common/s # Default names ifdef OPENJDK - LAUNCHER_NAME = openjdk -- PRODUCT_NAME = OpenJDK + LAUNCHER_NAME = java -+ PRODUCT_NAME = IcedTea6 + PRODUCT_NAME = OpenJDK PRODUCT_SUFFIX = Runtime Environment JDK_RC_PLATFORM_NAME = Platform COMPANY_NAME = N/A From langel at redhat.com Sun Feb 8 05:33:09 2009 From: langel at redhat.com (Lillian Angel) Date: Sun, 08 Feb 2009 13:33:09 +0000 Subject: changeset in /hg/icedtea6: Fixed typo Message-ID: changeset c402774cf211 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=c402774cf211 description: Fixed typo diffstat: 1 file changed, 11 insertions(+), 13 deletions(-) patches/icedtea-version.patch | 24 +++++++++++------------- diffs (35 lines): diff -r 0a04da4b4d6d -r c402774cf211 patches/icedtea-version.patch --- a/patches/icedtea-version.patch Sun Feb 08 07:39:47 2009 -0500 +++ b/patches/icedtea-version.patch Sun Feb 08 08:33:04 2009 -0500 @@ -1,16 +1,3 @@ diff -Nru openjdk.orig/jdk/make/common/s -diff -Nru openjdk.orig/jdk/make/common/shared/Defs.gmk openjdk/jdk/make/common/shared/Defs.gmk ---- openjdk.orig/jdk/make/common/shared/Defs.gmk 2008-10-15 15:36:07.000000000 +0100 -+++ openjdk/jdk/make/common/shared/Defs.gmk 2008-10-15 15:36:53.000000000 +0100 -@@ -194,8 +194,8 @@ - - # Default names - ifdef OPENJDK -- LAUNCHER_NAME = openjdk -+ LAUNCHER_NAME = java - PRODUCT_NAME = OpenJDK - PRODUCT_SUFFIX = Runtime Environment - JDK_RC_PLATFORM_NAME = Platform - COMPANY_NAME = N/A --- openjdk/langtools/make/Makefile.orig +++ openjdk/langtools/make/Makefile @@ -82,7 +82,11 @@ @@ -25,3 +12,14 @@ diff -Nru openjdk.orig/jdk/make/common/s endif ifdef BUILD_NUMBER +--- ../openjdk6/jdk/make/common/shared/Defs.gmk 2008-08-28 04:10:47.000000000 -0400 ++++ openjdk/jdk/make/common/shared/Defs.gmk 2009-02-08 08:30:21.000000000 -0500 +@@ -194,7 +194,7 @@ + + # Default names + ifdef OPENJDK +- LAUNCHER_NAME = openjdk ++ LAUNCHER_NAME = java + PRODUCT_NAME = OpenJDK + PRODUCT_SUFFIX = Runtime Environment + JDK_RC_PLATFORM_NAME = Platform From gbenson at redhat.com Sun Feb 8 06:49:10 2009 From: gbenson at redhat.com (Gary Benson) Date: Sun, 8 Feb 2009 06:49:10 -0800 (PST) Subject: Zero build passes TCK Message-ID: <20090208144910.20AED2C434@rexford.dreamhost.com> For the past three months the OpenJDK team at Red Hat has been working on a project to bring the Zero-assembler port of HotSpot to the point where IcedTea builds using Zero are capable of passing the Java SE 6 TCK. As a result of this work I am pleased to announce that the latest OpenJDK packages included in Fedora 10 for 32- and 64-bit PowerPC have passed the Java SE 6 TCK and are compatible with the Java SE 6 platform. This work was funded by Red Hat. From mvfranz at gmail.com Mon Feb 9 16:56:55 2009 From: mvfranz at gmail.com (Michael Franz) Date: Mon, 9 Feb 2009 19:56:55 -0500 Subject: BSD Port and Linux Differences Message-ID: Hi, I am still working through the issues to get the bsd-port repo to compile on Linux and have run into these issues. BSD is using statfs instead of statvfs. Both are available on Linux and OS X. The difference is how they are included. Linux uses either sys/statfs.h or sys/statfs.h while OS X (and I assume other BSDs) are use sys/param.h,sys/mount.h or sys/statvfs.h. See jdk/src/solaris/native/java/io/UnixFileSystem_md.c for more details. Is it better to use one over the other? Do we really want to use statfs on bsd and statvfs on linux? I have run into a similar issue with strncpy vs strlcpy. The bsd port is using strlcpy, as far as I can tell, strlcpy does not exist on linux. Both have strncpy, should this be used instead? This issue exists in jdk/src/solaris/native/java/util/TimeZone_md.c A previous difference that I have found was in the use of machine/endian.h in the BSD port. Thoughts? Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20090209/0d5f61d6/attachment.html From aph at redhat.com Tue Feb 10 02:17:12 2009 From: aph at redhat.com (Andrew Haley) Date: Tue, 10 Feb 2009 10:17:12 +0000 Subject: BSD Port and Linux Differences In-Reply-To: References: Message-ID: <49915428.7090407@redhat.com> Michael Franz wrote: > I am still working through the issues to get the bsd-port repo to > compile on Linux and have run into these issues. > > BSD is using statfs instead of statvfs. Both are available on Linux and > OS X. The difference is how they are included. Linux uses either > sys/statfs.h or sys/statfs.h while OS X (and I assume other BSDs) are > use sys/param.h,sys/mount.h or sys/statvfs.h. See > jdk/src/solaris/native/java/io/UnixFileSystem_md.c for more details. > > Is it better to use one over the other? Do we really want to use statfs > on bsd and statvfs on linux? statvfs is standard POSIX, whereas statfs isn't. The Linux statfs is based on BSD's but it's not the same. We surely should use standard interfaces. > I have run into a similar issue with strncpy vs strlcpy. The bsd port > is using strlcpy, as far as I can tell, strlcpy does not exist on > linux. Both have strncpy, should this be used instead? If it's safe, yes. Assuming the strncpy version is correct, we should use that. > This issue exists in jdk/src/solaris/native/java/util/TimeZone_md.c > > A previous difference that I have found was in the use of > machine/endian.h in the BSD port. Is it really needed? Andrew. From christos at zoulas.com Tue Feb 10 08:00:35 2009 From: christos at zoulas.com (Christos Zoulas) Date: Tue, 10 Feb 2009 11:00:35 -0500 Subject: BSD Port and Linux Differences In-Reply-To: from Michael Franz (Feb 9, 7:56pm) Message-ID: <20090210160035.DCC5D5654E@rebar.astron.com> On Feb 9, 7:56pm, mvfranz at gmail.com (Michael Franz) wrote: -- Subject: BSD Port and Linux Differences | Hi, | | I am still working through the issues to get the bsd-port repo to compile on | Linux and have run into these issues. | | BSD is using statfs instead of statvfs. Both are available on Linux and OS | X. The difference is how they are included. Linux uses either sys/statfs.h | or sys/statfs.h while OS X (and I assume other BSDs) are use | sys/param.h,sys/mount.h or sys/statvfs.h. See | jdk/src/solaris/native/java/io/UnixFileSystem_md.c for more details. NetBSD uses statvfs too. | Is it better to use one over the other? Do we really want to use statfs on | bsd and statvfs on linux? statvfs should be preferred over statfs because: 1. it is part of POSIX: http://www.opengroup.org/onlinepubs/009695399/functions/statvfs.html 2. it is newer and has 64 bit fields where appropriate (in most implementations) I think we need some #ifdef's there to handle which include is appropriate for which OS. | I have run into a similar issue with strncpy vs strlcpy. The bsd port is | using strlcpy, as far as I can tell, strlcpy does not exist on linux. Both | have strncpy, should this be used instead? | | This issue exists in jdk/src/solaris/native/java/util/TimeZone_md.c strl{cpy,cat} should be preferred over strn{cpy,cat}. If that is the only use though, I say put it back to use strncpy() correctly, since java probably uses strn{cpy,cat} all over the place and providing portability just for one use is overkill. | A previous difference that I have found was in the use of machine/endian.h | in the BSD port. This is a more complicated :-) and I will let someone else answer it. christos From gnu_andrew at member.fsf.org Tue Feb 10 11:07:26 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 10 Feb 2009 19:07:26 +0000 Subject: RFC: Only enable NIO2 by default when building with IcedTea Message-ID: <20090210190726.GA13625@rivendell.middle-earth.co.uk> It appears that some older versions of ecj fail when building the NIO2 code: 1. ERROR in ../../../src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java (at line 276) public final WatchKey register(WatchService watcher, WatchEvent.Kind... events) throws IOException ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Name clash: The method register(WatchService, WatchEvent.Kind...) of type AbstractPath has the same erasure as register(WatchService, WatchEvent.Kind...) of type Watchable but does not override it ---------- It looks like this bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=243820 The attached patch sets the NIO2 default based on whether with_icedtea is enabled. So this works, and to be consistent with the rest of the autotools macro, it switches the values used from true/false to yes/no. Okay to commit? ChangeLog: 2009-02-10 Andrew John Hughes * Makefile.am: Only build NIO2 by default if building with IcedTea. Fix with_icedtea/with_openjdk to use yes/no rather than true/false. -- Andrew :) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -------------- next part -------------- diff -r c402774cf211 configure.ac --- a/configure.ac Sun Feb 08 08:33:04 2009 -0500 +++ b/configure.ac Tue Feb 10 18:59:30 2009 +0000 @@ -44,15 +44,15 @@ [ if test "x${withval}" != xno then - with_icedtea=true + with_icedtea=yes else - with_icedtea=false + with_icedtea=no fi ], [ - with_icedtea=false + with_icedtea=no ]) -AM_CONDITIONAL(WITH_ICEDTEA, test "${with_icedtea}" = true) +AM_CONDITIONAL(WITH_ICEDTEA, test "${with_icedtea}" = yes) AC_MSG_RESULT(${with_icedtea}) AC_MSG_CHECKING([whether to build using an existing installation of OpenJDK]) @@ -62,15 +62,15 @@ [ if test "x${withval}" != xno then - with_openjdk=true + with_openjdk=yes else - with_openjdk=false + with_openjdk=no fi ], [ - with_openjdk=false + with_openjdk=no ]) -AM_CONDITIONAL(WITH_OPENJDK, test "${with_openjdk}" = true) +AM_CONDITIONAL(WITH_OPENJDK, test "${with_openjdk}" = yes) AC_MSG_RESULT(${with_openjdk}) AC_MSG_CHECKING(for Ant home directory) @@ -135,7 +135,7 @@ AC_ARG_ENABLE([nio2], [AS_HELP_STRING([--disable-nio2], [Disable inclusion of backported NIO2])], - [ENABLE_XRENDER="${enableval}"], [ENABLE_NIO2='yes']) + [ENABLE_NIO2="${enableval}"], [ENABLE_NIO2="${with_icedtea}"]) AM_CONDITIONAL([ENABLE_NIO2], [test x$ENABLE_NIO2 = xyes]) AC_MSG_RESULT(${ENABLE_NIO2}) @@ -183,7 +183,7 @@ SET_ARCH_DIRS SET_OS_DIRS -if test "${with_openjdk}" = true +if test "${with_openjdk}" = yes then AC_CHECK_FOR_OPENJDK JAVA=$SYSTEM_OPENJDK_DIR/bin/java @@ -197,7 +197,7 @@ RMIC=${SYSTEM_OPENJDK_DIR}/bin/rmic AC_SUBST(RMIC) else -if test "${with_icedtea}" = true +if test "${with_icedtea}" = yes then AC_CHECK_FOR_ICEDTEA JAVA=$SYSTEM_ICEDTEA_DIR/bin/java From mark at klomp.org Tue Feb 10 11:47:33 2009 From: mark at klomp.org (Mark Wielaard) Date: Tue, 10 Feb 2009 20:47:33 +0100 Subject: RFC: Only enable NIO2 by default when building with IcedTea In-Reply-To: <20090210190726.GA13625@rivendell.middle-earth.co.uk> References: <20090210190726.GA13625@rivendell.middle-earth.co.uk> Message-ID: <1234295253.2406.6.camel@fedora.wildebeest.org> Hi Andrew, On Tue, 2009-02-10 at 19:07 +0000, Andrew John Hughes wrote: > It appears that some older versions of ecj fail when building the > NIO2 code: > > 1. ERROR in ../../../src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java (at line 276) > public final WatchKey register(WatchService watcher, WatchEvent.Kind... events) > throws IOException > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > Name clash: The method register(WatchService, WatchEvent.Kind...) of type AbstractPath has the same erasure as register(WatchService, WatchEvent.Kind...) of type Watchable but does not override it > ---------- I can confirm this bug against Eclipse Java Compiler 0.793_R33x, 3.3.2. > The attached patch sets the NIO2 default based on whether with_icedtea is enabled. So this works, > and to be consistent with the rest of the autotools macro, it switches the values used from true/false > to yes/no. > > Okay to commit? > > ChangeLog: > > 2009-02-10 Andrew John Hughes > > * Makefile.am: > Only build NIO2 by default if building with > IcedTea. Fix with_icedtea/with_openjdk to use > yes/no rather than true/false. The attached patch is for configure.ac, not for Makefile.am. I am slightly confused by why this works. Are you counting on the fact that if --with-icedtea is given the provided javac will not be based on ecj and so not have the bug? Wouldn't it be more correct to disable nio2 by default and/or add a compiler configure check to see if these kind of constructs can be compiled? Cheers, Mark From gnu_andrew at member.fsf.org Tue Feb 10 11:50:35 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 10 Feb 2009 19:50:35 +0000 Subject: RFC: Only enable NIO2 by default when building with IcedTea In-Reply-To: <1234295253.2406.6.camel@fedora.wildebeest.org> References: <20090210190726.GA13625@rivendell.middle-earth.co.uk> <1234295253.2406.6.camel@fedora.wildebeest.org> Message-ID: <17c6771e0902101150wa88daa8kbe034f2af929f6bf@mail.gmail.com> 2009/2/10 Mark Wielaard : > Hi Andrew, > > On Tue, 2009-02-10 at 19:07 +0000, Andrew John Hughes wrote: >> It appears that some older versions of ecj fail when building the >> NIO2 code: >> >> 1. ERROR in ../../../src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java (at line 276) >> public final WatchKey register(WatchService watcher, WatchEvent.Kind... events) >> throws IOException >> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ >> Name clash: The method register(WatchService, WatchEvent.Kind...) of type AbstractPath has the same erasure as register(WatchService, WatchEvent.Kind...) of type Watchable but does not override it >> ---------- > > I can confirm this bug against Eclipse Java Compiler 0.793_R33x, 3.3.2. > >> The attached patch sets the NIO2 default based on whether with_icedtea is enabled. So this works, >> and to be consistent with the rest of the autotools macro, it switches the values used from true/false >> to yes/no. >> >> Okay to commit? >> >> ChangeLog: >> >> 2009-02-10 Andrew John Hughes >> >> * Makefile.am: >> Only build NIO2 by default if building with >> IcedTea. Fix with_icedtea/with_openjdk to use >> yes/no rather than true/false. > > The attached patch is for configure.ac, not for Makefile.am. > I am slightly confused by why this works. > Are you counting on the fact that if --with-icedtea is given the > provided javac will not be based on ecj and so not have the bug? --with-icedtea uses ICEDTEA_HOME/bin/javac so yeah but... > Wouldn't it be more correct to disable nio2 by default and/or add a > compiler configure check to see if these kind of constructs can be > compiled? ...I'd prefer this. But given I can't duplicate this myself, someone else needs to write the test... ;) > > Cheers, > > Mark > > -- Andrew :-) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint: F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From gnu_andrew at member.fsf.org Tue Feb 10 12:53:30 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Tue, 10 Feb 2009 20:53:30 +0000 Subject: [IcedTea7] FYI: Bump to b46 Message-ID: <20090210205330.GA10325@rivendell.middle-earth.co.uk> This adds support to IcedTea7 for the new build drop, b46. A number of patches were dropped: directaudio-close-trick: Is applied but unlisted in http://download.java.net/jdk7/changes/jdk7-b46.html enum-bug-181: Fixed by S6736248 jsoundhs, sound: Fixed by S6702956 and related patches (replacement of jsoundhs with Gervill) There is still no support for IMPORT_BINARY_PLUGS=false however; SNMP still seems to be required. 2009-02-10 Andrew John Hughes Bump to b46. * patches/icedtea-directaudio-close-trick.patch, * patches/icedtea-enum-bug-181.patch, * patches/icedtea-jsoundhs.patch, * patches/icedtea-sound.patch: Applied upstream. * HACKING, * Makefile.am: Updated. * patches/ecj/icedtea.patch: Recreated due to S6795030. * patches/icedtea-copy-plugs.patch: Recreated due to S6702956. -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -------------- next part -------------- diff -r 5a2104fb2256 HACKING --- a/HACKING Wed Feb 04 11:49:31 2009 +0000 +++ b/HACKING Tue Feb 10 20:30:15 2009 +0000 @@ -24,7 +24,6 @@ * icedtea-core-build.patch: Add support for building IcedTea core VM. * icedtea-debuginfo.patch: Add -g option to build to generate debugging information. * icedtea-demos.patch: Fix building of JVMTI demo. -* icedtea-enum-bug-181.patch: Fixes class type check (PR181/S6736248) * icedtea-float-double-trailing-zeros.patch: Remove trailing zeros from Double/Float (PR29/30) * icedtea-fonts.patch: Add Fedora fontconfig. * icedtea-gcc-suffix.patch: Append $(GCC_SUFFIX) to end of 'gcc' binary name. @@ -86,6 +85,7 @@ * icedtea-corba.patch: Adds additional files to org.omg.CORBA Makefile. * icedtea-display-mode-changer.patch: Add extra test class. (applied in OpenJDK7 b43) +* icedtea-enum-bug-181.patch: Fixes class type check (PR181/S6736248) * icedtea-gcc-4.3.patch: Fix code to compile with GCC 4.3 and turn off -Werror. * icedtea-generated.patch: Force use of /bin/bash. * icedtea-nomotif.patch: Remove sanity and GrabShell.h dependency on Motif/Lesstif library. @@ -105,15 +105,12 @@ * icedtea-constructor-properties.patch: Explicitly cast to ConstructorProperties as getAnnotation is broken in libgcj 4.3. -* icedtea-jsoundhs.patch: Remove attempted build of proprietary jsoundhs library. * icedtea-mbeanintrospector.patch: Explicitly cast to Description as getAnnotation is broken in libgcj 4.3. * icedtea-override.patch: Remove @Override annotation in javax.management.AttributeValueExp (unsupported by ecj < 3.4). * icedtea-snmp.patch: Remove proprietary SNMP support hooks. * icedtea-sound.patch: Remove proprietary MIDI support hooks. -* icedtea-fortify-source.patch: Fix build failures with -D_FORTIFY_SOURCE=2. -* icedtea-format-warnings.patch: Fix build failures with -Wformat=1. The following patches are only applied to the icedtea-ecj bootstrap tree: diff -r 5a2104fb2256 Makefile.am --- a/Makefile.am Wed Feb 04 11:49:31 2009 +0000 +++ b/Makefile.am Tue Feb 10 20:30:15 2009 +0000 @@ -1,6 +1,6 @@ -OPENJDK_DATE = 29_jan_2009 -OPENJDK_MD5SUM = 0d6ae1ed77b470c9665d069b34a1bc88 -OPENJDK_VERSION = b45 +OPENJDK_DATE = 05_feb_2009 +OPENJDK_MD5SUM = d5f92fec2f645d44437ab90e1dd2dbaf +OPENJDK_VERSION = b46 CACAO_VERSION = 0.99.3 CACAO_MD5SUM = 80de3ad344c1a20c086ec5f1390bd1b8 @@ -1845,7 +1845,6 @@ patches/icedtea-uname.patch \ patches/icedtea-ia64-fdlibm.patch \ patches/icedtea-fonts.patch \ - patches/icedtea-directaudio-close-trick.patch \ patches/hotspot/$(HSBUILD)/icedtea-sparc-ptracefix.patch \ patches/hotspot/$(HSBUILD)/icedtea-sparc-trapsfix.patch \ patches/icedtea-override-redirect-metacity.patch \ @@ -1854,13 +1853,11 @@ patches/hotspot/$(HSBUILD)/icedtea-shark-build.patch \ patches/icedtea-toolkit.patch \ patches/icedtea-security-updates.patch \ - patches/icedtea-jsoundhs.patch \ patches/icedtea-jdk-docs-target.patch \ patches/icedtea-mbeanintrospector.patch \ patches/icedtea-hotspot-gcc-pr36917.patch \ patches/icedtea-alpha-fixes.patch \ patches/icedtea-alt-jar.patch \ - patches/icedtea-enum-bug-181.patch \ patches/icedtea-jdk-use-ssize_t.patch \ patches/hotspot/$(HSBUILD)/icedtea-use-idx_t.patch \ patches/hotspot/$(HSBUILD)/icedtea-params-cast-size_t.patch \ @@ -1876,7 +1873,6 @@ patches/icedtea-xjc.patch \ patches/icedtea-renderer-crossing.patch \ patches/icedtea-snmp.patch \ - patches/icedtea-sound.patch \ patches/icedtea-tests-jdk.patch \ patches/icedtea-stroker-finish.patch \ patches/icedtea-alsa-default-device.patch \ diff -r 5a2104fb2256 patches/ecj/icedtea.patch --- a/patches/ecj/icedtea.patch Wed Feb 04 11:49:31 2009 +0000 +++ b/patches/ecj/icedtea.patch Tue Feb 10 20:30:15 2009 +0000 @@ -1,6 +1,6 @@ diff -Nru openjdk-ecj.orig/corba/make/com/sun/corba/se/Makefile openjdk-ecj/corba/make/com/sun/corba/se/Makefile ---- openjdk-ecj.orig/corba/make/com/sun/corba/se/Makefile 2008-10-09 08:41:14.000000000 +0100 -+++ openjdk-ecj/corba/make/com/sun/corba/se/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/com/sun/corba/se/Makefile 2009-02-05 08:40:51.000000000 +0000 ++++ openjdk-ecj/corba/make/com/sun/corba/se/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -42,7 +42,7 @@ # the rmic iiop backend needs some classes that are part of the impl/util # package. These classes use log wrappers, so they must be built after @@ -12,7 +12,7 @@ diff -Nru openjdk-ecj.orig/corba/make/com/sun/corba/se/org/Makefile openjdk-ecj/corba/make/com/sun/corba/se/org/Makefile --- openjdk-ecj.orig/corba/make/com/sun/corba/se/org/Makefile 1970-01-01 01:00:00.000000000 +0100 -+++ openjdk-ecj/corba/make/com/sun/corba/se/org/Makefile 2008-10-24 13:32:48.000000000 +0100 ++++ openjdk-ecj/corba/make/com/sun/corba/se/org/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -0,0 +1,38 @@ +# +# Copyright 2001-2005 Sun Microsystems, Inc. All Rights Reserved. @@ -53,8 +53,8 @@ +# +include $(BUILDDIR)/common/Classes.gmk diff -Nru openjdk-ecj.orig/corba/make/common/Defs.gmk openjdk-ecj/corba/make/common/Defs.gmk ---- openjdk-ecj.orig/corba/make/common/Defs.gmk 2008-10-09 08:41:14.000000000 +0100 -+++ openjdk-ecj/corba/make/common/Defs.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/common/Defs.gmk 2009-02-05 08:40:51.000000000 +0000 ++++ openjdk-ecj/corba/make/common/Defs.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -53,6 +53,13 @@ _OUTPUTDIR=$(TOPDIR)/build/$(PLATFORM)-$(ARCH) @@ -88,8 +88,8 @@ vpath %.java $(VPATH.java) vpath %.class $(CLASSBINDIR) diff -Nru openjdk-ecj.orig/corba/make/common/Defs-linux.gmk openjdk-ecj/corba/make/common/Defs-linux.gmk ---- openjdk-ecj.orig/corba/make/common/Defs-linux.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/corba/make/common/Defs-linux.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/common/Defs-linux.gmk 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/corba/make/common/Defs-linux.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -276,7 +276,7 @@ fi; \ done) @@ -100,8 +100,8 @@ # # We want to privatize JVM symbols on Solaris. This is so the user can diff -Nru openjdk-ecj.orig/corba/make/common/Rules.gmk openjdk-ecj/corba/make/common/Rules.gmk ---- openjdk-ecj.orig/corba/make/common/Rules.gmk 2008-10-09 08:41:14.000000000 +0100 -+++ openjdk-ecj/corba/make/common/Rules.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/common/Rules.gmk 2009-02-05 08:40:51.000000000 +0000 ++++ openjdk-ecj/corba/make/common/Rules.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -197,8 +197,10 @@ $(ECHO) "# Java sources to be compiled: (listed in file $(JAVA_SOURCE_LIST))"; \ $(CAT) $(JAVA_SOURCE_LIST); \ @@ -116,8 +116,8 @@ @$(java-vm-cleanup) diff -Nru openjdk-ecj.orig/corba/make/common/shared/Defs-java.gmk openjdk-ecj/corba/make/common/shared/Defs-java.gmk ---- openjdk-ecj.orig/corba/make/common/shared/Defs-java.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/corba/make/common/shared/Defs-java.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/common/shared/Defs-java.gmk 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/corba/make/common/shared/Defs-java.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -110,31 +110,13 @@ JAVACFLAGS += $(OTHER_JAVACFLAGS) @@ -155,8 +155,8 @@ # Override of what javac to use (see deploy workspace) ifdef JAVAC diff -Nru openjdk-ecj.orig/corba/make/org/omg/sources/Makefile openjdk-ecj/corba/make/org/omg/sources/Makefile ---- openjdk-ecj.orig/corba/make/org/omg/sources/Makefile 2008-10-09 08:41:14.000000000 +0100 -+++ openjdk-ecj/corba/make/org/omg/sources/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/org/omg/sources/Makefile 2009-02-05 08:40:51.000000000 +0000 ++++ openjdk-ecj/corba/make/org/omg/sources/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -93,8 +93,6 @@ POAHELHOLFILES = $(POA_GENERATED_HELP_HOL_java:%=$(GENSRCDIR)/%) @@ -234,8 +234,8 @@ pi.compile: $(PIGENERATEDFILES) diff -Nru openjdk-ecj.orig/corba/make/sun/rmi/corbalogsources/Makefile openjdk-ecj/corba/make/sun/rmi/corbalogsources/Makefile ---- openjdk-ecj.orig/corba/make/sun/rmi/corbalogsources/Makefile 2008-10-24 10:16:05.000000000 +0100 -+++ openjdk-ecj/corba/make/sun/rmi/corbalogsources/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/sun/rmi/corbalogsources/Makefile 2009-02-10 18:11:57.000000000 +0000 ++++ openjdk-ecj/corba/make/sun/rmi/corbalogsources/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -172,7 +172,6 @@ ACTIVATIONFILES = $(com_sun_corba_se_spi_activation_java:%=$(GENSRCDIR)/%) @@ -253,8 +253,8 @@ portableactivation.idl.compile: $(PORTABLEACTIVATIONFILES) diff -Nru openjdk-ecj.orig/jaxp/make/build.xml openjdk-ecj/jaxp/make/build.xml ---- openjdk-ecj.orig/jaxp/make/build.xml 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxp/make/build.xml 2008-10-24 13:33:43.000000000 +0100 +--- openjdk-ecj.orig/jaxp/make/build.xml 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxp/make/build.xml 2009-02-10 19:24:54.000000000 +0000 @@ -71,7 +71,10 @@ diff -Nru openjdk-ecj.orig/jaxp/make/Makefile openjdk-ecj/jaxp/make/Makefile ---- openjdk-ecj.orig/jaxp/make/Makefile 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxp/make/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jaxp/make/Makefile 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxp/make/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -75,7 +75,7 @@ endif @@ -289,8 +289,8 @@ ifdef ALT_OUTPUTDIR diff -Nru openjdk-ecj.orig/jaxws/make/build.properties openjdk-ecj/jaxws/make/build.properties ---- openjdk-ecj.orig/jaxws/make/build.properties 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxws/make/build.properties 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jaxws/make/build.properties 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxws/make/build.properties 2009-02-10 19:24:54.000000000 +0000 @@ -37,7 +37,7 @@ # set the following to -version to verify the versions of javac being used javac.version.opt = @@ -301,8 +301,8 @@ # JVM memory size javac.memoryInitialSize = 128m diff -Nru openjdk-ecj.orig/jaxws/make/build.xml openjdk-ecj/jaxws/make/build.xml ---- openjdk-ecj.orig/jaxws/make/build.xml 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxws/make/build.xml 2008-10-24 13:34:37.000000000 +0100 +--- openjdk-ecj.orig/jaxws/make/build.xml 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxws/make/build.xml 2009-02-10 19:24:54.000000000 +0000 @@ -84,7 +84,10 @@ diff -Nru openjdk-ecj.orig/jaxws/make/Makefile openjdk-ecj/jaxws/make/Makefile ---- openjdk-ecj.orig/jaxws/make/Makefile 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxws/make/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jaxws/make/Makefile 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxws/make/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -75,8 +75,8 @@ endif @@ -347,8 +347,8 @@ ifdef ALT_OUTPUTDIR diff -Nru openjdk-ecj.orig/jdk/make/common/BuildToolJar.gmk openjdk-ecj/jdk/make/common/BuildToolJar.gmk ---- openjdk-ecj.orig/jdk/make/common/BuildToolJar.gmk 2008-10-09 08:45:42.000000000 +0100 -+++ openjdk-ecj/jdk/make/common/BuildToolJar.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/common/BuildToolJar.gmk 2009-02-05 08:44:12.000000000 +0000 ++++ openjdk-ecj/jdk/make/common/BuildToolJar.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -43,7 +43,8 @@ @$(prep-target) @$(MKDIR) -p $(BUILDTOOLCLASSDIR) @@ -360,8 +360,8 @@ -C $(BUILDTOOLCLASSDIR) $(PKGDIR) \ $(BOOT_JAR_JFLAGS) || $(RM) $@ diff -Nru openjdk-ecj.orig/jdk/make/common/Release.gmk openjdk-ecj/jdk/make/common/Release.gmk ---- openjdk-ecj.orig/jdk/make/common/Release.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jdk/make/common/Release.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/common/Release.gmk 2009-02-10 18:12:01.000000000 +0000 ++++ openjdk-ecj/jdk/make/common/Release.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -651,10 +651,23 @@ $(RES_JAR_ARGLIST): $(RES_JAR_FILELIST) $(prep-target) @@ -409,7 +409,7 @@ @$(java-vm-cleanup) # Meta-index construction to make core class loaders lazier -@@ -951,19 +972,6 @@ +@@ -944,19 +965,6 @@ @$(java-vm-cleanup) $(CP) $(LIBDIR)/tools.jar $(JDK_IMAGE_DIR)/lib/tools.jar @# @@ -429,7 +429,7 @@ @# CORBA supported orb.idl and ir.idl should be copied to lib @# $(CP) $(LIBDIR)/orb.idl $(JDK_IMAGE_DIR)/lib/orb.idl -@@ -1040,16 +1048,6 @@ +@@ -1033,16 +1041,6 @@ $(CP) $(PLATFORM_SRC)/bin/java_md.h $(JDK_IMAGE_DIR)/src/launcher $(CD) $(JDK_IMAGE_DIR)/src && $(ZIPEXE) -qr ../src.zip * $(RM) -r $(JDK_IMAGE_DIR)/src @@ -447,8 +447,8 @@ $(call copy-man-pages,$(JDK_IMAGE_DIR),$(JDK_MAN_PAGES)) endif # !windows diff -Nru openjdk-ecj.orig/jdk/make/common/Rules.gmk openjdk-ecj/jdk/make/common/Rules.gmk ---- openjdk-ecj.orig/jdk/make/common/Rules.gmk 2008-10-09 08:45:42.000000000 +0100 -+++ openjdk-ecj/jdk/make/common/Rules.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/common/Rules.gmk 2009-02-05 08:44:12.000000000 +0000 ++++ openjdk-ecj/jdk/make/common/Rules.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -237,8 +237,9 @@ $(ECHO) "# Java sources to be compiled: (listed in file $<)"; \ $(CAT) $<.filtered; \ @@ -475,8 +475,8 @@ @$(TOUCH) $@ diff -Nru openjdk-ecj.orig/jdk/make/common/shared/Defs-java.gmk openjdk-ecj/jdk/make/common/shared/Defs-java.gmk ---- openjdk-ecj.orig/jdk/make/common/shared/Defs-java.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jdk/make/common/shared/Defs-java.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/common/shared/Defs-java.gmk 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jdk/make/common/shared/Defs-java.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -121,30 +121,19 @@ JAVACFLAGS += $(OTHER_JAVACFLAGS) @@ -510,8 +510,8 @@ # Override of what javac to use (see deploy workspace) diff -Nru openjdk-ecj.orig/jdk/make/java/nio/Makefile openjdk-ecj/jdk/make/java/nio/Makefile ---- openjdk-ecj.orig/jdk/make/java/nio/Makefile 2008-10-09 08:45:42.000000000 +0100 -+++ openjdk-ecj/jdk/make/java/nio/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/java/nio/Makefile 2009-02-05 08:44:13.000000000 +0000 ++++ openjdk-ecj/jdk/make/java/nio/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -31,7 +31,7 @@ PACKAGE = java.nio LIBRARY = nio @@ -522,8 +522,8 @@ NIO_SRC = $(SHARE_SRC)/classes/java/nio diff -Nru openjdk-ecj.orig/jdk/make/java/text/Makefile openjdk-ecj/jdk/make/java/text/Makefile ---- openjdk-ecj.orig/jdk/make/java/text/Makefile 2008-10-09 08:45:42.000000000 +0100 -+++ openjdk-ecj/jdk/make/java/text/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/java/text/Makefile 2009-02-05 08:44:13.000000000 +0000 ++++ openjdk-ecj/jdk/make/java/text/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -80,8 +80,8 @@ -sourcepath $(TEXT_SRCDIR) \ $(TEXT_SOURCES) @@ -536,8 +536,8 @@ -spec $(UNICODEDATA)/UnicodeData.txt @$(java-vm-cleanup) diff -Nru openjdk-ecj.orig/jdk/make/Makefile openjdk-ecj/jdk/make/Makefile ---- openjdk-ecj.orig/jdk/make/Makefile 2008-10-09 08:45:41.000000000 +0100 -+++ openjdk-ecj/jdk/make/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/Makefile 2009-02-05 08:44:12.000000000 +0000 ++++ openjdk-ecj/jdk/make/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -239,7 +239,7 @@ all build:: sanity-all post-sanity-all @@ -548,8 +548,8 @@ $(SUBDIRS-loop) diff -Nru openjdk-ecj.orig/jdk/make/sun/awt/FILES_export_unix.gmk openjdk-ecj/jdk/make/sun/awt/FILES_export_unix.gmk ---- openjdk-ecj.orig/jdk/make/sun/awt/FILES_export_unix.gmk 2008-10-09 08:45:43.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/awt/FILES_export_unix.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/awt/FILES_export_unix.gmk 2009-02-05 08:44:14.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/awt/FILES_export_unix.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -188,3 +188,5 @@ java/awt/dnd/DnDConstants.java \ sun/awt/CausedFocusEvent.java @@ -557,8 +557,8 @@ +EXPORTED_inner = \ + sun.java2d.opengl.OGLContext$$OGLContextCaps diff -Nru openjdk-ecj.orig/jdk/make/sun/awt/Makefile openjdk-ecj/jdk/make/sun/awt/Makefile ---- openjdk-ecj.orig/jdk/make/sun/awt/Makefile 2008-10-09 08:45:43.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/awt/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/awt/Makefile 2009-02-05 08:44:14.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/awt/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -395,10 +395,9 @@ COMPILEFONTCONFIG_JARFILE = $(BUILDTOOLJARDIR)/compilefontconfig.jar @@ -574,8 +574,8 @@ fontconfigs.clean : diff -Nru openjdk-ecj.orig/jdk/make/sun/javazic/Makefile openjdk-ecj/jdk/make/sun/javazic/Makefile ---- openjdk-ecj.orig/jdk/make/sun/javazic/Makefile 2008-10-09 08:45:43.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/javazic/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/javazic/Makefile 2009-02-05 08:44:14.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/javazic/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -62,7 +62,8 @@ $(WORKDIR)/$(MAPFILE): $(BUILDTOOLJARDIR)/javazic.jar $(TZFILES) $(RM) -r $(@D) @@ -587,8 +587,8 @@ $(INSTALLDIR)/$(MAPFILE): $(WORKDIR)/$(MAPFILE) diff -Nru openjdk-ecj.orig/jdk/make/sun/text/Makefile openjdk-ecj/jdk/make/sun/text/Makefile ---- openjdk-ecj.orig/jdk/make/sun/text/Makefile 2008-10-09 08:45:44.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/text/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/text/Makefile 2009-02-05 08:44:14.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/text/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -85,8 +85,9 @@ $(BOOT_JAVAC_CMD) -d $(TEXT_CLASSES) \ -sourcepath $(TEXT_SRCDIR) \ @@ -602,8 +602,8 @@ -spec $(UNICODEDATA)/UnicodeData.txt \ -language th diff -Nru openjdk-ecj.orig/jdk/make/sun/xawt/Makefile openjdk-ecj/jdk/make/sun/xawt/Makefile ---- openjdk-ecj.orig/jdk/make/sun/xawt/Makefile 2008-10-09 08:45:44.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/xawt/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/xawt/Makefile 2009-02-10 18:12:01.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/xawt/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -276,11 +276,7 @@ TEMPDIR_CLASSES = $(TEMPDIR)/classes @@ -641,8 +641,8 @@ done $(TOUCH) $@ diff -Nru openjdk-ecj.orig/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java openjdk-ecj/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java ---- openjdk-ecj.orig/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java 2008-10-24 10:16:45.000000000 +0100 -+++ openjdk-ecj/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java 2009-02-10 18:11:22.000000000 +0000 ++++ openjdk-ecj/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java 2009-02-10 19:24:54.000000000 +0000 @@ -647,9 +647,6 @@ throws FileNotFoundException, IOException { BufferedReader in = new BufferedReader(new FileReader(theTemplateFileName)); @@ -662,8 +662,8 @@ if (plane == 0 && bLatin1 == false) { genCaseMapTableDeclaration(result); diff -Nru openjdk-ecj.orig/jdk/src/share/classes/java/lang/Double.java openjdk-ecj/jdk/src/share/classes/java/lang/Double.java ---- openjdk-ecj.orig/jdk/src/share/classes/java/lang/Double.java 2008-10-24 10:16:33.000000000 +0100 -+++ openjdk-ecj/jdk/src/share/classes/java/lang/Double.java 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/src/share/classes/java/lang/Double.java 2009-02-10 18:11:12.000000000 +0000 ++++ openjdk-ecj/jdk/src/share/classes/java/lang/Double.java 2009-02-10 19:24:54.000000000 +0000 @@ -76,7 +76,7 @@ * {@code 0x1.fffffffffffffP+1023} and also equal to * {@code Double.longBitsToDouble(0x7fefffffffffffffL)}. @@ -692,8 +692,8 @@ /** * Maximum exponent a finite {@code double} variable may have. diff -Nru openjdk-ecj.orig/jdk/src/share/classes/java/lang/Float.java openjdk-ecj/jdk/src/share/classes/java/lang/Float.java ---- openjdk-ecj.orig/jdk/src/share/classes/java/lang/Float.java 2008-10-24 10:16:33.000000000 +0100 -+++ openjdk-ecj/jdk/src/share/classes/java/lang/Float.java 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/src/share/classes/java/lang/Float.java 2009-02-10 18:11:12.000000000 +0000 ++++ openjdk-ecj/jdk/src/share/classes/java/lang/Float.java 2009-02-10 19:24:54.000000000 +0000 @@ -76,7 +76,7 @@ * {@code 0x1.fffffeP+127f} and also equal to * {@code Float.intBitsToFloat(0x7f7fffff)}. @@ -722,8 +722,8 @@ /** * Maximum exponent a finite {@code float} variable may have. It diff -Nru openjdk-ecj.orig/jdk/src/share/native/sun/java2d/opengl/OGLContext.h openjdk-ecj/jdk/src/share/native/sun/java2d/opengl/OGLContext.h ---- openjdk-ecj.orig/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2008-10-09 08:46:24.000000000 +0100 -+++ openjdk-ecj/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2009-02-05 08:44:52.000000000 +0000 ++++ openjdk-ecj/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2009-02-10 19:24:54.000000000 +0000 @@ -27,6 +27,7 @@ #define OGLContext_h_Included @@ -789,49 +789,44 @@ /** * Evaluates to true if the given capability bitmask is present for the diff -Nru openjdk-ecj.orig/langtools/make/build.xml openjdk-ecj/langtools/make/build.xml ---- openjdk-ecj.orig/langtools/make/build.xml 2008-10-09 08:47:11.000000000 +0100 -+++ openjdk-ecj/langtools/make/build.xml 2008-10-24 13:32:48.000000000 +0100 -@@ -498,7 +498,10 @@ +--- openjdk-ecj.orig/langtools/make/build.xml 2009-02-05 08:45:36.000000000 +0000 ++++ openjdk-ecj/langtools/make/build.xml 2009-02-10 19:56:00.000000000 +0000 +@@ -502,7 +502,9 @@ includes="@{includes}" sourcepath="" includeAntRuntime="no" - target="@{javac.target}"> + target="@{javac.target}" -+ executable="${javac.executable}" + source="1.5"> + -@@ -512,7 +515,10 @@ +@@ -517,7 +519,9 @@ includeAntRuntime="no" target="@{javac.target}" debug="${javac.debug}" - debuglevel="${javac.debuglevel}"> -+ executable="${javac.executable}" + debuglevel="${javac.debuglevel}" + source="1.5"> + -@@ -563,8 +569,11 @@ - - - + classpath="${ant.home}/lib/ant.jar" -+ executable="${javac.executable}" -+ source="1.5"/> ++ source="1.5" /> diff -Nru openjdk-ecj.orig/langtools/make/Makefile openjdk-ecj/langtools/make/Makefile ---- openjdk-ecj.orig/langtools/make/Makefile 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/langtools/make/Makefile 2008-10-24 13:32:48.000000000 +0100 -@@ -108,7 +108,7 @@ +--- openjdk-ecj.orig/langtools/make/Makefile 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/langtools/make/Makefile 2009-02-10 19:24:54.000000000 +0000 +@@ -112,7 +112,7 @@ ifdef ALT_BOOTDIR ANT_OPTIONS += -Dboot.java.home=$(ALT_BOOTDIR) @@ -841,8 +836,8 @@ ifdef ALT_OUTPUTDIR diff -Nru openjdk-ecj.orig/make/jdk-rules.gmk openjdk-ecj/make/jdk-rules.gmk ---- openjdk-ecj.orig/make/jdk-rules.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/make/jdk-rules.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/make/jdk-rules.gmk 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/make/jdk-rules.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -58,7 +58,7 @@ endif diff -r 5a2104fb2256 patches/icedtea-copy-plugs.patch --- a/patches/icedtea-copy-plugs.patch Wed Feb 04 11:49:31 2009 +0000 +++ b/patches/icedtea-copy-plugs.patch Tue Feb 10 20:30:15 2009 +0000 @@ -1,7 +1,7 @@ diff -Nru openjdk.orig/jdk/make/common/internal/BinaryPlugs.gmk openjdk/jdk/make/common/internal/BinaryPlugs.gmk ---- openjdk.orig/jdk/make/common/internal/BinaryPlugs.gmk 2008-08-14 08:42:49.000000000 +0100 -+++ openjdk/jdk/make/common/internal/BinaryPlugs.gmk 2008-08-20 22:56:55.000000000 +0100 -@@ -147,6 +147,21 @@ +--- openjdk.orig/jdk/make/common/internal/BinaryPlugs.gmk 2009-02-05 08:44:12.000000000 +0000 ++++ openjdk/jdk/make/common/internal/BinaryPlugs.gmk 2009-02-10 15:49:40.000000000 +0000 +@@ -93,11 +93,32 @@ @for i in $(PLUG_JMF_CLASS_NAMES) ; do \ $(ECHO) "$$i" >> $@; \ done @@ -20,12 +20,10 @@ + @for i in $(PLUG_NETX_CLASS_NAMES) ; do \ + $(ECHO) "$$i" >> $@ ; \ + done - $(PLUG_TEMPDIR)/sound.clist: + $(PLUG_TEMPDIR)/all.clist: $(PLUG_CLISTS) @$(prep-target) - @for i in $(PLUG_SOUND_CLASS_NAMES) ; do \ -@@ -159,6 +174,12 @@ - $(plug-create-jargs) - $(PLUG_TEMPDIR)/sound.jargs: $(PLUG_TEMPDIR)/sound.clist + $(CAT) $(PLUG_CLISTS) > $@ + $(PLUG_TEMPDIR)/jmf.jargs: $(PLUG_TEMPDIR)/jmf.clist $(plug-create-jargs) +$(PLUG_TEMPDIR)/gnu.jargs: $(PLUG_TEMPDIR)/gnu.clist + $(plug-create-jargs) @@ -36,7 +34,7 @@ $(PLUG_TEMPDIR)/all.jargs: $(PLUG_TEMPDIR)/all.clist $(plug-create-jargs) -@@ -183,9 +204,9 @@ +@@ -122,9 +143,9 @@ # Import classes command define import-binary-plug-classes @@ -49,9 +47,9 @@ endef # import-binary-plug-classes diff -Nru openjdk.orig/jdk/src/share/classes/java/beans/MetaData.java openjdk/jdk/src/share/classes/java/beans/MetaData.java ---- openjdk.orig/jdk/src/share/classes/java/beans/MetaData.java 2008-08-14 08:43:00.000000000 +0100 -+++ openjdk/jdk/src/share/classes/java/beans/MetaData.java 2008-08-20 22:55:35.000000000 +0100 -@@ -1463,7 +1463,7 @@ +--- openjdk.orig/jdk/src/share/classes/java/beans/MetaData.java 2009-02-10 02:25:40.000000000 +0000 ++++ openjdk/jdk/src/share/classes/java/beans/MetaData.java 2009-02-10 15:45:15.000000000 +0000 +@@ -1475,7 +1475,7 @@ } private static String[] getAnnotationValue(Constructor constructor) { diff -r 5a2104fb2256 patches/icedtea-directaudio-close-trick.patch --- a/patches/icedtea-directaudio-close-trick.patch Wed Feb 04 11:49:31 2009 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,193 +0,0 @@ ---- /home/mark/src/openjdk/jdk/src/share/classes/com/sun/media/sound/DirectAudioDevice.java 2008-04-13 01:05:30.000000000 +0200 -+++ openjdk/jdk/src/share/classes/com/sun/media/sound/DirectAudioDevice.java 2008-05-09 02:18:21.000000000 +0200 -@@ -394,7 +394,12 @@ - private float leftGain, rightGain; - protected volatile boolean noService = false; // do not run the nService method - -+ // Guards all native calls. - protected Object lockNative = new Object(); -+ // Guards the lastOpened static variable in implOpen and implClose. -+ protected static Object lockLast = new Object(); -+ // Keeps track of last opened line, see implOpen "trick". -+ protected static DirectDL lastOpened; - - // CONSTRUCTOR - protected DirectDL(DataLine.Info info, -@@ -496,20 +501,47 @@ - // align buffer to full frames - bufferSize = ((int) bufferSize / format.getFrameSize()) * format.getFrameSize(); - -- id = nOpen(mixerIndex, deviceID, isSource, -- encoding, -- hardwareFormat.getSampleRate(), -- hardwareFormat.getSampleSizeInBits(), -- hardwareFormat.getFrameSize(), -- hardwareFormat.getChannels(), -- hardwareFormat.getEncoding().equals(AudioFormat.Encoding.PCM_SIGNED), -- hardwareFormat.isBigEndian(), -- bufferSize); -+ synchronized(lockLast) { -+ id = nOpen(mixerIndex, deviceID, isSource, -+ encoding, -+ hardwareFormat.getSampleRate(), -+ hardwareFormat.getSampleSizeInBits(), -+ hardwareFormat.getFrameSize(), -+ hardwareFormat.getChannels(), -+ hardwareFormat.getEncoding().equals(AudioFormat.Encoding.PCM_SIGNED), -+ hardwareFormat.isBigEndian(), -+ bufferSize); -+ -+ if (id == 0) { -+ // Bah... Dirty trick. The most likely cause is an application -+ // already having a line open for this particular hardware -+ // format and forgetting about it. If so, silently close that -+ // implementation and try again. Unfortuantely we can only -+ // open one line per hardware format currently. -+ if (lastOpened != null -+ && hardwareFormat.matches(lastOpened.hardwareFormat)) { -+ lastOpened.implClose(); -+ lastOpened = null; -+ -+ id = nOpen(mixerIndex, deviceID, isSource, -+ encoding, -+ hardwareFormat.getSampleRate(), -+ hardwareFormat.getSampleSizeInBits(), -+ hardwareFormat.getFrameSize(), -+ hardwareFormat.getChannels(), -+ hardwareFormat.getEncoding().equals(AudioFormat.Encoding.PCM_SIGNED), -+ hardwareFormat.isBigEndian(), -+ bufferSize); -+ } -+ -+ if (id == 0) { -+ // TODO: nicer error messages... -+ throw new LineUnavailableException("line with format "+format+" not supported."); -+ } -+ } -+ lastOpened = this; -+ } - -- if (id == 0) { -- // TODO: nicer error messages... -- throw new LineUnavailableException("line with format "+format+" not supported."); -- } - this.bufferSize = nGetBufferSize(id, isSource); - if (this.bufferSize < 1) { - // this is an error! -@@ -580,12 +612,12 @@ - } - synchronized (lockNative) { - nStop(id, isSource); -- } - -- // need to set doIO to false before notifying the -- // read/write thread, that's why isStartedRunning() -- // cannot be used -- doIO = false; -+ // need to set doIO to false before notifying the -+ // read/write thread, that's why isStartedRunning() -+ // cannot be used -+ doIO = false; -+ } - // wake up any waiting threads - synchronized(lock) { - lock.notifyAll(); -@@ -614,8 +646,12 @@ - doIO = false; - long oldID = id; - id = 0; -- synchronized (lockNative) { -- nClose(oldID, isSource); -+ synchronized (lockLast) { -+ synchronized (lockNative) { -+ nClose(oldID, isSource); -+ if (lastOpened == this) -+ lastOpened = null; -+ } - } - bytePosition = 0; - softwareConversionSize = 0; -@@ -630,7 +666,8 @@ - } - int a = 0; - synchronized (lockNative) { -- a = nAvailable(id, isSource); -+ if (doIO) -+ a = nAvailable(id, isSource); - } - return a; - } -@@ -644,9 +681,9 @@ - int counter = 0; - long startPos = getLongFramePosition(); - boolean posChanged = false; -- while (!drained && doIO) { -+ while (!drained) { - synchronized (lockNative) { -- if ((id == 0) || !nIsStillDraining(id, isSource)) -+ if ((id == 0) || (!doIO) || !nIsStillDraining(id, isSource)) - break; - } - // check every now and then for a new position -@@ -686,7 +723,7 @@ - lock.notifyAll(); - } - synchronized (lockNative) { -- if (id != 0) { -+ if (id != 0 && doIO) { - // then flush native buffers - nFlush(id, isSource); - } -@@ -697,9 +734,10 @@ - - // replacement for getFramePosition (see AbstractDataLine) - public long getLongFramePosition() { -- long pos; -+ long pos = 0; - synchronized (lockNative) { -- pos = nGetBytePosition(id, isSource, bytePosition); -+ if (doIO) -+ pos = nGetBytePosition(id, isSource, bytePosition); - } - // hack because ALSA sometimes reports wrong framepos - if (pos < 0) { -@@ -745,11 +783,12 @@ - } - int written = 0; - while (!flushing) { -- int thisWritten; -+ int thisWritten = 0; - synchronized (lockNative) { -- thisWritten = nWrite(id, b, off, len, -- softwareConversionSize, -- leftGain, rightGain); -+ if (doIO) -+ thisWritten = nWrite(id, b, off, len, -+ softwareConversionSize, -+ leftGain, rightGain); - if (thisWritten < 0) { - // error in native layer - break; -@@ -972,9 +1011,10 @@ - } - int read = 0; - while (doIO && !flushing) { -- int thisRead; -+ int thisRead = 0; - synchronized (lockNative) { -- thisRead = nRead(id, b, off, len, softwareConversionSize); -+ if (doIO) -+ thisRead = nRead(id, b, off, len, softwareConversionSize); - if (thisRead < 0) { - // error in native layer - break; -@@ -1209,7 +1249,8 @@ - // set new native position (if necessary) - // this must come after the flush! - synchronized (lockNative) { -- nSetBytePosition(id, isSource, frames * frameSize); -+ if (doIO) -+ nSetBytePosition(id, isSource, frames * frameSize); - } - - if (Printer.debug) Printer.debug(" DirectClip.setFramePosition: " diff -r 5a2104fb2256 patches/icedtea-enum-bug-181.patch --- a/patches/icedtea-enum-bug-181.patch Wed Feb 04 11:49:31 2009 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,11 +0,0 @@ ---- openjdkold/jdk/src/share/classes/sun/beans/editors/EnumEditor.java 2008-07-10 15:57:13.000000000 -0400 -+++ openjdk/jdk/src/share/classes/sun/beans/editors/EnumEditor.java 2008-08-11 15:07:05.000000000 -0400 -@@ -67,7 +67,7 @@ - } - - public void setValue( Object value ) { -- if ( ( value != null ) && ( this.type != value.getClass() ) ) { -+ if ( ( value != null ) && ! ( this.type.isInstance( value ) ) ) { - throw new IllegalArgumentException( "Unsupported value: " + value ); - } - Object oldValue; diff -r 5a2104fb2256 patches/icedtea-jsoundhs.patch --- a/patches/icedtea-jsoundhs.patch Wed Feb 04 11:49:31 2009 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,73 +0,0 @@ -diff -Nru openjdk.orig/jdk/make/common/internal/BinaryPlugs.gmk openjdk/jdk/make/common/internal/BinaryPlugs.gmk ---- openjdk.orig/jdk/make/common/internal/BinaryPlugs.gmk 2008-07-13 03:42:22.000000000 +0100 -+++ openjdk/jdk/make/common/internal/BinaryPlugs.gmk 2008-07-13 03:41:56.000000000 +0100 -@@ -27,16 +27,6 @@ - - # Definitions for openjdk plugs (used by both import and export) - --# Names of native shared libraries -- --PLUG_JSOUND_LIBRARY=$(LIB_PREFIX)jsoundhs.$(LIBRARY_SUFFIX) --PLUG_LIBRARY_NAMES = \ -- $(PLUG_JSOUND_LIBRARY) -- --# Sub-directory where native shared libraries are located (e.g. jre/bin or...) -- --PLUG_LOCATION_SUBDIR=$(ARCH_VM_SUBDIR) -- - # Explicit classfile lists - - # WARNING: These classlists will not work with pattern rules, only used in -@@ -222,17 +212,6 @@ - import-binary-plug-jmf-classes \ - import-binary-plug-sound-classes - --# Import native libraries -- --$(LIB_LOCATION)/$(PLUG_JSOUND_LIBRARY): \ -- $(PLUG_IMPORT_DIR)/$(PLUG_LOCATION_SUBDIR)/$(PLUG_JSOUND_LIBRARY) -- $(import-binary-plug-file) -- --# Rules only used by lower level makefiles -- --import-binary-plug-jsound-library: \ -- $(LIB_LOCATION)/$(PLUG_JSOUND_LIBRARY) -- - # Binary plug start/complete messages - - import-binary-plugs-started: -diff -Nru openjdk.orig/jdk/make/javax/sound/Makefile openjdk/jdk/make/javax/sound/Makefile ---- openjdk.orig/jdk/make/javax/sound/Makefile 2008-07-13 03:42:40.000000000 +0100 -+++ openjdk/jdk/make/javax/sound/Makefile 2008-07-13 03:41:22.000000000 +0100 -@@ -96,11 +96,6 @@ - - - # --# add "closed" library --# --SUBDIRS += jsoundhs -- --# - # system dependent flags - # - ifeq ($(PLATFORM), windows) -diff -uNr openjdk-orig/jdk/src/share/classes/com/sun/media/sound/Platform.java openjdk/jdk/src/share/classes/com/sun/media/sound/Platform.java ---- openjdk-orig/jdk/src/share/classes/com/sun/media/sound/Platform.java 2008-11-07 10:38:15.000000000 -0500 -+++ openjdk/jdk/src/share/classes/com/sun/media/sound/Platform.java 2008-11-07 10:43:21.000000000 -0500 -@@ -42,7 +42,6 @@ - - // native library we need to load - private static final String libNameMain = "jsound"; -- private static final String libNameMain2 = "jsoundhs"; - - private static final String libNameALSA = "jsoundalsa"; - private static final String libNameDSound = "jsoundds"; -@@ -160,7 +159,6 @@ - try { - // load the main libraries - JSSecurityManager.loadLibrary(libNameMain); -- JSSecurityManager.loadLibrary(libNameMain2); - // just for the heck of it... - loadedLibs |= LIB_MAIN; - } catch (SecurityException e) { - diff -r 5a2104fb2256 patches/icedtea-sound.patch --- a/patches/icedtea-sound.patch Wed Feb 04 11:49:31 2009 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,693 +0,0 @@ -diff -Nru openjdk.orig/jdk/src/share/classes/com/sun/media/sound/AbstractMidiDevice.java openjdk/jdk/src/share/classes/com/sun/media/sound/AbstractMidiDevice.java ---- openjdk.orig/jdk/src/share/classes/com/sun/media/sound/AbstractMidiDevice.java 2008-11-13 18:27:19.000000000 +0000 -+++ openjdk/jdk/src/share/classes/com/sun/media/sound/AbstractMidiDevice.java 2008-11-13 18:27:03.000000000 +0000 -@@ -586,7 +586,6 @@ - - private ArrayList transmitters = new ArrayList(); - private MidiOutDevice.MidiOutReceiver midiOutReceiver; -- private MixerSynth.SynthReceiver mixerSynthReceiver; - - // how many transmitters must be present for optimized - // handling -@@ -621,22 +620,14 @@ - if (midiOutReceiver == oldR) { - midiOutReceiver = null; - } -- if (mixerSynthReceiver == oldR) { -- mixerSynthReceiver = null; -- } - if (newR != null) { - if ((newR instanceof MidiOutDevice.MidiOutReceiver) - && (midiOutReceiver == null)) { - midiOutReceiver = ((MidiOutDevice.MidiOutReceiver) newR); - } -- if ((newR instanceof MixerSynth.SynthReceiver) -- && (mixerSynthReceiver == null)) { -- mixerSynthReceiver = ((MixerSynth.SynthReceiver) newR); -- } - } - optimizedReceiverCount = -- ((midiOutReceiver!=null)?1:0) -- + ((mixerSynthReceiver!=null)?1:0); -+ ((midiOutReceiver!=null)?1:0); - } - // more potential for optimization here - } -@@ -670,10 +661,6 @@ - if (TRACE_TRANSMITTER) Printer.println("Sending packed message to MidiOutReceiver"); - midiOutReceiver.sendPackedMidiMessage(packedMessage, timeStamp); - } -- if (mixerSynthReceiver != null) { -- if (TRACE_TRANSMITTER) Printer.println("Sending packed message to MixerSynthReceiver"); -- mixerSynthReceiver.sendPackedMidiMessage(packedMessage, timeStamp); -- } - } else { - if (TRACE_TRANSMITTER) Printer.println("Sending packed message to "+size+" transmitter's receivers"); - for (int i = 0; i < size; i++) { -@@ -682,9 +669,6 @@ - if (optimizedReceiverCount > 0) { - if (receiver instanceof MidiOutDevice.MidiOutReceiver) { - ((MidiOutDevice.MidiOutReceiver) receiver).sendPackedMidiMessage(packedMessage, timeStamp); -- } -- else if (receiver instanceof MixerSynth.SynthReceiver) { -- ((MixerSynth.SynthReceiver) receiver).sendPackedMidiMessage(packedMessage, timeStamp); - } else { - receiver.send(new FastShortMessage(packedMessage), timeStamp); - } -@@ -739,10 +723,6 @@ - if (TRACE_TRANSMITTER) Printer.println("Sending MIDI message to MidiOutReceiver"); - midiOutReceiver.send(message, timeStamp); - } -- if (mixerSynthReceiver != null) { -- if (TRACE_TRANSMITTER) Printer.println("Sending MIDI message to MixerSynthReceiver"); -- mixerSynthReceiver.send(message, timeStamp); -- } - } else { - if (TRACE_TRANSMITTER) Printer.println("Sending MIDI message to "+size+" transmitter's receivers"); - for (int i = 0; i < size; i++) { -diff -Nru openjdk.orig/jdk/src/share/classes/com/sun/media/sound/RealTimeSequencer.java openjdk/jdk/src/share/classes/com/sun/media/sound/RealTimeSequencer.java ---- openjdk.orig/jdk/src/share/classes/com/sun/media/sound/RealTimeSequencer.java 2008-11-13 18:27:30.000000000 +0000 -+++ openjdk/jdk/src/share/classes/com/sun/media/sound/RealTimeSequencer.java 2008-11-13 18:26:52.000000000 +0000 -@@ -56,7 +56,7 @@ - - - /** if true, we bridge RMF files over to the old MixerSequencer */ -- private final static boolean RMF = true; -+ private final static boolean RMF = false; - - /** - * Event Dispatcher thread. Should be using a shared event -@@ -145,9 +145,6 @@ - private ArrayList controllerEventListeners = new ArrayList(); - - -- /** for RMF media we need the RMF sequencer */ -- private MixerSequencer seqBridge = null; -- - /** automatic connection support */ - private boolean autoConnect = false; - -@@ -221,10 +218,6 @@ - } - } - if (RMF) { -- if (seqBridge != null) { -- seqBridge.close(); -- seqBridge = null; -- } - // if previous file was an RMF, but this file is not RMF, - // then need to call implOpen again! - if (isOpen() && sequence != null && playThread == null) { -@@ -255,44 +248,6 @@ - int type = fileFormat.getType(); - int resolution = fileFormat.getResolution(); - if (Printer.debug) Printer.debug("Got file with type="+type+" and resolution="+resolution); -- if (resolution == MidiFileFormat.UNKNOWN_LENGTH) { -- // seems to be RMF -- if (seqBridge == null) { -- try { -- seqBridge = new MixerSequencer(); -- if (isOpen()) { -- seqBridge.open(); -- } -- } catch (MidiUnavailableException mue) { -- // uhum, strange situation. Need to cast to InvalidMidiDataException -- throw new InvalidMidiDataException(mue.getMessage()); -- } -- } -- seqBridge.setSequence(stream); -- // propagate state -- seqBridge.setTempoFactor(getTempoFactor()); -- -- // propagate listeners -- synchronized(metaEventListeners) { -- for (int i = 0 ; i < metaEventListeners.size(); i++) { -- seqBridge.addMetaEventListener((MetaEventListener) (metaEventListeners.get(i))); -- } -- } -- synchronized(controllerEventListeners) { -- for (int i = 0 ; i < controllerEventListeners.size(); i++) { -- ControllerListElement cve = (ControllerListElement) (controllerEventListeners.get(i)); -- seqBridge.addControllerEventListener(cve.listener, cve.controllers); -- } -- } -- // disable the current sequence of RealTimeSequencer -- //setSequence((Sequence) null); -> will remove bridge again! -- this.sequence = null; -- return; -- } -- if (seqBridge != null) { -- seqBridge.close(); -- seqBridge = null; -- } - } - - Sequence seq = MidiSystem.getSequence(stream); // can throw IOException, InvalidMidiDataException -@@ -305,22 +260,11 @@ - - - public Sequence getSequence() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getSequence(); -- } -- } - return sequence; - } - - - public synchronized void start() { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.start(); -- return; -- } -- } - if (Printer.trace) Printer.trace(">> RealTimeSequencer: start()"); - - // sequencer not open: throw an exception -@@ -346,12 +290,6 @@ - - - public synchronized void stop() { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.stop(); -- return; -- } -- } - if (Printer.trace) Printer.trace(">> RealTimeSequencer: stop()"); - - if (!isOpen()) { -@@ -373,22 +311,11 @@ - - - public boolean isRunning() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.isRunning(); -- } -- } - return running; - } - - - public void startRecording() { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.startRecording(); -- return; -- } -- } - - if (!isOpen()) { - throw new IllegalStateException("Sequencer not open"); -@@ -400,12 +327,6 @@ - - - public void stopRecording() { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.stopRecording(); -- return; -- } -- } - - if (!isOpen()) { - throw new IllegalStateException("Sequencer not open"); -@@ -415,22 +336,11 @@ - - - public boolean isRecording() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.isRecording(); -- } -- } - return recording; - } - - - public void recordEnable(Track track, int channel) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.recordEnable(track, channel); -- return; -- } -- } - - if (!findTrack(track)) { - throw new IllegalArgumentException("Track does not exist in the current sequence"); -@@ -449,12 +359,6 @@ - - - public void recordDisable(Track track) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.recordDisable(track); -- return; -- } -- } - - synchronized(recordingTracks) { - RecordingTrack rc = RecordingTrack.get(recordingTracks, track); -@@ -482,11 +386,6 @@ - - - public float getTempoInBPM() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getTempoInBPM(); -- } -- } - if (Printer.trace) Printer.trace(">> RealTimeSequencer: getTempoInBPM() "); - - return (float) MidiUtils.convertTempo(getTempoInMPQ()); -@@ -494,12 +393,6 @@ - - - public void setTempoInBPM(float bpm) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setTempoInBPM(bpm); -- return; -- } -- } - if (Printer.trace) Printer.trace(">> RealTimeSequencer: setTempoInBPM() "); - if (bpm <= 0) { - // should throw IllegalArgumentException -@@ -511,11 +404,6 @@ - - - public float getTempoInMPQ() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getTempoInMPQ(); -- } -- } - - if (Printer.trace) Printer.trace(">> RealTimeSequencer: getTempoInMPQ() "); - -@@ -537,12 +425,6 @@ - - - public void setTempoInMPQ(float mpq) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setTempoInMPQ(mpq); -- return; -- } -- } - if (mpq <= 0) { - // should throw IllegalArgumentException - mpq = 1.0f; -@@ -564,12 +446,6 @@ - - - public void setTempoFactor(float factor) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setTempoFactor(factor); -- return; -- } -- } - if (factor <= 0) { - // should throw IllegalArgumentException - return; -@@ -588,11 +464,6 @@ - - - public float getTempoFactor() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getTempoFactor(); -- } -- } - if (Printer.trace) Printer.trace(">> RealTimeSequencer: getTempoFactor() "); - - if (needCaching()) { -@@ -606,11 +477,6 @@ - - - public long getTickLength() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getTickLength(); -- } -- } - if (Printer.trace) Printer.trace(">> RealTimeSequencer: getTickLength() "); - - if (sequence == null) { -@@ -622,11 +488,6 @@ - - - public synchronized long getTickPosition() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getTickPosition(); -- } -- } - if (Printer.trace) Printer.trace(">> RealTimeSequencer: getTickPosition() "); - - if (getDataPump() == null || sequence == null) { -@@ -638,12 +499,6 @@ - - - public synchronized void setTickPosition(long tick) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setTickPosition(tick); -- return; -- } -- } - if (tick < 0) { - // should throw IllegalArgumentException - return; -@@ -667,11 +522,6 @@ - - - public long getMicrosecondLength() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getMicrosecondLength(); -- } -- } - - if (Printer.trace) Printer.trace(">> RealTimeSequencer: getMicrosecondLength() "); - -@@ -684,11 +534,6 @@ - - - public long getMicrosecondPosition() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getMicrosecondPosition(); -- } -- } - - if (Printer.trace) Printer.trace(">> RealTimeSequencer: getMicrosecondPosition() "); - -@@ -702,12 +547,6 @@ - - - public void setMicrosecondPosition(long microseconds) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setMicrosecondPosition(microseconds); -- return; -- } -- } - - if (microseconds < 0) { - // should throw IllegalArgumentException -@@ -734,32 +573,16 @@ - - - public void setMasterSyncMode(Sequencer.SyncMode sync) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setMasterSyncMode(sync); -- return; -- } -- } - // not supported - } - - - public Sequencer.SyncMode getMasterSyncMode() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getMasterSyncMode(); -- } -- } - return masterSyncMode; - } - - - public Sequencer.SyncMode[] getMasterSyncModes() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getMasterSyncModes(); -- } -- } - - Sequencer.SyncMode[] returnedModes = new Sequencer.SyncMode[masterSyncModes.length]; - System.arraycopy(masterSyncModes, 0, returnedModes, 0, masterSyncModes.length); -@@ -768,32 +591,16 @@ - - - public void setSlaveSyncMode(Sequencer.SyncMode sync) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setSlaveSyncMode(sync); -- return; -- } -- } - // not supported - } - - - public Sequencer.SyncMode getSlaveSyncMode() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getSlaveSyncMode(); -- } -- } - return slaveSyncMode; - } - - - public Sequencer.SyncMode[] getSlaveSyncModes() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getSlaveSyncModes(); -- } -- } - - Sequencer.SyncMode[] returnedModes = new Sequencer.SyncMode[slaveSyncModes.length]; - System.arraycopy(slaveSyncModes, 0, returnedModes, 0, slaveSyncModes.length); -@@ -812,12 +619,6 @@ - - - public synchronized void setTrackMute(int track, boolean mute) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setTrackMute(track, mute); -- return; -- } -- } - int trackCount = getTrackCount(); - if (track < 0 || track >= getTrackCount()) return; - trackMuted = ensureBoolArraySize(trackMuted, trackCount); -@@ -829,11 +630,6 @@ - - - public synchronized boolean getTrackMute(int track) { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getTrackMute(track); -- } -- } - if (track < 0 || track >= getTrackCount()) return false; - if (trackMuted == null || trackMuted.length <= track) return false; - return trackMuted[track]; -@@ -841,12 +637,6 @@ - - - public synchronized void setTrackSolo(int track, boolean solo) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setTrackSolo(track, solo); -- return; -- } -- } - int trackCount = getTrackCount(); - if (track < 0 || track >= getTrackCount()) return; - trackSolo = ensureBoolArraySize(trackSolo, trackCount); -@@ -858,11 +648,6 @@ - - - public synchronized boolean getTrackSolo(int track) { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getTrackSolo(track); -- } -- } - if (track < 0 || track >= getTrackCount()) return false; - if (trackSolo == null || trackSolo.length <= track) return false; - return trackSolo[track]; -@@ -870,12 +655,6 @@ - - - public boolean addMetaEventListener(MetaEventListener listener) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.addMetaEventListener(listener); -- // do not return here! -- } -- } - synchronized(metaEventListeners) { - if (! metaEventListeners.contains(listener)) { - -@@ -887,12 +666,6 @@ - - - public void removeMetaEventListener(MetaEventListener listener) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.removeMetaEventListener(listener); -- // do not return here! -- } -- } - synchronized(metaEventListeners) { - int index = metaEventListeners.indexOf(listener); - if (index >= 0) { -@@ -903,12 +676,6 @@ - - - public int[] addControllerEventListener(ControllerEventListener listener, int[] controllers) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.addControllerEventListener(listener, controllers); -- // do not return here! -- } -- } - - synchronized(controllerEventListeners) { - -@@ -938,12 +705,6 @@ - - - public int[] removeControllerEventListener(ControllerEventListener listener, int[] controllers) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.removeControllerEventListener(listener, controllers); -- // do not return here! -- } -- } - synchronized(controllerEventListeners) { - ControllerListElement cve = null; - boolean flag = false; -@@ -973,12 +734,6 @@ - ////////////////// LOOPING (added in 1.5) /////////////////////// - - public void setLoopStartPoint(long tick) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setLoopStartPoint(tick); -- return; -- } -- } - if ((tick > getTickLength()) - || ((loopEnd != -1) && (tick > loopEnd)) - || (tick < 0)) { -@@ -988,21 +743,10 @@ - } - - public long getLoopStartPoint() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getLoopStartPoint(); -- } -- } - return loopStart; - } - - public void setLoopEndPoint(long tick) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setLoopEndPoint(tick); -- return; -- } -- } - if ((tick > getTickLength()) - || ((loopStart > tick) && (tick != -1)) - || (tick < -1)) { -@@ -1012,21 +756,10 @@ - } - - public long getLoopEndPoint() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getLoopEndPoint(); -- } -- } - return loopEnd; - } - - public void setLoopCount(int count) { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.setLoopCount(count); -- return; -- } -- } - if (count != LOOP_CONTINUOUSLY - && count < 0) { - throw new IllegalArgumentException("illegal value for loop count: "+count); -@@ -1038,11 +771,6 @@ - } - - public int getLoopCount() { -- if (RMF) { -- if (seqBridge != null) { -- return seqBridge.getLoopCount(); -- } -- } - return loopCount; - } - -@@ -1053,13 +781,6 @@ - */ - protected void implOpen() throws MidiUnavailableException { - if (Printer.trace) Printer.trace(">> RealTimeSequencer: implOpen()"); -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.open(); -- if (Printer.trace) Printer.trace("<< RealTimeSequencer: -> called seqBridge.open"); -- return; -- } -- } - - //openInternalSynth(); - -@@ -1147,12 +868,7 @@ - - - protected synchronized void implClose() { -- if (RMF) { -- if (seqBridge != null) { -- seqBridge.close(); -- // don't return here! -- } -- } -+ - if (Printer.trace) Printer.trace(">> RealTimeSequencer: implClose() "); - - if (playThread == null) { -@@ -1302,12 +1018,6 @@ - // OVERRIDES OF ABSTRACT MIDI DEVICE METHODS - - protected boolean hasReceivers() { -- if (RMF) { -- if (seqBridge != null) { -- //RMF does not allow recording -- return false; -- } -- } - return true; - } - -@@ -1318,12 +1028,6 @@ - - - protected boolean hasTransmitters() { -- if (RMF) { -- if (seqBridge != null) { -- //RMF does never allow setting own receivers -- return false; -- } -- } - return true; - } - From ahughes at redhat.com Tue Feb 10 13:09:44 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Tue, 10 Feb 2009 21:09:44 +0000 Subject: changeset in /hg/icedtea: Bump to b46. Message-ID: changeset fd8112e82992 in /hg/icedtea details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=fd8112e82992 description: Bump to b46. 2009-02-10 Andrew John Hughes Bump to b46. * patches/icedtea-directaudio-close-trick.patch, * patches/icedtea-enum-bug-181.patch, * patches/icedtea-jsoundhs.patch, * patches/icedtea-sound.patch: Applied upstream. * HACKING, * Makefile.am: Updated. * patches/ecj/icedtea.patch: Recreated due to S6795030. * patches/icedtea-copy-plugs.patch: Recreated due to S6702956. diffstat: 9 files changed, 101 insertions(+), 1070 deletions(-) ChangeLog | 15 HACKING | 5 Makefile.am | 10 patches/ecj/icedtea.patch | 149 ++--- patches/icedtea-copy-plugs.patch | 22 patches/icedtea-directaudio-close-trick.patch | 193 ------ patches/icedtea-enum-bug-181.patch | 11 patches/icedtea-jsoundhs.patch | 73 -- patches/icedtea-sound.patch | 693 ------------------------- diffs (truncated from 1546 to 500 lines): diff -r 5a2104fb2256 -r fd8112e82992 ChangeLog --- a/ChangeLog Wed Feb 04 11:49:31 2009 +0000 +++ b/ChangeLog Tue Feb 10 21:09:31 2009 +0000 @@ -1,3 +1,18 @@ 2009-02-03 Andrew John Hughes + + Bump to b46. + * patches/icedtea-directaudio-close-trick.patch, + * patches/icedtea-enum-bug-181.patch, + * patches/icedtea-jsoundhs.patch, + * patches/icedtea-sound.patch: + Applied upstream. + * HACKING, + * Makefile.am: Updated. + * patches/ecj/icedtea.patch: Recreated due to + S6795030. + * patches/icedtea-copy-plugs.patch: Recreated + due to S6702956. + 2009-02-03 Andrew John Hughes * Makefile.am: diff -r 5a2104fb2256 -r fd8112e82992 HACKING --- a/HACKING Wed Feb 04 11:49:31 2009 +0000 +++ b/HACKING Tue Feb 10 21:09:31 2009 +0000 @@ -24,7 +24,6 @@ The following patches are currently appl * icedtea-core-build.patch: Add support for building IcedTea core VM. * icedtea-debuginfo.patch: Add -g option to build to generate debugging information. * icedtea-demos.patch: Fix building of JVMTI demo. -* icedtea-enum-bug-181.patch: Fixes class type check (PR181/S6736248) * icedtea-float-double-trailing-zeros.patch: Remove trailing zeros from Double/Float (PR29/30) * icedtea-fonts.patch: Add Fedora fontconfig. * icedtea-gcc-suffix.patch: Append $(GCC_SUFFIX) to end of 'gcc' binary name. @@ -86,6 +85,7 @@ The following patches are only applied t * icedtea-corba.patch: Adds additional files to org.omg.CORBA Makefile. * icedtea-display-mode-changer.patch: Add extra test class. (applied in OpenJDK7 b43) +* icedtea-enum-bug-181.patch: Fixes class type check (PR181/S6736248) * icedtea-gcc-4.3.patch: Fix code to compile with GCC 4.3 and turn off -Werror. * icedtea-generated.patch: Force use of /bin/bash. * icedtea-nomotif.patch: Remove sanity and GrabShell.h dependency on Motif/Lesstif library. @@ -105,15 +105,12 @@ The following patches are only applied t * icedtea-constructor-properties.patch: Explicitly cast to ConstructorProperties as getAnnotation is broken in libgcj 4.3. -* icedtea-jsoundhs.patch: Remove attempted build of proprietary jsoundhs library. * icedtea-mbeanintrospector.patch: Explicitly cast to Description as getAnnotation is broken in libgcj 4.3. * icedtea-override.patch: Remove @Override annotation in javax.management.AttributeValueExp (unsupported by ecj < 3.4). * icedtea-snmp.patch: Remove proprietary SNMP support hooks. * icedtea-sound.patch: Remove proprietary MIDI support hooks. -* icedtea-fortify-source.patch: Fix build failures with -D_FORTIFY_SOURCE=2. -* icedtea-format-warnings.patch: Fix build failures with -Wformat=1. The following patches are only applied to the icedtea-ecj bootstrap tree: diff -r 5a2104fb2256 -r fd8112e82992 Makefile.am --- a/Makefile.am Wed Feb 04 11:49:31 2009 +0000 +++ b/Makefile.am Tue Feb 10 21:09:31 2009 +0000 @@ -1,6 +1,6 @@ OPENJDK_DATE = 29_jan_2009 -OPENJDK_DATE = 29_jan_2009 -OPENJDK_MD5SUM = 0d6ae1ed77b470c9665d069b34a1bc88 -OPENJDK_VERSION = b45 +OPENJDK_DATE = 05_feb_2009 +OPENJDK_MD5SUM = d5f92fec2f645d44437ab90e1dd2dbaf +OPENJDK_VERSION = b46 CACAO_VERSION = 0.99.3 CACAO_MD5SUM = 80de3ad344c1a20c086ec5f1390bd1b8 @@ -1845,7 +1845,6 @@ ICEDTEA_PATCHES = \ patches/icedtea-uname.patch \ patches/icedtea-ia64-fdlibm.patch \ patches/icedtea-fonts.patch \ - patches/icedtea-directaudio-close-trick.patch \ patches/hotspot/$(HSBUILD)/icedtea-sparc-ptracefix.patch \ patches/hotspot/$(HSBUILD)/icedtea-sparc-trapsfix.patch \ patches/icedtea-override-redirect-metacity.patch \ @@ -1854,13 +1853,11 @@ ICEDTEA_PATCHES = \ patches/hotspot/$(HSBUILD)/icedtea-shark-build.patch \ patches/icedtea-toolkit.patch \ patches/icedtea-security-updates.patch \ - patches/icedtea-jsoundhs.patch \ patches/icedtea-jdk-docs-target.patch \ patches/icedtea-mbeanintrospector.patch \ patches/icedtea-hotspot-gcc-pr36917.patch \ patches/icedtea-alpha-fixes.patch \ patches/icedtea-alt-jar.patch \ - patches/icedtea-enum-bug-181.patch \ patches/icedtea-jdk-use-ssize_t.patch \ patches/hotspot/$(HSBUILD)/icedtea-use-idx_t.patch \ patches/hotspot/$(HSBUILD)/icedtea-params-cast-size_t.patch \ @@ -1876,7 +1873,6 @@ ICEDTEA_PATCHES = \ patches/icedtea-xjc.patch \ patches/icedtea-renderer-crossing.patch \ patches/icedtea-snmp.patch \ - patches/icedtea-sound.patch \ patches/icedtea-tests-jdk.patch \ patches/icedtea-stroker-finish.patch \ patches/icedtea-alsa-default-device.patch \ diff -r 5a2104fb2256 -r fd8112e82992 patches/ecj/icedtea.patch --- a/patches/ecj/icedtea.patch Wed Feb 04 11:49:31 2009 +0000 +++ b/patches/ecj/icedtea.patch Tue Feb 10 21:09:31 2009 +0000 @@ -1,6 +1,6 @@ diff -Nru openjdk-ecj.orig/corba/make/co diff -Nru openjdk-ecj.orig/corba/make/com/sun/corba/se/Makefile openjdk-ecj/corba/make/com/sun/corba/se/Makefile ---- openjdk-ecj.orig/corba/make/com/sun/corba/se/Makefile 2008-10-09 08:41:14.000000000 +0100 -+++ openjdk-ecj/corba/make/com/sun/corba/se/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/com/sun/corba/se/Makefile 2009-02-05 08:40:51.000000000 +0000 ++++ openjdk-ecj/corba/make/com/sun/corba/se/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -42,7 +42,7 @@ # the rmic iiop backend needs some classes that are part of the impl/util # package. These classes use log wrappers, so they must be built after @@ -12,7 +12,7 @@ diff -Nru openjdk-ecj.orig/corba/make/co diff -Nru openjdk-ecj.orig/corba/make/com/sun/corba/se/org/Makefile openjdk-ecj/corba/make/com/sun/corba/se/org/Makefile --- openjdk-ecj.orig/corba/make/com/sun/corba/se/org/Makefile 1970-01-01 01:00:00.000000000 +0100 -+++ openjdk-ecj/corba/make/com/sun/corba/se/org/Makefile 2008-10-24 13:32:48.000000000 +0100 ++++ openjdk-ecj/corba/make/com/sun/corba/se/org/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -0,0 +1,38 @@ +# +# Copyright 2001-2005 Sun Microsystems, Inc. All Rights Reserved. @@ -53,8 +53,8 @@ diff -Nru openjdk-ecj.orig/corba/make/co +# +include $(BUILDDIR)/common/Classes.gmk diff -Nru openjdk-ecj.orig/corba/make/common/Defs.gmk openjdk-ecj/corba/make/common/Defs.gmk ---- openjdk-ecj.orig/corba/make/common/Defs.gmk 2008-10-09 08:41:14.000000000 +0100 -+++ openjdk-ecj/corba/make/common/Defs.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/common/Defs.gmk 2009-02-05 08:40:51.000000000 +0000 ++++ openjdk-ecj/corba/make/common/Defs.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -53,6 +53,13 @@ _OUTPUTDIR=$(TOPDIR)/build/$(PLATFORM)-$(ARCH) @@ -88,8 +88,8 @@ diff -Nru openjdk-ecj.orig/corba/make/co vpath %.java $(VPATH.java) vpath %.class $(CLASSBINDIR) diff -Nru openjdk-ecj.orig/corba/make/common/Defs-linux.gmk openjdk-ecj/corba/make/common/Defs-linux.gmk ---- openjdk-ecj.orig/corba/make/common/Defs-linux.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/corba/make/common/Defs-linux.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/common/Defs-linux.gmk 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/corba/make/common/Defs-linux.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -276,7 +276,7 @@ fi; \ done) @@ -100,8 +100,8 @@ diff -Nru openjdk-ecj.orig/corba/make/co # # We want to privatize JVM symbols on Solaris. This is so the user can diff -Nru openjdk-ecj.orig/corba/make/common/Rules.gmk openjdk-ecj/corba/make/common/Rules.gmk ---- openjdk-ecj.orig/corba/make/common/Rules.gmk 2008-10-09 08:41:14.000000000 +0100 -+++ openjdk-ecj/corba/make/common/Rules.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/common/Rules.gmk 2009-02-05 08:40:51.000000000 +0000 ++++ openjdk-ecj/corba/make/common/Rules.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -197,8 +197,10 @@ $(ECHO) "# Java sources to be compiled: (listed in file $(JAVA_SOURCE_LIST))"; \ $(CAT) $(JAVA_SOURCE_LIST); \ @@ -116,8 +116,8 @@ diff -Nru openjdk-ecj.orig/corba/make/co @$(java-vm-cleanup) diff -Nru openjdk-ecj.orig/corba/make/common/shared/Defs-java.gmk openjdk-ecj/corba/make/common/shared/Defs-java.gmk ---- openjdk-ecj.orig/corba/make/common/shared/Defs-java.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/corba/make/common/shared/Defs-java.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/common/shared/Defs-java.gmk 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/corba/make/common/shared/Defs-java.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -110,31 +110,13 @@ JAVACFLAGS += $(OTHER_JAVACFLAGS) @@ -155,8 +155,8 @@ diff -Nru openjdk-ecj.orig/corba/make/co # Override of what javac to use (see deploy workspace) ifdef JAVAC diff -Nru openjdk-ecj.orig/corba/make/org/omg/sources/Makefile openjdk-ecj/corba/make/org/omg/sources/Makefile ---- openjdk-ecj.orig/corba/make/org/omg/sources/Makefile 2008-10-09 08:41:14.000000000 +0100 -+++ openjdk-ecj/corba/make/org/omg/sources/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/org/omg/sources/Makefile 2009-02-05 08:40:51.000000000 +0000 ++++ openjdk-ecj/corba/make/org/omg/sources/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -93,8 +93,6 @@ POAHELHOLFILES = $(POA_GENERATED_HELP_HOL_java:%=$(GENSRCDIR)/%) @@ -234,8 +234,8 @@ diff -Nru openjdk-ecj.orig/corba/make/or pi.compile: $(PIGENERATEDFILES) diff -Nru openjdk-ecj.orig/corba/make/sun/rmi/corbalogsources/Makefile openjdk-ecj/corba/make/sun/rmi/corbalogsources/Makefile ---- openjdk-ecj.orig/corba/make/sun/rmi/corbalogsources/Makefile 2008-10-24 10:16:05.000000000 +0100 -+++ openjdk-ecj/corba/make/sun/rmi/corbalogsources/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/corba/make/sun/rmi/corbalogsources/Makefile 2009-02-10 18:11:57.000000000 +0000 ++++ openjdk-ecj/corba/make/sun/rmi/corbalogsources/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -172,7 +172,6 @@ ACTIVATIONFILES = $(com_sun_corba_se_spi_activation_java:%=$(GENSRCDIR)/%) @@ -253,8 +253,8 @@ diff -Nru openjdk-ecj.orig/corba/make/su portableactivation.idl.compile: $(PORTABLEACTIVATIONFILES) diff -Nru openjdk-ecj.orig/jaxp/make/build.xml openjdk-ecj/jaxp/make/build.xml ---- openjdk-ecj.orig/jaxp/make/build.xml 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxp/make/build.xml 2008-10-24 13:33:43.000000000 +0100 +--- openjdk-ecj.orig/jaxp/make/build.xml 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxp/make/build.xml 2009-02-10 19:24:54.000000000 +0000 @@ -71,7 +71,10 @@ diff -Nru openjdk-ecj.orig/jaxp/make/Makefile openjdk-ecj/jaxp/make/Makefile ---- openjdk-ecj.orig/jaxp/make/Makefile 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxp/make/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jaxp/make/Makefile 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxp/make/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -75,7 +75,7 @@ endif @@ -289,8 +289,8 @@ diff -Nru openjdk-ecj.orig/jaxp/make/Mak ifdef ALT_OUTPUTDIR diff -Nru openjdk-ecj.orig/jaxws/make/build.properties openjdk-ecj/jaxws/make/build.properties ---- openjdk-ecj.orig/jaxws/make/build.properties 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxws/make/build.properties 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jaxws/make/build.properties 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxws/make/build.properties 2009-02-10 19:24:54.000000000 +0000 @@ -37,7 +37,7 @@ # set the following to -version to verify the versions of javac being used javac.version.opt = @@ -301,8 +301,8 @@ diff -Nru openjdk-ecj.orig/jaxws/make/bu # JVM memory size javac.memoryInitialSize = 128m diff -Nru openjdk-ecj.orig/jaxws/make/build.xml openjdk-ecj/jaxws/make/build.xml ---- openjdk-ecj.orig/jaxws/make/build.xml 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxws/make/build.xml 2008-10-24 13:34:37.000000000 +0100 +--- openjdk-ecj.orig/jaxws/make/build.xml 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxws/make/build.xml 2009-02-10 19:24:54.000000000 +0000 @@ -84,7 +84,10 @@ diff -Nru openjdk-ecj.orig/jaxws/make/Makefile openjdk-ecj/jaxws/make/Makefile ---- openjdk-ecj.orig/jaxws/make/Makefile 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jaxws/make/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jaxws/make/Makefile 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jaxws/make/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -75,8 +75,8 @@ endif @@ -347,8 +347,8 @@ diff -Nru openjdk-ecj.orig/jaxws/make/Ma ifdef ALT_OUTPUTDIR diff -Nru openjdk-ecj.orig/jdk/make/common/BuildToolJar.gmk openjdk-ecj/jdk/make/common/BuildToolJar.gmk ---- openjdk-ecj.orig/jdk/make/common/BuildToolJar.gmk 2008-10-09 08:45:42.000000000 +0100 -+++ openjdk-ecj/jdk/make/common/BuildToolJar.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/common/BuildToolJar.gmk 2009-02-05 08:44:12.000000000 +0000 ++++ openjdk-ecj/jdk/make/common/BuildToolJar.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -43,7 +43,8 @@ @$(prep-target) @$(MKDIR) -p $(BUILDTOOLCLASSDIR) @@ -360,8 +360,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/comm -C $(BUILDTOOLCLASSDIR) $(PKGDIR) \ $(BOOT_JAR_JFLAGS) || $(RM) $@ diff -Nru openjdk-ecj.orig/jdk/make/common/Release.gmk openjdk-ecj/jdk/make/common/Release.gmk ---- openjdk-ecj.orig/jdk/make/common/Release.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jdk/make/common/Release.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/common/Release.gmk 2009-02-10 18:12:01.000000000 +0000 ++++ openjdk-ecj/jdk/make/common/Release.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -651,10 +651,23 @@ $(RES_JAR_ARGLIST): $(RES_JAR_FILELIST) $(prep-target) @@ -409,7 +409,7 @@ diff -Nru openjdk-ecj.orig/jdk/make/comm @$(java-vm-cleanup) # Meta-index construction to make core class loaders lazier -@@ -951,19 +972,6 @@ +@@ -944,19 +965,6 @@ @$(java-vm-cleanup) $(CP) $(LIBDIR)/tools.jar $(JDK_IMAGE_DIR)/lib/tools.jar @# @@ -429,7 +429,7 @@ diff -Nru openjdk-ecj.orig/jdk/make/comm @# CORBA supported orb.idl and ir.idl should be copied to lib @# $(CP) $(LIBDIR)/orb.idl $(JDK_IMAGE_DIR)/lib/orb.idl -@@ -1040,16 +1048,6 @@ +@@ -1033,16 +1041,6 @@ $(CP) $(PLATFORM_SRC)/bin/java_md.h $(JDK_IMAGE_DIR)/src/launcher $(CD) $(JDK_IMAGE_DIR)/src && $(ZIPEXE) -qr ../src.zip * $(RM) -r $(JDK_IMAGE_DIR)/src @@ -447,8 +447,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/comm $(call copy-man-pages,$(JDK_IMAGE_DIR),$(JDK_MAN_PAGES)) endif # !windows diff -Nru openjdk-ecj.orig/jdk/make/common/Rules.gmk openjdk-ecj/jdk/make/common/Rules.gmk ---- openjdk-ecj.orig/jdk/make/common/Rules.gmk 2008-10-09 08:45:42.000000000 +0100 -+++ openjdk-ecj/jdk/make/common/Rules.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/common/Rules.gmk 2009-02-05 08:44:12.000000000 +0000 ++++ openjdk-ecj/jdk/make/common/Rules.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -237,8 +237,9 @@ $(ECHO) "# Java sources to be compiled: (listed in file $<)"; \ $(CAT) $<.filtered; \ @@ -475,8 +475,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/comm @$(TOUCH) $@ diff -Nru openjdk-ecj.orig/jdk/make/common/shared/Defs-java.gmk openjdk-ecj/jdk/make/common/shared/Defs-java.gmk ---- openjdk-ecj.orig/jdk/make/common/shared/Defs-java.gmk 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/jdk/make/common/shared/Defs-java.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/common/shared/Defs-java.gmk 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/jdk/make/common/shared/Defs-java.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -121,30 +121,19 @@ JAVACFLAGS += $(OTHER_JAVACFLAGS) @@ -510,8 +510,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/comm # Override of what javac to use (see deploy workspace) diff -Nru openjdk-ecj.orig/jdk/make/java/nio/Makefile openjdk-ecj/jdk/make/java/nio/Makefile ---- openjdk-ecj.orig/jdk/make/java/nio/Makefile 2008-10-09 08:45:42.000000000 +0100 -+++ openjdk-ecj/jdk/make/java/nio/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/java/nio/Makefile 2009-02-05 08:44:13.000000000 +0000 ++++ openjdk-ecj/jdk/make/java/nio/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -31,7 +31,7 @@ PACKAGE = java.nio LIBRARY = nio @@ -522,8 +522,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/java NIO_SRC = $(SHARE_SRC)/classes/java/nio diff -Nru openjdk-ecj.orig/jdk/make/java/text/Makefile openjdk-ecj/jdk/make/java/text/Makefile ---- openjdk-ecj.orig/jdk/make/java/text/Makefile 2008-10-09 08:45:42.000000000 +0100 -+++ openjdk-ecj/jdk/make/java/text/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/java/text/Makefile 2009-02-05 08:44:13.000000000 +0000 ++++ openjdk-ecj/jdk/make/java/text/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -80,8 +80,8 @@ -sourcepath $(TEXT_SRCDIR) \ $(TEXT_SOURCES) @@ -536,8 +536,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/java -spec $(UNICODEDATA)/UnicodeData.txt @$(java-vm-cleanup) diff -Nru openjdk-ecj.orig/jdk/make/Makefile openjdk-ecj/jdk/make/Makefile ---- openjdk-ecj.orig/jdk/make/Makefile 2008-10-09 08:45:41.000000000 +0100 -+++ openjdk-ecj/jdk/make/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/Makefile 2009-02-05 08:44:12.000000000 +0000 ++++ openjdk-ecj/jdk/make/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -239,7 +239,7 @@ all build:: sanity-all post-sanity-all @@ -548,8 +548,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/Make $(SUBDIRS-loop) diff -Nru openjdk-ecj.orig/jdk/make/sun/awt/FILES_export_unix.gmk openjdk-ecj/jdk/make/sun/awt/FILES_export_unix.gmk ---- openjdk-ecj.orig/jdk/make/sun/awt/FILES_export_unix.gmk 2008-10-09 08:45:43.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/awt/FILES_export_unix.gmk 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/awt/FILES_export_unix.gmk 2009-02-05 08:44:14.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/awt/FILES_export_unix.gmk 2009-02-10 19:24:54.000000000 +0000 @@ -188,3 +188,5 @@ java/awt/dnd/DnDConstants.java \ sun/awt/CausedFocusEvent.java @@ -557,8 +557,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/sun/ +EXPORTED_inner = \ + sun.java2d.opengl.OGLContext$$OGLContextCaps diff -Nru openjdk-ecj.orig/jdk/make/sun/awt/Makefile openjdk-ecj/jdk/make/sun/awt/Makefile ---- openjdk-ecj.orig/jdk/make/sun/awt/Makefile 2008-10-09 08:45:43.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/awt/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/awt/Makefile 2009-02-05 08:44:14.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/awt/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -395,10 +395,9 @@ COMPILEFONTCONFIG_JARFILE = $(BUILDTOOLJARDIR)/compilefontconfig.jar @@ -574,8 +574,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/sun/ fontconfigs.clean : diff -Nru openjdk-ecj.orig/jdk/make/sun/javazic/Makefile openjdk-ecj/jdk/make/sun/javazic/Makefile ---- openjdk-ecj.orig/jdk/make/sun/javazic/Makefile 2008-10-09 08:45:43.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/javazic/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/javazic/Makefile 2009-02-05 08:44:14.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/javazic/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -62,7 +62,8 @@ $(WORKDIR)/$(MAPFILE): $(BUILDTOOLJARDIR)/javazic.jar $(TZFILES) $(RM) -r $(@D) @@ -587,8 +587,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/sun/ $(INSTALLDIR)/$(MAPFILE): $(WORKDIR)/$(MAPFILE) diff -Nru openjdk-ecj.orig/jdk/make/sun/text/Makefile openjdk-ecj/jdk/make/sun/text/Makefile ---- openjdk-ecj.orig/jdk/make/sun/text/Makefile 2008-10-09 08:45:44.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/text/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/text/Makefile 2009-02-05 08:44:14.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/text/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -85,8 +85,9 @@ $(BOOT_JAVAC_CMD) -d $(TEXT_CLASSES) \ -sourcepath $(TEXT_SRCDIR) \ @@ -602,8 +602,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/sun/ -spec $(UNICODEDATA)/UnicodeData.txt \ -language th diff -Nru openjdk-ecj.orig/jdk/make/sun/xawt/Makefile openjdk-ecj/jdk/make/sun/xawt/Makefile ---- openjdk-ecj.orig/jdk/make/sun/xawt/Makefile 2008-10-09 08:45:44.000000000 +0100 -+++ openjdk-ecj/jdk/make/sun/xawt/Makefile 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/sun/xawt/Makefile 2009-02-10 18:12:01.000000000 +0000 ++++ openjdk-ecj/jdk/make/sun/xawt/Makefile 2009-02-10 19:24:54.000000000 +0000 @@ -276,11 +276,7 @@ TEMPDIR_CLASSES = $(TEMPDIR)/classes @@ -641,8 +641,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/sun/ done $(TOUCH) $@ diff -Nru openjdk-ecj.orig/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java openjdk-ecj/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java ---- openjdk-ecj.orig/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java 2008-10-24 10:16:45.000000000 +0100 -+++ openjdk-ecj/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java 2009-02-10 18:11:22.000000000 +0000 ++++ openjdk-ecj/jdk/make/tools/src/build/tools/generatecharacter/GenerateCharacter.java 2009-02-10 19:24:54.000000000 +0000 @@ -647,9 +647,6 @@ throws FileNotFoundException, IOException { BufferedReader in = new BufferedReader(new FileReader(theTemplateFileName)); @@ -662,8 +662,8 @@ diff -Nru openjdk-ecj.orig/jdk/make/tool if (plane == 0 && bLatin1 == false) { genCaseMapTableDeclaration(result); diff -Nru openjdk-ecj.orig/jdk/src/share/classes/java/lang/Double.java openjdk-ecj/jdk/src/share/classes/java/lang/Double.java ---- openjdk-ecj.orig/jdk/src/share/classes/java/lang/Double.java 2008-10-24 10:16:33.000000000 +0100 -+++ openjdk-ecj/jdk/src/share/classes/java/lang/Double.java 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/src/share/classes/java/lang/Double.java 2009-02-10 18:11:12.000000000 +0000 ++++ openjdk-ecj/jdk/src/share/classes/java/lang/Double.java 2009-02-10 19:24:54.000000000 +0000 @@ -76,7 +76,7 @@ * {@code 0x1.fffffffffffffP+1023} and also equal to * {@code Double.longBitsToDouble(0x7fefffffffffffffL)}. @@ -692,8 +692,8 @@ diff -Nru openjdk-ecj.orig/jdk/src/share /** * Maximum exponent a finite {@code double} variable may have. diff -Nru openjdk-ecj.orig/jdk/src/share/classes/java/lang/Float.java openjdk-ecj/jdk/src/share/classes/java/lang/Float.java ---- openjdk-ecj.orig/jdk/src/share/classes/java/lang/Float.java 2008-10-24 10:16:33.000000000 +0100 -+++ openjdk-ecj/jdk/src/share/classes/java/lang/Float.java 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/src/share/classes/java/lang/Float.java 2009-02-10 18:11:12.000000000 +0000 ++++ openjdk-ecj/jdk/src/share/classes/java/lang/Float.java 2009-02-10 19:24:54.000000000 +0000 @@ -76,7 +76,7 @@ * {@code 0x1.fffffeP+127f} and also equal to * {@code Float.intBitsToFloat(0x7f7fffff)}. @@ -722,8 +722,8 @@ diff -Nru openjdk-ecj.orig/jdk/src/share /** * Maximum exponent a finite {@code float} variable may have. It diff -Nru openjdk-ecj.orig/jdk/src/share/native/sun/java2d/opengl/OGLContext.h openjdk-ecj/jdk/src/share/native/sun/java2d/opengl/OGLContext.h ---- openjdk-ecj.orig/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2008-10-09 08:46:24.000000000 +0100 -+++ openjdk-ecj/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2008-10-24 13:32:48.000000000 +0100 +--- openjdk-ecj.orig/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2009-02-05 08:44:52.000000000 +0000 ++++ openjdk-ecj/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2009-02-10 19:24:54.000000000 +0000 @@ -27,6 +27,7 @@ #define OGLContext_h_Included @@ -789,49 +789,44 @@ diff -Nru openjdk-ecj.orig/jdk/src/share /** * Evaluates to true if the given capability bitmask is present for the diff -Nru openjdk-ecj.orig/langtools/make/build.xml openjdk-ecj/langtools/make/build.xml ---- openjdk-ecj.orig/langtools/make/build.xml 2008-10-09 08:47:11.000000000 +0100 -+++ openjdk-ecj/langtools/make/build.xml 2008-10-24 13:32:48.000000000 +0100 -@@ -498,7 +498,10 @@ +--- openjdk-ecj.orig/langtools/make/build.xml 2009-02-05 08:45:36.000000000 +0000 ++++ openjdk-ecj/langtools/make/build.xml 2009-02-10 19:56:00.000000000 +0000 +@@ -502,7 +502,9 @@ includes="@{includes}" sourcepath="" includeAntRuntime="no" - target="@{javac.target}"> + target="@{javac.target}" -+ executable="${javac.executable}" + source="1.5"> + -@@ -512,7 +515,10 @@ +@@ -517,7 +519,9 @@ includeAntRuntime="no" target="@{javac.target}" debug="${javac.debug}" - debuglevel="${javac.debuglevel}"> -+ executable="${javac.executable}" + debuglevel="${javac.debuglevel}" + source="1.5"> + -@@ -563,8 +569,11 @@ - - - + classpath="${ant.home}/lib/ant.jar" -+ executable="${javac.executable}" -+ source="1.5"/> ++ source="1.5" /> diff -Nru openjdk-ecj.orig/langtools/make/Makefile openjdk-ecj/langtools/make/Makefile ---- openjdk-ecj.orig/langtools/make/Makefile 2008-10-24 10:16:06.000000000 +0100 -+++ openjdk-ecj/langtools/make/Makefile 2008-10-24 13:32:48.000000000 +0100 -@@ -108,7 +108,7 @@ +--- openjdk-ecj.orig/langtools/make/Makefile 2009-02-10 18:12:00.000000000 +0000 ++++ openjdk-ecj/langtools/make/Makefile 2009-02-10 19:24:54.000000000 +0000 +@@ -112,7 +112,7 @@ ifdef ALT_BOOTDIR ANT_OPTIONS += -Dboot.java.home=$(ALT_BOOTDIR) @@ -841,8 +836,8 @@ diff -Nru openjdk-ecj.orig/langtools/mak ifdef ALT_OUTPUTDIR From dbhole at redhat.com Tue Feb 10 13:20:07 2009 From: dbhole at redhat.com (Deepak Bhole) Date: Tue, 10 Feb 2009 21:20:07 +0000 Subject: changeset in /hg/icedtea6: Fix harmless, but annoying OOB except... Message-ID: changeset 3b8dcbd3d44d in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=3b8dcbd3d44d description: Fix harmless, but annoying OOB exception on browser exit. Fix exit permission checks. diffstat: 5 files changed, 44 insertions(+), 5 deletions(-) ChangeLog | 10 +++++ plugin/icedtea/sun/applet/PluginAppletSecurityContext.java | 3 + plugin/icedtea/sun/applet/PluginStreamHandler.java | 5 ++ rt/net/sourceforge/jnlp/runtime/JNLPRuntime.java | 9 ++++ rt/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java | 22 ++++++++++-- diffs (132 lines): diff -r c402774cf211 -r 3b8dcbd3d44d ChangeLog --- a/ChangeLog Sun Feb 08 08:33:04 2009 -0500 +++ b/ChangeLog Tue Feb 10 16:19:54 2009 -0500 @@ -1,3 +1,13 @@ 2009-02-08 Lillian Angel + * plugin/icedtea/sun/applet/PluginAppletSecurityContext.java: Fix + exit permissions for applets. + * plugin/icedtea/sun/applet/PluginStreamHandler.java: Fix harmless, but + annoying OOB exception on browser exit. + * rt/net/sourceforge/jnlp/runtime/JNLPRuntime.java: Add function to + 'always' disable exit. + * rt/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java: Same, and + update support in checkPermission() for exit permissions. + 2009-02-08 Lillian Angel * Makefile.am: Updated sed to search for OpenJDK instead of IcedTea6. diff -r c402774cf211 -r 3b8dcbd3d44d plugin/icedtea/sun/applet/PluginAppletSecurityContext.java --- a/plugin/icedtea/sun/applet/PluginAppletSecurityContext.java Sun Feb 08 08:33:04 2009 -0500 +++ b/plugin/icedtea/sun/applet/PluginAppletSecurityContext.java Tue Feb 10 16:19:54 2009 -0500 @@ -54,7 +54,6 @@ import java.security.PrivilegedAction; import java.security.PrivilegedAction; import java.security.ProtectionDomain; import java.util.ArrayList; -import java.util.HashMap; import java.util.Hashtable; import java.util.List; @@ -251,6 +250,8 @@ public class PluginAppletSecurityContext if (System.getSecurityManager() == null) { JNLPRuntime.initialize(); } + + JNLPRuntime.disableExit(); this.classLoaders.put(liveconnectLoader, "file://"); } diff -r c402774cf211 -r 3b8dcbd3d44d plugin/icedtea/sun/applet/PluginStreamHandler.java --- a/plugin/icedtea/sun/applet/PluginStreamHandler.java Sun Feb 08 08:33:04 2009 -0500 +++ b/plugin/icedtea/sun/applet/PluginStreamHandler.java Tue Feb 10 16:19:54 2009 -0500 @@ -221,7 +221,10 @@ public class PluginStreamHandler { String rest = ""; String[] msgComponents = message.split(" "); - + + if (msgComponents.length < 2) + return; + // type and identifier are guaranteed to be there String type = msgComponents[0]; final int identifier = Integer.parseInt(msgComponents[1]); diff -r c402774cf211 -r 3b8dcbd3d44d rt/net/sourceforge/jnlp/runtime/JNLPRuntime.java --- a/rt/net/sourceforge/jnlp/runtime/JNLPRuntime.java Sun Feb 08 08:33:04 2009 -0500 +++ b/rt/net/sourceforge/jnlp/runtime/JNLPRuntime.java Tue Feb 10 16:19:54 2009 -0500 @@ -285,6 +285,15 @@ public class JNLPRuntime { checkExitClass(); security.setExitClass(exitClass); } + + /** + * Disables applets from calling exit. + * + * Once disabled, exit cannot be re-enabled for the duration of the JVM instance + */ + public static void disableExit() { + security.disableExit(); + } /** * Return the current Application, or null if none can be diff -r c402774cf211 -r 3b8dcbd3d44d rt/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java --- a/rt/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Sun Feb 08 08:33:04 2009 -0500 +++ b/rt/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java Tue Feb 10 16:19:54 2009 -0500 @@ -23,6 +23,7 @@ import java.awt.event.WindowEvent; import java.awt.event.WindowEvent; import java.lang.ref.WeakReference; import java.net.SocketPermission; +import java.security.AccessControlException; import java.security.AccessController; import java.security.Permission; import java.security.PrivilegedAction; @@ -102,6 +103,9 @@ class JNLPSecurityManager extends Securi /** listener installs the app's classloader on the event dispatch thread */ private ContextUpdater contextListener = new ContextUpdater(); + + /** Sets whether or not exit is allowed (in the context of the plugin, this is always false) */ + private boolean exitAllowed = true; private class ContextUpdater extends WindowAdapter implements PrivilegedAction { private ApplicationInstance app = null; @@ -275,7 +279,7 @@ class JNLPSecurityManager extends Securi try { super.checkPermission(perm); } catch (SecurityException se) { - + //This section is a special case for dealing with SocketPermissions. if (JNLPRuntime.isDebug()) System.err.println("Requesting permission: " + perm.toString()); @@ -436,9 +440,17 @@ class JNLPSecurityManager extends Securi * behave normally, and the exit class can always exit the JVM. */ public void checkExit(int status) { - super.checkExit(status); - + + // applets are not allowed to exit, but the plugin main class (primordial loader) is Class stack[] = getClassContext(); + if (!exitAllowed) { + for (int i=0; i < stack.length; i++) + if (stack[i].getClassLoader() != null) + throw new AccessControlException("Applets may not call System.exit()"); + } + + super.checkExit(status); + boolean realCall = (stack[1] == Runtime.class); if (isExitClass(stack)) // either exitClass called or no exitClass set @@ -468,6 +480,10 @@ class JNLPSecurityManager extends Securi throw closeAppEx; } + protected void disableExit() { + exitAllowed = false; + } + } From ahughes at redhat.com Tue Feb 10 18:18:55 2009 From: ahughes at redhat.com (Andrew John Hughes) Date: Wed, 11 Feb 2009 02:18:55 +0000 Subject: changeset in /hg/icedtea6: Backport newly Freed tests. Message-ID: changeset 5d4d8012aa03 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=5d4d8012aa03 description: Backport newly Freed tests. 2009-02-11 Andrew John Hughes * Makefile.am: Add new patches. * patches/openjdk/bidi-tests.patch, * patches/openjdk/annotation-tests.patch: New. diffstat: 4 files changed, 6174 insertions(+), 1 deletion(-) ChangeLog | 9 Makefile.am | 4 patches/openjdk/annotation-tests.patch | 5867 ++++++++++++++++++++++++++++++++ patches/openjdk/bidi-tests.patch | 295 + diffs (truncated from 6201 to 500 lines): diff -r 3b8dcbd3d44d -r 5d4d8012aa03 ChangeLog --- a/ChangeLog Tue Feb 10 16:19:54 2009 -0500 +++ b/ChangeLog Wed Feb 11 02:18:27 2009 +0000 @@ -1,4 +1,13 @@ 2009-02-10 Deepak Bhole + + * Makefile.am: + Add new patches. + * patches/openjdk/bidi-tests.patch, + * patches/openjdk/annotation-tests.patch: + New. + 2009-02-10 Deepak Bhole + * plugin/icedtea/sun/applet/PluginAppletSecurityContext.java: Fix exit permissions for applets. * plugin/icedtea/sun/applet/PluginStreamHandler.java: Fix harmless, but diff -r 3b8dcbd3d44d -r 5d4d8012aa03 Makefile.am --- a/Makefile.am Tue Feb 10 16:19:54 2009 -0500 +++ b/Makefile.am Wed Feb 11 02:18:27 2009 +0000 @@ -563,7 +563,9 @@ ICEDTEA_PATCHES += \ patches/icedtea-io_util-overflow.patch \ patches/icedtea-cc-interp-jvmti.patch \ patches/icedtea-pr261.patch \ - patches/icedtea-doc-headers.patch + patches/icedtea-doc-headers.patch \ + patches/openjdk/bidi-tests.patch \ + patches/openjdk/annotation-tests.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ diff -r 3b8dcbd3d44d -r 5d4d8012aa03 patches/openjdk/annotation-tests.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/annotation-tests.patch Wed Feb 11 02:18:27 2009 +0000 @@ -0,0 +1,5867 @@ +# HG changeset patch +# User darcy +# Date 1233028166 28800 +# Node ID f3ad2ee4600b102d50a18d83aa797e187819e072 +# Parent 175b6adf65b31782480878f5a65044b4c97fd7cf +6740185: Move java/lang/annotations tests to open +Reviewed-by: jjg + +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/AnnotationTypeMismatchException/FoundType.java openjdk/jdk/test/java/lang/annotation/AnnotationTypeMismatchException/FoundType.java +--- openjdk.orig/jdk/test/java/lang/annotation/AnnotationTypeMismatchException/FoundType.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/AnnotationTypeMismatchException/FoundType.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,44 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 6179014 ++ * @summary AnnotationTypeMismatchException.foundType method shouldn't loop. ++ * @author Scott Seligman ++ * @run main/timeout=30 FoundType ++ */ ++ ++import java.lang.annotation.*; ++ ++public class FoundType { ++ ++ private static final String TYPE = "a.halting.Problem"; ++ ++ public static void main(String[] args) { ++ AnnotationTypeMismatchException ex = ++ new AnnotationTypeMismatchException(null, TYPE); ++ if (!TYPE.equals(ex.foundType())) ++ throw new Error(); ++ } ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/A.java openjdk/jdk/test/java/lang/annotation/loaderLeak/A.java +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/A.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/A.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,28 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++public ++ at java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.RUNTIME) ++ at interface A { ++ B b(); ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/B.java openjdk/jdk/test/java/lang/annotation/loaderLeak/B.java +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/B.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/B.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,24 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++public @interface B {} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/C.java openjdk/jdk/test/java/lang/annotation/loaderLeak/C.java +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/C.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/C.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,24 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++public @A(b=@B()) class C {} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh openjdk/jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh 2009-02-05 08:45:04.000000000 +0000 +@@ -0,0 +1,84 @@ ++#!/bin/sh ++ ++# Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++# ++# This code is free software; you can redistribute it and/or modify it ++# under the terms of the GNU General Public License version 2 only, as ++# published by the Free Software Foundation. ++# ++# This code is distributed in the hope that it will be useful, but WITHOUT ++# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++# version 2 for more details (a copy is included in the LICENSE file that ++# accompanied this code). ++# ++# You should have received a copy of the GNU General Public License version ++# 2 along with this work; if not, write to the Free Software Foundation, ++# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++# ++# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++# CA 95054 USA or visit www.sun.com if you need additional information or ++# have any questions. ++ ++if [ "${TESTSRC}" = "" ] ++then ++ echo "TESTSRC not set. Test cannot execute. Failed." ++ exit 1 ++fi ++echo "TESTSRC=${TESTSRC}" ++if [ "${TESTJAVA}" = "" ] ++then ++ echo "TESTJAVA not set. Test cannot execute. Failed." ++ exit 1 ++fi ++echo "TESTJAVA=${TESTJAVA}" ++if [ "${TESTCLASSES}" = "" ] ++then ++ echo "TESTCLASSES not set. Test cannot execute. Failed." ++ exit 1 ++fi ++echo "TESTCLASSES=${TESTCLASSES}" ++echo "CLASSPATH=${CLASSPATH}" ++ ++# set platform-dependent variables ++OS=`uname -s` ++case "$OS" in ++ SunOS | Linux ) ++ NULL=/dev/null ++ PS=":" ++ FS="/" ++ ;; ++ Windows* ) ++ NULL=NUL ++ PS=";" ++ FS="\\" ++ ;; ++ * ) ++ echo "Unrecognized system!" ++ exit 1; ++ ;; ++esac ++ ++mkdir -p classes ++cp ${TESTSRC}${FS}*.java . ++${TESTJAVA}${FS}bin${FS}javac -d classes A.java B.java C.java ++${TESTJAVA}${FS}bin${FS}javac Main.java ++${TESTJAVA}${FS}bin${FS}java Main ++result=$? ++if [ $result -eq 0 ] ++then ++ echo "Passed 1 of 2" ++else ++ echo "Failed 1 of 2" ++ exit $result ++fi ++${TESTJAVA}${FS}bin${FS}java Main foo ++result=$? ++if [ $result -eq 0 ] ++then ++ echo "Passed 2 of 2" ++else ++ echo "Failed 2 of 2" ++fi ++exit $result +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/Main.java openjdk/jdk/test/java/lang/annotation/loaderLeak/Main.java +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/Main.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/Main.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,127 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 5040740 ++ * @summary annotations cause memory leak ++ * @author gafter ++ * ++ * @run shell LoaderLeak.sh ++ */ ++ ++import java.net.*; ++import java.lang.ref.*; ++import java.util.*; ++import java.io.*; ++ ++public class Main { ++ public static void main(String[] args) throws Exception { ++ for (int i=0; i<100; i++) ++ doTest(args.length != 0); ++ } ++ ++ static void doTest(boolean readAnn) throws Exception { ++ // URL classes = new URL("file://" + System.getProperty("user.dir") + "/classes"); ++ // URL[] path = { classes }; ++ // URLClassLoader loader = new URLClassLoader(path); ++ ClassLoader loader = new SimpleClassLoader(); ++ WeakReference> c = new WeakReference(loader.loadClass("C")); ++ if (c.get() == null) throw new AssertionError(); ++ if (c.get().getClassLoader() != loader) throw new AssertionError(); ++ if (readAnn) System.out.println(c.get().getAnnotations()[0]); ++ if (c.get() == null) throw new AssertionError(); ++ System.gc(); ++ System.gc(); ++ if (c.get() == null) throw new AssertionError(); ++ System.gc(); ++ System.gc(); ++ loader = null; ++ System.gc(); ++ System.gc(); ++ if (c.get() != null) throw new AssertionError(); ++ } ++} ++ ++class SimpleClassLoader extends ClassLoader { ++ private Hashtable classes = new Hashtable(); ++ ++ public SimpleClassLoader() { ++ } ++ private byte getClassImplFromDataBase(String className)[] { ++ byte result[]; ++ try { ++ FileInputStream fi = new FileInputStream("classes/"+className+".class"); ++ result = new byte[fi.available()]; ++ fi.read(result); ++ return result; ++ } catch (Exception e) { ++ ++ /* ++ * If we caught an exception, either the class wasnt found or it ++ * was unreadable by our process. ++ */ ++ return null; ++ } ++ } ++ public Class loadClass(String className) throws ClassNotFoundException { ++ return (loadClass(className, true)); ++ } ++ public synchronized Class loadClass(String className, boolean resolveIt) ++ throws ClassNotFoundException { ++ Class result; ++ byte classData[]; ++ ++ /* Check our local cache of classes */ ++ result = (Class)classes.get(className); ++ if (result != null) { ++ return result; ++ } ++ ++ /* Check with the primordial class loader */ ++ try { ++ result = super.findSystemClass(className); ++ return result; ++ } catch (ClassNotFoundException e) { ++ } ++ ++ /* Try to load it from our repository */ ++ classData = getClassImplFromDataBase(className); ++ if (classData == null) { ++ throw new ClassNotFoundException(); ++ } ++ ++ /* Define it (parse the class file) */ ++ result = defineClass(classData, 0, classData.length); ++ if (result == null) { ++ throw new ClassFormatError(); ++ } ++ ++ if (resolveIt) { ++ resolveClass(result); ++ } ++ ++ classes.put(className, result); ++ return result; ++ } ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/A.java openjdk/jdk/test/java/lang/annotation/Missing/A.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/A.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/A.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,30 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/** ++ * Class to have a missing annotation applied for running MissingTest. ++ */ ++ at Missing ++ at Marker ++public class A { ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/B.java openjdk/jdk/test/java/lang/annotation/Missing/B.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/B.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/B.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,31 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/** ++ * Class to have an indirectly missing annotation applied for for ++ * running MisssingTest. ++ */ ++ at MissingWrapper(@Missing) ++ at Marker ++public class B { ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/C.java openjdk/jdk/test/java/lang/annotation/Missing/C.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/C.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/C.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,31 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/** ++ * Class to have a missing annotation applied for running MissingTest. ++ */ ++public class C { ++ public void method1(@Missing @Marker Object param1) { ++ return; From gnu_andrew at member.fsf.org Tue Feb 10 18:17:33 2009 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Wed, 11 Feb 2009 02:17:33 +0000 Subject: FYI: Backport newly Freed tests from OpenJDK7 Message-ID: <20090211021733.GA6617@rivendell.middle-earth.co.uk> A number of additional JTReg tests were Freed for OpenJDK7 b46. This patch backports them to IcedTea6. ChangeLog: 2009-02-11 Andrew John Hughes * Makefile.am: Add new patches. * patches/openjdk/bidi-tests.patch, * patches/openjdk/annotation-tests.patch: New. -- Andrew :) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint = F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 -------------- next part -------------- diff -r 3b8dcbd3d44d Makefile.am --- a/Makefile.am Tue Feb 10 16:19:54 2009 -0500 +++ b/Makefile.am Wed Feb 11 02:15:37 2009 +0000 @@ -563,7 +563,9 @@ patches/icedtea-io_util-overflow.patch \ patches/icedtea-cc-interp-jvmti.patch \ patches/icedtea-pr261.patch \ - patches/icedtea-doc-headers.patch + patches/icedtea-doc-headers.patch \ + patches/openjdk/bidi-tests.patch \ + patches/openjdk/annotation-tests.patch if WITH_ALT_HSBUILD ICEDTEA_PATCHES += \ diff -r 3b8dcbd3d44d patches/openjdk/annotation-tests.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/annotation-tests.patch Wed Feb 11 02:15:37 2009 +0000 @@ -0,0 +1,5867 @@ +# HG changeset patch +# User darcy +# Date 1233028166 28800 +# Node ID f3ad2ee4600b102d50a18d83aa797e187819e072 +# Parent 175b6adf65b31782480878f5a65044b4c97fd7cf +6740185: Move java/lang/annotations tests to open +Reviewed-by: jjg + +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/AnnotationTypeMismatchException/FoundType.java openjdk/jdk/test/java/lang/annotation/AnnotationTypeMismatchException/FoundType.java +--- openjdk.orig/jdk/test/java/lang/annotation/AnnotationTypeMismatchException/FoundType.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/AnnotationTypeMismatchException/FoundType.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,44 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 6179014 ++ * @summary AnnotationTypeMismatchException.foundType method shouldn't loop. ++ * @author Scott Seligman ++ * @run main/timeout=30 FoundType ++ */ ++ ++import java.lang.annotation.*; ++ ++public class FoundType { ++ ++ private static final String TYPE = "a.halting.Problem"; ++ ++ public static void main(String[] args) { ++ AnnotationTypeMismatchException ex = ++ new AnnotationTypeMismatchException(null, TYPE); ++ if (!TYPE.equals(ex.foundType())) ++ throw new Error(); ++ } ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/A.java openjdk/jdk/test/java/lang/annotation/loaderLeak/A.java +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/A.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/A.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,28 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++public ++ at java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.RUNTIME) ++ at interface A { ++ B b(); ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/B.java openjdk/jdk/test/java/lang/annotation/loaderLeak/B.java +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/B.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/B.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,24 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++public @interface B {} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/C.java openjdk/jdk/test/java/lang/annotation/loaderLeak/C.java +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/C.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/C.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,24 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++public @A(b=@B()) class C {} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh openjdk/jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/LoaderLeak.sh 2009-02-05 08:45:04.000000000 +0000 +@@ -0,0 +1,84 @@ ++#!/bin/sh ++ ++# Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++# ++# This code is free software; you can redistribute it and/or modify it ++# under the terms of the GNU General Public License version 2 only, as ++# published by the Free Software Foundation. ++# ++# This code is distributed in the hope that it will be useful, but WITHOUT ++# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++# version 2 for more details (a copy is included in the LICENSE file that ++# accompanied this code). ++# ++# You should have received a copy of the GNU General Public License version ++# 2 along with this work; if not, write to the Free Software Foundation, ++# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++# ++# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++# CA 95054 USA or visit www.sun.com if you need additional information or ++# have any questions. ++ ++if [ "${TESTSRC}" = "" ] ++then ++ echo "TESTSRC not set. Test cannot execute. Failed." ++ exit 1 ++fi ++echo "TESTSRC=${TESTSRC}" ++if [ "${TESTJAVA}" = "" ] ++then ++ echo "TESTJAVA not set. Test cannot execute. Failed." ++ exit 1 ++fi ++echo "TESTJAVA=${TESTJAVA}" ++if [ "${TESTCLASSES}" = "" ] ++then ++ echo "TESTCLASSES not set. Test cannot execute. Failed." ++ exit 1 ++fi ++echo "TESTCLASSES=${TESTCLASSES}" ++echo "CLASSPATH=${CLASSPATH}" ++ ++# set platform-dependent variables ++OS=`uname -s` ++case "$OS" in ++ SunOS | Linux ) ++ NULL=/dev/null ++ PS=":" ++ FS="/" ++ ;; ++ Windows* ) ++ NULL=NUL ++ PS=";" ++ FS="\\" ++ ;; ++ * ) ++ echo "Unrecognized system!" ++ exit 1; ++ ;; ++esac ++ ++mkdir -p classes ++cp ${TESTSRC}${FS}*.java . ++${TESTJAVA}${FS}bin${FS}javac -d classes A.java B.java C.java ++${TESTJAVA}${FS}bin${FS}javac Main.java ++${TESTJAVA}${FS}bin${FS}java Main ++result=$? ++if [ $result -eq 0 ] ++then ++ echo "Passed 1 of 2" ++else ++ echo "Failed 1 of 2" ++ exit $result ++fi ++${TESTJAVA}${FS}bin${FS}java Main foo ++result=$? ++if [ $result -eq 0 ] ++then ++ echo "Passed 2 of 2" ++else ++ echo "Failed 2 of 2" ++fi ++exit $result +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/Main.java openjdk/jdk/test/java/lang/annotation/loaderLeak/Main.java +--- openjdk.orig/jdk/test/java/lang/annotation/loaderLeak/Main.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/loaderLeak/Main.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,127 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 5040740 ++ * @summary annotations cause memory leak ++ * @author gafter ++ * ++ * @run shell LoaderLeak.sh ++ */ ++ ++import java.net.*; ++import java.lang.ref.*; ++import java.util.*; ++import java.io.*; ++ ++public class Main { ++ public static void main(String[] args) throws Exception { ++ for (int i=0; i<100; i++) ++ doTest(args.length != 0); ++ } ++ ++ static void doTest(boolean readAnn) throws Exception { ++ // URL classes = new URL("file://" + System.getProperty("user.dir") + "/classes"); ++ // URL[] path = { classes }; ++ // URLClassLoader loader = new URLClassLoader(path); ++ ClassLoader loader = new SimpleClassLoader(); ++ WeakReference> c = new WeakReference(loader.loadClass("C")); ++ if (c.get() == null) throw new AssertionError(); ++ if (c.get().getClassLoader() != loader) throw new AssertionError(); ++ if (readAnn) System.out.println(c.get().getAnnotations()[0]); ++ if (c.get() == null) throw new AssertionError(); ++ System.gc(); ++ System.gc(); ++ if (c.get() == null) throw new AssertionError(); ++ System.gc(); ++ System.gc(); ++ loader = null; ++ System.gc(); ++ System.gc(); ++ if (c.get() != null) throw new AssertionError(); ++ } ++} ++ ++class SimpleClassLoader extends ClassLoader { ++ private Hashtable classes = new Hashtable(); ++ ++ public SimpleClassLoader() { ++ } ++ private byte getClassImplFromDataBase(String className)[] { ++ byte result[]; ++ try { ++ FileInputStream fi = new FileInputStream("classes/"+className+".class"); ++ result = new byte[fi.available()]; ++ fi.read(result); ++ return result; ++ } catch (Exception e) { ++ ++ /* ++ * If we caught an exception, either the class wasnt found or it ++ * was unreadable by our process. ++ */ ++ return null; ++ } ++ } ++ public Class loadClass(String className) throws ClassNotFoundException { ++ return (loadClass(className, true)); ++ } ++ public synchronized Class loadClass(String className, boolean resolveIt) ++ throws ClassNotFoundException { ++ Class result; ++ byte classData[]; ++ ++ /* Check our local cache of classes */ ++ result = (Class)classes.get(className); ++ if (result != null) { ++ return result; ++ } ++ ++ /* Check with the primordial class loader */ ++ try { ++ result = super.findSystemClass(className); ++ return result; ++ } catch (ClassNotFoundException e) { ++ } ++ ++ /* Try to load it from our repository */ ++ classData = getClassImplFromDataBase(className); ++ if (classData == null) { ++ throw new ClassNotFoundException(); ++ } ++ ++ /* Define it (parse the class file) */ ++ result = defineClass(classData, 0, classData.length); ++ if (result == null) { ++ throw new ClassFormatError(); ++ } ++ ++ if (resolveIt) { ++ resolveClass(result); ++ } ++ ++ classes.put(className, result); ++ return result; ++ } ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/A.java openjdk/jdk/test/java/lang/annotation/Missing/A.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/A.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/A.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,30 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/** ++ * Class to have a missing annotation applied for running MissingTest. ++ */ ++ at Missing ++ at Marker ++public class A { ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/B.java openjdk/jdk/test/java/lang/annotation/Missing/B.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/B.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/B.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,31 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/** ++ * Class to have an indirectly missing annotation applied for for ++ * running MisssingTest. ++ */ ++ at MissingWrapper(@Missing) ++ at Marker ++public class B { ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/C.java openjdk/jdk/test/java/lang/annotation/Missing/C.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/C.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/C.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,31 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/** ++ * Class to have a missing annotation applied for running MissingTest. ++ */ ++public class C { ++ public void method1(@Missing @Marker Object param1) { ++ return; ++ } ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/D.java openjdk/jdk/test/java/lang/annotation/Missing/D.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/D.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/D.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,31 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/** ++ * Class to have a missing annotation applied for running MissingTest. ++ */ ++public class D { ++ public void method1(@MissingWrapper(@Missing) @Marker Object param1) { ++ return; ++ } ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/Marker.java openjdk/jdk/test/java/lang/annotation/Missing/Marker.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/Marker.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/Marker.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,32 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++import java.lang.annotation.Retention; ++import static java.lang.annotation.RetentionPolicy.*; ++ ++/** ++ * A marker annotation. Used so that at least one annotation will be ++ * present on the classes tested by MissingTest. ++ */ ++ at Retention(RUNTIME) ++public @interface Marker {} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/Missing.java openjdk/jdk/test/java/lang/annotation/Missing/Missing.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/Missing.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/Missing.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,32 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++import java.lang.annotation.Retention; ++import static java.lang.annotation.RetentionPolicy.*; ++ ++/** ++ * The class file for this annotation type is missing when MissingTest ++ * is run. ++ */ ++ at Retention(RUNTIME) ++public @interface Missing {} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/MissingTest.java openjdk/jdk/test/java/lang/annotation/Missing/MissingTest.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/MissingTest.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/MissingTest.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,135 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 6322301 ++ * @summary Verify when missing annotation classes cause exceptions ++ * @author Joseph D. Darcy ++ * @compile MissingTest.java A.java B.java C.java D.java Marker.java Missing.java MissingWrapper.java ++ * @clean Missing ++ * @run main MissingTest ++ */ ++ ++import java.lang.reflect.*; ++ ++/** ++ * This test verifies that a missing annotation class leads to the ++ * expected exceptional behavior; a missing directly applied ++ * annotation is currently ignored but a missing annotation value ++ * inside another annotation throws an exception. ++ * ++ * To be run as intended, the annotation type Missing should *not* be ++ * on the classpath when the test is run; with jtreg, it is deleted by ++ * the @clean directive. ++ */ ++public class MissingTest { ++ /** ++ * For the annotated element argument, get all its annotations and ++ * see whether or not an exception is throw upon reading the ++ * annotations. Additionally, verify at least one annotation is ++ * present. ++ */ ++ private static void testAnnotation(AnnotatedElement element, ++ boolean exceptionExpected) { ++ java.lang.annotation.Annotation[] annotations; ++ try { ++ annotations = element.getAnnotations(); ++ if (exceptionExpected) { ++ System.err.println("Error: Did not get an exception reading annotations on " ++ + element); ++ System.err.println("Annotations found: " ++ + java.util.Arrays.toString(annotations)); ++ throw new RuntimeException(); ++ } ++ if (annotations.length == 0) { ++ System.err.println("Error: no annotations found on " + element); ++ throw new RuntimeException(); ++ } ++ } catch (Throwable t) { ++ if (!exceptionExpected) { ++ System.err.println("Error: Got an unexpected exception reading annotations on " ++ + element); ++ throw new RuntimeException(t); ++ } ++ } ++ } ++ ++ /** ++ * For the annotated element argument, get all its annotations and ++ * see whether or not an exception is throw upon reading the ++ * annotations. Additionally, verify at least one annotation is ++ * present. ++ */ ++ private static void testParameterAnnotation(Method m, ++ boolean exceptionExpected) { ++ java.lang.annotation.Annotation[][] annotationsArray; ++ try { ++ annotationsArray = m.getParameterAnnotations(); ++ if (exceptionExpected) { ++ System.err.println("Error: Did not get an exception reading annotations on method" ++ + m); ++ System.err.println("Annotations found: " ++ + java.util.Arrays.toString(annotationsArray)); ++ throw new RuntimeException(); ++ } ++ if (annotationsArray.length == 0 ) { ++ System.err.println("Error: no parameters for " + m); ++ throw new RuntimeException(); ++ } else { ++ java.lang.annotation.Annotation[] annotations = annotationsArray[0]; ++ if (annotations.length == 0) { ++ System.err.println("Error: no annotations on " + m); ++ throw new RuntimeException(); ++ } ++ } ++ } catch (Throwable t) { ++ if (!exceptionExpected) { ++ System.err.println("Error: Got an unexpected exception reading annotations on " ++ + m); ++ throw new RuntimeException(t); ++ } ++ } ++ } ++ ++ public static void main(String argv[]) throws Exception { ++ // Class A has a directly applied annotation whose class is ++ // missing. ++ testAnnotation(A.class, false); ++ ++ // Class B has a directly applied annotation whose value ++ // includes to an annotation class that is missing. ++ testAnnotation(B.class, true); ++ ++ ++ // Class C has a directly applied parameter annotation whose ++ // class is missing. ++ testParameterAnnotation(C.class.getDeclaredMethod("method1", Object.class), ++ false); ++ ++ // Class D has a directly applied parameter annotation whose value ++ // includes to an annotation class that is missing. ++ testParameterAnnotation(D.class.getDeclaredMethod("method1", Object.class), ++ true); ++ } ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/Missing/MissingWrapper.java openjdk/jdk/test/java/lang/annotation/Missing/MissingWrapper.java +--- openjdk.orig/jdk/test/java/lang/annotation/Missing/MissingWrapper.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/Missing/MissingWrapper.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,34 @@ ++/* ++ * Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++import java.lang.annotation.Retention; ++import static java.lang.annotation.RetentionPolicy.*; ++ ++/** ++ * Annotation wrapper around an annotation whose class will be missing ++ * when MissingTest is run. ++ */ ++ at Retention(RUNTIME) ++public @interface MissingWrapper { ++ Missing value(); ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/package-info.java openjdk/jdk/test/java/lang/annotation/package-info.java +--- openjdk.orig/jdk/test/java/lang/annotation/package-info.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/package-info.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,37 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 4901290 5037531 ++ * @summary Package annotations ++ * @author gafter ++ * ++ * @compile -source 1.5 package-info.java PackageMain.java ++ * @run main PackageMain ++ */ ++ ++ at java.lang.annotation.Documented ++package foo.bar; ++ ++class Baz {} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/PackageMain.java openjdk/jdk/test/java/lang/annotation/PackageMain.java +--- openjdk.orig/jdk/test/java/lang/annotation/PackageMain.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/PackageMain.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,36 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++import java.lang.annotation.Documented; ++ ++public class PackageMain { ++ public static void main(String[] args) throws Exception { ++ Class c = Class.forName("foo.bar.Baz"); ++ System.out.println("c=" + c); ++ System.out.println("cl=" + c.getClassLoader()); ++ Package p = c.getPackage(); ++ System.out.println("p=" + p); ++ Documented d = p.getAnnotation(Documented.class); ++ if (d == null) throw new Error(); ++ } ++} +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/RecursiveAnnotation.java openjdk/jdk/test/java/lang/annotation/RecursiveAnnotation.java +--- openjdk.orig/jdk/test/java/lang/annotation/RecursiveAnnotation.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/RecursiveAnnotation.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,44 @@ ++/* ++ * Copyright 2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 5037685 ++ * @summary Under certain circumstances, recursive annotations disappeared ++ * @author Josh Bloch ++ */ ++ ++import java.lang.annotation.*; ++import static java.lang.annotation.RetentionPolicy.*; ++ ++ at Rat public class RecursiveAnnotation { ++ public static void main(String[] args) { ++ if (!RecursiveAnnotation.class.isAnnotationPresent(Rat.class)) ++ throw new RuntimeException("RecursiveAnnotation"); ++ ++ if (!Rat.class.isAnnotationPresent(Rat.class)) ++ throw new RuntimeException("Rat"); ++ } ++} ++ ++ at Retention(RUNTIME) @Rat @interface Rat { } +diff -Nru openjdk.orig/jdk/test/java/lang/annotation/UnitTest.java openjdk/jdk/test/java/lang/annotation/UnitTest.java +--- openjdk.orig/jdk/test/java/lang/annotation/UnitTest.java 1970-01-01 01:00:00.000000000 +0100 ++++ openjdk/jdk/test/java/lang/annotation/UnitTest.java 2009-02-11 00:58:01.000000000 +0000 +@@ -0,0 +1,4983 @@ ++/* ++ * Copyright 2003-2004 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 4906359 4963461 4965058 4965039 4986770 ++ * @summary Unit test for annotation reading ++ * @author Josh Bloch ++ * @compile -source 1.5 UnitTest.java ++ * @run main UnitTest ++ */ ++ ++import static java.lang.annotation.RetentionPolicy.RUNTIME; ++ ++import java.lang.annotation.*; ++import java.util.*; ++import java.lang.reflect.*; ++import java.io.*; ++ ++public class UnitTest { ++ private static final Class[] X = new Class[0]; ++ private static final Class[] Y = { int.class }; ++ ++ static int numTests = 0; ++ ++ public static void main(String[] args) throws Exception { ++ ++ // *** TESTS ON ANNOTATED METHODS *** ++ ++ // MULTIMEMBER SCALAR TYPES ON METHOD ++ checkScalarTypes(UnitTest.class.getMethod("scalarTypesMethod", X)); ++ checkScalarTypesOverrideDefault(UnitTest.class.getMethod("scalarTypesOverrideDefaultMethod", X)); ++ checkScalarTypesAcceptDefault(UnitTest.class.getMethod("scalarTypesAcceptDefaultMethod", X)); ++ ++ // MULTIMEMBER ARRAY TYPES ON METHOD ++ checkArrayTypes0(UnitTest.class.getMethod("emptyArrayTypesMethod", X)); ++ checkArrayTypes1(UnitTest.class.getMethod("singleElementArrayTypesMethod", X)); ++ checkArrayTypes2(UnitTest.class.getMethod("twoElementArrayTypesMethod", X)); ++ checkArrayTypesAcceptDefault(UnitTest.class.getMethod("arrayTypesAcceptDefaultMethod", X)); ++ checkArrayTypesOverrideDefault(UnitTest.class.getMethod("arrayTypesOverrideDefaultMethod", X)); ++ ++ // MARKER TYPE ON METHOD ++ checkMarker(UnitTest.class.getMethod("markerMethod", X)); ++ ++ // SINGLE-MEMBER SCALAR TYPES ON METHOD ++ checkSingleMemberByte(UnitTest.class.getMethod("SingleMemberByte", X)); ++ checkSingleMemberShort(UnitTest.class.getMethod("SingleMemberShort", X)); ++ checkSingleMemberInt(UnitTest.class.getMethod("SingleMemberInt", X)); ++ checkSingleMemberLong(UnitTest.class.getMethod("SingleMemberLong", X)); ++ checkSingleMemberChar(UnitTest.class.getMethod("SingleMemberChar", X)); ++ checkSingleMemberFloat(UnitTest.class.getMethod("SingleMemberFloat", X)); ++ checkSingleMemberDouble(UnitTest.class.getMethod("SingleMemberDouble", X)); ++ checkSingleMemberBoolean(UnitTest.class.getMethod("SingleMemberBoolean", X)); ++ checkSingleMemberString(UnitTest.class.getMethod("SingleMemberString", X)); ++ checkSingleMemberClass(UnitTest.class.getMethod("SingleMemberClass", X)); ++ checkSingleMemberEnum(UnitTest.class.getMethod("SingleMemberEnum", X)); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ON METHOD ++ checkSingleMemberByteOvrdDef(UnitTest.class.getMethod("SingleMemberByteOvrdDef", X)); ++ checkSingleMemberShortOvrdDef(UnitTest.class.getMethod("SingleMemberShortOvrdDef", X)); ++ checkSingleMemberIntOvrdDef(UnitTest.class.getMethod("SingleMemberIntOvrdDef", X)); ++ checkSingleMemberLongOvrdDef(UnitTest.class.getMethod("SingleMemberLongOvrdDef", X)); ++ checkSingleMemberCharOvrdDef(UnitTest.class.getMethod("SingleMemberCharOvrdDef", X)); ++ checkSingleMemberFloatOvrdDef(UnitTest.class.getMethod("SingleMemberFloatOvrdDef", X)); ++ checkSingleMemberDoubleOvrdDef(UnitTest.class.getMethod("SingleMemberDoubleOvrdDef", X)); ++ checkSingleMemberBooleanOvrdDef(UnitTest.class.getMethod("SingleMemberBooleanOvrdDef", X)); ++ checkSingleMemberStringOvrdDef(UnitTest.class.getMethod("SingleMemberStringOvrdDef", X)); ++ checkSingleMemberClassOvrdDef(UnitTest.class.getMethod("SingleMemberClassOvrdDef", X)); ++ checkSingleMemberEnumOvrdDef(UnitTest.class.getMethod("SingleMemberEnumOvrdDef", X)); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ON METHOD ++ checkSingleMemberByteAcceptDef(UnitTest.class.getMethod("SingleMemberByteAcceptDef", X)); ++ checkSingleMemberShortAcceptDef(UnitTest.class.getMethod("SingleMemberShortAcceptDef", X)); ++ checkSingleMemberIntAcceptDef(UnitTest.class.getMethod("SingleMemberIntAcceptDef", X)); ++ checkSingleMemberLongAcceptDef(UnitTest.class.getMethod("SingleMemberLongAcceptDef", X)); ++ checkSingleMemberCharAcceptDef(UnitTest.class.getMethod("SingleMemberCharAcceptDef", X)); ++ checkSingleMemberFloatAcceptDef(UnitTest.class.getMethod("SingleMemberFloatAcceptDef", X)); ++ checkSingleMemberDoubleAcceptDef(UnitTest.class.getMethod("SingleMemberDoubleAcceptDef", X)); ++ checkSingleMemberBooleanAcceptDef(UnitTest.class.getMethod("SingleMemberBooleanAcceptDef", X)); ++ checkSingleMemberStringAcceptDef(UnitTest.class.getMethod("SingleMemberStringAcceptDef", X)); ++ checkSingleMemberClassAcceptDef(UnitTest.class.getMethod("SingleMemberClassAcceptDef", X)); ++ checkSingleMemberEnumAcceptDef(UnitTest.class.getMethod("SingleMemberEnumAcceptDef", X)); ++ ++ // SINGLE-MEMBER ARRAY TYPES (EMPTY ARRAY) ON METHOD ++ checkSingleMemberByteArrEmpty(UnitTest.class.getMethod("SingleMemberByteArrEmpty", X)); ++ checkSingleMemberShortArrEmpty(UnitTest.class.getMethod("SingleMemberShortArrEmpty", X)); ++ checkSingleMemberIntArrEmpty(UnitTest.class.getMethod("SingleMemberIntArrEmpty", X)); ++ checkSingleMemberLongArrEmpty(UnitTest.class.getMethod("SingleMemberLongArrEmpty", X)); ++ checkSingleMemberCharArrEmpty(UnitTest.class.getMethod("SingleMemberCharArrEmpty", X)); ++ checkSingleMemberFloatArrEmpty(UnitTest.class.getMethod("SingleMemberFloatArrEmpty", X)); ++ checkSingleMemberDoubleArrEmpty(UnitTest.class.getMethod("SingleMemberDoubleArrEmpty", X)); ++ checkSingleMemberBooleanArrEmpty(UnitTest.class.getMethod("SingleMemberBooleanArrEmpty", X)); ++ checkSingleMemberStringArrEmpty(UnitTest.class.getMethod("SingleMemberStringArrEmpty", X)); ++ checkSingleMemberClassArrEmpty(UnitTest.class.getMethod("SingleMemberClassArrEmpty", X)); ++ checkSingleMemberEnumArrEmpty(UnitTest.class.getMethod("SingleMemberEnumArrEmpty", X)); ++ ++ // SINGLE-MEMBER ARRAY TYPES (ONE-ELEMENT ARRAY) ON METHOD ++ checkSingleMemberByteArrOne(UnitTest.class.getMethod("SingleMemberByteArrOne", X)); ++ checkSingleMemberShortArrOne(UnitTest.class.getMethod("SingleMemberShortArrOne", X)); ++ checkSingleMemberIntArrOne(UnitTest.class.getMethod("SingleMemberIntArrOne", X)); ++ checkSingleMemberLongArrOne(UnitTest.class.getMethod("SingleMemberLongArrOne", X)); ++ checkSingleMemberCharArrOne(UnitTest.class.getMethod("SingleMemberCharArrOne", X)); ++ checkSingleMemberFloatArrOne(UnitTest.class.getMethod("SingleMemberFloatArrOne", X)); ++ checkSingleMemberDoubleArrOne(UnitTest.class.getMethod("SingleMemberDoubleArrOne", X)); ++ checkSingleMemberBooleanArrOne(UnitTest.class.getMethod("SingleMemberBooleanArrOne", X)); ++ checkSingleMemberStringArrOne(UnitTest.class.getMethod("SingleMemberStringArrOne", X)); ++ checkSingleMemberClassArrOne(UnitTest.class.getMethod("SingleMemberClassArrOne", X)); ++ checkSingleMemberEnumArrOne(UnitTest.class.getMethod("SingleMemberEnumArrOne", X)); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TWO-ELEMENT ARRAY) ON METHOD ++ checkSingleMemberByteArrTwo(UnitTest.class.getMethod("SingleMemberByteArrTwo", X)); ++ checkSingleMemberShortArrTwo(UnitTest.class.getMethod("SingleMemberShortArrTwo", X)); ++ checkSingleMemberIntArrTwo(UnitTest.class.getMethod("SingleMemberIntArrTwo", X)); ++ checkSingleMemberLongArrTwo(UnitTest.class.getMethod("SingleMemberLongArrTwo", X)); ++ checkSingleMemberCharArrTwo(UnitTest.class.getMethod("SingleMemberCharArrTwo", X)); ++ checkSingleMemberFloatArrTwo(UnitTest.class.getMethod("SingleMemberFloatArrTwo", X)); ++ checkSingleMemberDoubleArrTwo(UnitTest.class.getMethod("SingleMemberDoubleArrTwo", X)); ++ checkSingleMemberBooleanArrTwo(UnitTest.class.getMethod("SingleMemberBooleanArrTwo", X)); ++ checkSingleMemberStringArrTwo(UnitTest.class.getMethod("SingleMemberStringArrTwo", X)); ++ checkSingleMemberClassArrTwo(UnitTest.class.getMethod("SingleMemberClassArrTwo", X)); ++ checkSingleMemberEnumArrTwo(UnitTest.class.getMethod("SingleMemberEnumArrTwo", X)); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (OVERRIDE)ON METHOD ++ checkSingleMemberByteArrOvrdDef(UnitTest.class.getMethod("SingleMemberByteArrOvrdDef", X)); ++ checkSingleMemberShortArrOvrdDef(UnitTest.class.getMethod("SingleMemberShortArrOvrdDef", X)); ++ checkSingleMemberIntArrOvrdDef(UnitTest.class.getMethod("SingleMemberIntArrOvrdDef", X)); ++ checkSingleMemberLongArrOvrdDef(UnitTest.class.getMethod("SingleMemberLongArrOvrdDef", X)); ++ checkSingleMemberCharArrOvrdDef(UnitTest.class.getMethod("SingleMemberCharArrOvrdDef", X)); ++ checkSingleMemberFloatArrOvrdDef(UnitTest.class.getMethod("SingleMemberFloatArrOvrdDef", X)); ++ checkSingleMemberDoubleArrOvrdDef(UnitTest.class.getMethod("SingleMemberDoubleArrOvrdDef", X)); ++ checkSingleMemberBooleanArrOvrdDef(UnitTest.class.getMethod("SingleMemberBooleanArrOvrdDef", X)); ++ checkSingleMemberStringArrOvrdDef(UnitTest.class.getMethod("SingleMemberStringArrOvrdDef", X)); ++ checkSingleMemberClassArrOvrdDef(UnitTest.class.getMethod("SingleMemberClassArrOvrdDef", X)); ++ checkSingleMemberEnumArrOvrdDef(UnitTest.class.getMethod("SingleMemberEnumArrOvrdDef", X)); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (ACCEPT)ON METHOD ++ checkSingleMemberByteArrAcceptDef(UnitTest.class.getMethod("SingleMemberByteArrAcceptDef", X)); ++ checkSingleMemberShortArrAcceptDef(UnitTest.class.getMethod("SingleMemberShortArrAcceptDef", X)); ++ checkSingleMemberIntArrAcceptDef(UnitTest.class.getMethod("SingleMemberIntArrAcceptDef", X)); ++ checkSingleMemberLongArrAcceptDef(UnitTest.class.getMethod("SingleMemberLongArrAcceptDef", X)); ++ checkSingleMemberCharArrAcceptDef(UnitTest.class.getMethod("SingleMemberCharArrAcceptDef", X)); ++ checkSingleMemberFloatArrAcceptDef(UnitTest.class.getMethod("SingleMemberFloatArrAcceptDef", X)); ++ checkSingleMemberDoubleArrAcceptDef(UnitTest.class.getMethod("SingleMemberDoubleArrAcceptDef", X)); ++ checkSingleMemberBooleanArrAcceptDef(UnitTest.class.getMethod("SingleMemberBooleanArrAcceptDef", X)); ++ checkSingleMemberStringArrAcceptDef(UnitTest.class.getMethod("SingleMemberStringArrAcceptDef", X)); ++ checkSingleMemberClassArrAcceptDef(UnitTest.class.getMethod("SingleMemberClassArrAcceptDef", X)); ++ checkSingleMemberEnumArrAcceptDef(UnitTest.class.getMethod("SingleMemberEnumArrAcceptDef", X)); ++ ++ // *** TESTS ON ANNOTATED FIELDS *** ++ ++ // MULTIMEMBER SCALAR TYPES ON FIELD ++ checkScalarTypes(UnitTest.class.getField("scalarTypesField")); ++ checkScalarTypesAcceptDefault(UnitTest.class.getField("scalarTypesAcceptDefaultField")); ++ checkScalarTypesOverrideDefault(UnitTest.class.getField("scalarTypesOverrideDefaultField")); ++ ++ // MULTIMEMBER ARRAY TYPES ON FIELD ++ checkArrayTypes0(UnitTest.class.getField("emptyArrayTypesField")); ++ checkArrayTypes1(UnitTest.class.getField("singleElementArrayTypesField")); ++ checkArrayTypes2(UnitTest.class.getField("twoElementArrayTypesField")); ++ checkArrayTypesAcceptDefault(UnitTest.class.getField("arrayTypesAcceptDefaultField")); ++ checkArrayTypesOverrideDefault(UnitTest.class.getField("arrayTypesOverrideDefaultField")); ++ ++ // MARKER TYPE ON FIELD ++ checkMarker(UnitTest.class.getField("markerField")); ++ ++ // SINGLE-MEMBER SCALAR TYPES ON FIELD ++ checkSingleMemberByte(UnitTest.class.getField("SingleMemberByteField")); ++ checkSingleMemberShort(UnitTest.class.getField("SingleMemberShortField")); ++ checkSingleMemberInt(UnitTest.class.getField("SingleMemberIntField")); ++ checkSingleMemberLong(UnitTest.class.getField("SingleMemberLongField")); ++ checkSingleMemberChar(UnitTest.class.getField("SingleMemberCharField")); ++ checkSingleMemberFloat(UnitTest.class.getField("SingleMemberFloatField")); ++ checkSingleMemberDouble(UnitTest.class.getField("SingleMemberDoubleField")); ++ checkSingleMemberBoolean(UnitTest.class.getField("SingleMemberBooleanField")); ++ checkSingleMemberString(UnitTest.class.getField("SingleMemberStringField")); ++ checkSingleMemberClass(UnitTest.class.getField("SingleMemberClassField")); ++ checkSingleMemberEnum(UnitTest.class.getField("SingleMemberEnumField")); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ON FIELD ++ checkSingleMemberByteOvrdDef(UnitTest.class.getField("SingleMemberByteOvrdDefField")); ++ checkSingleMemberShortOvrdDef(UnitTest.class.getField("SingleMemberShortOvrdDefField")); ++ checkSingleMemberIntOvrdDef(UnitTest.class.getField("SingleMemberIntOvrdDefField")); ++ checkSingleMemberLongOvrdDef(UnitTest.class.getField("SingleMemberLongOvrdDefField")); ++ checkSingleMemberCharOvrdDef(UnitTest.class.getField("SingleMemberCharOvrdDefField")); ++ checkSingleMemberFloatOvrdDef(UnitTest.class.getField("SingleMemberFloatOvrdDefField")); ++ checkSingleMemberDoubleOvrdDef(UnitTest.class.getField("SingleMemberDoubleOvrdDefField")); ++ checkSingleMemberBooleanOvrdDef(UnitTest.class.getField("SingleMemberBooleanOvrdDefField")); ++ checkSingleMemberStringOvrdDef(UnitTest.class.getField("SingleMemberStringOvrdDefField")); ++ checkSingleMemberClassOvrdDef(UnitTest.class.getField("SingleMemberClassOvrdDefField")); ++ checkSingleMemberEnumOvrdDef(UnitTest.class.getField("SingleMemberEnumOvrdDefField")); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ON FIELD ++ checkSingleMemberByteAcceptDef(UnitTest.class.getField("SingleMemberByteAcceptDefField")); ++ checkSingleMemberShortAcceptDef(UnitTest.class.getField("SingleMemberShortAcceptDefField")); ++ checkSingleMemberIntAcceptDef(UnitTest.class.getField("SingleMemberIntAcceptDefField")); ++ checkSingleMemberLongAcceptDef(UnitTest.class.getField("SingleMemberLongAcceptDefField")); ++ checkSingleMemberCharAcceptDef(UnitTest.class.getField("SingleMemberCharAcceptDefField")); ++ checkSingleMemberFloatAcceptDef(UnitTest.class.getField("SingleMemberFloatAcceptDefField")); ++ checkSingleMemberDoubleAcceptDef(UnitTest.class.getField("SingleMemberDoubleAcceptDefField")); ++ checkSingleMemberBooleanAcceptDef(UnitTest.class.getField("SingleMemberBooleanAcceptDefField")); ++ checkSingleMemberStringAcceptDef(UnitTest.class.getField("SingleMemberStringAcceptDefField")); ++ checkSingleMemberClassAcceptDef(UnitTest.class.getField("SingleMemberClassAcceptDefField")); ++ checkSingleMemberEnumAcceptDef(UnitTest.class.getField("SingleMemberEnumAcceptDefField")); ++ ++ // SINGLE-MEMBER ARRAY TYPES (EMPTY ARRAY) ON FIELD ++ checkSingleMemberByteArrEmpty(UnitTest.class.getField("SingleMemberByteArrEmptyField")); ++ checkSingleMemberShortArrEmpty(UnitTest.class.getField("SingleMemberShortArrEmptyField")); ++ checkSingleMemberIntArrEmpty(UnitTest.class.getField("SingleMemberIntArrEmptyField")); ++ checkSingleMemberLongArrEmpty(UnitTest.class.getField("SingleMemberLongArrEmptyField")); ++ checkSingleMemberCharArrEmpty(UnitTest.class.getField("SingleMemberCharArrEmptyField")); ++ checkSingleMemberFloatArrEmpty(UnitTest.class.getField("SingleMemberFloatArrEmptyField")); ++ checkSingleMemberDoubleArrEmpty(UnitTest.class.getField("SingleMemberDoubleArrEmptyField")); ++ checkSingleMemberBooleanArrEmpty(UnitTest.class.getField("SingleMemberBooleanArrEmptyField")); ++ checkSingleMemberStringArrEmpty(UnitTest.class.getField("SingleMemberStringArrEmptyField")); ++ checkSingleMemberClassArrEmpty(UnitTest.class.getField("SingleMemberClassArrEmptyField")); ++ checkSingleMemberEnumArrEmpty(UnitTest.class.getField("SingleMemberEnumArrEmptyField")); ++ ++ // SINGLE-MEMBER ARRAY TYPES (ONE-ELEMENT ARRAY) ON FIELD ++ checkSingleMemberByteArrOne(UnitTest.class.getField("SingleMemberByteArrOneField")); ++ checkSingleMemberShortArrOne(UnitTest.class.getField("SingleMemberShortArrOneField")); ++ checkSingleMemberIntArrOne(UnitTest.class.getField("SingleMemberIntArrOneField")); ++ checkSingleMemberLongArrOne(UnitTest.class.getField("SingleMemberLongArrOneField")); ++ checkSingleMemberCharArrOne(UnitTest.class.getField("SingleMemberCharArrOneField")); ++ checkSingleMemberFloatArrOne(UnitTest.class.getField("SingleMemberFloatArrOneField")); ++ checkSingleMemberDoubleArrOne(UnitTest.class.getField("SingleMemberDoubleArrOneField")); ++ checkSingleMemberBooleanArrOne(UnitTest.class.getField("SingleMemberBooleanArrOneField")); ++ checkSingleMemberStringArrOne(UnitTest.class.getField("SingleMemberStringArrOneField")); ++ checkSingleMemberClassArrOne(UnitTest.class.getField("SingleMemberClassArrOneField")); ++ checkSingleMemberEnumArrOne(UnitTest.class.getField("SingleMemberEnumArrOneField")); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TWO-ELEMENT ARRAY) ON FIELD ++ checkSingleMemberByteArrTwo(UnitTest.class.getField("SingleMemberByteArrTwoField")); ++ checkSingleMemberShortArrTwo(UnitTest.class.getField("SingleMemberShortArrTwoField")); ++ checkSingleMemberIntArrTwo(UnitTest.class.getField("SingleMemberIntArrTwoField")); ++ checkSingleMemberLongArrTwo(UnitTest.class.getField("SingleMemberLongArrTwoField")); ++ checkSingleMemberCharArrTwo(UnitTest.class.getField("SingleMemberCharArrTwoField")); ++ checkSingleMemberFloatArrTwo(UnitTest.class.getField("SingleMemberFloatArrTwoField")); ++ checkSingleMemberDoubleArrTwo(UnitTest.class.getField("SingleMemberDoubleArrTwoField")); ++ checkSingleMemberBooleanArrTwo(UnitTest.class.getField("SingleMemberBooleanArrTwoField")); ++ checkSingleMemberStringArrTwo(UnitTest.class.getField("SingleMemberStringArrTwoField")); ++ checkSingleMemberClassArrTwo(UnitTest.class.getField("SingleMemberClassArrTwoField")); ++ checkSingleMemberEnumArrTwo(UnitTest.class.getField("SingleMemberEnumArrTwoField")); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (OVERRIDE)ON FIELD ++ checkSingleMemberByteArrOvrdDef(UnitTest.class.getField("SingleMemberByteArrOvrdDefField")); ++ checkSingleMemberShortArrOvrdDef(UnitTest.class.getField("SingleMemberShortArrOvrdDefField")); ++ checkSingleMemberIntArrOvrdDef(UnitTest.class.getField("SingleMemberIntArrOvrdDefField")); ++ checkSingleMemberLongArrOvrdDef(UnitTest.class.getField("SingleMemberLongArrOvrdDefField")); ++ checkSingleMemberCharArrOvrdDef(UnitTest.class.getField("SingleMemberCharArrOvrdDefField")); ++ checkSingleMemberFloatArrOvrdDef(UnitTest.class.getField("SingleMemberFloatArrOvrdDefField")); ++ checkSingleMemberDoubleArrOvrdDef(UnitTest.class.getField("SingleMemberDoubleArrOvrdDefField")); ++ checkSingleMemberBooleanArrOvrdDef(UnitTest.class.getField("SingleMemberBooleanArrOvrdDefField")); ++ checkSingleMemberStringArrOvrdDef(UnitTest.class.getField("SingleMemberStringArrOvrdDefField")); ++ checkSingleMemberClassArrOvrdDef(UnitTest.class.getField("SingleMemberClassArrOvrdDefField")); ++ checkSingleMemberEnumArrOvrdDef(UnitTest.class.getField("SingleMemberEnumArrOvrdDefField")); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (ACCEPT)ON FIELD ++ checkSingleMemberByteArrAcceptDef(UnitTest.class.getField("SingleMemberByteArrAcceptDefField")); ++ checkSingleMemberShortArrAcceptDef(UnitTest.class.getField("SingleMemberShortArrAcceptDefField")); ++ checkSingleMemberIntArrAcceptDef(UnitTest.class.getField("SingleMemberIntArrAcceptDefField")); ++ checkSingleMemberLongArrAcceptDef(UnitTest.class.getField("SingleMemberLongArrAcceptDefField")); ++ checkSingleMemberCharArrAcceptDef(UnitTest.class.getField("SingleMemberCharArrAcceptDefField")); ++ checkSingleMemberFloatArrAcceptDef(UnitTest.class.getField("SingleMemberFloatArrAcceptDefField")); ++ checkSingleMemberDoubleArrAcceptDef(UnitTest.class.getField("SingleMemberDoubleArrAcceptDefField")); ++ checkSingleMemberBooleanArrAcceptDef(UnitTest.class.getField("SingleMemberBooleanArrAcceptDefField")); ++ checkSingleMemberStringArrAcceptDef(UnitTest.class.getField("SingleMemberStringArrAcceptDefField")); ++ checkSingleMemberClassArrAcceptDef(UnitTest.class.getField("SingleMemberClassArrAcceptDefField")); ++ checkSingleMemberEnumArrAcceptDef(UnitTest.class.getField("SingleMemberEnumArrAcceptDefField")); ++ ++ // *** TESTS ON ANNOTATED ENUM CONSTS *** ++ ++ // MULTIMEMBER SCALAR TYPES ON ENUM CONST ++ checkScalarTypes(TestType.class.getField("scalarTypesField")); ++ checkScalarTypesAcceptDefault(TestType.class.getField("scalarTypesAcceptDefaultField")); ++ checkScalarTypesOverrideDefault(TestType.class.getField("scalarTypesOverrideDefaultField")); ++ ++ // MULTIMEMBER ARRAY TYPES ON ENUM CONST ++ checkArrayTypes0(TestType.class.getField("emptyArrayTypesField")); ++ checkArrayTypes1(TestType.class.getField("singleElementArrayTypesField")); ++ checkArrayTypes2(TestType.class.getField("twoElementArrayTypesField")); ++ checkArrayTypesAcceptDefault(TestType.class.getField("arrayTypesAcceptDefaultField")); ++ checkArrayTypesOverrideDefault(TestType.class.getField("arrayTypesOverrideDefaultField")); ++ ++ // MARKER TYPE ON CLASS ++ checkMarker(TestType.class.getField("marker")); ++ ++ // SINGLE-MEMBER SCALAR TYPES ON CLASS ++ checkSingleMemberByte(TestType.class.getField("SingleMemberByte")); ++ checkSingleMemberShort(TestType.class.getField("SingleMemberShort")); ++ checkSingleMemberInt(TestType.class.getField("SingleMemberInt")); ++ checkSingleMemberLong(TestType.class.getField("SingleMemberLong")); ++ checkSingleMemberChar(TestType.class.getField("SingleMemberChar")); ++ checkSingleMemberFloat(TestType.class.getField("SingleMemberFloat")); ++ checkSingleMemberDouble(TestType.class.getField("SingleMemberDouble")); ++ checkSingleMemberBoolean(TestType.class.getField("SingleMemberBoolean")); ++ checkSingleMemberString(TestType.class.getField("SingleMemberString")); ++ checkSingleMemberClass(TestType.class.getField("SingleMemberClass")); ++ checkSingleMemberEnum(TestType.class.getField("SingleMemberEnum")); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ON CLASS ++ checkSingleMemberByteOvrdDef(TestType.class.getField("SingleMemberByteOvrdDef")); ++ checkSingleMemberShortOvrdDef(TestType.class.getField("SingleMemberShortOvrdDef")); ++ checkSingleMemberIntOvrdDef(TestType.class.getField("SingleMemberIntOvrdDef")); ++ checkSingleMemberLongOvrdDef(TestType.class.getField("SingleMemberLongOvrdDef")); ++ checkSingleMemberCharOvrdDef(TestType.class.getField("SingleMemberCharOvrdDef")); ++ checkSingleMemberFloatOvrdDef(TestType.class.getField("SingleMemberFloatOvrdDef")); ++ checkSingleMemberDoubleOvrdDef(TestType.class.getField("SingleMemberDoubleOvrdDef")); ++ checkSingleMemberBooleanOvrdDef(TestType.class.getField("SingleMemberBooleanOvrdDef")); ++ checkSingleMemberStringOvrdDef(TestType.class.getField("SingleMemberStringOvrdDef")); ++ checkSingleMemberClassOvrdDef(TestType.class.getField("SingleMemberClassOvrdDef")); ++ checkSingleMemberEnumOvrdDef(TestType.class.getField("SingleMemberEnumOvrdDef")); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ON CLASS ++ checkSingleMemberByteAcceptDef(TestType.class.getField("SingleMemberByteAcceptDef")); ++ checkSingleMemberShortAcceptDef(TestType.class.getField("SingleMemberShortAcceptDef")); ++ checkSingleMemberIntAcceptDef(TestType.class.getField("SingleMemberIntAcceptDef")); ++ checkSingleMemberLongAcceptDef(TestType.class.getField("SingleMemberLongAcceptDef")); ++ checkSingleMemberCharAcceptDef(TestType.class.getField("SingleMemberCharAcceptDef")); ++ checkSingleMemberFloatAcceptDef(TestType.class.getField("SingleMemberFloatAcceptDef")); ++ checkSingleMemberDoubleAcceptDef(TestType.class.getField("SingleMemberDoubleAcceptDef")); ++ checkSingleMemberBooleanAcceptDef(TestType.class.getField("SingleMemberBooleanAcceptDef")); ++ checkSingleMemberStringAcceptDef(TestType.class.getField("SingleMemberStringAcceptDef")); ++ checkSingleMemberClassAcceptDef(TestType.class.getField("SingleMemberClassAcceptDef")); ++ checkSingleMemberEnumAcceptDef(TestType.class.getField("SingleMemberEnumAcceptDef")); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TestType.class.getField("EMPTY ARRAY) ON CLASS ++ checkSingleMemberByteArrEmpty(TestType.class.getField("SingleMemberByteArrEmpty")); ++ checkSingleMemberShortArrEmpty(TestType.class.getField("SingleMemberShortArrEmpty")); ++ checkSingleMemberIntArrEmpty(TestType.class.getField("SingleMemberIntArrEmpty")); ++ checkSingleMemberLongArrEmpty(TestType.class.getField("SingleMemberLongArrEmpty")); ++ checkSingleMemberCharArrEmpty(TestType.class.getField("SingleMemberCharArrEmpty")); ++ checkSingleMemberFloatArrEmpty(TestType.class.getField("SingleMemberFloatArrEmpty")); ++ checkSingleMemberDoubleArrEmpty(TestType.class.getField("SingleMemberDoubleArrEmpty")); ++ checkSingleMemberBooleanArrEmpty(TestType.class.getField("SingleMemberBooleanArrEmpty")); ++ checkSingleMemberStringArrEmpty(TestType.class.getField("SingleMemberStringArrEmpty")); ++ checkSingleMemberClassArrEmpty(TestType.class.getField("SingleMemberClassArrEmpty")); ++ checkSingleMemberEnumArrEmpty(TestType.class.getField("SingleMemberEnumArrEmpty")); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TestType.class.getField("ONE-ELEMENT ARRAY) ON CLASS ++ checkSingleMemberByteArrOne(TestType.class.getField("SingleMemberByteArrOne")); ++ checkSingleMemberShortArrOne(TestType.class.getField("SingleMemberShortArrOne")); ++ checkSingleMemberIntArrOne(TestType.class.getField("SingleMemberIntArrOne")); ++ checkSingleMemberLongArrOne(TestType.class.getField("SingleMemberLongArrOne")); ++ checkSingleMemberCharArrOne(TestType.class.getField("SingleMemberCharArrOne")); ++ checkSingleMemberFloatArrOne(TestType.class.getField("SingleMemberFloatArrOne")); ++ checkSingleMemberDoubleArrOne(TestType.class.getField("SingleMemberDoubleArrOne")); ++ checkSingleMemberBooleanArrOne(TestType.class.getField("SingleMemberBooleanArrOne")); ++ checkSingleMemberStringArrOne(TestType.class.getField("SingleMemberStringArrOne")); ++ checkSingleMemberClassArrOne(TestType.class.getField("SingleMemberClassArrOne")); ++ checkSingleMemberEnumArrOne(TestType.class.getField("SingleMemberEnumArrOne")); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TestType.class.getField("TWO-ELEMENT ARRAY) ON CLASS ++ checkSingleMemberByteArrTwo(TestType.class.getField("SingleMemberByteArrTwo")); ++ checkSingleMemberShortArrTwo(TestType.class.getField("SingleMemberShortArrTwo")); ++ checkSingleMemberIntArrTwo(TestType.class.getField("SingleMemberIntArrTwo")); ++ checkSingleMemberLongArrTwo(TestType.class.getField("SingleMemberLongArrTwo")); ++ checkSingleMemberCharArrTwo(TestType.class.getField("SingleMemberCharArrTwo")); ++ checkSingleMemberFloatArrTwo(TestType.class.getField("SingleMemberFloatArrTwo")); ++ checkSingleMemberDoubleArrTwo(TestType.class.getField("SingleMemberDoubleArrTwo")); ++ checkSingleMemberBooleanArrTwo(TestType.class.getField("SingleMemberBooleanArrTwo")); ++ checkSingleMemberStringArrTwo(TestType.class.getField("SingleMemberStringArrTwo")); ++ checkSingleMemberClassArrTwo(TestType.class.getField("SingleMemberClassArrTwo")); ++ checkSingleMemberEnumArrTwo(TestType.class.getField("SingleMemberEnumArrTwo")); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (TestType.class.getField("OVERRIDE)ON CLASS ++ checkSingleMemberByteArrOvrdDef(TestType.class.getField("SingleMemberByteArrOvrdDef")); ++ checkSingleMemberShortArrOvrdDef(TestType.class.getField("SingleMemberShortArrOvrdDef")); ++ checkSingleMemberIntArrOvrdDef(TestType.class.getField("SingleMemberIntArrOvrdDef")); ++ checkSingleMemberLongArrOvrdDef(TestType.class.getField("SingleMemberLongArrOvrdDef")); ++ checkSingleMemberCharArrOvrdDef(TestType.class.getField("SingleMemberCharArrOvrdDef")); ++ checkSingleMemberFloatArrOvrdDef(TestType.class.getField("SingleMemberFloatArrOvrdDef")); ++ checkSingleMemberDoubleArrOvrdDef(TestType.class.getField("SingleMemberDoubleArrOvrdDef")); ++ checkSingleMemberBooleanArrOvrdDef(TestType.class.getField("SingleMemberBooleanArrOvrdDef")); ++ checkSingleMemberStringArrOvrdDef(TestType.class.getField("SingleMemberStringArrOvrdDef")); ++ checkSingleMemberClassArrOvrdDef(TestType.class.getField("SingleMemberClassArrOvrdDef")); ++ checkSingleMemberEnumArrOvrdDef(TestType.class.getField("SingleMemberEnumArrOvrdDef")); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (TestType.class.getField("ACCEPT)ON CLASS ++ checkSingleMemberByteArrAcceptDef(TestType.class.getField("SingleMemberByteArrAcceptDef")); ++ checkSingleMemberShortArrAcceptDef(TestType.class.getField("SingleMemberShortArrAcceptDef")); ++ checkSingleMemberIntArrAcceptDef(TestType.class.getField("SingleMemberIntArrAcceptDef")); ++ checkSingleMemberLongArrAcceptDef(TestType.class.getField("SingleMemberLongArrAcceptDef")); ++ checkSingleMemberCharArrAcceptDef(TestType.class.getField("SingleMemberCharArrAcceptDef")); ++ checkSingleMemberFloatArrAcceptDef(TestType.class.getField("SingleMemberFloatArrAcceptDef")); ++ checkSingleMemberDoubleArrAcceptDef(TestType.class.getField("SingleMemberDoubleArrAcceptDef")); ++ checkSingleMemberBooleanArrAcceptDef(TestType.class.getField("SingleMemberBooleanArrAcceptDef")); ++ checkSingleMemberStringArrAcceptDef(TestType.class.getField("SingleMemberStringArrAcceptDef")); ++ checkSingleMemberClassArrAcceptDef(TestType.class.getField("SingleMemberClassArrAcceptDef")); ++ checkSingleMemberEnumArrAcceptDef(TestType.class.getField("SingleMemberEnumArrAcceptDef")); ++ ++ // *** TESTS ON ANNOTATED CONSTRUCTORS *** ++ ++ // MULTIMEMBER SCALAR TYPES ON CONSTRUCTOR ++ checkScalarTypes(UnitTest.class.getConstructor(new Class[]{Iterator.class})); ++ checkScalarTypesOverrideDefault(UnitTest.class.getConstructor(new Class[]{Map.class})); ++ checkScalarTypesAcceptDefault(UnitTest.class.getConstructor(new Class[]{Set.class})); ++ ++ // MULTIMEMBER ARRAY TYPES ON CONSTRUCTOR ++ checkArrayTypes0(UnitTest.class.getConstructor(new Class[]{List.class})); ++ checkArrayTypes1(UnitTest.class.getConstructor(new Class[]{Collection.class})); ++ checkArrayTypes2(UnitTest.class.getConstructor(new Class[]{SortedSet.class})); ++ checkArrayTypesAcceptDefault(UnitTest.class.getConstructor(new Class[]{SortedMap.class})); ++ checkArrayTypesOverrideDefault(UnitTest.class.getConstructor(new Class[]{RandomAccess.class})); ++ ++ // MARKER TYPE ON CONSTRUCTOR ++ checkMarker(UnitTest.class.getConstructor(new Class[] { })); ++ ++ // SINGLE-MEMBER SCALAR TYPES ON CONSTRUCTOR ++ checkSingleMemberByte(UnitTest.class.getConstructor(new Class[] { byte.class })); ++ checkSingleMemberShort(UnitTest.class.getConstructor(new Class[] { short.class })); ++ checkSingleMemberInt(UnitTest.class.getConstructor(new Class[] { int.class })); ++ checkSingleMemberLong(UnitTest.class.getConstructor(new Class[] { long.class })); ++ checkSingleMemberChar(UnitTest.class.getConstructor(new Class[] { char.class })); ++ checkSingleMemberFloat(UnitTest.class.getConstructor(new Class[] { float.class })); ++ checkSingleMemberDouble(UnitTest.class.getConstructor(new Class[] { double.class })); ++ checkSingleMemberBoolean(UnitTest.class.getConstructor(new Class[] { boolean.class })); ++ checkSingleMemberString(UnitTest.class.getConstructor(new Class[] { String.class })); ++ checkSingleMemberClass(UnitTest.class.getConstructor(new Class[] { Class.class })); ++ checkSingleMemberEnum(UnitTest.class.getConstructor(new Class[] { Enum.class })); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ON CONSTRUCTOR ++ checkSingleMemberByteOvrdDef(UnitTest.class.getConstructor(new Class[] { byte.class, Set.class })); ++ checkSingleMemberShortOvrdDef(UnitTest.class.getConstructor(new Class[] { short.class, Set.class })); ++ checkSingleMemberIntOvrdDef(UnitTest.class.getConstructor(new Class[] { int.class, Set.class })); ++ checkSingleMemberLongOvrdDef(UnitTest.class.getConstructor(new Class[] { long.class, Set.class })); ++ checkSingleMemberCharOvrdDef(UnitTest.class.getConstructor(new Class[] { char.class, Set.class })); ++ checkSingleMemberFloatOvrdDef(UnitTest.class.getConstructor(new Class[] { float.class, Set.class })); ++ checkSingleMemberDoubleOvrdDef(UnitTest.class.getConstructor(new Class[] { double.class, Set.class })); ++ checkSingleMemberBooleanOvrdDef(UnitTest.class.getConstructor(new Class[] { boolean.class, Set.class })); ++ checkSingleMemberStringOvrdDef(UnitTest.class.getConstructor(new Class[] { String.class, Set.class })); ++ checkSingleMemberClassOvrdDef(UnitTest.class.getConstructor(new Class[] { Class.class, Set.class })); ++ checkSingleMemberEnumOvrdDef(UnitTest.class.getConstructor(new Class[] { Enum.class, Set.class })); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ON CONSTRUCTOR ++ checkSingleMemberByteAcceptDef(UnitTest.class.getConstructor(new Class[] { byte.class, Map.class })); ++ checkSingleMemberShortAcceptDef(UnitTest.class.getConstructor(new Class[] { short.class, Map.class })); ++ checkSingleMemberIntAcceptDef(UnitTest.class.getConstructor(new Class[] { int.class, Map.class })); ++ checkSingleMemberLongAcceptDef(UnitTest.class.getConstructor(new Class[] { long.class, Map.class })); ++ checkSingleMemberCharAcceptDef(UnitTest.class.getConstructor(new Class[] { char.class, Map.class })); ++ checkSingleMemberFloatAcceptDef(UnitTest.class.getConstructor(new Class[] { float.class, Map.class })); ++ checkSingleMemberDoubleAcceptDef(UnitTest.class.getConstructor(new Class[] { double.class, Map.class })); ++ checkSingleMemberBooleanAcceptDef(UnitTest.class.getConstructor(new Class[] { boolean.class, Map.class })); ++ checkSingleMemberStringAcceptDef(UnitTest.class.getConstructor(new Class[] { String.class, Map.class })); ++ checkSingleMemberClassAcceptDef(UnitTest.class.getConstructor(new Class[] { Class.class, Map.class })); ++ checkSingleMemberEnumAcceptDef(UnitTest.class.getConstructor(new Class[] { Enum.class, Map.class })); ++ ++ // SINGLE-MEMBER ARRAY TYPES (EMPTY ARRAY) ON CONSTRUCTOR ++ checkSingleMemberByteArrEmpty(UnitTest.class.getConstructor(new Class[] { byte[].class })); ++ checkSingleMemberShortArrEmpty(UnitTest.class.getConstructor(new Class[] { short[].class })); ++ checkSingleMemberIntArrEmpty(UnitTest.class.getConstructor(new Class[] { int[].class })); ++ checkSingleMemberLongArrEmpty(UnitTest.class.getConstructor(new Class[] { long[].class })); ++ checkSingleMemberCharArrEmpty(UnitTest.class.getConstructor(new Class[] { char[].class })); ++ checkSingleMemberFloatArrEmpty(UnitTest.class.getConstructor(new Class[] { float[].class })); ++ checkSingleMemberDoubleArrEmpty(UnitTest.class.getConstructor(new Class[] { double[].class })); ++ checkSingleMemberBooleanArrEmpty(UnitTest.class.getConstructor(new Class[] { boolean[].class })); ++ checkSingleMemberStringArrEmpty(UnitTest.class.getConstructor(new Class[] { String[].class })); ++ checkSingleMemberClassArrEmpty(UnitTest.class.getConstructor(new Class[] { Class[].class })); ++ checkSingleMemberEnumArrEmpty(UnitTest.class.getConstructor(new Class[] { Enum[].class })); ++ ++ // SINGLE-MEMBER ARRAY TYPES (ONE-ELEMENT ARRAY) ON CONSTRUCTOR ++ checkSingleMemberByteArrOne(UnitTest.class.getConstructor(new Class[] { byte[].class, Set.class })); ++ checkSingleMemberShortArrOne(UnitTest.class.getConstructor(new Class[] { short[].class, Set.class })); ++ checkSingleMemberIntArrOne(UnitTest.class.getConstructor(new Class[] { int[].class, Set.class })); ++ checkSingleMemberLongArrOne(UnitTest.class.getConstructor(new Class[] { long[].class, Set.class })); ++ checkSingleMemberCharArrOne(UnitTest.class.getConstructor(new Class[] { char[].class, Set.class })); ++ checkSingleMemberFloatArrOne(UnitTest.class.getConstructor(new Class[] { float[].class, Set.class })); ++ checkSingleMemberDoubleArrOne(UnitTest.class.getConstructor(new Class[] { double[].class, Set.class })); ++ checkSingleMemberBooleanArrOne(UnitTest.class.getConstructor(new Class[] { boolean[].class, Set.class })); ++ checkSingleMemberStringArrOne(UnitTest.class.getConstructor(new Class[] { String[].class, Set.class })); ++ checkSingleMemberClassArrOne(UnitTest.class.getConstructor(new Class[] { Class[].class, Set.class })); ++ checkSingleMemberEnumArrOne(UnitTest.class.getConstructor(new Class[] { Enum[].class, Set.class })); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TWO-ELEMENT ARRAY) ON CONSTRUCTOR ++ checkSingleMemberByteArrTwo(UnitTest.class.getConstructor(new Class[] { byte[].class, Map.class })); ++ checkSingleMemberShortArrTwo(UnitTest.class.getConstructor(new Class[] { short[].class, Map.class })); ++ checkSingleMemberIntArrTwo(UnitTest.class.getConstructor(new Class[] { int[].class, Map.class })); ++ checkSingleMemberLongArrTwo(UnitTest.class.getConstructor(new Class[] { long[].class, Map.class })); ++ checkSingleMemberCharArrTwo(UnitTest.class.getConstructor(new Class[] { char[].class, Map.class })); ++ checkSingleMemberFloatArrTwo(UnitTest.class.getConstructor(new Class[] { float[].class, Map.class })); ++ checkSingleMemberDoubleArrTwo(UnitTest.class.getConstructor(new Class[] { double[].class, Map.class })); ++ checkSingleMemberBooleanArrTwo(UnitTest.class.getConstructor(new Class[] { boolean[].class, Map.class })); ++ checkSingleMemberStringArrTwo(UnitTest.class.getConstructor(new Class[] { String[].class, Map.class })); ++ checkSingleMemberClassArrTwo(UnitTest.class.getConstructor(new Class[] { Class[].class, Map.class })); ++ checkSingleMemberEnumArrTwo(UnitTest.class.getConstructor(new Class[] { Enum[].class, Map.class })); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (OVERRIDE)ON CONSTRUCTOR ++ checkSingleMemberByteArrOvrdDef(UnitTest.class.getConstructor(new Class[] { byte[].class, List.class })); ++ checkSingleMemberShortArrOvrdDef(UnitTest.class.getConstructor(new Class[] { short[].class, List.class })); ++ checkSingleMemberIntArrOvrdDef(UnitTest.class.getConstructor(new Class[] { int[].class, List.class })); ++ checkSingleMemberLongArrOvrdDef(UnitTest.class.getConstructor(new Class[] { long[].class, List.class })); ++ checkSingleMemberCharArrOvrdDef(UnitTest.class.getConstructor(new Class[] { char[].class, List.class })); ++ checkSingleMemberFloatArrOvrdDef(UnitTest.class.getConstructor(new Class[] { float[].class, List.class })); ++ checkSingleMemberDoubleArrOvrdDef(UnitTest.class.getConstructor(new Class[] { double[].class, List.class })); ++ checkSingleMemberBooleanArrOvrdDef(UnitTest.class.getConstructor(new Class[] { boolean[].class, List.class })); ++ checkSingleMemberStringArrOvrdDef(UnitTest.class.getConstructor(new Class[] { String[].class, List.class })); ++ checkSingleMemberClassArrOvrdDef(UnitTest.class.getConstructor(new Class[] { Class[].class, List.class })); ++ checkSingleMemberEnumArrOvrdDef(UnitTest.class.getConstructor(new Class[] { Enum[].class, List.class })); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (ACCEPT)ON CONSTRUCTOR ++ checkSingleMemberByteArrAcceptDef(UnitTest.class.getConstructor(new Class[] { byte[].class, Collection.class })); ++ checkSingleMemberShortArrAcceptDef(UnitTest.class.getConstructor(new Class[] { short[].class, Collection.class })); ++ checkSingleMemberIntArrAcceptDef(UnitTest.class.getConstructor(new Class[] { int[].class, Collection.class })); ++ checkSingleMemberLongArrAcceptDef(UnitTest.class.getConstructor(new Class[] { long[].class, Collection.class })); ++ checkSingleMemberCharArrAcceptDef(UnitTest.class.getConstructor(new Class[] { char[].class, Collection.class })); ++ checkSingleMemberFloatArrAcceptDef(UnitTest.class.getConstructor(new Class[] { float[].class, Collection.class })); ++ checkSingleMemberDoubleArrAcceptDef(UnitTest.class.getConstructor(new Class[] { double[].class, Collection.class })); ++ checkSingleMemberBooleanArrAcceptDef(UnitTest.class.getConstructor(new Class[] { boolean[].class, Collection.class })); ++ checkSingleMemberStringArrAcceptDef(UnitTest.class.getConstructor(new Class[] { String[].class, Collection.class })); ++ checkSingleMemberClassArrAcceptDef(UnitTest.class.getConstructor(new Class[] { Class[].class, Collection.class })); ++ checkSingleMemberEnumArrAcceptDef(UnitTest.class.getConstructor(new Class[] { Enum[].class, Collection.class })); ++ ++ // *** TESTS ON ANNOTATED PARAMETERS *** ++ ++ // MULTIMEMBER SCALAR TYPES ON PARAM ++ checkScalarTypesParam(UnitTest.class.getMethod("scalarTypesParam", Y)); ++ checkScalarTypesOverrideDefaultParam(UnitTest.class.getMethod("scalarTypesOverrideDefaultParam", Y)); ++ checkScalarTypesAcceptDefaultParam(UnitTest.class.getMethod("scalarTypesAcceptDefaultParam", Y)); ++ ++ // MULTIMEMBER ARRAY TYPES ON PARAM ++ checkArrayTypes0Param(UnitTest.class.getMethod("emptyArrayTypesParam", Y)); ++ checkArrayTypes1Param(UnitTest.class.getMethod("singleElementArrayTypesParam", Y)); ++ checkArrayTypes2Param(UnitTest.class.getMethod("twoElementArrayTypesParam", Y)); ++ checkArrayTypesAcceptDefaultParam(UnitTest.class.getMethod("arrayTypesAcceptDefaultParam", Y)); ++ checkArrayTypesOverrideDefaultParam(UnitTest.class.getMethod("arrayTypesOverrideDefaultParam", Y)); ++ ++ // MARKER TYPE ON PARAMETER ++ checkMarkerParam(UnitTest.class.getMethod("markerParam", Y)); ++ ++ // SINGLE-MEMBER SCALAR TYPES ON PARAMETER ++ checkSingleMemberByteParam(UnitTest.class.getMethod("SingleMemberByteParam", Y)); ++ checkSingleMemberShortParam(UnitTest.class.getMethod("SingleMemberShortParam", Y)); ++ checkSingleMemberIntParam(UnitTest.class.getMethod("SingleMemberIntParam", Y)); ++ checkSingleMemberLongParam(UnitTest.class.getMethod("SingleMemberLongParam", Y)); ++ checkSingleMemberCharParam(UnitTest.class.getMethod("SingleMemberCharParam", Y)); ++ checkSingleMemberFloatParam(UnitTest.class.getMethod("SingleMemberFloatParam", Y)); ++ checkSingleMemberDoubleParam(UnitTest.class.getMethod("SingleMemberDoubleParam", Y)); ++ checkSingleMemberBooleanParam(UnitTest.class.getMethod("SingleMemberBooleanParam", Y)); ++ checkSingleMemberStringParam(UnitTest.class.getMethod("SingleMemberStringParam", Y)); ++ checkSingleMemberClassParam(UnitTest.class.getMethod("SingleMemberClassParam", Y)); ++ checkSingleMemberEnumParam(UnitTest.class.getMethod("SingleMemberEnumParam", Y)); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ON PARAMETER ++ checkSingleMemberByteOvrdDefParam(UnitTest.class.getMethod("SingleMemberByteOvrdDefParam", Y)); ++ checkSingleMemberShortOvrdDefParam(UnitTest.class.getMethod("SingleMemberShortOvrdDefParam", Y)); ++ checkSingleMemberIntOvrdDefParam(UnitTest.class.getMethod("SingleMemberIntOvrdDefParam", Y)); ++ checkSingleMemberLongOvrdDefParam(UnitTest.class.getMethod("SingleMemberLongOvrdDefParam", Y)); ++ checkSingleMemberCharOvrdDefParam(UnitTest.class.getMethod("SingleMemberCharOvrdDefParam", Y)); ++ checkSingleMemberFloatOvrdDefParam(UnitTest.class.getMethod("SingleMemberFloatOvrdDefParam", Y)); ++ checkSingleMemberDoubleOvrdDefParam(UnitTest.class.getMethod("SingleMemberDoubleOvrdDefParam", Y)); ++ checkSingleMemberBooleanOvrdDefParam(UnitTest.class.getMethod("SingleMemberBooleanOvrdDefParam", Y)); ++ checkSingleMemberStringOvrdDefParam(UnitTest.class.getMethod("SingleMemberStringOvrdDefParam", Y)); ++ checkSingleMemberClassOvrdDefParam(UnitTest.class.getMethod("SingleMemberClassOvrdDefParam", Y)); ++ checkSingleMemberEnumOvrdDefParam(UnitTest.class.getMethod("SingleMemberEnumOvrdDefParam", Y)); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ON PARAMETER ++ checkSingleMemberByteAcceptDefParam(UnitTest.class.getMethod("SingleMemberByteAcceptDefParam", Y)); ++ checkSingleMemberShortAcceptDefParam(UnitTest.class.getMethod("SingleMemberShortAcceptDefParam", Y)); ++ checkSingleMemberIntAcceptDefParam(UnitTest.class.getMethod("SingleMemberIntAcceptDefParam", Y)); ++ checkSingleMemberLongAcceptDefParam(UnitTest.class.getMethod("SingleMemberLongAcceptDefParam", Y)); ++ checkSingleMemberCharAcceptDefParam(UnitTest.class.getMethod("SingleMemberCharAcceptDefParam", Y)); ++ checkSingleMemberFloatAcceptDefParam(UnitTest.class.getMethod("SingleMemberFloatAcceptDefParam", Y)); ++ checkSingleMemberDoubleAcceptDefParam(UnitTest.class.getMethod("SingleMemberDoubleAcceptDefParam", Y)); ++ checkSingleMemberBooleanAcceptDefParam(UnitTest.class.getMethod("SingleMemberBooleanAcceptDefParam", Y)); ++ checkSingleMemberStringAcceptDefParam(UnitTest.class.getMethod("SingleMemberStringAcceptDefParam", Y)); ++ checkSingleMemberClassAcceptDefParam(UnitTest.class.getMethod("SingleMemberClassAcceptDefParam", Y)); ++ checkSingleMemberEnumAcceptDefParam(UnitTest.class.getMethod("SingleMemberEnumAcceptDefParam", Y)); ++ ++ // SINGLE-MEMBER ARRAY TYPES Param(UnitTest.class.getMethod("EMPTY ARRAY) ON PARAMETER ++ checkSingleMemberByteArrEmptyParam(UnitTest.class.getMethod("SingleMemberByteArrEmptyParam", Y)); ++ checkSingleMemberShortArrEmptyParam(UnitTest.class.getMethod("SingleMemberShortArrEmptyParam", Y)); ++ checkSingleMemberIntArrEmptyParam(UnitTest.class.getMethod("SingleMemberIntArrEmptyParam", Y)); ++ checkSingleMemberLongArrEmptyParam(UnitTest.class.getMethod("SingleMemberLongArrEmptyParam", Y)); ++ checkSingleMemberCharArrEmptyParam(UnitTest.class.getMethod("SingleMemberCharArrEmptyParam", Y)); ++ checkSingleMemberFloatArrEmptyParam(UnitTest.class.getMethod("SingleMemberFloatArrEmptyParam", Y)); ++ checkSingleMemberDoubleArrEmptyParam(UnitTest.class.getMethod("SingleMemberDoubleArrEmptyParam", Y)); ++ checkSingleMemberBooleanArrEmptyParam(UnitTest.class.getMethod("SingleMemberBooleanArrEmptyParam", Y)); ++ checkSingleMemberStringArrEmptyParam(UnitTest.class.getMethod("SingleMemberStringArrEmptyParam", Y)); ++ checkSingleMemberClassArrEmptyParam(UnitTest.class.getMethod("SingleMemberClassArrEmptyParam", Y)); ++ checkSingleMemberEnumArrEmptyParam(UnitTest.class.getMethod("SingleMemberEnumArrEmptyParam", Y)); ++ ++ // SINGLE-MEMBER ARRAY TYPES Param(UnitTest.class.getMethod("ONE-ELEMENT ARRAY) ON PARAMETER ++ checkSingleMemberByteArrOneParam(UnitTest.class.getMethod("SingleMemberByteArrOneParam", Y)); ++ checkSingleMemberShortArrOneParam(UnitTest.class.getMethod("SingleMemberShortArrOneParam", Y)); ++ checkSingleMemberIntArrOneParam(UnitTest.class.getMethod("SingleMemberIntArrOneParam", Y)); ++ checkSingleMemberLongArrOneParam(UnitTest.class.getMethod("SingleMemberLongArrOneParam", Y)); ++ checkSingleMemberCharArrOneParam(UnitTest.class.getMethod("SingleMemberCharArrOneParam", Y)); ++ checkSingleMemberFloatArrOneParam(UnitTest.class.getMethod("SingleMemberFloatArrOneParam", Y)); ++ checkSingleMemberDoubleArrOneParam(UnitTest.class.getMethod("SingleMemberDoubleArrOneParam", Y)); ++ checkSingleMemberBooleanArrOneParam(UnitTest.class.getMethod("SingleMemberBooleanArrOneParam", Y)); ++ checkSingleMemberStringArrOneParam(UnitTest.class.getMethod("SingleMemberStringArrOneParam", Y)); ++ checkSingleMemberClassArrOneParam(UnitTest.class.getMethod("SingleMemberClassArrOneParam", Y)); ++ checkSingleMemberEnumArrOneParam(UnitTest.class.getMethod("SingleMemberEnumArrOneParam", Y)); ++ ++ // SINGLE-MEMBER ARRAY TYPES Param(UnitTest.class.getMethod("TWO-ELEMENT ARRAY) ON PARAMETER ++ checkSingleMemberByteArrTwoParam(UnitTest.class.getMethod("SingleMemberByteArrTwoParam", Y)); ++ checkSingleMemberShortArrTwoParam(UnitTest.class.getMethod("SingleMemberShortArrTwoParam", Y)); ++ checkSingleMemberIntArrTwoParam(UnitTest.class.getMethod("SingleMemberIntArrTwoParam", Y)); ++ checkSingleMemberLongArrTwoParam(UnitTest.class.getMethod("SingleMemberLongArrTwoParam", Y)); ++ checkSingleMemberCharArrTwoParam(UnitTest.class.getMethod("SingleMemberCharArrTwoParam", Y)); ++ checkSingleMemberFloatArrTwoParam(UnitTest.class.getMethod("SingleMemberFloatArrTwoParam", Y)); ++ checkSingleMemberDoubleArrTwoParam(UnitTest.class.getMethod("SingleMemberDoubleArrTwoParam", Y)); ++ checkSingleMemberBooleanArrTwoParam(UnitTest.class.getMethod("SingleMemberBooleanArrTwoParam", Y)); ++ checkSingleMemberStringArrTwoParam(UnitTest.class.getMethod("SingleMemberStringArrTwoParam", Y)); ++ checkSingleMemberClassArrTwoParam(UnitTest.class.getMethod("SingleMemberClassArrTwoParam", Y)); ++ checkSingleMemberEnumArrTwoParam(UnitTest.class.getMethod("SingleMemberEnumArrTwoParam", Y)); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT Param(UnitTest.class.getMethod("OVERRIDE)ON PARAMETER ++ checkSingleMemberByteArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberByteArrOvrdDefParam", Y)); ++ checkSingleMemberShortArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberShortArrOvrdDefParam", Y)); ++ checkSingleMemberIntArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberIntArrOvrdDefParam", Y)); ++ checkSingleMemberLongArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberLongArrOvrdDefParam", Y)); ++ checkSingleMemberCharArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberCharArrOvrdDefParam", Y)); ++ checkSingleMemberFloatArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberFloatArrOvrdDefParam", Y)); ++ checkSingleMemberDoubleArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberDoubleArrOvrdDefParam", Y)); ++ checkSingleMemberBooleanArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberBooleanArrOvrdDefParam", Y)); ++ checkSingleMemberStringArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberStringArrOvrdDefParam", Y)); ++ checkSingleMemberClassArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberClassArrOvrdDefParam", Y)); ++ checkSingleMemberEnumArrOvrdDefParam(UnitTest.class.getMethod("SingleMemberEnumArrOvrdDefParam", Y)); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT Param(UnitTest.class.getMethod("ACCEPT)ON PARAMETER ++ checkSingleMemberByteArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberByteArrAcceptDefParam", Y)); ++ checkSingleMemberShortArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberShortArrAcceptDefParam", Y)); ++ checkSingleMemberIntArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberIntArrAcceptDefParam", Y)); ++ checkSingleMemberLongArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberLongArrAcceptDefParam", Y)); ++ checkSingleMemberCharArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberCharArrAcceptDefParam", Y)); ++ checkSingleMemberFloatArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberFloatArrAcceptDefParam", Y)); ++ checkSingleMemberDoubleArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberDoubleArrAcceptDefParam", Y)); ++ checkSingleMemberBooleanArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberBooleanArrAcceptDefParam", Y)); ++ checkSingleMemberStringArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberStringArrAcceptDefParam", Y)); ++ checkSingleMemberClassArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberClassArrAcceptDefParam", Y)); ++ checkSingleMemberEnumArrAcceptDefParam(UnitTest.class.getMethod("SingleMemberEnumArrAcceptDefParam", Y)); ++ ++ // *** TESTS ON ANNOTATED CLASSES *** ++ ++ // MULTIMEMBER SCALAR TYPES ON CLASS ++ checkScalarTypes(scalarTypesClass.class); ++ checkScalarTypesOverrideDefault(scalarTypesOverrideDefaultClass.class); ++ checkScalarTypesAcceptDefault(scalarTypesAcceptDefaultClass.class); ++ ++ // MULTIMEMBER ARRAY TYPES ON CLASS ++ checkArrayTypes0(emptyArrayTypesClass.class); ++ checkArrayTypes1(singleElementArrayTypesClass.class); ++ checkArrayTypes2(twoElementArrayTypesClass.class); ++ checkArrayTypesOverrideDefault(arrayTypesOverrideDefaultClass.class); ++ checkArrayTypesAcceptDefault(arrayTypesAcceptDefaultClass.class); ++ ++ // MARKER TYPE ON CLASS ++ checkMarker(markerClass.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES ON CLASS ++ checkSingleMemberByte(SingleMemberByteClass.class); ++ checkSingleMemberShort(SingleMemberShortClass.class); ++ checkSingleMemberInt(SingleMemberIntClass.class); ++ checkSingleMemberLong(SingleMemberLongClass.class); ++ checkSingleMemberChar(SingleMemberCharClass.class); ++ checkSingleMemberFloat(SingleMemberFloatClass.class); ++ checkSingleMemberDouble(SingleMemberDoubleClass.class); ++ checkSingleMemberBoolean(SingleMemberBooleanClass.class); ++ checkSingleMemberString(SingleMemberStringClass.class); ++ checkSingleMemberClass(SingleMemberClassClass.class); ++ checkSingleMemberEnum(SingleMemberEnumClass.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ON CLASS ++ checkSingleMemberByteOvrdDef(SingleMemberByteOvrdDefClass.class); ++ checkSingleMemberShortOvrdDef(SingleMemberShortOvrdDefClass.class); ++ checkSingleMemberIntOvrdDef(SingleMemberIntOvrdDefClass.class); ++ checkSingleMemberLongOvrdDef(SingleMemberLongOvrdDefClass.class); ++ checkSingleMemberCharOvrdDef(SingleMemberCharOvrdDefClass.class); ++ checkSingleMemberFloatOvrdDef(SingleMemberFloatOvrdDefClass.class); ++ checkSingleMemberDoubleOvrdDef(SingleMemberDoubleOvrdDefClass.class); ++ checkSingleMemberBooleanOvrdDef(SingleMemberBooleanOvrdDefClass.class); ++ checkSingleMemberStringOvrdDef(SingleMemberStringOvrdDefClass.class); ++ checkSingleMemberClassOvrdDef(SingleMemberClassOvrdDefClass.class); ++ checkSingleMemberEnumOvrdDef(SingleMemberEnumOvrdDefClass.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ON CLASS ++ checkSingleMemberByteAcceptDef(SingleMemberByteAcceptDefClass.class); ++ checkSingleMemberShortAcceptDef(SingleMemberShortAcceptDefClass.class); ++ checkSingleMemberIntAcceptDef(SingleMemberIntAcceptDefClass.class); ++ checkSingleMemberLongAcceptDef(SingleMemberLongAcceptDefClass.class); ++ checkSingleMemberCharAcceptDef(SingleMemberCharAcceptDefClass.class); ++ checkSingleMemberFloatAcceptDef(SingleMemberFloatAcceptDefClass.class); ++ checkSingleMemberDoubleAcceptDef(SingleMemberDoubleAcceptDefClass.class); ++ checkSingleMemberBooleanAcceptDef(SingleMemberBooleanAcceptDefClass.class); ++ checkSingleMemberStringAcceptDef(SingleMemberStringAcceptDefClass.class); ++ checkSingleMemberClassAcceptDef(SingleMemberClassAcceptDefClass.class); ++ checkSingleMemberEnumAcceptDef(SingleMemberEnumAcceptDefClass.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (EMPTY ARRAY) ON CLASS ++ checkSingleMemberByteArrEmpty(SingleMemberByteArrEmptyClass.class); ++ checkSingleMemberShortArrEmpty(SingleMemberShortArrEmptyClass.class); ++ checkSingleMemberIntArrEmpty(SingleMemberIntArrEmptyClass.class); ++ checkSingleMemberLongArrEmpty(SingleMemberLongArrEmptyClass.class); ++ checkSingleMemberCharArrEmpty(SingleMemberCharArrEmptyClass.class); ++ checkSingleMemberFloatArrEmpty(SingleMemberFloatArrEmptyClass.class); ++ checkSingleMemberDoubleArrEmpty(SingleMemberDoubleArrEmptyClass.class); ++ checkSingleMemberBooleanArrEmpty(SingleMemberBooleanArrEmptyClass.class); ++ checkSingleMemberStringArrEmpty(SingleMemberStringArrEmptyClass.class); ++ checkSingleMemberClassArrEmpty(SingleMemberClassArrEmptyClass.class); ++ checkSingleMemberEnumArrEmpty(SingleMemberEnumArrEmptyClass.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (ONE-ELEMENT ARRAY) ON CLASS ++ checkSingleMemberByteArrOne(SingleMemberByteArrOneClass.class); ++ checkSingleMemberShortArrOne(SingleMemberShortArrOneClass.class); ++ checkSingleMemberIntArrOne(SingleMemberIntArrOneClass.class); ++ checkSingleMemberLongArrOne(SingleMemberLongArrOneClass.class); ++ checkSingleMemberCharArrOne(SingleMemberCharArrOneClass.class); ++ checkSingleMemberFloatArrOne(SingleMemberFloatArrOneClass.class); ++ checkSingleMemberDoubleArrOne(SingleMemberDoubleArrOneClass.class); ++ checkSingleMemberBooleanArrOne(SingleMemberBooleanArrOneClass.class); ++ checkSingleMemberStringArrOne(SingleMemberStringArrOneClass.class); ++ checkSingleMemberClassArrOne(SingleMemberClassArrOneClass.class); ++ checkSingleMemberEnumArrOne(SingleMemberEnumArrOneClass.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TWO-ELEMENT ARRAY) ON CLASS ++ checkSingleMemberByteArrTwo(SingleMemberByteArrTwoClass.class); ++ checkSingleMemberShortArrTwo(SingleMemberShortArrTwoClass.class); ++ checkSingleMemberIntArrTwo(SingleMemberIntArrTwoClass.class); ++ checkSingleMemberLongArrTwo(SingleMemberLongArrTwoClass.class); ++ checkSingleMemberCharArrTwo(SingleMemberCharArrTwoClass.class); ++ checkSingleMemberFloatArrTwo(SingleMemberFloatArrTwoClass.class); ++ checkSingleMemberDoubleArrTwo(SingleMemberDoubleArrTwoClass.class); ++ checkSingleMemberBooleanArrTwo(SingleMemberBooleanArrTwoClass.class); ++ checkSingleMemberStringArrTwo(SingleMemberStringArrTwoClass.class); ++ checkSingleMemberClassArrTwo(SingleMemberClassArrTwoClass.class); ++ checkSingleMemberEnumArrTwo(SingleMemberEnumArrTwoClass.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (OVERRIDE)ON CLASS ++ checkSingleMemberByteArrOvrdDef(SingleMemberByteArrOvrdDefClass.class); ++ checkSingleMemberShortArrOvrdDef(SingleMemberShortArrOvrdDefClass.class); ++ checkSingleMemberIntArrOvrdDef(SingleMemberIntArrOvrdDefClass.class); ++ checkSingleMemberLongArrOvrdDef(SingleMemberLongArrOvrdDefClass.class); ++ checkSingleMemberCharArrOvrdDef(SingleMemberCharArrOvrdDefClass.class); ++ checkSingleMemberFloatArrOvrdDef(SingleMemberFloatArrOvrdDefClass.class); ++ checkSingleMemberDoubleArrOvrdDef(SingleMemberDoubleArrOvrdDefClass.class); ++ checkSingleMemberBooleanArrOvrdDef(SingleMemberBooleanArrOvrdDefClass.class); ++ checkSingleMemberStringArrOvrdDef(SingleMemberStringArrOvrdDefClass.class); ++ checkSingleMemberClassArrOvrdDef(SingleMemberClassArrOvrdDefClass.class); ++ checkSingleMemberEnumArrOvrdDef(SingleMemberEnumArrOvrdDefClass.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (ACCEPT)ON CLASS ++ checkSingleMemberByteArrAcceptDef(SingleMemberByteArrAcceptDefClass.class); ++ checkSingleMemberShortArrAcceptDef(SingleMemberShortArrAcceptDefClass.class); ++ checkSingleMemberIntArrAcceptDef(SingleMemberIntArrAcceptDefClass.class); ++ checkSingleMemberLongArrAcceptDef(SingleMemberLongArrAcceptDefClass.class); ++ checkSingleMemberCharArrAcceptDef(SingleMemberCharArrAcceptDefClass.class); ++ checkSingleMemberFloatArrAcceptDef(SingleMemberFloatArrAcceptDefClass.class); ++ checkSingleMemberDoubleArrAcceptDef(SingleMemberDoubleArrAcceptDefClass.class); ++ checkSingleMemberBooleanArrAcceptDef(SingleMemberBooleanArrAcceptDefClass.class); ++ checkSingleMemberStringArrAcceptDef(SingleMemberStringArrAcceptDefClass.class); ++ checkSingleMemberClassArrAcceptDef(SingleMemberClassArrAcceptDefClass.class); ++ checkSingleMemberEnumArrAcceptDef(SingleMemberEnumArrAcceptDefClass.class); ++ ++ // *** TESTS FOR EQUALS AND HASHCODE - POSITIVE ++ ++ // MULTIMEMBER SCALAR TYPES ++ checkEquals(scalarTypesClass.class, UnitTest.class.getField("scalarTypesField"), ++ ScalarTypes.class); ++ checkEquals(scalarTypesOverrideDefaultClass.class, UnitTest.class.getField("scalarTypesOverrideDefaultField"), ++ ScalarTypesWithDefault.class); ++ checkEquals(scalarTypesAcceptDefaultClass.class, UnitTest.class.getField("scalarTypesAcceptDefaultField"), ++ ScalarTypesWithDefault.class); ++ ++ // MULTIMEMBER ARRAY TYPES ++ checkEquals(emptyArrayTypesClass.class, UnitTest.class.getField("emptyArrayTypesField"), ++ ArrayTypes.class); ++ checkEquals(singleElementArrayTypesClass.class, UnitTest.class.getField("singleElementArrayTypesField"), ++ ArrayTypes.class); ++ checkEquals(twoElementArrayTypesClass.class, UnitTest.class.getField("twoElementArrayTypesField"), ++ ArrayTypes.class); ++ checkEquals(arrayTypesOverrideDefaultClass.class, UnitTest.class.getField("arrayTypesOverrideDefaultField"), ++ ArrayTypesWithDefault.class); ++ checkEquals(arrayTypesAcceptDefaultClass.class, UnitTest.class.getField("arrayTypesAcceptDefaultField"), ++ ArrayTypesWithDefault.class); ++ ++ // MARKER TYPE ++ checkEquals(markerClass.class, UnitTest.class.getField("markerField"), ++ Marker.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES ++ checkEquals(SingleMemberByteClass.class, UnitTest.class.getField("SingleMemberByteField"), ++ SingleMemberByte.class); ++ checkEquals(SingleMemberShortClass.class, UnitTest.class.getField("SingleMemberShortField"), ++ SingleMemberShort.class); ++ checkEquals(SingleMemberIntClass.class, UnitTest.class.getField("SingleMemberIntField"), ++ SingleMemberInt.class); ++ checkEquals(SingleMemberLongClass.class, UnitTest.class.getField("SingleMemberLongField"), ++ SingleMemberLong.class); ++ checkEquals(SingleMemberCharClass.class, UnitTest.class.getField("SingleMemberCharField"), ++ SingleMemberChar.class); ++ checkEquals(SingleMemberFloatClass.class, UnitTest.class.getField("SingleMemberFloatField"), ++ SingleMemberFloat.class); ++ checkEquals(SingleMemberDoubleClass.class, UnitTest.class.getField("SingleMemberDoubleField"), ++ SingleMemberDouble.class); ++ checkEquals(SingleMemberBooleanClass.class, UnitTest.class.getField("SingleMemberBooleanField"), ++ SingleMemberBoolean.class); ++ checkEquals(SingleMemberStringClass.class, UnitTest.class.getField("SingleMemberStringField"), ++ SingleMemberString.class); ++ checkEquals(SingleMemberClassClass.class, UnitTest.class.getField("SingleMemberClassField"), ++ SingleMemberClass.class); ++ checkEquals(SingleMemberEnumClass.class, UnitTest.class.getField("SingleMemberEnumField"), ++ SingleMemberEnum.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ++ checkEquals(SingleMemberByteOvrdDefClass.class, UnitTest.class.getField("SingleMemberByteOvrdDefField"), ++ SingleMemberByteWithDef.class); ++ checkEquals(SingleMemberShortOvrdDefClass.class, UnitTest.class.getField("SingleMemberShortOvrdDefField"), ++ SingleMemberShortWithDef.class); ++ checkEquals(SingleMemberIntOvrdDefClass.class, UnitTest.class.getField("SingleMemberIntOvrdDefField"), ++ SingleMemberIntWithDef.class); ++ checkEquals(SingleMemberLongOvrdDefClass.class, UnitTest.class.getField("SingleMemberLongOvrdDefField"), ++ SingleMemberLongWithDef.class); ++ checkEquals(SingleMemberCharOvrdDefClass.class, UnitTest.class.getField("SingleMemberCharOvrdDefField"), ++ SingleMemberCharWithDef.class); ++ checkEquals(SingleMemberFloatOvrdDefClass.class, UnitTest.class.getField("SingleMemberFloatOvrdDefField"), ++ SingleMemberFloatWithDef.class); ++ checkEquals(SingleMemberDoubleOvrdDefClass.class, UnitTest.class.getField("SingleMemberDoubleOvrdDefField"), ++ SingleMemberDoubleWithDef.class); ++ checkEquals(SingleMemberBooleanOvrdDefClass.class, UnitTest.class.getField("SingleMemberBooleanOvrdDefField"), ++ SingleMemberBooleanWithDef.class); ++ checkEquals(SingleMemberStringOvrdDefClass.class, UnitTest.class.getField("SingleMemberStringOvrdDefField"), ++ SingleMemberStringWithDef.class); ++ checkEquals(SingleMemberClassOvrdDefClass.class, UnitTest.class.getField("SingleMemberClassOvrdDefField"), ++ SingleMemberClassWithDef.class); ++ checkEquals(SingleMemberEnumOvrdDefClass.class, UnitTest.class.getField("SingleMemberEnumOvrdDefField"), ++ SingleMemberEnumWithDef.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ++ checkEquals(SingleMemberByteAcceptDefClass.class, UnitTest.class.getField("SingleMemberByteAcceptDefField"), ++ SingleMemberByteWithDef.class); ++ checkEquals(SingleMemberShortAcceptDefClass.class, UnitTest.class.getField("SingleMemberShortAcceptDefField"), ++ SingleMemberShortWithDef.class); ++ checkEquals(SingleMemberIntAcceptDefClass.class, UnitTest.class.getField("SingleMemberIntAcceptDefField"), ++ SingleMemberIntWithDef.class); ++ checkEquals(SingleMemberLongAcceptDefClass.class, UnitTest.class.getField("SingleMemberLongAcceptDefField"), ++ SingleMemberLongWithDef.class); ++ checkEquals(SingleMemberCharAcceptDefClass.class, UnitTest.class.getField("SingleMemberCharAcceptDefField"), ++ SingleMemberCharWithDef.class); ++ checkEquals(SingleMemberFloatAcceptDefClass.class, UnitTest.class.getField("SingleMemberFloatAcceptDefField"), ++ SingleMemberFloatWithDef.class); ++ checkEquals(SingleMemberDoubleAcceptDefClass.class, UnitTest.class.getField("SingleMemberDoubleAcceptDefField"), ++ SingleMemberDoubleWithDef.class); ++ checkEquals(SingleMemberBooleanAcceptDefClass.class, UnitTest.class.getField("SingleMemberBooleanAcceptDefField"), ++ SingleMemberBooleanWithDef.class); ++ checkEquals(SingleMemberStringAcceptDefClass.class, UnitTest.class.getField("SingleMemberStringAcceptDefField"), ++ SingleMemberStringWithDef.class); ++ checkEquals(SingleMemberClassAcceptDefClass.class, UnitTest.class.getField("SingleMemberClassAcceptDefField"), ++ SingleMemberClassWithDef.class); ++ checkEquals(SingleMemberEnumAcceptDefClass.class, UnitTest.class.getField("SingleMemberEnumAcceptDefField"), ++ SingleMemberEnumWithDef.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (EMPTY ARRAY) ++ checkEquals(SingleMemberByteArrEmptyClass.class, UnitTest.class.getField("SingleMemberByteArrEmptyField"), ++ SingleMemberByteArray.class); ++ checkEquals(SingleMemberShortArrEmptyClass.class, UnitTest.class.getField("SingleMemberShortArrEmptyField"), ++ SingleMemberShortArray.class); ++ checkEquals(SingleMemberIntArrEmptyClass.class, UnitTest.class.getField("SingleMemberIntArrEmptyField"), ++ SingleMemberIntArray.class); ++ checkEquals(SingleMemberLongArrEmptyClass.class, UnitTest.class.getField("SingleMemberLongArrEmptyField"), ++ SingleMemberLongArray.class); ++ checkEquals(SingleMemberCharArrEmptyClass.class, UnitTest.class.getField("SingleMemberCharArrEmptyField"), ++ SingleMemberCharArray.class); ++ checkEquals(SingleMemberFloatArrEmptyClass.class, UnitTest.class.getField("SingleMemberFloatArrEmptyField"), ++ SingleMemberFloatArray.class); ++ checkEquals(SingleMemberDoubleArrEmptyClass.class, UnitTest.class.getField("SingleMemberDoubleArrEmptyField"), ++ SingleMemberDoubleArray.class); ++ checkEquals(SingleMemberBooleanArrEmptyClass.class, UnitTest.class.getField("SingleMemberBooleanArrEmptyField"), ++ SingleMemberBooleanArray.class); ++ checkEquals(SingleMemberStringArrEmptyClass.class, UnitTest.class.getField("SingleMemberStringArrEmptyField"), ++ SingleMemberStringArray.class); ++ checkEquals(SingleMemberClassArrEmptyClass.class, UnitTest.class.getField("SingleMemberClassArrEmptyField"), ++ SingleMemberClassArray.class); ++ checkEquals(SingleMemberEnumArrEmptyClass.class, UnitTest.class.getField("SingleMemberEnumArrEmptyField"), ++ SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (ONE-ELEMENT ARRAY) ++ checkEquals(SingleMemberByteArrOneClass.class, UnitTest.class.getField("SingleMemberByteArrOneField"), ++ SingleMemberByteArray.class); ++ checkEquals(SingleMemberShortArrOneClass.class, UnitTest.class.getField("SingleMemberShortArrOneField"), ++ SingleMemberShortArray.class); ++ checkEquals(SingleMemberIntArrOneClass.class, UnitTest.class.getField("SingleMemberIntArrOneField"), ++ SingleMemberIntArray.class); ++ checkEquals(SingleMemberLongArrOneClass.class, UnitTest.class.getField("SingleMemberLongArrOneField"), ++ SingleMemberLongArray.class); ++ checkEquals(SingleMemberCharArrOneClass.class, UnitTest.class.getField("SingleMemberCharArrOneField"), ++ SingleMemberCharArray.class); ++ checkEquals(SingleMemberFloatArrOneClass.class, UnitTest.class.getField("SingleMemberFloatArrOneField"), ++ SingleMemberFloatArray.class); ++ checkEquals(SingleMemberDoubleArrOneClass.class, UnitTest.class.getField("SingleMemberDoubleArrOneField"), ++ SingleMemberDoubleArray.class); ++ checkEquals(SingleMemberBooleanArrOneClass.class, UnitTest.class.getField("SingleMemberBooleanArrOneField"), ++ SingleMemberBooleanArray.class); ++ checkEquals(SingleMemberStringArrOneClass.class, UnitTest.class.getField("SingleMemberStringArrOneField"), ++ SingleMemberStringArray.class); ++ checkEquals(SingleMemberClassArrOneClass.class, UnitTest.class.getField("SingleMemberClassArrOneField"), ++ SingleMemberClassArray.class); ++ checkEquals(SingleMemberEnumArrOneClass.class, UnitTest.class.getField("SingleMemberEnumArrOneField"), ++ SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TWO-ELEMENT ARRAY) ++ checkEquals(SingleMemberByteArrTwoClass.class, UnitTest.class.getField("SingleMemberByteArrTwoField"), ++ SingleMemberByteArray.class); ++ checkEquals(SingleMemberShortArrTwoClass.class, UnitTest.class.getField("SingleMemberShortArrTwoField"), ++ SingleMemberShortArray.class); ++ checkEquals(SingleMemberIntArrTwoClass.class, UnitTest.class.getField("SingleMemberIntArrTwoField"), ++ SingleMemberIntArray.class); ++ checkEquals(SingleMemberLongArrTwoClass.class, UnitTest.class.getField("SingleMemberLongArrTwoField"), ++ SingleMemberLongArray.class); ++ checkEquals(SingleMemberCharArrTwoClass.class, UnitTest.class.getField("SingleMemberCharArrTwoField"), ++ SingleMemberCharArray.class); ++ checkEquals(SingleMemberFloatArrTwoClass.class, UnitTest.class.getField("SingleMemberFloatArrTwoField"), ++ SingleMemberFloatArray.class); ++ checkEquals(SingleMemberDoubleArrTwoClass.class, UnitTest.class.getField("SingleMemberDoubleArrTwoField"), ++ SingleMemberDoubleArray.class); ++ checkEquals(SingleMemberBooleanArrTwoClass.class, UnitTest.class.getField("SingleMemberBooleanArrTwoField"), ++ SingleMemberBooleanArray.class); ++ checkEquals(SingleMemberStringArrTwoClass.class, UnitTest.class.getField("SingleMemberStringArrTwoField"), ++ SingleMemberStringArray.class); ++ checkEquals(SingleMemberClassArrTwoClass.class, UnitTest.class.getField("SingleMemberClassArrTwoField"), ++ SingleMemberClassArray.class); ++ checkEquals(SingleMemberEnumArrTwoClass.class, UnitTest.class.getField("SingleMemberEnumArrTwoField"), ++ SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (OVERRIDE) ++ checkEquals(SingleMemberByteArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberByteArrOvrdDefField"), ++ SingleMemberByteArrayDef.class); ++ checkEquals(SingleMemberShortArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberShortArrOvrdDefField"), ++ SingleMemberShortArrayDef.class); ++ checkEquals(SingleMemberIntArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberIntArrOvrdDefField"), ++ SingleMemberIntArrayDef.class); ++ checkEquals(SingleMemberLongArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberLongArrOvrdDefField"), ++ SingleMemberLongArrayDef.class); ++ checkEquals(SingleMemberCharArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberCharArrOvrdDefField"), ++ SingleMemberCharArrayDef.class); ++ checkEquals(SingleMemberFloatArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberFloatArrOvrdDefField"), ++ SingleMemberFloatArrayDef.class); ++ checkEquals(SingleMemberDoubleArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberDoubleArrOvrdDefField"), ++ SingleMemberDoubleArrayDef.class); ++ checkEquals(SingleMemberBooleanArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberBooleanArrOvrdDefField"), ++ SingleMemberBooleanArrayDef.class); ++ checkEquals(SingleMemberStringArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberStringArrOvrdDefField"), ++ SingleMemberStringArrayDef.class); ++ checkEquals(SingleMemberClassArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberClassArrOvrdDefField"), ++ SingleMemberClassArrayDef.class); ++ checkEquals(SingleMemberEnumArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberEnumArrOvrdDefField"), ++ SingleMemberEnumArrayDef.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (ACCEPT) ++ checkEquals(SingleMemberByteArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberByteArrAcceptDefField"), ++ SingleMemberByteArrayDef.class); ++ checkEquals(SingleMemberShortArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberShortArrAcceptDefField"), ++ SingleMemberShortArrayDef.class); ++ checkEquals(SingleMemberIntArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberIntArrAcceptDefField"), ++ SingleMemberIntArrayDef.class); ++ checkEquals(SingleMemberLongArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberLongArrAcceptDefField"), ++ SingleMemberLongArrayDef.class); ++ checkEquals(SingleMemberCharArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberCharArrAcceptDefField"), ++ SingleMemberCharArrayDef.class); ++ checkEquals(SingleMemberFloatArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberFloatArrAcceptDefField"), ++ SingleMemberFloatArrayDef.class); ++ checkEquals(SingleMemberDoubleArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberDoubleArrAcceptDefField"), ++ SingleMemberDoubleArrayDef.class); ++ checkEquals(SingleMemberBooleanArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberBooleanArrAcceptDefField"), ++ SingleMemberBooleanArrayDef.class); ++ checkEquals(SingleMemberStringArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberStringArrAcceptDefField"), ++ SingleMemberStringArrayDef.class); ++ checkEquals(SingleMemberClassArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberClassArrAcceptDefField"), ++ SingleMemberClassArrayDef.class); ++ checkEquals(SingleMemberEnumArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberEnumArrAcceptDefField"), ++ SingleMemberEnumArrayDef.class); ++ ++ // *** TESTS FOR EQUALS AND HASHCODE - NEGATIVE ++ ++ // MULTIMEMBER SCALAR TYPES ++ checkUnequals(scalarTypesOverrideDefaultClass.class, UnitTest.class.getField("scalarTypesAcceptDefaultField"), ++ ScalarTypesWithDefault.class); ++ checkUnequals(scalarTypesAcceptDefaultClass.class, UnitTest.class.getField("scalarTypesOverrideDefaultField"), ++ ScalarTypesWithDefault.class); ++ ++ // MULTIMEMBER ARRAY TYPES ++ checkUnequals(emptyArrayTypesClass.class, UnitTest.class.getField("singleElementArrayTypesField"), ++ ArrayTypes.class); ++ checkUnequals(singleElementArrayTypesClass.class, UnitTest.class.getField("twoElementArrayTypesField"), ++ ArrayTypes.class); ++ checkUnequals(twoElementArrayTypesClass.class, UnitTest.class.getField("singleElementArrayTypesField"), ++ ArrayTypes.class); ++ checkUnequals(arrayTypesOverrideDefaultClass.class, UnitTest.class.getField("arrayTypesAcceptDefaultField"), ++ ArrayTypesWithDefault.class); ++ checkUnequals(arrayTypesAcceptDefaultClass.class, UnitTest.class.getField("arrayTypesOverrideDefaultField"), ++ ArrayTypesWithDefault.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ++ checkUnequals(SingleMemberByteOvrdDefClass.class, UnitTest.class.getField("SingleMemberByteAcceptDefField"), ++ SingleMemberByteWithDef.class); ++ checkUnequals(SingleMemberShortOvrdDefClass.class, UnitTest.class.getField("SingleMemberShortAcceptDefField"), ++ SingleMemberShortWithDef.class); ++ checkUnequals(SingleMemberIntOvrdDefClass.class, UnitTest.class.getField("SingleMemberIntAcceptDefField"), ++ SingleMemberIntWithDef.class); ++ checkUnequals(SingleMemberLongOvrdDefClass.class, UnitTest.class.getField("SingleMemberLongAcceptDefField"), ++ SingleMemberLongWithDef.class); ++ checkUnequals(SingleMemberCharOvrdDefClass.class, UnitTest.class.getField("SingleMemberCharAcceptDefField"), ++ SingleMemberCharWithDef.class); ++ checkUnequals(SingleMemberFloatOvrdDefClass.class, UnitTest.class.getField("SingleMemberFloatAcceptDefField"), ++ SingleMemberFloatWithDef.class); ++ checkUnequals(SingleMemberDoubleOvrdDefClass.class, UnitTest.class.getField("SingleMemberDoubleAcceptDefField"), ++ SingleMemberDoubleWithDef.class); ++ checkUnequals(SingleMemberBooleanOvrdDefClass.class, UnitTest.class.getField("SingleMemberBooleanAcceptDefField"), ++ SingleMemberBooleanWithDef.class); ++ checkUnequals(SingleMemberStringOvrdDefClass.class, UnitTest.class.getField("SingleMemberStringAcceptDefField"), ++ SingleMemberStringWithDef.class); ++ checkUnequals(SingleMemberClassOvrdDefClass.class, UnitTest.class.getField("SingleMemberClassAcceptDefField"), ++ SingleMemberClassWithDef.class); ++ checkUnequals(SingleMemberEnumOvrdDefClass.class, UnitTest.class.getField("SingleMemberEnumAcceptDefField"), ++ SingleMemberEnumWithDef.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ++ checkUnequals(SingleMemberByteAcceptDefClass.class, UnitTest.class.getField("SingleMemberByteOvrdDefField"), ++ SingleMemberByteWithDef.class); ++ checkUnequals(SingleMemberShortAcceptDefClass.class, UnitTest.class.getField("SingleMemberShortOvrdDefField"), ++ SingleMemberShortWithDef.class); ++ checkUnequals(SingleMemberIntAcceptDefClass.class, UnitTest.class.getField("SingleMemberIntOvrdDefField"), ++ SingleMemberIntWithDef.class); ++ checkUnequals(SingleMemberLongAcceptDefClass.class, UnitTest.class.getField("SingleMemberLongOvrdDefField"), ++ SingleMemberLongWithDef.class); ++ checkUnequals(SingleMemberCharAcceptDefClass.class, UnitTest.class.getField("SingleMemberCharOvrdDefField"), ++ SingleMemberCharWithDef.class); ++ checkUnequals(SingleMemberFloatAcceptDefClass.class, UnitTest.class.getField("SingleMemberFloatOvrdDefField"), ++ SingleMemberFloatWithDef.class); ++ checkUnequals(SingleMemberDoubleAcceptDefClass.class, UnitTest.class.getField("SingleMemberDoubleOvrdDefField"), ++ SingleMemberDoubleWithDef.class); ++ checkUnequals(SingleMemberBooleanAcceptDefClass.class, UnitTest.class.getField("SingleMemberBooleanOvrdDefField"), ++ SingleMemberBooleanWithDef.class); ++ checkUnequals(SingleMemberStringAcceptDefClass.class, UnitTest.class.getField("SingleMemberStringOvrdDefField"), ++ SingleMemberStringWithDef.class); ++ checkUnequals(SingleMemberClassAcceptDefClass.class, UnitTest.class.getField("SingleMemberClassOvrdDefField"), ++ SingleMemberClassWithDef.class); ++ checkUnequals(SingleMemberEnumAcceptDefClass.class, UnitTest.class.getField("SingleMemberEnumOvrdDefField"), ++ SingleMemberEnumWithDef.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (EMPTY ARRAY) ++ checkUnequals(SingleMemberByteArrEmptyClass.class, UnitTest.class.getField("SingleMemberByteArrOneField"), ++ SingleMemberByteArray.class); ++ checkUnequals(SingleMemberShortArrEmptyClass.class, UnitTest.class.getField("SingleMemberShortArrOneField"), ++ SingleMemberShortArray.class); ++ checkUnequals(SingleMemberIntArrEmptyClass.class, UnitTest.class.getField("SingleMemberIntArrOneField"), ++ SingleMemberIntArray.class); ++ checkUnequals(SingleMemberLongArrEmptyClass.class, UnitTest.class.getField("SingleMemberLongArrOneField"), ++ SingleMemberLongArray.class); ++ checkUnequals(SingleMemberCharArrEmptyClass.class, UnitTest.class.getField("SingleMemberCharArrOneField"), ++ SingleMemberCharArray.class); ++ checkUnequals(SingleMemberFloatArrEmptyClass.class, UnitTest.class.getField("SingleMemberFloatArrOneField"), ++ SingleMemberFloatArray.class); ++ checkUnequals(SingleMemberDoubleArrEmptyClass.class, UnitTest.class.getField("SingleMemberDoubleArrOneField"), ++ SingleMemberDoubleArray.class); ++ checkUnequals(SingleMemberBooleanArrEmptyClass.class, UnitTest.class.getField("SingleMemberBooleanArrOneField"), ++ SingleMemberBooleanArray.class); ++ checkUnequals(SingleMemberStringArrEmptyClass.class, UnitTest.class.getField("SingleMemberStringArrOneField"), ++ SingleMemberStringArray.class); ++ checkUnequals(SingleMemberClassArrEmptyClass.class, UnitTest.class.getField("SingleMemberClassArrOneField"), ++ SingleMemberClassArray.class); ++ checkUnequals(SingleMemberEnumArrEmptyClass.class, UnitTest.class.getField("SingleMemberEnumArrOneField"), ++ SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (ONE-ELEMENT ARRAY) ++ checkUnequals(SingleMemberByteArrOneClass.class, UnitTest.class.getField("SingleMemberByteArrTwoField"), ++ SingleMemberByteArray.class); ++ checkUnequals(SingleMemberShortArrOneClass.class, UnitTest.class.getField("SingleMemberShortArrTwoField"), ++ SingleMemberShortArray.class); ++ checkUnequals(SingleMemberIntArrOneClass.class, UnitTest.class.getField("SingleMemberIntArrTwoField"), ++ SingleMemberIntArray.class); ++ checkUnequals(SingleMemberLongArrOneClass.class, UnitTest.class.getField("SingleMemberLongArrTwoField"), ++ SingleMemberLongArray.class); ++ checkUnequals(SingleMemberCharArrOneClass.class, UnitTest.class.getField("SingleMemberCharArrTwoField"), ++ SingleMemberCharArray.class); ++ checkUnequals(SingleMemberFloatArrOneClass.class, UnitTest.class.getField("SingleMemberFloatArrTwoField"), ++ SingleMemberFloatArray.class); ++ checkUnequals(SingleMemberDoubleArrOneClass.class, UnitTest.class.getField("SingleMemberDoubleArrTwoField"), ++ SingleMemberDoubleArray.class); ++ checkUnequals(SingleMemberBooleanArrOneClass.class, UnitTest.class.getField("SingleMemberBooleanArrTwoField"), ++ SingleMemberBooleanArray.class); ++ checkUnequals(SingleMemberStringArrOneClass.class, UnitTest.class.getField("SingleMemberStringArrTwoField"), ++ SingleMemberStringArray.class); ++ checkUnequals(SingleMemberClassArrOneClass.class, UnitTest.class.getField("SingleMemberClassArrTwoField"), ++ SingleMemberClassArray.class); ++ checkUnequals(SingleMemberEnumArrOneClass.class, UnitTest.class.getField("SingleMemberEnumArrTwoField"), ++ SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TWO-ELEMENT ARRAY) ++ checkUnequals(SingleMemberByteArrTwoClass.class, UnitTest.class.getField("SingleMemberByteArrOneField"), ++ SingleMemberByteArray.class); ++ checkUnequals(SingleMemberShortArrTwoClass.class, UnitTest.class.getField("SingleMemberShortArrOneField"), ++ SingleMemberShortArray.class); ++ checkUnequals(SingleMemberIntArrTwoClass.class, UnitTest.class.getField("SingleMemberIntArrOneField"), ++ SingleMemberIntArray.class); ++ checkUnequals(SingleMemberLongArrTwoClass.class, UnitTest.class.getField("SingleMemberLongArrOneField"), ++ SingleMemberLongArray.class); ++ checkUnequals(SingleMemberCharArrTwoClass.class, UnitTest.class.getField("SingleMemberCharArrOneField"), ++ SingleMemberCharArray.class); ++ checkUnequals(SingleMemberFloatArrTwoClass.class, UnitTest.class.getField("SingleMemberFloatArrOneField"), ++ SingleMemberFloatArray.class); ++ checkUnequals(SingleMemberDoubleArrTwoClass.class, UnitTest.class.getField("SingleMemberDoubleArrOneField"), ++ SingleMemberDoubleArray.class); ++ checkUnequals(SingleMemberBooleanArrTwoClass.class, UnitTest.class.getField("SingleMemberBooleanArrOneField"), ++ SingleMemberBooleanArray.class); ++ checkUnequals(SingleMemberStringArrTwoClass.class, UnitTest.class.getField("SingleMemberStringArrOneField"), ++ SingleMemberStringArray.class); ++ checkUnequals(SingleMemberClassArrTwoClass.class, UnitTest.class.getField("SingleMemberClassArrOneField"), ++ SingleMemberClassArray.class); ++ checkUnequals(SingleMemberEnumArrTwoClass.class, UnitTest.class.getField("SingleMemberEnumArrOneField"), ++ SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (OVERRIDE) ++ checkUnequals(SingleMemberByteArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberByteArrAcceptDefField"), ++ SingleMemberByteArrayDef.class); ++ checkUnequals(SingleMemberShortArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberShortArrAcceptDefField"), ++ SingleMemberShortArrayDef.class); ++ checkUnequals(SingleMemberIntArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberIntArrAcceptDefField"), ++ SingleMemberIntArrayDef.class); ++ checkUnequals(SingleMemberLongArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberLongArrAcceptDefField"), ++ SingleMemberLongArrayDef.class); ++ checkUnequals(SingleMemberCharArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberCharArrAcceptDefField"), ++ SingleMemberCharArrayDef.class); ++ checkUnequals(SingleMemberFloatArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberFloatArrAcceptDefField"), ++ SingleMemberFloatArrayDef.class); ++ checkUnequals(SingleMemberDoubleArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberDoubleArrAcceptDefField"), ++ SingleMemberDoubleArrayDef.class); ++ checkUnequals(SingleMemberBooleanArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberBooleanArrAcceptDefField"), ++ SingleMemberBooleanArrayDef.class); ++ checkUnequals(SingleMemberStringArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberStringArrAcceptDefField"), ++ SingleMemberStringArrayDef.class); ++ checkUnequals(SingleMemberClassArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberClassArrAcceptDefField"), ++ SingleMemberClassArrayDef.class); ++ checkUnequals(SingleMemberEnumArrOvrdDefClass.class, UnitTest.class.getField("SingleMemberEnumArrAcceptDefField"), ++ SingleMemberEnumArrayDef.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (ACCEPT) ++ checkUnequals(SingleMemberByteArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberByteArrOvrdDefField"), ++ SingleMemberByteArrayDef.class); ++ checkUnequals(SingleMemberShortArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberShortArrOvrdDefField"), ++ SingleMemberShortArrayDef.class); ++ checkUnequals(SingleMemberIntArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberIntArrOvrdDefField"), ++ SingleMemberIntArrayDef.class); ++ checkUnequals(SingleMemberLongArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberLongArrOvrdDefField"), ++ SingleMemberLongArrayDef.class); ++ checkUnequals(SingleMemberCharArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberCharArrOvrdDefField"), ++ SingleMemberCharArrayDef.class); ++ checkUnequals(SingleMemberFloatArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberFloatArrOvrdDefField"), ++ SingleMemberFloatArrayDef.class); ++ checkUnequals(SingleMemberDoubleArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberDoubleArrOvrdDefField"), ++ SingleMemberDoubleArrayDef.class); ++ checkUnequals(SingleMemberBooleanArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberBooleanArrOvrdDefField"), ++ SingleMemberBooleanArrayDef.class); ++ checkUnequals(SingleMemberStringArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberStringArrOvrdDefField"), ++ SingleMemberStringArrayDef.class); ++ checkUnequals(SingleMemberClassArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberClassArrOvrdDefField"), ++ SingleMemberClassArrayDef.class); ++ checkUnequals(SingleMemberEnumArrAcceptDefClass.class, UnitTest.class.getField("SingleMemberEnumArrOvrdDefField"), ++ SingleMemberEnumArrayDef.class); ++ ++ // *** TESTS FOR SERIALIZATION AND DESERIALIZATION ++ ++ // MULTIMEMBER SCALAR TYPES ++ checkSerialization(scalarTypesClass.class, ScalarTypes.class); ++ checkSerialization(scalarTypesOverrideDefaultClass.class, ScalarTypesWithDefault.class); ++ checkSerialization(scalarTypesAcceptDefaultClass.class, ScalarTypesWithDefault.class); ++ ++ // MULTIMEMBER ARRAY TYPES ++ checkSerialization(emptyArrayTypesClass.class, ArrayTypes.class); ++ checkSerialization(singleElementArrayTypesClass.class, ArrayTypes.class); ++ checkSerialization(twoElementArrayTypesClass.class, ArrayTypes.class); ++ checkSerialization(arrayTypesOverrideDefaultClass.class, ArrayTypesWithDefault.class); ++ checkSerialization(arrayTypesAcceptDefaultClass.class, ArrayTypesWithDefault.class); ++ ++ // MARKER TYPE ++ checkSerialization(markerClass.class, Marker.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES ++ checkSerialization(SingleMemberByteClass.class, SingleMemberByte.class); ++ checkSerialization(SingleMemberShortClass.class, SingleMemberShort.class); ++ checkSerialization(SingleMemberIntClass.class, SingleMemberInt.class); ++ checkSerialization(SingleMemberLongClass.class, SingleMemberLong.class); ++ checkSerialization(SingleMemberCharClass.class, SingleMemberChar.class); ++ checkSerialization(SingleMemberFloatClass.class, SingleMemberFloat.class); ++ checkSerialization(SingleMemberDoubleClass.class, SingleMemberDouble.class); ++ checkSerialization(SingleMemberBooleanClass.class, SingleMemberBoolean.class); ++ checkSerialization(SingleMemberStringClass.class, SingleMemberString.class); ++ checkSerialization(SingleMemberClassClass.class, SingleMemberClass.class); ++ checkSerialization(SingleMemberEnumClass.class, SingleMemberEnum.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-OVERRIDE ++ checkSerialization(SingleMemberByteOvrdDefClass.class, SingleMemberByteWithDef.class); ++ checkSerialization(SingleMemberShortOvrdDefClass.class, SingleMemberShortWithDef.class); ++ checkSerialization(SingleMemberIntOvrdDefClass.class, SingleMemberIntWithDef.class); ++ checkSerialization(SingleMemberLongOvrdDefClass.class, SingleMemberLongWithDef.class); ++ checkSerialization(SingleMemberCharOvrdDefClass.class, SingleMemberCharWithDef.class); ++ checkSerialization(SingleMemberFloatOvrdDefClass.class, SingleMemberFloatWithDef.class); ++ checkSerialization(SingleMemberDoubleOvrdDefClass.class, SingleMemberDoubleWithDef.class); ++ checkSerialization(SingleMemberBooleanOvrdDefClass.class, SingleMemberBooleanWithDef.class); ++ checkSerialization(SingleMemberStringOvrdDefClass.class, SingleMemberStringWithDef.class); ++ checkSerialization(SingleMemberClassOvrdDefClass.class, SingleMemberClassWithDef.class); ++ checkSerialization(SingleMemberEnumOvrdDefClass.class, SingleMemberEnumWithDef.class); ++ ++ // SINGLE-MEMBER SCALAR TYPES WITH DEFAULT-ACCEPT ++ checkSerialization(SingleMemberByteAcceptDefClass.class, SingleMemberByteWithDef.class); ++ checkSerialization(SingleMemberShortAcceptDefClass.class, SingleMemberShortWithDef.class); ++ checkSerialization(SingleMemberIntAcceptDefClass.class, SingleMemberIntWithDef.class); ++ checkSerialization(SingleMemberLongAcceptDefClass.class, SingleMemberLongWithDef.class); ++ checkSerialization(SingleMemberCharAcceptDefClass.class, SingleMemberCharWithDef.class); ++ checkSerialization(SingleMemberFloatAcceptDefClass.class, SingleMemberFloatWithDef.class); ++ checkSerialization(SingleMemberDoubleAcceptDefClass.class, SingleMemberDoubleWithDef.class); ++ checkSerialization(SingleMemberBooleanAcceptDefClass.class, SingleMemberBooleanWithDef.class); ++ checkSerialization(SingleMemberStringAcceptDefClass.class, SingleMemberStringWithDef.class); ++ checkSerialization(SingleMemberClassAcceptDefClass.class, SingleMemberClassWithDef.class); ++ checkSerialization(SingleMemberEnumAcceptDefClass.class, SingleMemberEnumWithDef.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (EMPTY ARRAY) ++ checkSerialization(SingleMemberByteArrEmptyClass.class, SingleMemberByteArray.class); ++ checkSerialization(SingleMemberShortArrEmptyClass.class, SingleMemberShortArray.class); ++ checkSerialization(SingleMemberIntArrEmptyClass.class, SingleMemberIntArray.class); ++ checkSerialization(SingleMemberLongArrEmptyClass.class, SingleMemberLongArray.class); ++ checkSerialization(SingleMemberCharArrEmptyClass.class, SingleMemberCharArray.class); ++ checkSerialization(SingleMemberFloatArrEmptyClass.class, SingleMemberFloatArray.class); ++ checkSerialization(SingleMemberDoubleArrEmptyClass.class, SingleMemberDoubleArray.class); ++ checkSerialization(SingleMemberBooleanArrEmptyClass.class, SingleMemberBooleanArray.class); ++ checkSerialization(SingleMemberStringArrEmptyClass.class, SingleMemberStringArray.class); ++ checkSerialization(SingleMemberClassArrEmptyClass.class, SingleMemberClassArray.class); ++ checkSerialization(SingleMemberEnumArrEmptyClass.class, SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (ONE-ELEMENT ARRAY) ++ checkSerialization(SingleMemberByteArrOneClass.class, SingleMemberByteArray.class); ++ checkSerialization(SingleMemberShortArrOneClass.class, SingleMemberShortArray.class); ++ checkSerialization(SingleMemberIntArrOneClass.class, SingleMemberIntArray.class); ++ checkSerialization(SingleMemberLongArrOneClass.class, SingleMemberLongArray.class); ++ checkSerialization(SingleMemberCharArrOneClass.class, SingleMemberCharArray.class); ++ checkSerialization(SingleMemberFloatArrOneClass.class, SingleMemberFloatArray.class); ++ checkSerialization(SingleMemberDoubleArrOneClass.class, SingleMemberDoubleArray.class); ++ checkSerialization(SingleMemberBooleanArrOneClass.class, SingleMemberBooleanArray.class); ++ checkSerialization(SingleMemberStringArrOneClass.class, SingleMemberStringArray.class); ++ checkSerialization(SingleMemberClassArrOneClass.class, SingleMemberClassArray.class); ++ checkSerialization(SingleMemberEnumArrOneClass.class, SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES (TWO-ELEMENT ARRAY) ++ checkSerialization(SingleMemberByteArrTwoClass.class, SingleMemberByteArray.class); ++ checkSerialization(SingleMemberShortArrTwoClass.class, SingleMemberShortArray.class); ++ checkSerialization(SingleMemberIntArrTwoClass.class, SingleMemberIntArray.class); ++ checkSerialization(SingleMemberLongArrTwoClass.class, SingleMemberLongArray.class); ++ checkSerialization(SingleMemberCharArrTwoClass.class, SingleMemberCharArray.class); ++ checkSerialization(SingleMemberFloatArrTwoClass.class, SingleMemberFloatArray.class); ++ checkSerialization(SingleMemberDoubleArrTwoClass.class, SingleMemberDoubleArray.class); ++ checkSerialization(SingleMemberBooleanArrTwoClass.class, SingleMemberBooleanArray.class); ++ checkSerialization(SingleMemberStringArrTwoClass.class, SingleMemberStringArray.class); ++ checkSerialization(SingleMemberClassArrTwoClass.class, SingleMemberClassArray.class); ++ checkSerialization(SingleMemberEnumArrTwoClass.class, SingleMemberEnumArray.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (OVERRIDE) ++ checkSerialization(SingleMemberByteArrOvrdDefClass.class, SingleMemberByteArrayDef.class); ++ checkSerialization(SingleMemberShortArrOvrdDefClass.class, SingleMemberShortArrayDef.class); ++ checkSerialization(SingleMemberIntArrOvrdDefClass.class, SingleMemberIntArrayDef.class); ++ checkSerialization(SingleMemberLongArrOvrdDefClass.class, SingleMemberLongArrayDef.class); ++ checkSerialization(SingleMemberCharArrOvrdDefClass.class, SingleMemberCharArrayDef.class); ++ checkSerialization(SingleMemberFloatArrOvrdDefClass.class, SingleMemberFloatArrayDef.class); ++ checkSerialization(SingleMemberDoubleArrOvrdDefClass.class, SingleMemberDoubleArrayDef.class); ++ checkSerialization(SingleMemberBooleanArrOvrdDefClass.class, SingleMemberBooleanArrayDef.class); ++ checkSerialization(SingleMemberStringArrOvrdDefClass.class, SingleMemberStringArrayDef.class); ++ checkSerialization(SingleMemberClassArrOvrdDefClass.class, SingleMemberClassArrayDef.class); ++ checkSerialization(SingleMemberEnumArrOvrdDefClass.class, SingleMemberEnumArrayDef.class); ++ ++ // SINGLE-MEMBER ARRAY TYPES WITH DEFAULT (ACCEPT) ++ checkSerialization(SingleMemberByteArrAcceptDefClass.class, SingleMemberByteArrayDef.class); ++ checkSerialization(SingleMemberShortArrAcceptDefClass.class, SingleMemberShortArrayDef.class); ++ checkSerialization(SingleMemberIntArrAcceptDefClass.class, SingleMemberIntArrayDef.class); ++ checkSerialization(SingleMemberLongArrAcceptDefClass.class, SingleMemberLongArrayDef.class); ++ checkSerialization(SingleMemberCharArrAcceptDefClass.class, SingleMemberCharArrayDef.class); ++ checkSerialization(SingleMemberFloatArrAcceptDefClass.class, SingleMemberFloatArrayDef.class); ++ checkSerialization(SingleMemberDoubleArrAcceptDefClass.class, SingleMemberDoubleArrayDef.class); ++ checkSerialization(SingleMemberBooleanArrAcceptDefClass.class, SingleMemberBooleanArrayDef.class); ++ checkSerialization(SingleMemberStringArrAcceptDefClass.class, SingleMemberStringArrayDef.class); ++ checkSerialization(SingleMemberClassArrAcceptDefClass.class, SingleMemberClassArrayDef.class); ++ checkSerialization(SingleMemberEnumArrAcceptDefClass.class, SingleMemberEnumArrayDef.class); ++ ++ // *** TESTS FOR ANNOTATION INHERITANCE AND ENUMERATING DECLARED ANNOTATIONS ++ ++ // Inheritance tests ++ checkInheritence(Grandpa.class, true, true); ++ checkInheritence(Dad.class, true, false); ++ checkInheritence(Son.class, true, true); ++ ++ // Declared annotations tests ++ checkDeclaredAnnotations(Grandpa.class, true, true); ++ checkDeclaredAnnotations(Dad.class, false, false); ++ checkDeclaredAnnotations(Son.class, false, true); ++ ++ // Generate summary ++ System.out.println("\n" + numTests + " tests completed"); ++ if (failCount != 0) ++ throw new Exception("Failure count: " + failCount); ++ else ++ System.out.println("Success."); ++ } ++ ++ static int failCount = 0; ++ ++ private static void fail(String test) { ++ System.out.println("Failure: " + test); ++ failCount++; ++ } ++ ++ // ANNOTATION-VERIFICATION METHODS ++ ++ // Scalar multi-member ++ ++ static void checkScalarTypes(AnnotatedElement e) { ++ try { ++ checkScalarTypes(e.getAnnotation(ScalarTypes.class), e); ++ } catch(Throwable t) { ++ fail("ScalarTypes " + e + ": " + t); ++ t.printStackTrace(); ++ } ++ } ++ ++ static void checkScalarTypes(ScalarTypes st, AnnotatedElement e) throws Exception { ++ numTests++; ++ if (!(st.b() == 1 && ++ st.s() == 2 && ++ st.i() == 3 && ++ st.l() == 4L && ++ st.c() == '5' && ++ st.f() == 6.0f && ++ st.d() == 7.0 && ++ st.bool() == true && ++ st.str().equals("custom") && ++ st.cls() == Map.class && ++ st.e() == Stooge.MOE && ++ st.a().x() == 1 && st.a().y() == 2)) ++ fail("ScalarTypes" + e); ++ } ++ ++ static void checkScalarTypesOverrideDefault(AnnotatedElement e) { ++ try { ++ checkScalarTypesOverrideDefault(e.getAnnotation(ScalarTypesWithDefault.class), e); ++ } catch(Throwable t) { ++ fail("ScalarTypesOverrideDefaults" + e + ": " + t); ++ } ++ } ++ ++ static void checkScalarTypesOverrideDefault(ScalarTypesWithDefault st, AnnotatedElement e) { ++ numTests++; ++ if (!(st.b() == 1 && ++ st.s() == 2 && ++ st.i() == 3 && ++ st.l() == 4L && ++ st.c() == '5' && ++ st.f() == 6.0f && ++ st.d() == 7.0 && ++ st.bool() == true && ++ st.str().equals("custom") && ++ st.cls() == Map.class && ++ st.e() == Stooge.MOE)) ++ fail("ScalarTypesOverrideDefaults" + e); ++ } ++ ++ static void checkScalarTypesAcceptDefault(AnnotatedElement e) { ++ try { ++ checkScalarTypesAcceptDefault(e.getAnnotation(ScalarTypesWithDefault.class), e); ++ } catch(Throwable t) { ++ fail("ScalarTypesAcceptDefaults" + e + ": " + t); ++ } ++ } ++ ++ static void checkScalarTypesAcceptDefault(ScalarTypesWithDefault st, AnnotatedElement e) { ++ numTests++; ++ if (!(st.b() == 11 && ++ st.s() == 12 && ++ st.i() == 13 && ++ st.l() == 14L && ++ st.c() == 'V' && ++ st.f() == 16.0f && ++ st.d() == 17.0 && ++ st.bool() == false && ++ st.str().equals("default") && ++ st.cls() == Class.class && ++ st.e() == Stooge.LARRY && ++ st.a().x() == 11 && st.a().y() == 12)) ++ fail("ScalarTypesAcceptDefaults" + e); ++ } ++ ++ // Array multi-member ++ ++ static void checkArrayTypes0(AnnotatedElement e) { ++ try { ++ checkArrayTypes0(e.getAnnotation(ArrayTypes.class), e); ++ } catch(Throwable t) { ++ fail("ArrayTypes(Empty)" + e + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypes0(ArrayTypes at, AnnotatedElement e) { ++ numTests++; ++ if (!(at.b().length == 0 && ++ at.s().length == 0 && ++ at.i().length == 0 && ++ at.l().length == 0 && ++ at.c().length == 0 && ++ at.f().length == 0 && ++ at.d().length == 0 && ++ at.bool().length == 0 && ++ at.str().length == 0 && ++ at.cls().length == 0 && ++ at.e().length == 0 && ++ at.a().length == 0)) { ++ fail("ArrayTypes(Empty)" + e); ++ } ++ } ++ ++ static void checkArrayTypes1(AnnotatedElement e) { ++ try { ++ checkArrayTypes1(e.getAnnotation(ArrayTypes.class), e); ++ } catch(Throwable t) { ++ fail("ArrayTypes(One element)" + e + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypes1(ArrayTypes at, AnnotatedElement e) { ++ numTests++; ++ if (!(at.b()[0] == 1 && ++ at.s()[0] == 2 && ++ at.i()[0] == 3 && ++ at.l()[0] == 4L && ++ at.c()[0] == '5' && ++ at.f()[0] == 6.0f && ++ at.d()[0] == 7.0 && ++ at.bool()[0] == true && ++ at.str()[0].equals("custom") && ++ at.cls()[0] == Map.class && ++ at.e()[0] == Stooge.MOE && ++ at.a()[0].x() == 1 && at.a()[0].y() == 2 && ++ ++ at.b().length==1 && at.s().length==1 && at.i().length==1 && ++ at.l().length==1 && at.c().length==1 && at.d().length==1 && ++ at.bool().length==1 && at.str().length==1 && ++ at.cls().length==1 && at.cls().length==1 && at.a().length==1)) ++ fail("ArrayTypes(One element)" + e); ++ } ++ ++ static void checkArrayTypes2(AnnotatedElement e) { ++ try { ++ checkArrayTypes2(e.getAnnotation(ArrayTypes.class), e); ++ } catch(Throwable t) { ++ fail("ArrayTypes(Two element)" + e + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypes2(ArrayTypes at, AnnotatedElement e) { ++ numTests++; ++ if (!(at.b()[0] == 1 && at.b()[1] == 2 && ++ at.s()[0] == 2 && at.s()[1] == 3 && ++ at.i()[0] == 3 && at.i()[1] == 4 && ++ at.l()[0] == 4L && at.l()[1] == 5L && ++ at.c()[0] == '5' && at.c()[1] == '6' && ++ at.f()[0] == 6.0f && at.f()[1] == 7.0f && ++ at.d()[0] == 7.0 && at.d()[1] == 8.0 && ++ at.bool()[0] == true && at.bool()[1] == false && ++ at.str()[0].equals("custom") && at.str()[1].equals("paint") && ++ at.cls()[0] == Map.class && at.cls()[1] == Set.class && ++ at.e()[0] == Stooge.MOE && at.e()[1] == Stooge.CURLY && ++ at.a()[0].x() == 1 && at.a()[0].y() == 2 && at.a()[1].x() == 3 && at.a()[1].y() == 4 && ++ ++ at.b().length==2 && at.s().length==2 && at.i().length==2 && ++ at.l().length==2 && at.c().length==2 && at.d().length==2 && ++ at.bool().length==2 && at.str().length==2 && ++ at.cls().length==2 && at.cls().length==2 && at.a().length==2)) ++ fail("ArrayTypes(Two element)" + e); ++ } ++ ++ static void checkArrayTypesOverrideDefault(AnnotatedElement e) { ++ try { ++ checkArrayTypesOverrideDefault(e.getAnnotation(ArrayTypesWithDefault.class), e); ++ } catch(Throwable t) { ++ fail("ArrayTypesOverrideDefault" + e + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypesOverrideDefault(ArrayTypesWithDefault at, AnnotatedElement e) { ++ numTests++; ++ if (!(at.b()[0] == 1 && ++ at.s()[0] == 2 && ++ at.i()[0] == 3 && ++ at.l()[0] == 4L && ++ at.c()[0] == '5' && ++ at.f()[0] == 6.0f && ++ at.d()[0] == 7.0 && ++ at.bool()[0] == true && ++ at.str()[0].equals("custom") && ++ at.cls()[0] == Map.class && ++ at.e()[0] == Stooge.MOE && ++ at.a()[0].x() == 1 && at.a()[0].y() == 2 && ++ ++ at.b().length==1 && at.s().length==1 && at.i().length==1 && ++ at.l().length==1 && at.c().length==1 && at.d().length==1 && ++ at.bool().length==1 && at.str().length==1 && ++ at.cls().length==1 && at.cls().length==1)) ++ fail("ArrayTypesOverrideDefault" + e); ++ } ++ ++ static void checkArrayTypesAcceptDefault(AnnotatedElement e) { ++ try { ++ checkArrayTypesAcceptDefault(e.getAnnotation(ArrayTypesWithDefault.class), e); ++ } catch(Throwable t) { ++ fail("ArrayTypesAcceptDefault" + e + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypesAcceptDefault(ArrayTypesWithDefault at, AnnotatedElement e) { ++ numTests++; ++ if (!(at.b()[0] == 11 && ++ at.s()[0] == 12 && ++ at.i()[0] == 13 && ++ at.l()[0] == 14L && ++ at.c()[0] == 'V' && ++ at.f()[0] == 16.0f && ++ at.d()[0] == 17.0 && ++ at.bool()[0] == false && ++ at.str()[0].equals("default") && ++ at.cls()[0] == Class.class && ++ at.e()[0] == Stooge.LARRY && ++ at.a()[0].x() == 11 && at.a()[0].y() == 12 && ++ ++ at.b().length==1 && at.s().length==1 && at.i().length==1 && ++ at.l().length==1 && at.c().length==1 && at.d().length==1 && ++ at.bool().length==1 && at.str().length==1 && ++ at.cls().length==1 && at.cls().length==1)) ++ fail("ArrayTypesAcceptDefault" + e); ++ } ++ ++ // Scalar multi-member for parameters ++ ++ static void checkScalarTypesParam(Method m) { ++ try { ++ checkScalarTypes((ScalarTypes) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("ScalarTypes" + m + ": " + t); ++ } ++ } ++ ++ static void checkScalarTypesOverrideDefaultParam(Method m) { ++ try { ++ checkScalarTypesOverrideDefault((ScalarTypesWithDefault) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("ScalarTypesOverrideDefaults" + m + ": " + t); ++ } ++ } ++ ++ static void checkScalarTypesAcceptDefaultParam(Method m) { ++ try { ++ checkScalarTypesAcceptDefault((ScalarTypesWithDefault) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("ScalarTypesAcceptDefaults" + m + ": " + t); ++ } ++ } ++ ++ // Array multi-member for parameters ++ ++ static void checkArrayTypes0Param(Method m) { ++ try { ++ checkArrayTypes0((ArrayTypes) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("ArrayTypes(Empty)" + m + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypes1Param(Method m) { ++ try { ++ checkArrayTypes1((ArrayTypes) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("ArrayTypes(One Element)" + m + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypes2Param(Method m) { ++ try { ++ checkArrayTypes2((ArrayTypes) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("ArrayTypes(Two Elements)" + m + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypesOverrideDefaultParam(Method m) { ++ try { ++ checkArrayTypesOverrideDefault((ArrayTypesWithDefault) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("ArrayTypesOverrideDefault" + m + ": " + t); ++ } ++ } ++ ++ static void checkArrayTypesAcceptDefaultParam(Method m) { ++ try { ++ checkArrayTypesAcceptDefault((ArrayTypesWithDefault) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("ArrayTypesAcceptDefault" + m + ": " + t); ++ } ++ } ++ ++ // marker type on parameter ++ static void checkMarkerParam(Method m) { ++ try { ++ checkMarker((Marker) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("Marker" + m + ": " + t); ++ } ++ } ++ ++ // single-member scalar types on parameter ++ static void checkSingleMemberByteParam(Method m) { ++ try { ++ checkSingleMemberByte((SingleMemberByte) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberByte" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortParam(Method m) { ++ try { ++ checkSingleMemberShort((SingleMemberShort) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberShort" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntParam(Method m) { ++ try { ++ checkSingleMemberInt((SingleMemberInt) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberInt" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongParam(Method m) { ++ try { ++ checkSingleMemberLong((SingleMemberLong) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberLong" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharParam(Method m) { ++ try { ++ checkSingleMemberChar((SingleMemberChar) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberChar" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatParam(Method m) { ++ try { ++ checkSingleMemberFloat((SingleMemberFloat) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberFloat" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleParam(Method m) { ++ try { ++ checkSingleMemberDouble((SingleMemberDouble) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberDouble" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanParam(Method m) { ++ try { ++ checkSingleMemberBoolean((SingleMemberBoolean) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberBoolean" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringParam(Method m) { ++ try { ++ checkSingleMemberString((SingleMemberString) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberString" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassParam(Method m) { ++ try { ++ checkSingleMemberClass((SingleMemberClass) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberClass" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumParam(Method m) { ++ try { ++ checkSingleMemberEnum((SingleMemberEnum) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberEnum" + m + ": " + t); ++ } ++ } ++ ++ // single-member scalar types with default-override on parameter ++ static void checkSingleMemberByteOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberByteOvrdDef((SingleMemberByteWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberByteOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberShortOvrdDef((SingleMemberShortWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberShortOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberIntOvrdDef((SingleMemberIntWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberIntOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberLongOvrdDef((SingleMemberLongWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberLongOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberCharOvrdDef((SingleMemberCharWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberCharOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberFloatOvrdDef((SingleMemberFloatWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberDoubleOvrdDef((SingleMemberDoubleWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberBooleanOvrdDef((SingleMemberBooleanWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberStringOvrdDef((SingleMemberStringWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberStringOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberClassOvrdDef((SingleMemberClassWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberClassOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberEnumOvrdDef((SingleMemberEnumWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ // single-member scalar types with default-accept on PARAMETER ++ static void checkSingleMemberByteAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberByteAcceptDef((SingleMemberByteWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberByteAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberShortAcceptDef((SingleMemberShortWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberShortAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberIntAcceptDef((SingleMemberIntWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberIntAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberLongAcceptDef((SingleMemberLongWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberLongAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberCharAcceptDef((SingleMemberCharWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberCharAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberFloatAcceptDef((SingleMemberFloatWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberDoubleAcceptDef((SingleMemberDoubleWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberBooleanAcceptDef((SingleMemberBooleanWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberStringAcceptDef((SingleMemberStringWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberStringAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberClassAcceptDef((SingleMemberClassWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberClassAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberEnumAcceptDef((SingleMemberEnumWithDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ // single-member array types (empty array) parameter ++ static void checkSingleMemberByteArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberByteArrEmpty((SingleMemberByteArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberShortArrEmpty((SingleMemberShortArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberIntArrEmpty((SingleMemberIntArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberLongArrEmpty((SingleMemberLongArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberCharArrEmpty((SingleMemberCharArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberFloatArrEmpty((SingleMemberFloatArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberDoubleArrEmpty((SingleMemberDoubleArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberBooleanArrEmpty((SingleMemberBooleanArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberStringArrEmpty((SingleMemberStringArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberClassArrEmpty((SingleMemberClassArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrEmptyParam(Method m) { ++ try { ++ checkSingleMemberEnumArrEmpty((SingleMemberEnumArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrEmpty" + m + ": " + t); ++ } ++ } ++ ++ // single-member array types (one-element array) on parameter ++ static void checkSingleMemberByteArrOneParam(Method m) { ++ try { ++ checkSingleMemberByteArrOne((SingleMemberByteArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrOneParam(Method m) { ++ try { ++ checkSingleMemberShortArrOne((SingleMemberShortArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrOneParam(Method m) { ++ try { ++ checkSingleMemberIntArrOne((SingleMemberIntArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrOneParam(Method m) { ++ try { ++ checkSingleMemberLongArrOne((SingleMemberLongArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrOneParam(Method m) { ++ try { ++ checkSingleMemberCharArrOne((SingleMemberCharArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrOneParam(Method m) { ++ try { ++ checkSingleMemberFloatArrOne((SingleMemberFloatArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrOneParam(Method m) { ++ try { ++ checkSingleMemberDoubleArrOne((SingleMemberDoubleArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrOneParam(Method m) { ++ try { ++ checkSingleMemberBooleanArrOne((SingleMemberBooleanArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrOneParam(Method m) { ++ try { ++ checkSingleMemberStringArrOne((SingleMemberStringArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrOneParam(Method m) { ++ try { ++ checkSingleMemberClassArrOne((SingleMemberClassArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrOne" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrOneParam(Method m) { ++ try { ++ checkSingleMemberEnumArrOne((SingleMemberEnumArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrOne" + m + ": " + t); ++ } ++ } ++ ++ // single-member array types (two-element array) on parameter ++ static void checkSingleMemberByteArrTwoParam(Method m) { ++ try { ++ checkSingleMemberByteArrTwo((SingleMemberByteArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrTwoParam(Method m) { ++ try { ++ checkSingleMemberShortArrTwo((SingleMemberShortArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrTwoParam(Method m) { ++ try { ++ checkSingleMemberIntArrTwo((SingleMemberIntArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrTwoParam(Method m) { ++ try { ++ checkSingleMemberLongArrTwo((SingleMemberLongArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrTwoParam(Method m) { ++ try { ++ checkSingleMemberCharArrTwo((SingleMemberCharArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrTwoParam(Method m) { ++ try { ++ checkSingleMemberFloatArrTwo((SingleMemberFloatArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrTwoParam(Method m) { ++ try { ++ checkSingleMemberDoubleArrTwo((SingleMemberDoubleArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrTwoParam(Method m) { ++ try { ++ checkSingleMemberBooleanArrTwo((SingleMemberBooleanArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrTwoParam(Method m) { ++ try { ++ checkSingleMemberStringArrTwo((SingleMemberStringArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrTwoParam(Method m) { ++ try { ++ checkSingleMemberClassArrTwo((SingleMemberClassArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrTwo" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrTwoParam(Method m) { ++ try { ++ checkSingleMemberEnumArrTwo((SingleMemberEnumArray) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrTwo" + m + ": " + t); ++ } ++ } ++ ++ // single-member array types with default (override)on parameter ++ static void checkSingleMemberByteArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberByteArrOvrdDef((SingleMemberByteArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberShortArrOvrdDef((SingleMemberShortArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberIntArrOvrdDef((SingleMemberIntArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberLongArrOvrdDef((SingleMemberLongArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberCharArrOvrdDef((SingleMemberCharArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberFloatArrOvrdDef((SingleMemberFloatArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberDoubleArrOvrdDef((SingleMemberDoubleArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberBooleanArrOvrdDef((SingleMemberBooleanArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberStringArrOvrdDef((SingleMemberStringArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberClassArrOvrdDef((SingleMemberClassArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrOvrdDefParam(Method m) { ++ try { ++ checkSingleMemberEnumArrOvrdDef((SingleMemberEnumArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrOvrdDef" + m + ": " + t); ++ } ++ } ++ ++ // single-member array types with default (accept)on parameter ++ static void checkSingleMemberByteArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberByteArrAcceptDef((SingleMemberByteArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberShortArrAcceptDef((SingleMemberShortArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberIntArrAcceptDef((SingleMemberIntArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberLongArrAcceptDef((SingleMemberLongArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberCharArrAcceptDef((SingleMemberCharArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberFloatArrAcceptDef((SingleMemberFloatArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberDoubleArrAcceptDef((SingleMemberDoubleArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberBooleanArrAcceptDef((SingleMemberBooleanArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberStringArrAcceptDef((SingleMemberStringArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberClassArrAcceptDef((SingleMemberClassArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrAcceptDefParam(Method m) { ++ try { ++ checkSingleMemberEnumArrAcceptDef((SingleMemberEnumArrayDef) m.getParameterAnnotations()[0][0], m); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrAcceptDef" + m + ": " + t); ++ } ++ } ++ ++ // Marker ++ static void checkMarker(AnnotatedElement e) { ++ checkMarker(e.getAnnotation(Marker.class), e); ++ } ++ static void checkMarker(Marker m, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (m == null) fail("Marker " + e); ++ } catch(Throwable t) { ++ fail("Marker " + e + ": " + t); ++ } ++ } ++ ++ // Single-member ++ ++ static void checkSingleMemberByte(AnnotatedElement e) { ++ checkSingleMemberByte(e.getAnnotation(SingleMemberByte.class), e); ++ } ++ static void checkSingleMemberByte(SingleMemberByte a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 1) fail("SingleMemberByte " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberByte " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShort(AnnotatedElement e) { ++ checkSingleMemberShort(e.getAnnotation(SingleMemberShort.class), e); ++ } ++ static void checkSingleMemberShort(SingleMemberShort a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 2) fail("SingleMemberShort " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberShort " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberInt(AnnotatedElement e) { ++ checkSingleMemberInt(e.getAnnotation(SingleMemberInt.class), e); ++ } ++ static void checkSingleMemberInt(SingleMemberInt a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 3) fail("SingleMemberInt " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberInt " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLong(AnnotatedElement e) { ++ checkSingleMemberLong(e.getAnnotation(SingleMemberLong.class), e); ++ } ++ static void checkSingleMemberLong(SingleMemberLong a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 4L) fail("SingleMemberLong " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberLong " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberChar(AnnotatedElement e) { ++ checkSingleMemberChar(e.getAnnotation(SingleMemberChar.class), e); ++ } ++ static void checkSingleMemberChar(SingleMemberChar a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != '5') fail("SingleMemberChar " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberChar " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloat(AnnotatedElement e) { ++ checkSingleMemberFloat(e.getAnnotation(SingleMemberFloat.class), e); ++ } ++ static void checkSingleMemberFloat(SingleMemberFloat a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 6.0f) fail("SingleMemberFloat " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberFloat " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDouble(AnnotatedElement e) { ++ checkSingleMemberDouble(e.getAnnotation(SingleMemberDouble.class), e); ++ } ++ static void checkSingleMemberDouble(SingleMemberDouble a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 7.0) fail("SingleMemberDouble " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberDouble " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBoolean(AnnotatedElement e) { ++ checkSingleMemberBoolean(e.getAnnotation(SingleMemberBoolean.class), e); ++ } ++ static void checkSingleMemberBoolean(SingleMemberBoolean a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (!a.value()) fail("SingleMemberBoolean " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberBoolean " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberString(AnnotatedElement e) { ++ checkSingleMemberString(e.getAnnotation(SingleMemberString.class), e); ++ } ++ static void checkSingleMemberString(SingleMemberString a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (!(a.value().equals("custom"))) fail("SingleMemberString " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberString " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClass(AnnotatedElement e) { ++ checkSingleMemberClass(e.getAnnotation(SingleMemberClass.class), e); ++ } ++ static void checkSingleMemberClass(SingleMemberClass a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != Map.class) fail("SingleMemberClass " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberClass " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnum(AnnotatedElement e) { ++ checkSingleMemberEnum(e.getAnnotation(SingleMemberEnum.class), e); ++ } ++ static void checkSingleMemberEnum(SingleMemberEnum a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != Stooge.MOE) fail("SingleMemberEnum " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberEnum " + e + ": " + t); ++ } ++ } ++ ++ // Single-member with default (Override) ++ ++ static void checkSingleMemberByteOvrdDef(AnnotatedElement e) { ++ checkSingleMemberByteOvrdDef(e.getAnnotation(SingleMemberByteWithDef.class), e); ++ } ++ static void checkSingleMemberByteOvrdDef(SingleMemberByteWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 1) fail("SingleMemberByteOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberByteOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortOvrdDef(AnnotatedElement e) { ++ checkSingleMemberShortOvrdDef(e.getAnnotation(SingleMemberShortWithDef.class), e); ++ } ++ static void checkSingleMemberShortOvrdDef(SingleMemberShortWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 2) fail("SingleMemberShortOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberShortOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntOvrdDef(AnnotatedElement e) { ++ checkSingleMemberIntOvrdDef(e.getAnnotation(SingleMemberIntWithDef.class), e); ++ } ++ static void checkSingleMemberIntOvrdDef(SingleMemberIntWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 3) fail("SingleMemberIntOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberIntOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongOvrdDef(AnnotatedElement e) { ++ checkSingleMemberLongOvrdDef(e.getAnnotation(SingleMemberLongWithDef.class), e); ++ } ++ static void checkSingleMemberLongOvrdDef(SingleMemberLongWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 4L) fail("SingleMemberLongOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberLongOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharOvrdDef(AnnotatedElement e) { ++ checkSingleMemberCharOvrdDef(e.getAnnotation(SingleMemberCharWithDef.class), e); ++ } ++ static void checkSingleMemberCharOvrdDef(SingleMemberCharWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != '5') fail("SingleMemberCharOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberCharOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatOvrdDef(AnnotatedElement e) { ++ checkSingleMemberFloatOvrdDef(e.getAnnotation(SingleMemberFloatWithDef.class), e); ++ } ++ static void checkSingleMemberFloatOvrdDef(SingleMemberFloatWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 6.0f) fail("SingleMemberFloatOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleOvrdDef(AnnotatedElement e) { ++ checkSingleMemberDoubleOvrdDef(e.getAnnotation(SingleMemberDoubleWithDef.class), e); ++ } ++ static void checkSingleMemberDoubleOvrdDef(SingleMemberDoubleWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 7.0) fail("SingleMemberDoubleOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanOvrdDef(AnnotatedElement e) { ++ checkSingleMemberBooleanOvrdDef(e.getAnnotation(SingleMemberBooleanWithDef.class), e); ++ } ++ static void checkSingleMemberBooleanOvrdDef(SingleMemberBooleanWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (!a.value()) fail("SingleMemberBooleanOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringOvrdDef(AnnotatedElement e) { ++ checkSingleMemberStringOvrdDef(e.getAnnotation(SingleMemberStringWithDef.class), e); ++ } ++ static void checkSingleMemberStringOvrdDef(SingleMemberStringWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (!(a.value().equals("custom"))) fail("SingleMemberStringOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberStringOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassOvrdDef(AnnotatedElement e) { ++ checkSingleMemberClassOvrdDef(e.getAnnotation(SingleMemberClassWithDef.class), e); ++ } ++ static void checkSingleMemberClassOvrdDef(SingleMemberClassWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != Map.class) fail("SingleMemberClassOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberClassOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumOvrdDef(AnnotatedElement e) { ++ checkSingleMemberEnumOvrdDef(e.getAnnotation(SingleMemberEnumWithDef.class), e); ++ } ++ static void checkSingleMemberEnumOvrdDef(SingleMemberEnumWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != Stooge.MOE) fail("SingleMemberEnumOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ // Single-member with default (Accept) ++ ++ static void checkSingleMemberByteAcceptDef(AnnotatedElement e) { ++ checkSingleMemberByteAcceptDef(e.getAnnotation(SingleMemberByteWithDef.class), e); ++ } ++ static void checkSingleMemberByteAcceptDef(SingleMemberByteWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 11) fail("SingleMemberByteAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberByteAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortAcceptDef(AnnotatedElement e) { ++ checkSingleMemberShortAcceptDef(e.getAnnotation(SingleMemberShortWithDef.class), e); ++ } ++ static void checkSingleMemberShortAcceptDef(SingleMemberShortWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 12) fail("SingleMemberShortAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberShortAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntAcceptDef(AnnotatedElement e) { ++ checkSingleMemberIntAcceptDef(e.getAnnotation(SingleMemberIntWithDef.class), e); ++ } ++ static void checkSingleMemberIntAcceptDef(SingleMemberIntWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 13) fail("SingleMemberIntAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberIntAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongAcceptDef(AnnotatedElement e) { ++ checkSingleMemberLongAcceptDef(e.getAnnotation(SingleMemberLongWithDef.class), e); ++ } ++ static void checkSingleMemberLongAcceptDef(SingleMemberLongWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 14L) fail("SingleMemberLongAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberLongAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharAcceptDef(AnnotatedElement e) { ++ checkSingleMemberCharAcceptDef(e.getAnnotation(SingleMemberCharWithDef.class), e); ++ } ++ static void checkSingleMemberCharAcceptDef(SingleMemberCharWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 'V') fail("SingleMemberCharAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberCharAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatAcceptDef(AnnotatedElement e) { ++ checkSingleMemberFloatAcceptDef(e.getAnnotation(SingleMemberFloatWithDef.class), e); ++ } ++ static void checkSingleMemberFloatAcceptDef(SingleMemberFloatWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 16.0f) fail("SingleMemberFloatAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleAcceptDef(AnnotatedElement e) { ++ checkSingleMemberDoubleAcceptDef(e.getAnnotation(SingleMemberDoubleWithDef.class), e); ++ } ++ static void checkSingleMemberDoubleAcceptDef(SingleMemberDoubleWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != 17.0) fail("SingleMemberDoubleAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanAcceptDef(AnnotatedElement e) { ++ checkSingleMemberBooleanAcceptDef(e.getAnnotation(SingleMemberBooleanWithDef.class), e); ++ } ++ static void checkSingleMemberBooleanAcceptDef(SingleMemberBooleanWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value()) fail("SingleMemberBooleanAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringAcceptDef(AnnotatedElement e) { ++ checkSingleMemberStringAcceptDef(e.getAnnotation(SingleMemberStringWithDef.class), e); ++ } ++ static void checkSingleMemberStringAcceptDef(SingleMemberStringWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (!(a.value().equals("default"))) fail("SingleMemberStringAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberStringAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassAcceptDef(AnnotatedElement e) { ++ checkSingleMemberClassAcceptDef(e.getAnnotation(SingleMemberClassWithDef.class), e); ++ } ++ static void checkSingleMemberClassAcceptDef(SingleMemberClassWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != Class.class) fail("SingleMemberClassAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberClassAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumAcceptDef(AnnotatedElement e) { ++ checkSingleMemberEnumAcceptDef(e.getAnnotation(SingleMemberEnumWithDef.class), e); ++ } ++ static void checkSingleMemberEnumAcceptDef(SingleMemberEnumWithDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value() != Stooge.LARRY) fail("SingleMemberEnumAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ // Single member array (empty array) ++ static void checkSingleMemberByteArrEmpty(AnnotatedElement e) { ++ checkSingleMemberByteArrEmpty(e.getAnnotation(SingleMemberByteArray.class), e); ++ } ++ static void checkSingleMemberByteArrEmpty(SingleMemberByteArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberByteArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrEmpty(AnnotatedElement e) { ++ checkSingleMemberShortArrEmpty(e.getAnnotation(SingleMemberShortArray.class), e); ++ } ++ static void checkSingleMemberShortArrEmpty(SingleMemberShortArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberShortArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrEmpty(AnnotatedElement e) { ++ checkSingleMemberIntArrEmpty(e.getAnnotation(SingleMemberIntArray.class), e); ++ } ++ static void checkSingleMemberIntArrEmpty(SingleMemberIntArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberIntArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrEmpty(AnnotatedElement e) { ++ checkSingleMemberLongArrEmpty(e.getAnnotation(SingleMemberLongArray.class), e); ++ } ++ static void checkSingleMemberLongArrEmpty(SingleMemberLongArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberLongArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrEmpty(AnnotatedElement e) { ++ checkSingleMemberCharArrEmpty(e.getAnnotation(SingleMemberCharArray.class), e); ++ } ++ static void checkSingleMemberCharArrEmpty(SingleMemberCharArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberCharArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrEmpty(AnnotatedElement e) { ++ checkSingleMemberFloatArrEmpty(e.getAnnotation(SingleMemberFloatArray.class), e); ++ } ++ static void checkSingleMemberFloatArrEmpty(SingleMemberFloatArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberFloatArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrEmpty(AnnotatedElement e) { ++ checkSingleMemberDoubleArrEmpty(e.getAnnotation(SingleMemberDoubleArray.class), e); ++ } ++ static void checkSingleMemberDoubleArrEmpty(SingleMemberDoubleArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberDoubleArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrEmpty(AnnotatedElement e) { ++ checkSingleMemberBooleanArrEmpty(e.getAnnotation(SingleMemberBooleanArray.class), e); ++ } ++ static void checkSingleMemberBooleanArrEmpty(SingleMemberBooleanArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberBooleanArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrEmpty(AnnotatedElement e) { ++ checkSingleMemberStringArrEmpty(e.getAnnotation(SingleMemberStringArray.class), e); ++ } ++ static void checkSingleMemberStringArrEmpty(SingleMemberStringArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberStringArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrEmpty(AnnotatedElement e) { ++ checkSingleMemberClassArrEmpty(e.getAnnotation(SingleMemberClassArray.class), e); ++ } ++ static void checkSingleMemberClassArrEmpty(SingleMemberClassArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberClassArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrEmpty(AnnotatedElement e) { ++ checkSingleMemberEnumArrEmpty(e.getAnnotation(SingleMemberEnumArray.class), e); ++ } ++ static void checkSingleMemberEnumArrEmpty(SingleMemberEnumArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 0) fail("SingleMemberEnumArrEmpty " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrEmpty " + e + ": " + t); ++ } ++ } ++ ++ // Single member array (one element array) ++ static void checkSingleMemberByteArrOne(AnnotatedElement e) { ++ checkSingleMemberByteArrOne(e.getAnnotation(SingleMemberByteArray.class), e); ++ } ++ static void checkSingleMemberByteArrOne(SingleMemberByteArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != (byte)1) ++ fail("SingleMemberByteArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrOne(AnnotatedElement e) { ++ checkSingleMemberShortArrOne(e.getAnnotation(SingleMemberShortArray.class), e); ++ } ++ static void checkSingleMemberShortArrOne(SingleMemberShortArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != (short)2) ++ fail("SingleMemberShortArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrOne(AnnotatedElement e) { ++ checkSingleMemberIntArrOne(e.getAnnotation(SingleMemberIntArray.class), e); ++ } ++ static void checkSingleMemberIntArrOne(SingleMemberIntArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 3) ++ fail("SingleMemberIntArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrOne(AnnotatedElement e) { ++ checkSingleMemberLongArrOne(e.getAnnotation(SingleMemberLongArray.class), e); ++ } ++ static void checkSingleMemberLongArrOne(SingleMemberLongArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 4L) ++ fail("SingleMemberLongArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrOne(AnnotatedElement e) { ++ checkSingleMemberCharArrOne(e.getAnnotation(SingleMemberCharArray.class), e); ++ } ++ static void checkSingleMemberCharArrOne(SingleMemberCharArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != '5') ++ fail("SingleMemberCharArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrOne(AnnotatedElement e) { ++ checkSingleMemberFloatArrOne(e.getAnnotation(SingleMemberFloatArray.class), e); ++ } ++ static void checkSingleMemberFloatArrOne(SingleMemberFloatArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 6.0f) ++ fail("SingleMemberFloatArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrOne(AnnotatedElement e) { ++ checkSingleMemberDoubleArrOne(e.getAnnotation(SingleMemberDoubleArray.class), e); ++ } ++ static void checkSingleMemberDoubleArrOne(SingleMemberDoubleArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 7.0) ++ fail("SingleMemberDoubleArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrOne(AnnotatedElement e) { ++ checkSingleMemberBooleanArrOne(e.getAnnotation(SingleMemberBooleanArray.class), e); ++ } ++ static void checkSingleMemberBooleanArrOne(SingleMemberBooleanArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || !a.value()[0]) ++ fail("SingleMemberBooleanArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrOne(AnnotatedElement e) { ++ checkSingleMemberStringArrOne(e.getAnnotation(SingleMemberStringArray.class), e); ++ } ++ static void checkSingleMemberStringArrOne(SingleMemberStringArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || !(a.value()[0].equals("custom"))) ++ fail("SingleMemberStringArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrOne(AnnotatedElement e) { ++ checkSingleMemberClassArrOne(e.getAnnotation(SingleMemberClassArray.class), e); ++ } ++ static void checkSingleMemberClassArrOne(SingleMemberClassArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != Map.class) ++ fail("SingleMemberClassArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrOne " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrOne(AnnotatedElement e) { ++ checkSingleMemberEnumArrOne(e.getAnnotation(SingleMemberEnumArray.class), e); ++ } ++ static void checkSingleMemberEnumArrOne(SingleMemberEnumArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != Stooge.MOE) ++ fail("SingleMemberEnumArrOne " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrOne " + e + ": " + t); ++ } ++ } ++ ++ // Single member array (two element array) ++ static void checkSingleMemberByteArrTwo(AnnotatedElement e) { ++ checkSingleMemberByteArrTwo(e.getAnnotation(SingleMemberByteArray.class), e); ++ } ++ static void checkSingleMemberByteArrTwo(SingleMemberByteArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != (byte)1 || a.value()[1] != (byte)2) ++ fail("SingleMemberByteArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrTwo(AnnotatedElement e) { ++ checkSingleMemberShortArrTwo(e.getAnnotation(SingleMemberShortArray.class), e); ++ } ++ static void checkSingleMemberShortArrTwo(SingleMemberShortArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != (short)2 || a.value()[1] != (short)3) ++ fail("SingleMemberShortArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrTwo(AnnotatedElement e) { ++ checkSingleMemberIntArrTwo(e.getAnnotation(SingleMemberIntArray.class), e); ++ } ++ static void checkSingleMemberIntArrTwo(SingleMemberIntArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != 3 || a.value()[1] != 4) ++ fail("SingleMemberIntArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrTwo(AnnotatedElement e) { ++ checkSingleMemberLongArrTwo(e.getAnnotation(SingleMemberLongArray.class), e); ++ } ++ static void checkSingleMemberLongArrTwo(SingleMemberLongArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != 4L || a.value()[1] != 5L) ++ fail("SingleMemberLongArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrTwo(AnnotatedElement e) { ++ checkSingleMemberCharArrTwo(e.getAnnotation(SingleMemberCharArray.class), e); ++ } ++ static void checkSingleMemberCharArrTwo(SingleMemberCharArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != '5' || a.value()[1] != '6') ++ fail("SingleMemberCharArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrTwo(AnnotatedElement e) { ++ checkSingleMemberFloatArrTwo(e.getAnnotation(SingleMemberFloatArray.class), e); ++ } ++ static void checkSingleMemberFloatArrTwo(SingleMemberFloatArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != 6.0f || a.value()[1] != 7.0f) ++ fail("SingleMemberFloatArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrTwo(AnnotatedElement e) { ++ checkSingleMemberDoubleArrTwo(e.getAnnotation(SingleMemberDoubleArray.class), e); ++ } ++ static void checkSingleMemberDoubleArrTwo(SingleMemberDoubleArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != 7.0 || a.value()[1] != 8.0) ++ fail("SingleMemberDoubleArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrTwo(AnnotatedElement e) { ++ checkSingleMemberBooleanArrTwo(e.getAnnotation(SingleMemberBooleanArray.class), e); ++ } ++ static void checkSingleMemberBooleanArrTwo(SingleMemberBooleanArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || !a.value()[0] || a.value()[1]) ++ fail("SingleMemberBooleanArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrTwo(AnnotatedElement e) { ++ checkSingleMemberStringArrTwo(e.getAnnotation(SingleMemberStringArray.class), e); ++ } ++ static void checkSingleMemberStringArrTwo(SingleMemberStringArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || !(a.value()[0].equals("custom")) || !(a.value()[1].equals("paint"))) ++ fail("SingleMemberStringArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrTwo(AnnotatedElement e) { ++ checkSingleMemberClassArrTwo(e.getAnnotation(SingleMemberClassArray.class), e); ++ } ++ static void checkSingleMemberClassArrTwo(SingleMemberClassArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != Map.class || a.value()[1] != Set.class) ++ fail("SingleMemberClassArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrTwo " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrTwo(AnnotatedElement e) { ++ checkSingleMemberEnumArrTwo(e.getAnnotation(SingleMemberEnumArray.class), e); ++ } ++ static void checkSingleMemberEnumArrTwo(SingleMemberEnumArray a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 2 || a.value()[0] != Stooge.MOE || a.value()[1] != Stooge.CURLY) ++ fail("SingleMemberEnumArrTwo " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrTwo " + e + ": " + t); ++ } ++ } ++ ++ // Single member array with default (override) ++ static void checkSingleMemberByteArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberByteArrOvrdDef(e.getAnnotation(SingleMemberByteArrayDef.class), e); ++ } ++ static void checkSingleMemberByteArrOvrdDef(SingleMemberByteArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != (byte)1) ++ fail("SingleMemberByteArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberShortArrOvrdDef(e.getAnnotation(SingleMemberShortArrayDef.class), e); ++ } ++ static void checkSingleMemberShortArrOvrdDef(SingleMemberShortArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != (short)2) ++ fail("SingleMemberShortArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberIntArrOvrdDef(e.getAnnotation(SingleMemberIntArrayDef.class), e); ++ } ++ static void checkSingleMemberIntArrOvrdDef(SingleMemberIntArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 3) ++ fail("SingleMemberIntArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberLongArrOvrdDef(e.getAnnotation(SingleMemberLongArrayDef.class), e); ++ } ++ static void checkSingleMemberLongArrOvrdDef(SingleMemberLongArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 4L) ++ fail("SingleMemberLongArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberCharArrOvrdDef(e.getAnnotation(SingleMemberCharArrayDef.class), e); ++ } ++ static void checkSingleMemberCharArrOvrdDef(SingleMemberCharArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != '5') ++ fail("SingleMemberCharArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberFloatArrOvrdDef(e.getAnnotation(SingleMemberFloatArrayDef.class), e); ++ } ++ static void checkSingleMemberFloatArrOvrdDef(SingleMemberFloatArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 6.0f) ++ fail("SingleMemberFloatArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberDoubleArrOvrdDef(e.getAnnotation(SingleMemberDoubleArrayDef.class), e); ++ } ++ static void checkSingleMemberDoubleArrOvrdDef(SingleMemberDoubleArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 7.0) ++ fail("SingleMemberDoubleArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberBooleanArrOvrdDef(e.getAnnotation(SingleMemberBooleanArrayDef.class), e); ++ } ++ static void checkSingleMemberBooleanArrOvrdDef(SingleMemberBooleanArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || !a.value()[0]) ++ fail("SingleMemberBooleanArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberStringArrOvrdDef(e.getAnnotation(SingleMemberStringArrayDef.class), e); ++ } ++ static void checkSingleMemberStringArrOvrdDef(SingleMemberStringArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || !(a.value()[0].equals("custom"))) ++ fail("SingleMemberStringArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberClassArrOvrdDef(e.getAnnotation(SingleMemberClassArrayDef.class), e); ++ } ++ static void checkSingleMemberClassArrOvrdDef(SingleMemberClassArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != Map.class) ++ fail("SingleMemberClassArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrOvrdDef(AnnotatedElement e) { ++ checkSingleMemberEnumArrOvrdDef(e.getAnnotation(SingleMemberEnumArrayDef.class), e); ++ } ++ static void checkSingleMemberEnumArrOvrdDef(SingleMemberEnumArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != Stooge.MOE) ++ fail("SingleMemberEnumArrOvrdDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrOvrdDef " + e + ": " + t); ++ } ++ } ++ ++ // Single member array with default (accept) ++ static void checkSingleMemberByteArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberByteArrAcceptDef(e.getAnnotation(SingleMemberByteArrayDef.class), e); ++ } ++ static void checkSingleMemberByteArrAcceptDef(SingleMemberByteArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != (byte)11) ++ fail("SingleMemberByteArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberByteArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberShortArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberShortArrAcceptDef(e.getAnnotation(SingleMemberShortArrayDef.class), e); ++ } ++ static void checkSingleMemberShortArrAcceptDef(SingleMemberShortArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != (short)12) ++ fail("SingleMemberShortArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberShortArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberIntArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberIntArrAcceptDef(e.getAnnotation(SingleMemberIntArrayDef.class), e); ++ } ++ static void checkSingleMemberIntArrAcceptDef(SingleMemberIntArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 13) ++ fail("SingleMemberIntArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberIntArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberLongArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberLongArrAcceptDef(e.getAnnotation(SingleMemberLongArrayDef.class), e); ++ } ++ static void checkSingleMemberLongArrAcceptDef(SingleMemberLongArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 14L) ++ fail("SingleMemberLongArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberLongArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberCharArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberCharArrAcceptDef(e.getAnnotation(SingleMemberCharArrayDef.class), e); ++ } ++ static void checkSingleMemberCharArrAcceptDef(SingleMemberCharArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 'V') ++ fail("SingleMemberCharArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberCharArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberFloatArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberFloatArrAcceptDef(e.getAnnotation(SingleMemberFloatArrayDef.class), e); ++ } ++ static void checkSingleMemberFloatArrAcceptDef(SingleMemberFloatArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 16.0f) ++ fail("SingleMemberFloatArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberFloatArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberDoubleArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberDoubleArrAcceptDef(e.getAnnotation(SingleMemberDoubleArrayDef.class), e); ++ } ++ static void checkSingleMemberDoubleArrAcceptDef(SingleMemberDoubleArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != 17.0) ++ fail("SingleMemberDoubleArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberDoubleArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberBooleanArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberBooleanArrAcceptDef(e.getAnnotation(SingleMemberBooleanArrayDef.class), e); ++ } ++ static void checkSingleMemberBooleanArrAcceptDef(SingleMemberBooleanArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0]) ++ fail("SingleMemberBooleanArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberBooleanArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberStringArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberStringArrAcceptDef(e.getAnnotation(SingleMemberStringArrayDef.class), e); ++ } ++ static void checkSingleMemberStringArrAcceptDef(SingleMemberStringArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || !(a.value()[0].equals("default"))) ++ fail("SingleMemberStringArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberStringArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberClassArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberClassArrAcceptDef(e.getAnnotation(SingleMemberClassArrayDef.class), e); ++ } ++ static void checkSingleMemberClassArrAcceptDef(SingleMemberClassArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != Class.class) ++ fail("SingleMemberClassArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberClassArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ static void checkSingleMemberEnumArrAcceptDef(AnnotatedElement e) { ++ checkSingleMemberEnumArrAcceptDef(e.getAnnotation(SingleMemberEnumArrayDef.class), e); ++ } ++ static void checkSingleMemberEnumArrAcceptDef(SingleMemberEnumArrayDef a, AnnotatedElement e) { ++ numTests++; ++ try { ++ if (a.value().length != 1 || a.value()[0] != Stooge.LARRY) ++ fail("SingleMemberEnumArrAcceptDef " + e + " = " + a.value()); ++ } catch(Throwable t) { ++ fail("SingleMemberEnumArrAcceptDef " + e + ": " + t); ++ } ++ } ++ ++ // Verfification methods for equals/hashCode/serialization ++ ++ static void checkEquals(AnnotatedElement e1, AnnotatedElement e2, Class annoType) { ++ numTests++; ++ T a1 = e1.getAnnotation(annoType); ++ T a2 = e2.getAnnotation(annoType); ++ try { ++ if (!a1.equals(a2)) ++ fail(a1 + " != " + a2); ++ if (a1.hashCode() != a2.hashCode()) ++ fail(a1 + ".hashCode() [" + a1.hashCode() + "] != " + a2 + " .hashCode()["+ a2.hashCode()+"]"); ++ if (!(a1.toString().equals(a2.toString()))) ++ fail(a1 + ".toString() != " + a2 + ".toString()"); ++ } catch(Throwable t) { ++ fail(a1 + " == " + a2 + ": " + t); ++ } ++ } ++ ++ static void checkUnequals(AnnotatedElement e1, AnnotatedElement e2, Class annoType) { ++ numTests++; ++ T a1 = e1.getAnnotation(annoType); ++ T a2 = e2.getAnnotation(annoType); ++ try { ++ if (a1.equals(a2)) ++ fail(a1 + " == " + a2); ++ if (a1.hashCode() == a2.hashCode()) ++ fail(a1 + ".hashCode() [" + a1.hashCode() + "] == " + a2 + " .hashCode()[" + a2.hashCode() + "]"); ++ if (a1.toString().equals(a2.toString())) ++ fail(a1 + ".toString() == " + a2 + ".toString()"); ++ } catch(Throwable t) { ++ fail(a1 + " != " + a2 + ": " + t); ++ } ++ } ++ ++ // Verfification method for serialization/deserialization ++ ++ static void checkSerialization(AnnotatedElement e, Class annoType) { ++ numTests++; ++ T a1 = e.getAnnotation(annoType); ++ Object a2 = deepCopy(a1); ++ try { ++ if (!a1.equals(a2)) ++ fail("Serialization: " + a1 + " != " + a2); ++ if (a1.hashCode() != a2.hashCode()) ++ fail("Serialization: " + a1 + ".hashCode() [" + a1.hashCode() + "] != " + a2 + " .hashCode()["+a2.hashCode()+"]"); ++ if (!(a1.toString().equals(a2.toString()))) ++ fail("Serialization: " + a1 + ".toString() != " + a2 + ".toString()"); ++ } catch(Throwable t) { ++ fail("Serialization: " + a1 + " == " + a2 + ": " + t); ++ } ++ } ++ ++ private static Object deepCopy(Object original) { ++ try { ++ ByteArrayOutputStream bos = new ByteArrayOutputStream(); ++ ObjectOutputStream oos = new ObjectOutputStream(bos); ++ oos.writeObject(original); ++ oos.flush(); ++ ByteArrayInputStream bin = new ByteArrayInputStream( ++ bos.toByteArray()); ++ ObjectInputStream ois = new ObjectInputStream(bin); ++ return ois.readObject(); ++ } catch(Exception e) { ++ throw new IllegalArgumentException(e); ++ } ++ } ++ ++ // Verification method for inheritance test ++ static void checkInheritence(AnnotatedElement e, boolean shouldHaveFoo, boolean shouldHaveBar) { ++ numTests++; ++ try { ++ boolean hasFoo = e.isAnnotationPresent(Foo.class); ++ boolean hasBar = e.isAnnotationPresent(Bar.class); ++ if (hasFoo != shouldHaveFoo || hasBar != shouldHaveBar) ++ fail("Inheritance(1): " + e +" - Foo: " + hasFoo + ", Bar: " + hasBar); ++ ++ // Now test getAnnotations ++ hasFoo = hasBar = false; ++ Annotation[] allAnnotations = e.getAnnotations(); ++ for (Annotation a : allAnnotations) { ++ if (a instanceof Foo) ++ hasFoo = true; ++ else if (a instanceof Bar) ++ hasBar = true; ++ } ++ if (hasFoo != shouldHaveFoo ||hasBar != shouldHaveBar) ++ fail("Inheritance(2): " + e +" - Foo: " + hasFoo + ", Bar: " + hasBar); ++ } catch(Throwable t) { ++ fail("Inheritance: " + e +": " + t); ++ } ++ } ++ ++ // Verification method for declared annotations test ++ static void checkDeclaredAnnotations(AnnotatedElement e, boolean shouldHaveFoo, boolean shouldHaveBar) { ++ numTests++; ++ try { ++ boolean hasFoo = false; ++ boolean hasBar = false; ++ Annotation[] declaredAnnotations = e.getDeclaredAnnotations(); ++ for (Annotation a : declaredAnnotations) { ++ if (a instanceof Foo) ++ hasFoo = true; ++ else if (a instanceof Bar) ++ hasBar = true; ++ } ++ if (hasFoo != shouldHaveFoo ||hasBar != shouldHaveBar) ++ fail("Declared annotations: " + e +" - Foo: " + hasFoo + ", Bar: " + hasBar); ++ } catch(Throwable t) { ++ fail("Declared annotations: " + e +": " + t); ++ } ++ } ++ ++ ++ // ANNOTATED METHODS ++ ++ @ScalarTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ public void scalarTypesMethod() { } ++ ++ @ScalarTypesWithDefault ( ) ++ public void scalarTypesAcceptDefaultMethod() { } ++ ++ @ScalarTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE ++ ) ++ public void scalarTypesOverrideDefaultMethod() { } ++ ++ @ArrayTypes ( ++ b = { }, ++ s = { }, ++ i = { }, ++ l = { }, ++ c = { }, ++ f = { }, ++ d = { }, ++ bool = { }, ++ str = { }, ++ cls = { }, ++ e = { }, ++ a = { } ++ ) ++ public void emptyArrayTypesMethod() { } ++ ++ @ArrayTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = { @Point(x = 1, y = 2) } ++ ) ++ public void singleElementArrayTypesMethod() { } ++ ++ @ArrayTypes ( ++ b = { 1, 2 }, ++ s = { 2, 3 }, ++ i = { 3, 4 }, ++ l = { 4L, 5L }, ++ c = { '5', '6' }, ++ f = { 6.0f, 7.0f }, ++ d = { 7.0, 8.0 }, ++ bool = { true, false }, ++ str = { "custom", "paint" }, ++ cls = { Map.class, Set.class }, ++ e = { Stooge.MOE, Stooge.CURLY }, ++ a = { @Point(x = 1, y = 2), @Point(x = 3, y = 4) } ++ ) ++ public void twoElementArrayTypesMethod() { } ++ ++ @ArrayTypesWithDefault ( ++ ) ++ public void arrayTypesAcceptDefaultMethod() { } ++ ++ @ArrayTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = { @Point(x = 1, y = 2) } ++ ) ++ public void arrayTypesOverrideDefaultMethod() { } ++ ++ // Marker ++ @Marker public void markerMethod() { } ++ ++ // Single-member (shorthand) ++ @SingleMemberByte(1) public void SingleMemberByte() {} ++ @SingleMemberShort(2) public void SingleMemberShort() {} ++ @SingleMemberInt(3) public void SingleMemberInt() {} ++ @SingleMemberLong(4L) public void SingleMemberLong() {} ++ @SingleMemberChar('5') public void SingleMemberChar() {} ++ @SingleMemberFloat(6.0f) public void SingleMemberFloat() {} ++ @SingleMemberDouble(7.0) public void SingleMemberDouble() {} ++ @SingleMemberBoolean(true) public void SingleMemberBoolean() {} ++ @SingleMemberString("custom") public void SingleMemberString() {} ++ @SingleMemberClass(Map.class) public void SingleMemberClass() {} ++ @SingleMemberEnum(Stooge.MOE) public void SingleMemberEnum() {} ++ ++ // Single-member with default (Override) ++ @SingleMemberByteWithDef(1) public void SingleMemberByteOvrdDef() {} ++ @SingleMemberShortWithDef(2) public void SingleMemberShortOvrdDef() {} ++ @SingleMemberIntWithDef(3) public void SingleMemberIntOvrdDef() {} ++ @SingleMemberLongWithDef(4L) public void SingleMemberLongOvrdDef() {} ++ @SingleMemberCharWithDef('5') public void SingleMemberCharOvrdDef() {} ++ @SingleMemberFloatWithDef(6.0f) public void SingleMemberFloatOvrdDef() {} ++ @SingleMemberDoubleWithDef(7.0) public void SingleMemberDoubleOvrdDef() {} ++ @SingleMemberBooleanWithDef(true) public void SingleMemberBooleanOvrdDef() {} ++ @SingleMemberStringWithDef("custom") public void SingleMemberStringOvrdDef() {} ++ @SingleMemberClassWithDef(Map.class) public void SingleMemberClassOvrdDef() {} ++ @SingleMemberEnumWithDef(Stooge.MOE) public void SingleMemberEnumOvrdDef() {} ++ ++ // Single-member with default (Accept) ++ @SingleMemberByteWithDef public void SingleMemberByteAcceptDef() {} ++ @SingleMemberShortWithDef public void SingleMemberShortAcceptDef() {} ++ @SingleMemberIntWithDef public void SingleMemberIntAcceptDef() {} ++ @SingleMemberLongWithDef public void SingleMemberLongAcceptDef() {} ++ @SingleMemberCharWithDef public void SingleMemberCharAcceptDef() {} ++ @SingleMemberFloatWithDef public void SingleMemberFloatAcceptDef() {} ++ @SingleMemberDoubleWithDef public void SingleMemberDoubleAcceptDef() {} ++ @SingleMemberBooleanWithDef public void SingleMemberBooleanAcceptDef() {} ++ @SingleMemberStringWithDef public void SingleMemberStringAcceptDef() {} ++ @SingleMemberClassWithDef public void SingleMemberClassAcceptDef() {} ++ @SingleMemberEnumWithDef public void SingleMemberEnumAcceptDef() {} ++ ++ // Single member array (empty array) ++ @SingleMemberByteArray({}) public void SingleMemberByteArrEmpty() {} ++ @SingleMemberShortArray({}) public void SingleMemberShortArrEmpty() {} ++ @SingleMemberIntArray({}) public void SingleMemberIntArrEmpty() {} ++ @SingleMemberLongArray({}) public void SingleMemberLongArrEmpty() {} ++ @SingleMemberCharArray({}) public void SingleMemberCharArrEmpty() {} ++ @SingleMemberFloatArray({}) public void SingleMemberFloatArrEmpty() {} ++ @SingleMemberDoubleArray({}) public void SingleMemberDoubleArrEmpty() {} ++ @SingleMemberBooleanArray({})public void SingleMemberBooleanArrEmpty() {} ++ @SingleMemberStringArray({}) public void SingleMemberStringArrEmpty() {} ++ @SingleMemberClassArray({}) public void SingleMemberClassArrEmpty() {} ++ @SingleMemberEnumArray({}) public void SingleMemberEnumArrEmpty() {} ++ ++ // Single member array (one-element shorthand) ++ @SingleMemberByteArray(1) public void SingleMemberByteArrOne() {} ++ @SingleMemberShortArray(2) public void SingleMemberShortArrOne() {} ++ @SingleMemberIntArray(3) public void SingleMemberIntArrOne() {} ++ @SingleMemberLongArray(4L) public void SingleMemberLongArrOne() {} ++ @SingleMemberCharArray('5') public void SingleMemberCharArrOne() {} ++ @SingleMemberFloatArray(6.0f) public void SingleMemberFloatArrOne() {} ++ @SingleMemberDoubleArray(7.0) public void SingleMemberDoubleArrOne() {} ++ @SingleMemberBooleanArray(true) public void SingleMemberBooleanArrOne() {} ++ @SingleMemberStringArray("custom") public void SingleMemberStringArrOne() {} ++ @SingleMemberClassArray(Map.class) public void SingleMemberClassArrOne() {} ++ @SingleMemberEnumArray(Stooge.MOE) public void SingleMemberEnumArrOne() {} ++ ++ // Single member array (two elements) ++ @SingleMemberByteArray({1, 2}) public void SingleMemberByteArrTwo() {} ++ @SingleMemberShortArray({2, 3}) public void SingleMemberShortArrTwo() {} ++ @SingleMemberIntArray({3, 4}) public void SingleMemberIntArrTwo() {} ++ @SingleMemberLongArray({4L, 5L}) public void SingleMemberLongArrTwo() {} ++ @SingleMemberCharArray({'5', '6'}) public void SingleMemberCharArrTwo() {} ++ @SingleMemberFloatArray({6.0f, 7.0f}) public void SingleMemberFloatArrTwo() {} ++ @SingleMemberDoubleArray({7.0, 8.0}) public void SingleMemberDoubleArrTwo() {} ++ @SingleMemberBooleanArray({true, false}) public void SingleMemberBooleanArrTwo(){} ++ @SingleMemberStringArray({"custom", "paint"}) public void SingleMemberStringArrTwo(){} ++ @SingleMemberClassArray({Map.class, Set.class}) public void SingleMemberClassArrTwo() {} ++ @SingleMemberEnumArray({Stooge.MOE, Stooge.CURLY}) public void SingleMemberEnumArrTwo() {} ++ ++ // Single member array with default (override) ++ @SingleMemberByteArrayDef(1) public void SingleMemberByteArrOvrdDef() {} ++ @SingleMemberShortArrayDef(2) public void SingleMemberShortArrOvrdDef() {} ++ @SingleMemberIntArrayDef(3) public void SingleMemberIntArrOvrdDef() {} ++ @SingleMemberLongArrayDef(4L) public void SingleMemberLongArrOvrdDef() {} ++ @SingleMemberCharArrayDef('5') public void SingleMemberCharArrOvrdDef() {} ++ @SingleMemberFloatArrayDef(6.0f) public void SingleMemberFloatArrOvrdDef() {} ++ @SingleMemberDoubleArrayDef(7.0) public void SingleMemberDoubleArrOvrdDef() {} ++ @SingleMemberBooleanArrayDef(true) public void SingleMemberBooleanArrOvrdDef(){} ++ @SingleMemberStringArrayDef("custom") public void SingleMemberStringArrOvrdDef() {} ++ @SingleMemberClassArrayDef(Map.class) public void SingleMemberClassArrOvrdDef() {} ++ @SingleMemberEnumArrayDef(Stooge.MOE) public void SingleMemberEnumArrOvrdDef() {} ++ ++ // Single member array with default - accept ++ @SingleMemberByteArrayDef public void SingleMemberByteArrAcceptDef() {} ++ @SingleMemberShortArrayDef public void SingleMemberShortArrAcceptDef() {} ++ @SingleMemberIntArrayDef public void SingleMemberIntArrAcceptDef() {} ++ @SingleMemberLongArrayDef public void SingleMemberLongArrAcceptDef() {} ++ @SingleMemberCharArrayDef public void SingleMemberCharArrAcceptDef() {} ++ @SingleMemberFloatArrayDef public void SingleMemberFloatArrAcceptDef() {} ++ @SingleMemberDoubleArrayDef public void SingleMemberDoubleArrAcceptDef() {} ++ @SingleMemberBooleanArrayDef public void SingleMemberBooleanArrAcceptDef() {} ++ @SingleMemberStringArrayDef public void SingleMemberStringArrAcceptDef() {} ++ @SingleMemberClassArrayDef public void SingleMemberClassArrAcceptDef() {} ++ @SingleMemberEnumArrayDef public void SingleMemberEnumArrAcceptDef() {} ++ ++ // ANNOTATED FIELDS ++ @ScalarTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ public int scalarTypesField; ++ ++ @ScalarTypesWithDefault ( ) ++ public int scalarTypesAcceptDefaultField; ++ ++ @ScalarTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE ++ ) ++ public int scalarTypesOverrideDefaultField; ++ ++ @ArrayTypes ( ++ b = { }, ++ s = { }, ++ i = { }, ++ l = { }, ++ c = { }, ++ f = { }, ++ d = { }, ++ bool = { }, ++ str = { }, ++ cls = { }, ++ e = { }, ++ a = { } ++ ) ++ public int emptyArrayTypesField; ++ ++ @ArrayTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = { @Point(x = 1, y = 2) } ++ ) ++ public int singleElementArrayTypesField; ++ ++ @ArrayTypes ( ++ b = { 1, 2 }, ++ s = { 2, 3 }, ++ i = { 3, 4 }, ++ l = { 4L, 5L }, ++ c = { '5', '6' }, ++ f = { 6.0f, 7.0f }, ++ d = { 7.0, 8.0 }, ++ bool = { true, false }, ++ str = { "custom", "paint" }, ++ cls = { Map.class, Set.class }, ++ e = { Stooge.MOE, Stooge.CURLY }, ++ a = { @Point(x = 1, y = 2), @Point(x = 3, y = 4) } ++ ) ++ public int twoElementArrayTypesField; ++ ++ @ArrayTypesWithDefault ( ) ++ public int arrayTypesAcceptDefaultField; ++ ++ @ArrayTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = { @Point(x = 1, y = 2) } ++ ) ++ public int arrayTypesOverrideDefaultField; ++ ++ @Marker public int markerField; ++ ++ // Single-member (shorthand) ++ @SingleMemberByte(1) public int SingleMemberByteField; ++ @SingleMemberShort(2) public int SingleMemberShortField; ++ @SingleMemberInt(3) public int SingleMemberIntField; ++ @SingleMemberLong(4L) public int SingleMemberLongField; ++ @SingleMemberChar('5') public int SingleMemberCharField; ++ @SingleMemberFloat(6.0f) public int SingleMemberFloatField; ++ @SingleMemberDouble(7.0) public int SingleMemberDoubleField; ++ @SingleMemberBoolean(true) public int SingleMemberBooleanField; ++ @SingleMemberString("custom") public int SingleMemberStringField; ++ @SingleMemberClass(Map.class) public int SingleMemberClassField; ++ @SingleMemberEnum(Stooge.MOE) public int SingleMemberEnumField; ++ ++ // Single-member with default (Override) ++ @SingleMemberByteWithDef(1) public int SingleMemberByteOvrdDefField; ++ @SingleMemberShortWithDef(2) public int SingleMemberShortOvrdDefField; ++ @SingleMemberIntWithDef(3) public int SingleMemberIntOvrdDefField; ++ @SingleMemberLongWithDef(4L) public int SingleMemberLongOvrdDefField; ++ @SingleMemberCharWithDef('5') public int SingleMemberCharOvrdDefField; ++ @SingleMemberFloatWithDef(6.0f) public int SingleMemberFloatOvrdDefField; ++ @SingleMemberDoubleWithDef(7.0) public int SingleMemberDoubleOvrdDefField; ++ @SingleMemberBooleanWithDef(true) public int SingleMemberBooleanOvrdDefField; ++ @SingleMemberStringWithDef("custom") public int SingleMemberStringOvrdDefField; ++ @SingleMemberClassWithDef(Map.class) public int SingleMemberClassOvrdDefField; ++ @SingleMemberEnumWithDef(Stooge.MOE) public int SingleMemberEnumOvrdDefField; ++ ++ // Single-member with default (Accept) ++ @SingleMemberByteWithDef public int SingleMemberByteAcceptDefField; ++ @SingleMemberShortWithDef public int SingleMemberShortAcceptDefField; ++ @SingleMemberIntWithDef public int SingleMemberIntAcceptDefField; ++ @SingleMemberLongWithDef public int SingleMemberLongAcceptDefField; ++ @SingleMemberCharWithDef public int SingleMemberCharAcceptDefField; ++ @SingleMemberFloatWithDef public int SingleMemberFloatAcceptDefField; ++ @SingleMemberDoubleWithDef public int SingleMemberDoubleAcceptDefField; ++ @SingleMemberBooleanWithDef public int SingleMemberBooleanAcceptDefField; ++ @SingleMemberStringWithDef public int SingleMemberStringAcceptDefField; ++ @SingleMemberClassWithDef public int SingleMemberClassAcceptDefField; ++ @SingleMemberEnumWithDef public int SingleMemberEnumAcceptDefField; ++ ++ // Single member array (empty array) ++ @SingleMemberByteArray({}) public int SingleMemberByteArrEmptyField; ++ @SingleMemberShortArray({}) public int SingleMemberShortArrEmptyField; ++ @SingleMemberIntArray({}) public int SingleMemberIntArrEmptyField; ++ @SingleMemberLongArray({}) public int SingleMemberLongArrEmptyField; ++ @SingleMemberCharArray({}) public int SingleMemberCharArrEmptyField; ++ @SingleMemberFloatArray({}) public int SingleMemberFloatArrEmptyField; ++ @SingleMemberDoubleArray({}) public int SingleMemberDoubleArrEmptyField; ++ @SingleMemberBooleanArray({})public int SingleMemberBooleanArrEmptyField; ++ @SingleMemberStringArray({}) public int SingleMemberStringArrEmptyField; ++ @SingleMemberClassArray({}) public int SingleMemberClassArrEmptyField; ++ @SingleMemberEnumArray({}) public int SingleMemberEnumArrEmptyField; ++ ++ // Single member array (one-element shorthand) ++ @SingleMemberByteArray(1) public int SingleMemberByteArrOneField; ++ @SingleMemberShortArray(2) public int SingleMemberShortArrOneField; ++ @SingleMemberIntArray(3) public int SingleMemberIntArrOneField; ++ @SingleMemberLongArray(4L) public int SingleMemberLongArrOneField; ++ @SingleMemberCharArray('5') public int SingleMemberCharArrOneField; ++ @SingleMemberFloatArray(6.0f) public int SingleMemberFloatArrOneField; ++ @SingleMemberDoubleArray(7.0) public int SingleMemberDoubleArrOneField; ++ @SingleMemberBooleanArray(true) public int SingleMemberBooleanArrOneField; ++ @SingleMemberStringArray("custom") public int SingleMemberStringArrOneField; ++ @SingleMemberClassArray(Map.class) public int SingleMemberClassArrOneField; ++ @SingleMemberEnumArray(Stooge.MOE) public int SingleMemberEnumArrOneField; ++ ++ // Single member array (two elements) ++ @SingleMemberByteArray({1, 2}) public int SingleMemberByteArrTwoField; ++ @SingleMemberShortArray({2, 3}) public int SingleMemberShortArrTwoField; ++ @SingleMemberIntArray({3, 4}) public int SingleMemberIntArrTwoField; ++ @SingleMemberLongArray({4L, 5L}) public int SingleMemberLongArrTwoField; ++ @SingleMemberCharArray({'5', '6'}) public int SingleMemberCharArrTwoField; ++ @SingleMemberFloatArray({6.0f, 7.0f}) public int SingleMemberFloatArrTwoField; ++ @SingleMemberDoubleArray({7.0, 8.0}) public int SingleMemberDoubleArrTwoField; ++ @SingleMemberBooleanArray({true,false}) public int SingleMemberBooleanArrTwoField; ++ @SingleMemberStringArray({"custom", "paint"}) public int SingleMemberStringArrTwoField; ++ @SingleMemberClassArray({Map.class, Set.class}) public int SingleMemberClassArrTwoField; ++ @SingleMemberEnumArray({Stooge.MOE, Stooge.CURLY}) public int SingleMemberEnumArrTwoField; ++ ++ // Single member array with default (override) ++ @SingleMemberByteArrayDef(1) public int SingleMemberByteArrOvrdDefField; ++ @SingleMemberShortArrayDef(2) public int SingleMemberShortArrOvrdDefField; ++ @SingleMemberIntArrayDef(3) public int SingleMemberIntArrOvrdDefField; ++ @SingleMemberLongArrayDef(4L) public int SingleMemberLongArrOvrdDefField; ++ @SingleMemberCharArrayDef('5') public int SingleMemberCharArrOvrdDefField; ++ @SingleMemberFloatArrayDef(6.0f) public int SingleMemberFloatArrOvrdDefField; ++ @SingleMemberDoubleArrayDef(7.0) public int SingleMemberDoubleArrOvrdDefField; ++ @SingleMemberBooleanArrayDef(true) public int SingleMemberBooleanArrOvrdDefField; ++ @SingleMemberStringArrayDef("custom") public int SingleMemberStringArrOvrdDefField; ++ @SingleMemberClassArrayDef(Map.class) public int SingleMemberClassArrOvrdDefField; ++ @SingleMemberEnumArrayDef(Stooge.MOE) public int SingleMemberEnumArrOvrdDefField; ++ ++ // Single member array with default - accept ++ @SingleMemberByteArrayDef public int SingleMemberByteArrAcceptDefField; ++ @SingleMemberShortArrayDef public int SingleMemberShortArrAcceptDefField; ++ @SingleMemberIntArrayDef public int SingleMemberIntArrAcceptDefField; ++ @SingleMemberLongArrayDef public int SingleMemberLongArrAcceptDefField; ++ @SingleMemberCharArrayDef public int SingleMemberCharArrAcceptDefField; ++ @SingleMemberFloatArrayDef public int SingleMemberFloatArrAcceptDefField; ++ @SingleMemberDoubleArrayDef public int SingleMemberDoubleArrAcceptDefField; ++ @SingleMemberBooleanArrayDef public int SingleMemberBooleanArrAcceptDefField; ++ @SingleMemberStringArrayDef public int SingleMemberStringArrAcceptDefField; ++ @SingleMemberClassArrayDef public int SingleMemberClassArrAcceptDefField; ++ @SingleMemberEnumArrayDef public int SingleMemberEnumArrAcceptDefField; ++ ++ // ANNOTATED ENUM CONSTANTS ++ enum TestType { ++ @ScalarTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ scalarTypesField, ++ ++ @ScalarTypesWithDefault ( ) ++ scalarTypesAcceptDefaultField, ++ ++ @ScalarTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE ++ ) ++ scalarTypesOverrideDefaultField, ++ ++ @ArrayTypes ( ++ b = { }, ++ s = { }, ++ i = { }, ++ l = { }, ++ c = { }, ++ f = { }, ++ d = { }, ++ bool = { }, ++ str = { }, ++ cls = { }, ++ e = { }, ++ a = { } ++ ) ++ emptyArrayTypesField, ++ ++ @ArrayTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ singleElementArrayTypesField, ++ ++ @ArrayTypes ( ++ b = { 1, 2 }, ++ s = { 2, 3 }, ++ i = { 3, 4 }, ++ l = { 4L, 5L }, ++ c = { '5', '6' }, ++ f = { 6.0f, 7.0f }, ++ d = { 7.0, 8.0 }, ++ bool = { true, false }, ++ str = { "custom", "paint" }, ++ cls = { Map.class, Set.class }, ++ e = { Stooge.MOE, Stooge.CURLY }, ++ a = { @Point(x = 1, y = 2), @Point(x = 3, y = 4) } ++ ) ++ twoElementArrayTypesField, ++ ++ @ArrayTypesWithDefault ( ) ++ arrayTypesAcceptDefaultField, ++ ++ @ArrayTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = { @Point(x = 1, y = 2) } ++ ) ++ arrayTypesOverrideDefaultField, ++ ++ // marker ++ @Marker marker, ++ ++ // Single-member (shorthand) ++ @SingleMemberByte(1) SingleMemberByte, ++ @SingleMemberShort(2) SingleMemberShort, ++ @SingleMemberInt(3) SingleMemberInt, ++ @SingleMemberLong(4L) SingleMemberLong, ++ @SingleMemberChar('5') SingleMemberChar, ++ @SingleMemberFloat(6.0f) SingleMemberFloat, ++ @SingleMemberDouble(7.0) SingleMemberDouble, ++ @SingleMemberBoolean(true) SingleMemberBoolean, ++ @SingleMemberString("custom") SingleMemberString, ++ @SingleMemberClass(Map.class) SingleMemberClass, ++ @SingleMemberEnum(Stooge.MOE) SingleMemberEnum, ++ ++ // Single-member with default (Override) ++ @SingleMemberByteWithDef(1) SingleMemberByteOvrdDef, ++ @SingleMemberShortWithDef(2) SingleMemberShortOvrdDef, ++ @SingleMemberIntWithDef(3) SingleMemberIntOvrdDef, ++ @SingleMemberLongWithDef(4L) SingleMemberLongOvrdDef, ++ @SingleMemberCharWithDef('5') SingleMemberCharOvrdDef, ++ @SingleMemberFloatWithDef(6.0f) SingleMemberFloatOvrdDef, ++ @SingleMemberDoubleWithDef(7.0) SingleMemberDoubleOvrdDef, ++ @SingleMemberBooleanWithDef(true) SingleMemberBooleanOvrdDef, ++ @SingleMemberStringWithDef("custom") SingleMemberStringOvrdDef, ++ @SingleMemberClassWithDef(Map.class) SingleMemberClassOvrdDef, ++ @SingleMemberEnumWithDef(Stooge.MOE) SingleMemberEnumOvrdDef, ++ ++ // Single-member with default (Accept) ++ @SingleMemberByteWithDef SingleMemberByteAcceptDef, ++ @SingleMemberShortWithDef SingleMemberShortAcceptDef, ++ @SingleMemberIntWithDef SingleMemberIntAcceptDef, ++ @SingleMemberLongWithDef SingleMemberLongAcceptDef, ++ @SingleMemberCharWithDef SingleMemberCharAcceptDef, ++ @SingleMemberFloatWithDef SingleMemberFloatAcceptDef, ++ @SingleMemberDoubleWithDef SingleMemberDoubleAcceptDef, ++ @SingleMemberBooleanWithDef SingleMemberBooleanAcceptDef, ++ @SingleMemberStringWithDef SingleMemberStringAcceptDef, ++ @SingleMemberClassWithDef SingleMemberClassAcceptDef, ++ @SingleMemberEnumWithDef SingleMemberEnumAcceptDef, ++ ++ // Single member array (empty array) ++ @SingleMemberByteArray({}) SingleMemberByteArrEmpty, ++ @SingleMemberShortArray({}) SingleMemberShortArrEmpty, ++ @SingleMemberIntArray({}) SingleMemberIntArrEmpty, ++ @SingleMemberLongArray({}) SingleMemberLongArrEmpty, ++ @SingleMemberCharArray({}) SingleMemberCharArrEmpty, ++ @SingleMemberFloatArray({}) SingleMemberFloatArrEmpty, ++ @SingleMemberDoubleArray({}) SingleMemberDoubleArrEmpty, ++ @SingleMemberBooleanArray({})SingleMemberBooleanArrEmpty, ++ @SingleMemberStringArray({}) SingleMemberStringArrEmpty, ++ @SingleMemberClassArray({}) SingleMemberClassArrEmpty, ++ @SingleMemberEnumArray({}) SingleMemberEnumArrEmpty, ++ ++ // Single member array (one-element shorthand) ++ @SingleMemberByteArray(1) SingleMemberByteArrOne, ++ @SingleMemberShortArray(2) SingleMemberShortArrOne, ++ @SingleMemberIntArray(3) SingleMemberIntArrOne, ++ @SingleMemberLongArray(4L) SingleMemberLongArrOne, ++ @SingleMemberCharArray('5') SingleMemberCharArrOne, ++ @SingleMemberFloatArray(6.0f) SingleMemberFloatArrOne, ++ @SingleMemberDoubleArray(7.0) SingleMemberDoubleArrOne, ++ @SingleMemberBooleanArray(true) SingleMemberBooleanArrOne, ++ @SingleMemberStringArray("custom") SingleMemberStringArrOne, ++ @SingleMemberClassArray(Map.class) SingleMemberClassArrOne, ++ @SingleMemberEnumArray(Stooge.MOE) SingleMemberEnumArrOne, ++ ++ // Single member array (two elements) ++ @SingleMemberByteArray({1, 2}) SingleMemberByteArrTwo, ++ @SingleMemberShortArray({2, 3}) SingleMemberShortArrTwo, ++ @SingleMemberIntArray({3, 4}) SingleMemberIntArrTwo, ++ @SingleMemberLongArray({4L, 5L}) SingleMemberLongArrTwo, ++ @SingleMemberCharArray({'5', '6'}) SingleMemberCharArrTwo, ++ @SingleMemberFloatArray({6.0f, 7.0f}) SingleMemberFloatArrTwo, ++ @SingleMemberDoubleArray({7.0, 8.0}) SingleMemberDoubleArrTwo, ++ @SingleMemberBooleanArray({true,false}) SingleMemberBooleanArrTwo, ++ @SingleMemberStringArray({"custom", "paint"}) SingleMemberStringArrTwo, ++ @SingleMemberClassArray({Map.class, Set.class}) SingleMemberClassArrTwo, ++ @SingleMemberEnumArray({Stooge.MOE, Stooge.CURLY}) SingleMemberEnumArrTwo, ++ ++ // Single member array with default (override) ++ @SingleMemberByteArrayDef(1) SingleMemberByteArrOvrdDef, ++ @SingleMemberShortArrayDef(2) SingleMemberShortArrOvrdDef, ++ @SingleMemberIntArrayDef(3) SingleMemberIntArrOvrdDef, ++ @SingleMemberLongArrayDef(4L) SingleMemberLongArrOvrdDef, ++ @SingleMemberCharArrayDef('5') SingleMemberCharArrOvrdDef, ++ @SingleMemberFloatArrayDef(6.0f) SingleMemberFloatArrOvrdDef, ++ @SingleMemberDoubleArrayDef(7.0) SingleMemberDoubleArrOvrdDef, ++ @SingleMemberBooleanArrayDef(true) SingleMemberBooleanArrOvrdDef, ++ @SingleMemberStringArrayDef("custom") SingleMemberStringArrOvrdDef, ++ @SingleMemberClassArrayDef(Map.class) SingleMemberClassArrOvrdDef, ++ @SingleMemberEnumArrayDef(Stooge.MOE) SingleMemberEnumArrOvrdDef, ++ ++ // Single member array with default - accept ++ @SingleMemberByteArrayDef SingleMemberByteArrAcceptDef, ++ @SingleMemberShortArrayDef SingleMemberShortArrAcceptDef, ++ @SingleMemberIntArrayDef SingleMemberIntArrAcceptDef, ++ @SingleMemberLongArrayDef SingleMemberLongArrAcceptDef, ++ @SingleMemberCharArrayDef SingleMemberCharArrAcceptDef, ++ @SingleMemberFloatArrayDef SingleMemberFloatArrAcceptDef, ++ @SingleMemberDoubleArrayDef SingleMemberDoubleArrAcceptDef, ++ @SingleMemberBooleanArrayDef SingleMemberBooleanArrAcceptDef, ++ @SingleMemberStringArrayDef SingleMemberStringArrAcceptDef, ++ @SingleMemberClassArrayDef SingleMemberClassArrAcceptDef, ++ @SingleMemberEnumArrayDef SingleMemberEnumArrAcceptDef, ++ } ++ ++ // ANNOTATED CONSTRUCTORS ++ ++ @ScalarTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ public UnitTest(Iterator it) { } // scalar types ++ ++ @ScalarTypesWithDefault ( ) ++ public UnitTest(Set s) { } // scalarTypesAcceptDefault ++ ++ @ScalarTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE ++ ) ++ public UnitTest(Map s) { } // scalarTypesOverrideDefault ++ ++ @ArrayTypes ( ++ b = { }, ++ s = { }, ++ i = { }, ++ l = { }, ++ c = { }, ++ f = { }, ++ d = { }, ++ bool = { }, ++ str = { }, ++ cls = { }, ++ e = { }, ++ a = { } ++ ) ++ public UnitTest(List l){ } // emptyArrayTypes ++ ++ @ArrayTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ public UnitTest(Collection c) { } // singleElementArrayTypes ++ ++ @ArrayTypes ( ++ b = { 1, 2 }, ++ s = { 2, 3 }, ++ i = { 3, 4 }, ++ l = { 4L, 5L }, ++ c = { '5', '6' }, ++ f = { 6.0f, 7.0f }, ++ d = { 7.0, 8.0 }, ++ bool = { true, false }, ++ str = { "custom", "paint" }, ++ cls = { Map.class, Set.class }, ++ e = { Stooge.MOE, Stooge.CURLY }, ++ a = { @Point(x = 1, y = 2), @Point(x = 3, y = 4) } ++ ) ++ public UnitTest(SortedSet ss) { } // twoElementArrayTypes ++ ++ @ArrayTypesWithDefault ( ) ++ public UnitTest(SortedMap sm) { } // arrayTypesAcceptDefault ++ ++ @ArrayTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = { @Point(x = 1, y = 2) } ++ ) ++ public UnitTest(RandomAccess r) { } // arrayTypesOverrideDefault ++ ++ // Marker ++ @Marker public UnitTest() { } // marker ++ ++ // Single-member (shorthand) ++ @SingleMemberByte(1) public UnitTest(byte b) { } ++ @SingleMemberShort(2) public UnitTest(short s) { } ++ @SingleMemberInt(3) public UnitTest(int i) { } ++ @SingleMemberLong(4L) public UnitTest(long l) { } ++ @SingleMemberChar('5') public UnitTest(char c) { } ++ @SingleMemberFloat(6.0f) public UnitTest(float f) { } ++ @SingleMemberDouble(7.0) public UnitTest(double d) { } ++ @SingleMemberBoolean(true) public UnitTest(boolean b) { } ++ @SingleMemberString("custom") public UnitTest(String s) { } ++ @SingleMemberClass(Map.class) public UnitTest(Class c) { } ++ @SingleMemberEnum(Stooge.MOE) public UnitTest(Enum e) { } ++ ++ // Single-member with default (Override) ++ @SingleMemberByteWithDef(1) public UnitTest(byte b, Set s) { } ++ @SingleMemberShortWithDef(2) public UnitTest(short s, Set x) { } ++ @SingleMemberIntWithDef(3) public UnitTest(int i, Set s) { } ++ @SingleMemberLongWithDef(4L) public UnitTest(long l, Set s) { } ++ @SingleMemberCharWithDef('5') public UnitTest(char c, Set s) { } ++ @SingleMemberFloatWithDef(6.0f) public UnitTest(float f, Set s) { } ++ @SingleMemberDoubleWithDef(7.0) public UnitTest(double d, Set s) { } ++ @SingleMemberBooleanWithDef(true) public UnitTest(boolean b, Set s) { } ++ @SingleMemberStringWithDef("custom") public UnitTest(String s, Set x) { } ++ @SingleMemberClassWithDef(Map.class) public UnitTest(Class c, Set s) { } ++ @SingleMemberEnumWithDef(Stooge.MOE) public UnitTest(Enum e, Set s) { } ++ ++ // Single-member with default (Accept) ++ @SingleMemberByteWithDef public UnitTest(byte b, Map m) { } ++ @SingleMemberShortWithDef public UnitTest(short s, Map m) { } ++ @SingleMemberIntWithDef public UnitTest(int i, Map m) { } ++ @SingleMemberLongWithDef public UnitTest(long l, Map m) { } ++ @SingleMemberCharWithDef public UnitTest(char c, Map m) { } ++ @SingleMemberFloatWithDef public UnitTest(float f, Map m) { } ++ @SingleMemberDoubleWithDef public UnitTest(double d, Map m) { } ++ @SingleMemberBooleanWithDef public UnitTest(boolean b, Map m) { } ++ @SingleMemberStringWithDef public UnitTest(String s, Map m) { } ++ @SingleMemberClassWithDef public UnitTest(Class c, Map m) { } ++ @SingleMemberEnumWithDef public UnitTest(Enum e, Map m) { } ++ ++ // Single member array (empty array) ++ @SingleMemberByteArray({}) public UnitTest(byte[] b) { } ++ @SingleMemberShortArray({}) public UnitTest(short[] s) { } ++ @SingleMemberIntArray({}) public UnitTest(int[] i) { } ++ @SingleMemberLongArray({}) public UnitTest(long[] l) { } ++ @SingleMemberCharArray({}) public UnitTest(char[] c) { } ++ @SingleMemberFloatArray({}) public UnitTest(float[] f) { } ++ @SingleMemberDoubleArray({}) public UnitTest(double[] d) { } ++ @SingleMemberBooleanArray({})public UnitTest(boolean[] b) { } ++ @SingleMemberStringArray({}) public UnitTest(String[] s) { } ++ @SingleMemberClassArray({}) public UnitTest(Class[] c) { } ++ @SingleMemberEnumArray({}) public UnitTest(Enum[] e) { } ++ ++ // Single member array (one-element shorthand) ++ @SingleMemberByteArray(1) public UnitTest(byte[] b, Set s) { } ++ @SingleMemberShortArray(2) public UnitTest(short[] s, Set x) { } ++ @SingleMemberIntArray(3) public UnitTest(int[] i, Set s) { } ++ @SingleMemberLongArray(4L) public UnitTest(long[] l, Set s) { } ++ @SingleMemberCharArray('5') public UnitTest(char[] c, Set s) { } ++ @SingleMemberFloatArray(6.0f) public UnitTest(float[] f, Set s) { } ++ @SingleMemberDoubleArray(7.0) public UnitTest(double[] d, Set s) { } ++ @SingleMemberBooleanArray(true) public UnitTest(boolean[] b, Set s) { } ++ @SingleMemberStringArray("custom") public UnitTest(String[] s, Set x) { } ++ @SingleMemberClassArray(Map.class) public UnitTest(Class[] c, Set s) { } ++ @SingleMemberEnumArray(Stooge.MOE) public UnitTest(Enum[] e, Set s) { } ++ ++ // Single member array (two elements) ++ @SingleMemberByteArray({1, 2}) public UnitTest(byte[] b, Map m) { } ++ @SingleMemberShortArray({2, 3}) public UnitTest(short[] s, Map m) { } ++ @SingleMemberIntArray({3, 4}) public UnitTest(int[] i, Map m) { } ++ @SingleMemberLongArray({4L, 5L}) public UnitTest(long[] l, Map m) { } ++ @SingleMemberCharArray({'5', '6'}) public UnitTest(char[] c, Map m) { } ++ @SingleMemberFloatArray({6.0f, 7.0f}) public UnitTest(float[] f, Map m) { } ++ @SingleMemberDoubleArray({7.0, 8.0}) public UnitTest(double[] d, Map m) { } ++ @SingleMemberBooleanArray({true, false}) public UnitTest(boolean[] b, Map m) { } ++ @SingleMemberStringArray({"custom", "paint"}) public UnitTest(String[] s, Map m) { } ++ @SingleMemberClassArray({Map.class,Set.class}) public UnitTest(Class[] c, Map m) { } ++ @SingleMemberEnumArray({Stooge.MOE, Stooge.CURLY}) public UnitTest(Enum[] e, Map m) { } ++ ++ ++ // Single member array with default (override) ++ @SingleMemberByteArrayDef(1) public UnitTest(byte[] b, List l) { } ++ @SingleMemberShortArrayDef(2) public UnitTest(short[] s, List l) { } ++ @SingleMemberIntArrayDef(3) public UnitTest(int[] i, List l) { } ++ @SingleMemberLongArrayDef(4L) public UnitTest(long[] l, List x) { } ++ @SingleMemberCharArrayDef('5') public UnitTest(char[] c, List l) { } ++ @SingleMemberFloatArrayDef(6.0f) public UnitTest(float[] f, List l) { } ++ @SingleMemberDoubleArrayDef(7.0) public UnitTest(double[] d, List l) { } ++ @SingleMemberBooleanArrayDef(true) public UnitTest(boolean[] b, List l) { } ++ @SingleMemberStringArrayDef("custom") public UnitTest(String[] s, List l) { } ++ @SingleMemberClassArrayDef(Map.class) public UnitTest(Class[] c, List l) { } ++ @SingleMemberEnumArrayDef(Stooge.MOE) public UnitTest(Enum[] e, List l) { } ++ ++ // Single member array with default - accept ++ @SingleMemberByteArrayDef public UnitTest(byte[] b, Collection c) { } ++ @SingleMemberShortArrayDef public UnitTest(short[] s, Collection c) { } ++ @SingleMemberIntArrayDef public UnitTest(int[] i, Collection c) { } ++ @SingleMemberLongArrayDef public UnitTest(long[] l, Collection c) { } ++ @SingleMemberCharArrayDef public UnitTest(char[] c, Collection x) { } ++ @SingleMemberFloatArrayDef public UnitTest(float[] f, Collection c) { } ++ @SingleMemberDoubleArrayDef public UnitTest(double[] d, Collection c) { } ++ @SingleMemberBooleanArrayDef public UnitTest(boolean[] b, Collection c) { } ++ @SingleMemberStringArrayDef public UnitTest(String[] s, Collection c) { } ++ @SingleMemberClassArrayDef public UnitTest(Class[] c, Collection x) { } ++ @SingleMemberEnumArrayDef public UnitTest(Enum[] e, Collection c) { } ++ ++ // ANNOTATED PARAMETERS ++ ++ public void scalarTypesParam( ++ @ScalarTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ int x) { } ++ ++ ++ public void scalarTypesAcceptDefaultParam( ++ @ScalarTypesWithDefault int x) { } ++ ++ public void scalarTypesOverrideDefaultParam( ++ @ScalarTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE ++ ) ++ int x) { } ++ ++ public void emptyArrayTypesParam( ++ @ArrayTypes ( ++ b = { }, ++ s = { }, ++ i = { }, ++ l = { }, ++ c = { }, ++ f = { }, ++ d = { }, ++ bool = { }, ++ str = { }, ++ cls = { }, ++ e = { }, ++ a = { } ++ ) ++ int x) { } ++ ++ public void singleElementArrayTypesParam( ++ @ArrayTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ int x) { } ++ ++ public void twoElementArrayTypesParam( ++ @ArrayTypes ( ++ b = { 1, 2 }, ++ s = { 2, 3 }, ++ i = { 3, 4 }, ++ l = { 4L, 5L }, ++ c = { '5', '6' }, ++ f = { 6.0f, 7.0f }, ++ d = { 7.0, 8.0 }, ++ bool = { true, false }, ++ str = { "custom", "paint" }, ++ cls = { Map.class, Set.class }, ++ e = { Stooge.MOE, Stooge.CURLY }, ++ a = { @Point(x = 1, y = 2), @Point(x = 3, y = 4) } ++ ) ++ int x) { } ++ ++ public void arrayTypesAcceptDefaultParam( ++ @ArrayTypesWithDefault ++ int x) { } ++ ++ public void arrayTypesOverrideDefaultParam( ++ @ArrayTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = { @Point(x = 1, y = 2) } ++ ) ++ int x) { } ++ ++ // Marker ++ public void markerParam(@Marker int x) { } ++ ++ // Single-member (shorthand) ++ public void SingleMemberByteParam(@SingleMemberByte(1) int x) {} ++ public void SingleMemberShortParam(@SingleMemberShort(2) int x) {} ++ public void SingleMemberIntParam(@SingleMemberInt(3) int x) {} ++ public void SingleMemberLongParam(@SingleMemberLong(4L) int x) {} ++ public void SingleMemberCharParam(@SingleMemberChar('5') int x) {} ++ public void SingleMemberFloatParam(@SingleMemberFloat(6.0f) int x) {} ++ public void SingleMemberDoubleParam(@SingleMemberDouble(7.0) int x) {} ++ public void SingleMemberBooleanParam(@SingleMemberBoolean(true) int x) {} ++ public void SingleMemberStringParam(@SingleMemberString("custom") int x) {} ++ public void SingleMemberClassParam(@SingleMemberClass(Map.class) int x) {} ++ public void SingleMemberEnumParam(@SingleMemberEnum(Stooge.MOE) int x) {} ++ ++ // Single-member with default (Override) ++ public void SingleMemberByteOvrdDefParam(@SingleMemberByteWithDef(1) int x) {} ++ public void SingleMemberShortOvrdDefParam(@SingleMemberShortWithDef(2) int x) {} ++ public void SingleMemberIntOvrdDefParam(@SingleMemberIntWithDef(3) int x) {} ++ public void SingleMemberLongOvrdDefParam(@SingleMemberLongWithDef(4L) int x) {} ++ public void SingleMemberCharOvrdDefParam(@SingleMemberCharWithDef('5') int x) {} ++ public void SingleMemberFloatOvrdDefParam(@SingleMemberFloatWithDef(6.0f) int x) {} ++ public void SingleMemberDoubleOvrdDefParam(@SingleMemberDoubleWithDef(7.0) int x) {} ++ public void SingleMemberBooleanOvrdDefParam(@SingleMemberBooleanWithDef(true) int x) {} ++ public void SingleMemberStringOvrdDefParam(@SingleMemberStringWithDef("custom") int x) {} ++ public void SingleMemberClassOvrdDefParam(@SingleMemberClassWithDef(Map.class) int x) {} ++ public void SingleMemberEnumOvrdDefParam(@SingleMemberEnumWithDef(Stooge.MOE) int x) {} ++ ++ // Single-member with default (Accept) ++ public void SingleMemberByteAcceptDefParam(@SingleMemberByteWithDef int x) {} ++ public void SingleMemberShortAcceptDefParam(@SingleMemberShortWithDef int x) {} ++ public void SingleMemberIntAcceptDefParam(@SingleMemberIntWithDef int x) {} ++ public void SingleMemberLongAcceptDefParam(@SingleMemberLongWithDef int x) {} ++ public void SingleMemberCharAcceptDefParam(@SingleMemberCharWithDef int x) {} ++ public void SingleMemberFloatAcceptDefParam(@SingleMemberFloatWithDef int x) {} ++ public void SingleMemberDoubleAcceptDefParam(@SingleMemberDoubleWithDef int x) {} ++ public void SingleMemberBooleanAcceptDefParam(@SingleMemberBooleanWithDef int x){} ++ public void SingleMemberStringAcceptDefParam(@SingleMemberStringWithDef int x) {} ++ public void SingleMemberClassAcceptDefParam(@SingleMemberClassWithDef int x) {} ++ public void SingleMemberEnumAcceptDefParam(@SingleMemberEnumWithDef int x) {} ++ ++ // Single member array (empty array) ++ public void SingleMemberByteArrEmptyParam(@SingleMemberByteArray({}) int x) {} ++ public void SingleMemberShortArrEmptyParam(@SingleMemberShortArray({}) int x) {} ++ public void SingleMemberIntArrEmptyParam(@SingleMemberIntArray({}) int x) {} ++ public void SingleMemberLongArrEmptyParam(@SingleMemberLongArray({}) int x) {} ++ public void SingleMemberCharArrEmptyParam(@SingleMemberCharArray({}) int x) {} ++ public void SingleMemberFloatArrEmptyParam(@SingleMemberFloatArray({}) int x) {} ++ public void SingleMemberDoubleArrEmptyParam(@SingleMemberDoubleArray({}) int x) {} ++ public void SingleMemberBooleanArrEmptyParam(@SingleMemberBooleanArray({}) int x) {} ++ public void SingleMemberStringArrEmptyParam(@SingleMemberStringArray({}) int x) {} ++ public void SingleMemberClassArrEmptyParam(@SingleMemberClassArray({}) int x) {} ++ public void SingleMemberEnumArrEmptyParam(@SingleMemberEnumArray({}) int x) {} ++ ++ // Single member array (one-element shorthand) ++ public void SingleMemberByteArrOneParam(@SingleMemberByteArray(1) int x) {} ++ public void SingleMemberShortArrOneParam(@SingleMemberShortArray(2) int x) {} ++ public void SingleMemberIntArrOneParam(@SingleMemberIntArray(3) int x) {} ++ public void SingleMemberLongArrOneParam(@SingleMemberLongArray(4L) int x) {} ++ public void SingleMemberCharArrOneParam(@SingleMemberCharArray('5') int x) {} ++ public void SingleMemberFloatArrOneParam(@SingleMemberFloatArray(6.0f) int x) {} ++ public void SingleMemberDoubleArrOneParam(@SingleMemberDoubleArray(7.0) int x) {} ++ public void SingleMemberBooleanArrOneParam(@SingleMemberBooleanArray(true) int x) {} ++ public void SingleMemberStringArrOneParam(@SingleMemberStringArray("custom") int x) {} ++ public void SingleMemberClassArrOneParam(@SingleMemberClassArray(Map.class) int x) {} ++ public void SingleMemberEnumArrOneParam(@SingleMemberEnumArray(Stooge.MOE) int x) {} ++ ++ // Single member array (two elements) ++ public void SingleMemberByteArrTwoParam(@SingleMemberByteArray({1, 2}) int x) {} ++ public void SingleMemberShortArrTwoParam(@SingleMemberShortArray({2, 3}) int x) {} ++ public void SingleMemberIntArrTwoParam(@SingleMemberIntArray({3, 4}) int x) {} ++ public void SingleMemberLongArrTwoParam(@SingleMemberLongArray({4L, 5L}) int x) {} ++ public void SingleMemberCharArrTwoParam(@SingleMemberCharArray({'5', '6'}) int x) {} ++ public void SingleMemberFloatArrTwoParam(@SingleMemberFloatArray({6.0f, 7.0f}) int x) {} ++ public void SingleMemberDoubleArrTwoParam(@SingleMemberDoubleArray({7.0, 8.0}) int x) {} ++ public void SingleMemberBooleanArrTwoParam(@SingleMemberBooleanArray({true, false}) int x){} ++ public void SingleMemberStringArrTwoParam(@SingleMemberStringArray({"custom", "paint"}) int x) {} ++ public void SingleMemberClassArrTwoParam(@SingleMemberClassArray({Map.class, Set.class}) int x) {} ++ public void SingleMemberEnumArrTwoParam(@SingleMemberEnumArray({Stooge.MOE, Stooge.CURLY}) int x) {} ++ ++ // Single member array with default (override) ++ public void SingleMemberByteArrOvrdDefParam(@SingleMemberByteArrayDef(1) int x) {} ++ public void SingleMemberShortArrOvrdDefParam(@SingleMemberShortArrayDef(2) int x) {} ++ public void SingleMemberIntArrOvrdDefParam(@SingleMemberIntArrayDef(3) int x) {} ++ public void SingleMemberLongArrOvrdDefParam(@SingleMemberLongArrayDef(4L) int x) {} ++ public void SingleMemberCharArrOvrdDefParam(@SingleMemberCharArrayDef('5') int x) {} ++ public void SingleMemberFloatArrOvrdDefParam(@SingleMemberFloatArrayDef(6.0f) int x) {} ++ public void SingleMemberDoubleArrOvrdDefParam(@SingleMemberDoubleArrayDef(7.0) int x) {} ++ public void SingleMemberBooleanArrOvrdDefParam(@SingleMemberBooleanArrayDef(true) int x){} ++ public void SingleMemberStringArrOvrdDefParam(@SingleMemberStringArrayDef("custom") int x) {} ++ public void SingleMemberClassArrOvrdDefParam(@SingleMemberClassArrayDef(Map.class) int x) {} ++ public void SingleMemberEnumArrOvrdDefParam(@SingleMemberEnumArrayDef(Stooge.MOE) int x) {} ++ ++ // Single member array with default - accept ++ public void SingleMemberByteArrAcceptDefParam(@SingleMemberByteArrayDef int x) {} ++ public void SingleMemberShortArrAcceptDefParam(@SingleMemberShortArrayDef int x) {} ++ public void SingleMemberIntArrAcceptDefParam(@SingleMemberIntArrayDef int x) {} ++ public void SingleMemberLongArrAcceptDefParam(@SingleMemberLongArrayDef int x) {} ++ public void SingleMemberCharArrAcceptDefParam(@SingleMemberCharArrayDef int x) {} ++ public void SingleMemberFloatArrAcceptDefParam(@SingleMemberFloatArrayDef int x) {} ++ public void SingleMemberDoubleArrAcceptDefParam(@SingleMemberDoubleArrayDef int x) {} ++ public void SingleMemberBooleanArrAcceptDefParam(@SingleMemberBooleanArrayDef int x){} ++ public void SingleMemberStringArrAcceptDefParam(@SingleMemberStringArrayDef int x) {} ++ public void SingleMemberClassArrAcceptDefParam(@SingleMemberClassArrayDef int x) {} ++ public void SingleMemberEnumArrAcceptDefParam(@SingleMemberEnumArrayDef int x) {} ++} ++ ++// Helper types ++ ++enum Stooge { LARRY, MOE, CURLY } ++ ++ at Target({}) @interface Point { int x(); int y(); } ++ ++// ANNOTATION TYPES ++ ++ at Retention(RUNTIME) @interface ScalarTypes { ++ byte b(); ++ short s(); ++ int i(); ++ long l(); ++ char c(); ++ float f(); ++ double d(); ++ boolean bool(); ++ String str(); ++ Class cls(); ++ Stooge e(); ++ Point a(); ++} ++ ++ at Retention(RUNTIME) @interface ScalarTypesWithDefault { ++ byte b() default 11; ++ short s() default 12; ++ int i() default 13; ++ long l() default 14; ++ char c() default 'V'; ++ float f() default 16.0f; ++ double d() default 17.0; ++ boolean bool() default false; ++ String str() default "default"; ++ Class cls() default Class.class; ++ Stooge e() default Stooge.LARRY; ++ Point a() default @Point(x = 11, y = 12); ++} ++ ++ at Retention(RUNTIME) @interface ArrayTypes { ++ byte[] b(); ++ short[] s(); ++ int[] i(); ++ long[] l(); ++ char[] c(); ++ float[] f(); ++ double[] d(); ++ boolean[] bool(); ++ String[] str(); ++ Class[] cls(); ++ Stooge[] e(); ++ Point[] a(); ++} ++ ++ at Retention(RUNTIME) @interface ArrayTypesWithDefault { ++ byte[] b() default { 11 }; ++ short[] s() default { 12 }; ++ int[] i() default { 13 }; ++ long[] l() default { 14L }; ++ char[] c() default { 'V' }; ++ float[] f() default { 16.0f }; ++ double[] d() default { 17.0 }; ++ boolean[] bool() default { false }; ++ String[] str() default { "default" }; ++ Class[] cls() default { Class.class }; ++ Stooge[] e() default { Stooge.LARRY }; ++ Point[] a() default { @Point(x = 11, y = 12) }; ++} ++ ++ at Retention(RUNTIME) @interface Marker { } ++ ++ at Retention(RUNTIME) @interface SingleMemberByte { byte value(); } ++ at Retention(RUNTIME) @interface SingleMemberShort { short value(); } ++ at Retention(RUNTIME) @interface SingleMemberInt { int value(); } ++ at Retention(RUNTIME) @interface SingleMemberLong { long value(); } ++ at Retention(RUNTIME) @interface SingleMemberChar { char value(); } ++ at Retention(RUNTIME) @interface SingleMemberFloat { float value(); } ++ at Retention(RUNTIME) @interface SingleMemberDouble { double value(); } ++ at Retention(RUNTIME) @interface SingleMemberBoolean { boolean value(); } ++ at Retention(RUNTIME) @interface SingleMemberString { String value(); } ++ at Retention(RUNTIME) @interface SingleMemberClass { Class value(); } ++ at Retention(RUNTIME) @interface SingleMemberEnum { Stooge value(); } ++ ++ at Retention(RUNTIME) @interface SingleMemberByteWithDef { byte value() default 11; } ++ at Retention(RUNTIME) @interface SingleMemberShortWithDef { short value() default 12; } ++ at Retention(RUNTIME) @interface SingleMemberIntWithDef { int value() default 13; } ++ at Retention(RUNTIME) @interface SingleMemberLongWithDef { long value() default 14; } ++ at Retention(RUNTIME) @interface SingleMemberCharWithDef { char value() default 'V'; } ++ at Retention(RUNTIME) @interface SingleMemberFloatWithDef { float value() default 16.0f; } ++ at Retention(RUNTIME) @interface SingleMemberDoubleWithDef { double value() default 17.0; } ++ at Retention(RUNTIME) @interface SingleMemberBooleanWithDef { boolean value() default false; } ++ at Retention(RUNTIME) @interface SingleMemberStringWithDef { String value() default "default"; } ++ at Retention(RUNTIME) @interface SingleMemberClassWithDef { Class value() default Class.class; } ++ at Retention(RUNTIME) @interface SingleMemberEnumWithDef { Stooge value() default Stooge.LARRY; } ++ ++ at Retention(RUNTIME) @interface SingleMemberByteArray { byte[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberShortArray { short[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberIntArray { int[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberLongArray { long[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberCharArray { char[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberFloatArray { float[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberDoubleArray { double[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberBooleanArray { boolean[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberStringArray { String[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberClassArray { Class[] value(); } ++ at Retention(RUNTIME) @interface SingleMemberEnumArray { Stooge[] value(); } ++ ++ at Retention(RUNTIME) @interface SingleMemberByteArrayDef { byte[] value() default { 11 }; } ++ at Retention(RUNTIME) @interface SingleMemberShortArrayDef { short[] value() default { 12 }; } ++ at Retention(RUNTIME) @interface SingleMemberIntArrayDef { int[] value() default { 13 }; } ++ at Retention(RUNTIME) @interface SingleMemberLongArrayDef { long[] value() default { 14 }; } ++ at Retention(RUNTIME) @interface SingleMemberCharArrayDef { char[] value() default { 'V' }; } ++ at Retention(RUNTIME) @interface SingleMemberFloatArrayDef { float[] value() default { 16.0f };} ++ at Retention(RUNTIME) @interface SingleMemberDoubleArrayDef { double[] value() default { 17.0 }; } ++ at Retention(RUNTIME) @interface SingleMemberBooleanArrayDef { boolean[] value() default { false };} ++ at Retention(RUNTIME) @interface SingleMemberStringArrayDef { ++ String[] value() default {"default"}; ++} ++ at Retention(RUNTIME) @interface SingleMemberClassArrayDef { ++ Class[] value() default {Class.class}; ++} ++ at Retention(RUNTIME) @interface SingleMemberEnumArrayDef { ++ Stooge[] value() default {Stooge.LARRY}; ++} ++ ++// Annotation types for inheritance and declared-annotations tests ++ at Inherited @Retention(RUNTIME) @interface Foo { } ++ @Retention(RUNTIME) @interface Bar { } ++ ++ ++ // ANNOTATED CLASSES ++ ++ @ScalarTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ class scalarTypesClass { } ++ ++ @ScalarTypesWithDefault ( ) ++ class scalarTypesAcceptDefaultClass { } ++ ++ @ScalarTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE ++ ) ++ class scalarTypesOverrideDefaultClass { } ++ ++ @ArrayTypes ( ++ b = { }, ++ s = { }, ++ i = { }, ++ l = { }, ++ c = { }, ++ f = { }, ++ d = { }, ++ bool = { }, ++ str = { }, ++ cls = { }, ++ e = { }, ++ a = { } ++ ) ++ class emptyArrayTypesClass { } ++ ++ @ArrayTypes ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = @Point(x = 1, y = 2) ++ ) ++ class singleElementArrayTypesClass { } ++ ++ @ArrayTypes ( ++ b = { 1, 2 }, ++ s = { 2, 3 }, ++ i = { 3, 4 }, ++ l = { 4L, 5L }, ++ c = { '5', '6' }, ++ f = { 6.0f, 7.0f }, ++ d = { 7.0, 8.0 }, ++ bool = { true, false }, ++ str = { "custom", "paint" }, ++ cls = { Map.class, Set.class }, ++ e = { Stooge.MOE, Stooge.CURLY }, ++ a = { @Point(x = 1, y = 2), @Point(x = 3, y = 4) } ++ ) ++ class twoElementArrayTypesClass { } ++ ++ @ArrayTypesWithDefault ( ++ ) ++ class arrayTypesAcceptDefaultClass { } ++ ++ @ArrayTypesWithDefault ( ++ b = 1, ++ s = 2, ++ i = 3, ++ l = 4L, ++ c = '5', ++ f = 6.0f, ++ d = 7.0, ++ bool = true, ++ str = "custom", ++ cls = Map.class, ++ e = Stooge.MOE, ++ a = { @Point(x = 1, y = 2) } ++ ) ++ class arrayTypesOverrideDefaultClass { } ++ ++ @Marker class markerClass { } ++ ++ // Single-member (shorthand) ++ @SingleMemberByte(1) class SingleMemberByteClass { } ++ @SingleMemberShort(2) class SingleMemberShortClass { } ++ @SingleMemberInt(3) class SingleMemberIntClass { } ++ @SingleMemberLong(4L) class SingleMemberLongClass { } ++ @SingleMemberChar('5') class SingleMemberCharClass { } ++ @SingleMemberFloat(6.0f) class SingleMemberFloatClass { } ++ @SingleMemberDouble(7.0) class SingleMemberDoubleClass { } ++ @SingleMemberBoolean(true) class SingleMemberBooleanClass { } ++ @SingleMemberString("custom") class SingleMemberStringClass { } ++ @SingleMemberClass(Map.class) class SingleMemberClassClass { } ++ @SingleMemberEnum(Stooge.MOE) class SingleMemberEnumClass { } ++ ++ // Single-member with default (Override) ++ @SingleMemberByteWithDef(1) class SingleMemberByteOvrdDefClass { } ++ @SingleMemberShortWithDef(2) class SingleMemberShortOvrdDefClass { } ++ @SingleMemberIntWithDef(3) class SingleMemberIntOvrdDefClass { } ++ @SingleMemberLongWithDef(4L) class SingleMemberLongOvrdDefClass { } ++ @SingleMemberCharWithDef('5') class SingleMemberCharOvrdDefClass { } ++ @SingleMemberFloatWithDef(6.0f) class SingleMemberFloatOvrdDefClass { } ++ @SingleMemberDoubleWithDef(7.0) class SingleMemberDoubleOvrdDefClass { } ++ @SingleMemberBooleanWithDef(true) class SingleMemberBooleanOvrdDefClass { } ++ @SingleMemberStringWithDef("custom") class SingleMemberStringOvrdDefClass { } ++ @SingleMemberClassWithDef(Map.class) class SingleMemberClassOvrdDefClass { } ++ @SingleMemberEnumWithDef(Stooge.MOE) class SingleMemberEnumOvrdDefClass { } ++ ++ // Single-member with default (Accept) ++ @SingleMemberByteWithDef class SingleMemberByteAcceptDefClass { } ++ @SingleMemberShortWithDef class SingleMemberShortAcceptDefClass { } ++ @SingleMemberIntWithDef class SingleMemberIntAcceptDefClass { } ++ @SingleMemberLongWithDef class SingleMemberLongAcceptDefClass { } ++ @SingleMemberCharWithDef class SingleMemberCharAcceptDefClass { } ++ @SingleMemberFloatWithDef class SingleMemberFloatAcceptDefClass { } ++ @SingleMemberDoubleWithDef class SingleMemberDoubleAcceptDefClass { } ++ @SingleMemberBooleanWithDef class SingleMemberBooleanAcceptDefClass { } ++ @SingleMemberStringWithDef class SingleMemberStringAcceptDefClass { } ++ @SingleMemberClassWithDef class SingleMemberClassAcceptDefClass { } ++ @SingleMemberEnumWithDef class SingleMemberEnumAcceptDefClass { } ++ ++ // Single member array (empty array) ++ @SingleMemberByteArray({}) class SingleMemberByteArrEmptyClass { } ++ @SingleMemberShortArray({}) class SingleMemberShortArrEmptyClass { } ++ @SingleMemberIntArray({}) class SingleMemberIntArrEmptyClass { } ++ @SingleMemberLongArray({}) class SingleMemberLongArrEmptyClass { } ++ @SingleMemberCharArray({}) class SingleMemberCharArrEmptyClass { } ++ @SingleMemberFloatArray({}) class SingleMemberFloatArrEmptyClass { } ++ @SingleMemberDoubleArray({}) class SingleMemberDoubleArrEmptyClass { } ++ @SingleMemberBooleanArray({})class SingleMemberBooleanArrEmptyClass { } ++ @SingleMemberStringArray({}) class SingleMemberStringArrEmptyClass { } ++ @SingleMemberClassArray({}) class SingleMemberClassArrEmptyClass { } ++ @SingleMemberEnumArray({}) class SingleMemberEnumArrEmptyClass { } ++ ++ // Single member array (one-element shorthand) ++ @SingleMemberByteArray(1) class SingleMemberByteArrOneClass { } ++ @SingleMemberShortArray(2) class SingleMemberShortArrOneClass { } ++ @SingleMemberIntArray(3) class SingleMemberIntArrOneClass { } ++ @SingleMemberLongArray(4L) class SingleMemberLongArrOneClass { } ++ @SingleMemberCharArray('5') class SingleMemberCharArrOneClass { } ++ @SingleMemberFloatArray(6.0f) class SingleMemberFloatArrOneClass { } ++ @SingleMemberDoubleArray(7.0) class SingleMemberDoubleArrOneClass { } ++ @SingleMemberBooleanArray(true) class SingleMemberBooleanArrOneClass { } ++ @SingleMemberStringArray("custom") class SingleMemberStringArrOneClass { } ++ @SingleMemberClassArray(Map.class) class SingleMemberClassArrOneClass { } ++ @SingleMemberEnumArray(Stooge.MOE) class SingleMemberEnumArrOneClass { } ++ ++ // Single member array (two elements) ++ @SingleMemberByteArray({1, 2}) class SingleMemberByteArrTwoClass { } ++ @SingleMemberShortArray({2, 3}) class SingleMemberShortArrTwoClass { } ++ @SingleMemberIntArray({3, 4}) class SingleMemberIntArrTwoClass { } ++ @SingleMemberLongArray({4L, 5L}) class SingleMemberLongArrTwoClass { } ++ @SingleMemberCharArray({'5', '6'}) class SingleMemberCharArrTwoClass { } ++ @SingleMemberFloatArray({6.0f, 7.0f}) class SingleMemberFloatArrTwoClass { } ++ @SingleMemberDoubleArray({7.0, 8.0}) class SingleMemberDoubleArrTwoClass { } ++ @SingleMemberBooleanArray({true,false}) class SingleMemberBooleanArrTwoClass { } ++ @SingleMemberStringArray({"custom", "paint"}) class SingleMemberStringArrTwoClass { } ++ @SingleMemberClassArray({Map.class, Set.class}) class SingleMemberClassArrTwoClass { } ++ @SingleMemberEnumArray({Stooge.MOE, Stooge.CURLY}) class SingleMemberEnumArrTwoClass { } ++ ++ // Single member array with default (override) ++ @SingleMemberByteArrayDef(1) class SingleMemberByteArrOvrdDefClass { } ++ @SingleMemberShortArrayDef(2) class SingleMemberShortArrOvrdDefClass { } ++ @SingleMemberIntArrayDef(3) class SingleMemberIntArrOvrdDefClass { } ++ @SingleMemberLongArrayDef(4L) class SingleMemberLongArrOvrdDefClass { } ++ @SingleMemberCharArrayDef('5') class SingleMemberCharArrOvrdDefClass { } ++ @SingleMemberFloatArrayDef(6.0f) class SingleMemberFloatArrOvrdDefClass { } ++ @SingleMemberDoubleArrayDef(7.0) class SingleMemberDoubleArrOvrdDefClass { } ++ @SingleMemberBooleanArrayDef(true) class SingleMemberBooleanArrOvrdDefClass { } ++ @SingleMemberStringArrayDef("custom") class SingleMemberStringArrOvrdDefClass { } ++ @SingleMemberClassArrayDef(Map.class) class SingleMemberClassArrOvrdDefClass { } ++ @SingleMemberEnumArrayDef(Stooge.MOE) class SingleMemberEnumArrOvrdDefClass { } ++ ++ // Single member array with default - accept ++ @SingleMemberByteArrayDef class SingleMemberByteArrAcceptDefClass { } ++ @SingleMemberShortArrayDef class SingleMemberShortArrAcceptDefClass { } ++ @SingleMemberIntArrayDef class SingleMemberIntArrAcceptDefClass { } ++ @SingleMemberLongArrayDef class SingleMemberLongArrAcceptDefClass { } ++ @SingleMemberCharArrayDef class SingleMemberCharArrAcceptDefClass { } ++ @SingleMemberFloatArrayDef class SingleMemberFloatArrAcceptDefClass { } ++ @SingleMemberDoubleArrayDef class SingleMemberDoubleArrAcceptDefClass { } ++ @SingleMemberBooleanArrayDef class SingleMemberBooleanArrAcceptDefClass { } ++ @SingleMemberStringArrayDef class SingleMemberStringArrAcceptDefClass { } ++ @SingleMemberClassArrayDef class SingleMemberClassArrAcceptDefClass { } ++ @SingleMemberEnumArrayDef class SingleMemberEnumArrAcceptDefClass { } ++ ++ // Annotated classes for inheritance and declared-annotations tests ++ @Foo @Bar class Grandpa { } ++ class Dad extends Grandpa { } ++ @Bar class Son extends Dad { } diff -r 3b8dcbd3d44d patches/openjdk/bidi-tests.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/openjdk/bidi-tests.patch Wed Feb 11 02:15:37 2009 +0000 @@ -0,0 +1,295 @@ + +# HG changeset patch +# User peytoia +# Date 1224218043 -32400 +# Node ID 8ea49fa4c2f761eeb67711ba2fa5482cb3b0347c +# Parent 244f62312fec34c292e082ba3bb9c76aef30858e +6759521: Move Bidi test programs from closed to open. +Reviewed-by: okutsu + +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 ++++ openjdk/jdk/test/java/text/Bidi/BidiBug.java Fri Oct 17 13:34:03 2008 +0900 +@@ -0,0 +1,41 @@ ++/* ++ * Copyright (c) 2008 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 4827312 ++ * @summary verify that argument validity check is not fooled by overflow ++ */ ++public class BidiBug { ++ public static void main(String[] args) { ++ try { ++ byte buff[] = new byte[3000]; ++ java.text.Bidi bidi = new java.text.Bidi(new char[20],10,buff,Integer.MAX_VALUE-3,4,1); ++ } ++ catch (IllegalArgumentException e) { ++ System.out.println(e); ++ return; // success ++ } ++ throw new RuntimeException("didn't throw error, though we didn't crash either"); ++ } ++} +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 ++++ openjdk/jdk/test/java/text/Bidi/BidiEmbeddingTest.java Fri Oct 17 13:34:03 2008 +0900 +@@ -0,0 +1,132 @@ ++/* ++ * Copyright (c) 2008 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 4396492 4396496 4778510 ++ * @summary verify that the embedding values processed by the bidi code use negative values to ++ * indicate overrides, rather than using bit 7. Also tests Bidi without loading awt classes to ++ * confirm that Bidi can be used without awt. Verify that embedding level 0 is properly mapped ++ * to the base embedding level. ++ */ ++ ++import java.awt.Color; ++import java.awt.Frame; ++import java.awt.font.TextAttribute; ++import java.text.AttributedString; ++import java.text.Bidi; ++ ++public class BidiEmbeddingTest { ++ public static void main(String[] args) { ++ // to regress embedding test against old fix, call with an arg. A window will pop ++ // up causing awt lib to be loaded so the vm won't die with the unsatisfied link error. ++ if (args.length > 0) { ++ Frame f = new Frame(); ++ f.setSize(300, 300); ++ f.setBackground(Color.white); ++ f.show(); ++ } ++ ++ test1(); ++ test2(); ++ } ++ ++ static void test1() { ++ String target = "BACK WARDS"; ++ String str = "If this text is >" + target + "< the test passed."; ++ int start = str.indexOf(target); ++ int limit = start + target.length(); ++ ++ System.out.println("start: " + start + " limit: " + limit); ++ ++ AttributedString astr = new AttributedString(str); ++ astr.addAttribute(TextAttribute.BIDI_EMBEDDING, ++ new Integer(-1), ++ start, ++ limit); ++ ++ Bidi bidi = new Bidi(astr.getIterator()); ++ ++ for (int i = 0; i < bidi.getRunCount(); ++i) { ++ System.out.println("run " + i + ++ " from " + bidi.getRunStart(i) + ++ " to " + bidi.getRunLimit(i) + ++ " at level " + bidi.getRunLevel(i)); ++ } ++ ++ System.out.println(bidi); ++ ++ byte[] embs = new byte[str.length() + 3]; ++ for (int i = start + 1; i < limit + 1; ++i) { ++ embs[i] = -1; ++ } ++ ++ Bidi bidi2 = new Bidi(str.toCharArray(), 0, embs, 1, str.length(), Bidi.DIRECTION_DEFAULT_LEFT_TO_RIGHT); ++ for (int i = 0; i < bidi2.getRunCount(); ++i) { ++ System.out.println("run " + i + ++ " from " + bidi2.getRunStart(i) + ++ " to " + bidi2.getRunLimit(i) + ++ " at level " + bidi2.getRunLevel(i)); ++ } ++ ++ System.out.println(bidi2); ++ ++ if (bidi.getRunCount() != 3 || bidi2.getRunCount() != 3) { ++ throw new Error("Bidi run count incorrect"); ++ } ++ } ++ ++ // make sure BIDI_EMBEDDING values of 0 are mapped to base run direction, instead of flagging an error. ++ static void test2() { ++ String target = "BACK WARDS"; ++ String str = "If this text is >" + target + "< the test passed."; ++ int length = str.length(); ++ int start = str.indexOf(target); ++ int limit = start + target.length(); ++ ++ System.out.println("start: " + start + " limit: " + limit); ++ ++ AttributedString astr = new AttributedString(str); ++ astr.addAttribute(TextAttribute.RUN_DIRECTION, TextAttribute.RUN_DIRECTION_RTL); ++ ++ astr.addAttribute(TextAttribute.BIDI_EMBEDDING, ++ new Integer(-3), ++ start, ++ limit); ++ ++ Bidi bidi = new Bidi(astr.getIterator()); ++ ++ for (int i = 0; i < bidi.getRunCount(); ++i) { ++ System.out.println("run " + i + ++ " from " + bidi.getRunStart(i) + ++ " to " + bidi.getRunLimit(i) + ++ " at level " + bidi.getRunLevel(i)); ++ } ++ ++ System.out.println(bidi); ++ ++ if (bidi.getRunCount() != 6) { // runs of spaces and angles at embedding bound,s and final period, each get level 1 ++ throw new Error("Bidi embedding processing failed"); ++ } ++ } ++} +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 ++++ openjdk/jdk/test/java/text/Bidi/BidiSurrogateTest.java Fri Oct 17 13:34:03 2008 +0900 +@@ -0,0 +1,103 @@ ++/* ++ * Copyright (c) 2008 Sun Microsystems, Inc. All Rights Reserved. ++ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. ++ * ++ * This code is free software; you can redistribute it and/or modify it ++ * under the terms of the GNU General Public License version 2 only, as ++ * published by the Free Software Foundation. ++ * ++ * This code is distributed in the hope that it will be useful, but WITHOUT ++ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or ++ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ++ * version 2 for more details (a copy is included in the LICENSE file that ++ * accompanied this code). ++ * ++ * You should have received a copy of the GNU General Public License version ++ * 2 along with this work; if not, write to the Free Software Foundation, ++ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. ++ * ++ * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, ++ * CA 95054 USA or visit www.sun.com if you need additional information or ++ * have any questions. ++ */ ++ ++/* ++ * @test ++ * @bug 4888843 ++ * @summary verify that surrogate pairs representing codepoints with R or AL directionality ++ * and correctly recognized and reordered. ++ */ ++ ++import java.text.Bidi; ++ ++public class BidiSurrogateTest { ++ private static final String RTLS = new String(Character.toChars(0x10800)); // surrogate code point with R directionality ++ private static final String LTRS = new String(Character.toChars(0x107ff)); // surrogate code point with L directionality ++ private static final String LRE = "\u202a"; ++ private static final String RLE = "\u202b"; ++ private static final String PDF = "\u202c"; ++ ++ ++ public static void main(String[] args) { ++ new BidiSurrogateTest().test(); ++ } ++ ++ void test() { ++ test0(); ++ test1(); ++ } ++ ++ void test0() { ++ // test unpaired surrogates - should have L directionality ++ testRequiresBidi("\ud800", false); // unpaired lead surrogate ++ testRequiresBidi("\udc00", false); // unpaired trail surrogate ++ testRequiresBidi("\udc00\ud800", false); // out of order surrogates ++ testRequiresBidi("a\udc00b\ud800c", false); // out of order surrogates split ++ testRequiresBidi(LTRS, false); // supplementary with L ++ testRequiresBidi(RTLS, true); // supplementary with R ++ testRequiresBidi("a" + RTLS + "b", true); // R supplementary in LTR text ++ testRequiresBidi(LTRS + RTLS, true); // R supplementary in LTR supplementary text ++ testRequiresBidi(LRE, false); // LRE lone embedding ++ testRequiresBidi(RLE, true); // RLE lone embedding ++ testRequiresBidi(PDF, false); // PDF lone pop embedding ++ } ++ ++ void testRequiresBidi(String string, boolean requiresBidi) { ++ char[] text = string.toCharArray(); ++ if (Bidi.requiresBidi(text, 0, text.length) != requiresBidi) { ++ throw new RuntimeException("testRequiresBidi failed with '" + string + "', " + requiresBidi); ++ } ++ } ++ ++ void test1() { ++ // test that strings with surrogate runs process surrogate directionality ok ++ testBidi("This is a string with " + LTRS + " in it.", false); ++ testBidi("This is a string with \ud800 in it.", false); ++ testBidi("This is a string with \u0640 in it.", 22, 1); ++ testBidi(RTLS, true); ++ testBidi("This is a string with " + RTLS + RTLS + RTLS + " in it.", 22, 6); ++ } ++ ++ void testBidi(String string, boolean directionIsRTL) { ++ Bidi bidi = new Bidi(string, Bidi.DIRECTION_DEFAULT_LEFT_TO_RIGHT); ++ if (bidi.isMixed()) { ++ throw new RuntimeException("bidi is mixed"); ++ } ++ if (bidi.isRightToLeft() != directionIsRTL) { ++ throw new RuntimeException("bidi is not " + (directionIsRTL ? "rtl" : "ltr")); ++ } ++ } ++ ++ void testBidi(String string, int rtlstart, int rtllength) { ++ Bidi bidi = new Bidi(string, Bidi.DIRECTION_DEFAULT_LEFT_TO_RIGHT); ++ for (int i = 0; i < bidi.getRunCount(); ++i) { ++ if ((bidi.getRunLevel(i) & 1) != 0) { ++ if (bidi.getRunStart(i) != rtlstart || ++ bidi.getRunLimit(i) != rtlstart + rtllength) { ++ throw new RuntimeException("first rtl run didn't match " + rtlstart + ", " + rtllength); ++ } ++ break; ++ } ++ } ++ } ++} + From glewis at eyesbeyond.com Tue Feb 10 21:13:45 2009 From: glewis at eyesbeyond.com (Greg Lewis) Date: Tue, 10 Feb 2009 21:13:45 -0800 Subject: BSD Port and Linux Differences In-Reply-To: <20090210160035.DCC5D5654E@rebar.astron.com> References: <20090210160035.DCC5D5654E@rebar.astron.com> Message-ID: <20090211051345.GA56272@misty.eyesbeyond.com> On Tue, Feb 10, 2009 at 11:00:35AM -0500, Christos Zoulas wrote: > On Feb 9, 7:56pm, mvfranz at gmail.com (Michael Franz) wrote: > -- Subject: BSD Port and Linux Differences > > | Hi, > | > | I am still working through the issues to get the bsd-port repo to compile on > | Linux and have run into these issues. > | > | BSD is using statfs instead of statvfs. Both are available on Linux and OS > | X. The difference is how they are included. Linux uses either sys/statfs.h > | or sys/statfs.h while OS X (and I assume other BSDs) are use > | sys/param.h,sys/mount.h or sys/statvfs.h. See > | jdk/src/solaris/native/java/io/UnixFileSystem_md.c for more details. > > NetBSD uses statvfs too. > > | Is it better to use one over the other? Do we really want to use statfs on > | bsd and statvfs on linux? > > statvfs should be preferred over statfs because: > 1. it is part of POSIX: > http://www.opengroup.org/onlinepubs/009695399/functions/statvfs.html > 2. it is newer and has 64 bit fields where appropriate (in most implementations) > > I think we need some #ifdef's there to handle which include is appropriate > for which OS. It looks like everything supports statvfs now, so I don't think we need any #ifdef's at all. I've got a patch to revert this change. > | I have run into a similar issue with strncpy vs strlcpy. The bsd port is > | using strlcpy, as far as I can tell, strlcpy does not exist on linux. Both > | have strncpy, should this be used instead? > | > | This issue exists in jdk/src/solaris/native/java/util/TimeZone_md.c > > strl{cpy,cat} should be preferred over strn{cpy,cat}. If that is the only > use though, I say put it back to use strncpy() correctly, since java probably > uses strn{cpy,cat} all over the place and providing portability just for > one use is overkill. *sigh* It looks like the GNU libc maintainers don't like strlcpy, so although *BSD and Solaris have it, Linux does not. I'll change it to strncpy universally rather than adding an #ifdef just for that. > | A previous difference that I have found was in the use of machine/endian.h > | in the BSD port. > > This is a more complicated :-) and I will let someone else answer it. I've already answered this before :). Its the right thing to do. We just need to also do the right thing for Linux and Solaris. I've got access to an Ubuntu box -- I can try a compile there as well. -- Greg Lewis Email : glewis at eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis at FreeBSD.org From aph at redhat.com Wed Feb 11 00:59:52 2009 From: aph at redhat.com (Andrew Haley) Date: Wed, 11 Feb 2009 08:59:52 +0000 Subject: RFC: Only enable NIO2 by default when building with IcedTea In-Reply-To: <20090210190726.GA13625@rivendell.middle-earth.co.uk> References: <20090210190726.GA13625@rivendell.middle-earth.co.uk> Message-ID: <49929388.1030002@redhat.com> Andrew John Hughes wrote: > It appears that some older versions of ecj fail when building the > NIO2 code: > > 1. ERROR in ../../../src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java (at line 276) > public final WatchKey register(WatchService watcher, WatchEvent.Kind... events) > throws IOException > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > Name clash: The method register(WatchService, WatchEvent.Kind...) of type AbstractPath has the same erasure as register(WatchService, WatchEvent.Kind...) of type Watchable but does not override it > ---------- > > It looks like this bug: > > https://bugs.eclipse.org/bugs/show_bug.cgi?id=243820 > > The attached patch sets the NIO2 default based on whether with_icedtea is enabled. So this works, > and to be consistent with the rest of the autotools macro, it switches the values used from true/false > to yes/no. > > Okay to commit? Would it not make more sense to: 1. require a newer version of ecj in our build documentation and 2. tell people that if they have an old ecj they'll have to diable NIO2 ? Andrew. From doko at ubuntu.com Wed Feb 11 04:00:44 2009 From: doko at ubuntu.com (Matthias Klose) Date: Wed, 11 Feb 2009 13:00:44 +0100 Subject: RFC: Only enable NIO2 by default when building with IcedTea In-Reply-To: <49929388.1030002@redhat.com> References: <20090210190726.GA13625@rivendell.middle-earth.co.uk> <49929388.1030002@redhat.com> Message-ID: <4992BDEC.8080301@ubuntu.com> Andrew Haley schrieb: > Andrew John Hughes wrote: >> It appears that some older versions of ecj fail when building the >> NIO2 code: >> >> 1. ERROR in ../../../src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java (at line 276) >> public final WatchKey register(WatchService watcher, WatchEvent.Kind... events) >> throws IOException >> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ >> Name clash: The method register(WatchService, WatchEvent.Kind...) of type AbstractPath has the same erasure as register(WatchService, WatchEvent.Kind...) of type Watchable but does not override it >> ---------- >> >> It looks like this bug: >> >> https://bugs.eclipse.org/bugs/show_bug.cgi?id=243820 >> >> The attached patch sets the NIO2 default based on whether with_icedtea is enabled. So this works, >> and to be consistent with the rest of the autotools macro, it switches the values used from true/false >> to yes/no. >> >> Okay to commit? > > Would it not make more sense to: > > 1. require a newer version of ecj in our build documentation > > and > > 2. tell people that if they have an old ecj they'll have to diable NIO2 documenting the requirement sounds fine. For distributing ecj I am interested in one version which can be used to build ecj1 and a vanilla ecj which is used as standalone compiler, or javac for java-gcj-compat. Last time I checked an update to the next ecj-3.3.x release didn't work well for libgcj. I'll try to check the ecj-3.4.2 release and see how/if this works when used as ecj1. Are there any patches available for ecj-3.4.2 to build it as ecj1? Matthias From aph at redhat.com Wed Feb 11 05:01:47 2009 From: aph at redhat.com (Andrew Haley) Date: Wed, 11 Feb 2009 13:01:47 +0000 Subject: RFC: Only enable NIO2 by default when building with IcedTea In-Reply-To: <4992BDEC.8080301@ubuntu.com> References: <20090210190726.GA13625@rivendell.middle-earth.co.uk> <49929388.1030002@redhat.com> <4992BDEC.8080301@ubuntu.com> Message-ID: <4992CC3B.2040708@redhat.com> Matthias Klose wrote: > Andrew Haley schrieb: >> Andrew John Hughes wrote: >>> It appears that some older versions of ecj fail when building the >>> NIO2 code: >>> >>> 1. ERROR in ../../../src/share/classes/org/classpath/icedtea/java/nio/file/spi/AbstractPath.java (at line 276) >>> public final WatchKey register(WatchService watcher, WatchEvent.Kind... events) >>> throws IOException >>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ >>> Name clash: The method register(WatchService, WatchEvent.Kind...) of type AbstractPath has the same erasure as register(WatchService, WatchEvent.Kind...) of type Watchable but does not override it >>> ---------- >>> >>> It looks like this bug: >>> >>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=243820 >>> >>> The attached patch sets the NIO2 default based on whether with_icedtea is enabled. So this works, >>> and to be consistent with the rest of the autotools macro, it switches the values used from true/false >>> to yes/no. >>> >>> Okay to commit? >> Would it not make more sense to: >> >> 1. require a newer version of ecj in our build documentation >> >> and >> >> 2. tell people that if they have an old ecj they'll have to diable NIO2 > > documenting the requirement sounds fine. > > For distributing ecj I am interested in one version which can be used to build > ecj1 and a vanilla ecj which is used as standalone compiler, or javac for > java-gcj-compat. Last time I checked an update to the next ecj-3.3.x release > didn't work well for libgcj. I'll try to check the ecj-3.4.2 release and see > how/if this works when used as ecj1. Are there any patches available for > ecj-3.4.2 to build it as ecj1? I have seen none, but I can't imagine it'd be hard. Andrew. From mark at klomp.org Wed Feb 11 05:27:45 2009 From: mark at klomp.org (Mark Wielaard) Date: Wed, 11 Feb 2009 14:27:45 +0100 Subject: RFC: Only enable NIO2 by default when building with IcedTea In-Reply-To: <4992CC3B.2040708@redhat.com> References: <20090210190726.GA13625@rivendell.middle-earth.co.uk> <49929388.1030002@redhat.com> <4992BDEC.8080301@ubuntu.com> <4992CC3B.2040708@redhat.com> Message-ID: <1234358866.2340.55.camel@fedora.wildebeest.org> Hi, On Wed, 2009-02-11 at 13:01 +0000, Andrew Haley wrote: > > For distributing ecj I am interested in one version which can be used to build > > ecj1 and a vanilla ecj which is used as standalone compiler, or javac for > > java-gcj-compat. Last time I checked an update to the next ecj-3.3.x release > > didn't work well for libgcj. I'll try to check the ecj-3.4.2 release and see > > how/if this works when used as ecj1. Are there any patches available for > > ecj-3.4.2 to build it as ecj1? > > I have seen none, but I can't imagine it'd be hard. The only thing necessary should be the GCCMain one that is being kept up to date by Tom in the rhug repository: http://sourceware.org/cgi-bin/cvsweb.cgi/eclipse-gcj/org/eclipse/jdt/internal/compiler/batch/GCCMain.java?cvsroot=rhug Latest version is r34_1, haven't yet tried if it also applies to 3.4.2. If that works out then it would be good to update the recommended version of ecj-latest.jar that the gcc/contrib/download_ecj grabs so that future versions (4.4?) of gcc will come with it. Cheers, Mark From mark at klomp.org Wed Feb 11 05:37:31 2009 From: mark at klomp.org (Mark Wielaard) Date: Wed, 11 Feb 2009 14:37:31 +0100 Subject: RFC: Only enable NIO2 by default when building with IcedTea In-Reply-To: <1234358866.2340.55.camel@fedora.wildebeest.org> References: <20090210190726.GA13625@rivendell.middle-earth.co.uk> <49929388.1030002@redhat.com> <4992BDEC.8080301@ubuntu.com> <4992CC3B.2040708@redhat.com> <1234358866.2340.55.camel@fedora.wildebeest.org> Message-ID: <1234359452.2340.61.camel@fedora.wildebeest.org> On Wed, 2009-02-11 at 14:27 +0100, Mark Wielaard wrote: > The only thing necessary should be the GCCMain one that is being kept up > to date by Tom in the rhug repository: > http://sourceware.org/cgi-bin/cvsweb.cgi/eclipse-gcj/org/eclipse/jdt/internal/compiler/batch/GCCMain.java?cvsroot=rhug > Latest version is r34_1, haven't yet tried if it also applies to 3.4.2. > > If that works out then it would be good to update the recommended > version of ecj-latest.jar that the gcc/contrib/download_ecj grabs so > that future versions (4.4?) of gcc will come with it. Alternatively, someone might want to look into the Summer Of Code work from Dalibor to integrate the openjdk javac (or actually any JSR 199 compliant byte code compiler): http://code.google.com/p/google-summer-of-code-2007-gcc/downloads/detail?name=Dalibor_Topic.tar.gz The eclipse-gcj-pretty/README.GSOC gives a nice summary of the work. Cheers, Mark From xerxes at zafena.se Wed Feb 11 05:54:49 2009 From: xerxes at zafena.se (=?ISO-8859-1?Q?Xerxes_R=E5nby?=) Date: Wed, 11 Feb 2009 14:54:49 +0100 Subject: [patches] pointers to Robert Schusters patches for Icedtea6 to make Icedtea6 cross-compilation work using OE/Jalimo and shark fixes for ARM using llvm 2.4 Message-ID: <4992D8A9.5090004@zafena.se> Cheers to you all fellow free java hackers! I had a great time at Fosdem 09, it was great fun meeting you(all) and I returned quite safely to Sweden a early thuesday morning after a rough airliner adventure, more about this will pop up on a familiar blogroll near you in the near future. Before I forget, here I have composed some pointers to all the patches Robert Schuster had pushed on the mailinglist in order to make Icedtea6 cross-compile using openembedded and Jalimo, fixes for shark and llvm. These patches needs sponsoring in one way or another: [patch] fix to make icedtea6 cross-compile using openembedded and jalimo http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2009-January/004435.html - patch for Icedtea6 http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2009-January/004428.html - start of discussion for patch inclusion [patch] fix for building shark using llvm 2.4 http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2009-January/004606.html - patch for Icedtea6 http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2009-January/004591.html - start of discussion for patch inclusion http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2009-January/004609.html - verdict Robert had also pushed some patches for llvm 2.4 on the mailinglist, do you happen to know some llvm people who might sponsor inclusion fo these patches upstreams in llvm? [patch] fix for llvm 2.4 on ARM http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2009-January/004605.html - patch for llvm 2.4 (found in shark discussion thread above) Robert please fill in if there is some patches that i have missed related to your awesome cross-compilation work. Cheers and have a great day! Xerxes From omajid at redhat.com Wed Feb 11 06:35:55 2009 From: omajid at redhat.com (Omair Majid) Date: Wed, 11 Feb 2009 14:35:55 +0000 Subject: changeset in /hg/icedtea6: 2009-02-11 Marc Schoenefeld changeset 24c29e381e49 in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=24c29e381e49 description: 2009-02-11 Marc Schoenefeld Omair Majid * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java (write): Fix bounds checking. diffstat: 2 files changed, 9 insertions(+), 12 deletions(-) ChangeLog | 6 ++++ pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java | 15 ++-------- diffs (39 lines): diff -r 5d4d8012aa03 -r 24c29e381e49 ChangeLog --- a/ChangeLog Wed Feb 11 02:18:27 2009 +0000 +++ b/ChangeLog Wed Feb 11 09:14:17 2009 -0500 @@ -1,3 +1,9 @@ 2009-02-11 Andrew John Hughes + Omair Majid + + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java + (write): Fix bounds checking. + 2009-02-11 Andrew John Hughes * Makefile.am: diff -r 5d4d8012aa03 -r 24c29e381e49 pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java --- a/pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java Wed Feb 11 02:18:27 2009 +0000 +++ b/pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java Wed Feb 11 09:14:17 2009 -0500 @@ -151,19 +151,10 @@ public final class PulseAudioSourceDataL throw new IllegalArgumentException( "amount of data to write does not represent an integral number of frames"); } - if (length < 0) { - throw new IllegalArgumentException("length is negative"); - } - - if (offset < 0) { - throw new ArrayIndexOutOfBoundsException("offset is negative: " - + offset); - } - - if (length + offset > data.length) { + if (length < 0 || offset < 0 || offset > data.length - length) { throw new ArrayIndexOutOfBoundsException( - "writing data beyond the length of the array: " - + (length + offset)); + "Overflow condition: buffer.length=" + data.length + + " offset= " + offset + " length=" + length ); } int position = offset; From omajid at redhat.com Wed Feb 11 08:50:52 2009 From: omajid at redhat.com (Omair Majid) Date: Wed, 11 Feb 2009 16:50:52 +0000 Subject: changeset in /hg/icedtea6: 2009-02-11 Omair Majid changeset 551c49cb2e2a in /hg/icedtea6 details: http://icedtea.classpath.org/hg/icedtea6?cmd=changeset;node=551c49cb2e2a description: 2009-02-11 Omair Majid * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java (write): Throw IllegalArgumentException instead of ArrayIndexOutOfBoundsException for length. * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetDataLine.java (read): Fixed bounds checking. diffstat: 3 files changed, 17 insertions(+), 4 deletions(-) ChangeLog | 8 ++++++++ pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java | 5 +++++ pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetDataLine.java | 8 ++++---- diffs (48 lines): diff -r 24c29e381e49 -r 551c49cb2e2a ChangeLog --- a/ChangeLog Wed Feb 11 09:14:17 2009 -0500 +++ b/ChangeLog Wed Feb 11 11:49:45 2009 -0500 @@ -1,3 +1,11 @@ 2009-02-11 Marc Schoenefeld + + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java + (write): Throw IllegalArgumentException instead of + ArrayIndexOutOfBoundsException for length. + * pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetDataLine.java + (read): Fixed bounds checking. + 2009-02-11 Marc Schoenefeld Omair Majid diff -r 24c29e381e49 -r 551c49cb2e2a pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java --- a/pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java Wed Feb 11 09:14:17 2009 -0500 +++ b/pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioSourceDataLine.java Wed Feb 11 11:49:45 2009 -0500 @@ -151,6 +151,11 @@ public final class PulseAudioSourceDataL throw new IllegalArgumentException( "amount of data to write does not represent an integral number of frames"); } + + if (length < 0) { + throw new IllegalArgumentException("length is negative"); + } + if (length < 0 || offset < 0 || offset > data.length - length) { throw new ArrayIndexOutOfBoundsException( "Overflow condition: buffer.length=" + data.length + diff -r 24c29e381e49 -r 551c49cb2e2a pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetDataLine.java --- a/pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetDataLine.java Wed Feb 11 09:14:17 2009 -0500 +++ b/pulseaudio/src/java/org/classpath/icedtea/pulseaudio/PulseAudioTargetDataLine.java Wed Feb 11 11:49:45 2009 -0500 @@ -156,10 +156,10 @@ public final class PulseAudioTargetDataL if (length < 0) { throw new IllegalArgumentException("length is negative"); } - - if (length + offset > data.length) { - throw new ArrayIndexOutOfBoundsException("index: " - + (length + offset) + " array size: " + data.length); + + if ( offset < 0 || offset > data.length - length) { + throw new ArrayIndexOutOfBoundsException("array size: " + data.length + + " offset:" + offset + " length:" + length ); } /* everything ok */ From langel at redhat.com Wed Feb 11 11:38:30 2009 From: langel at redhat.com (Lillian Angel) Date: Wed, 11 Feb 2009 14:38:30 -0500 Subject: mozilla.javascript still encumbered...? Message-ID: <49932936.7060300@redhat.com> Hi, I was attempting to build the yui-compressor tool[1], and I found that IcedTea/OpenJDK is missing some mozilla.javascript[2] classes still. At the moment, I don't have the time to start implementing these, but let me know if anyone does. The tool does build with JDK 1.6.0. https://bugzilla.redhat.com/show_bug.cgi?id=485135 Cheers, Lillian [1] http://www.julienlecomte.net/yuicompressor/ [2] [...yuicompressor-2.4.2]$ ant Buildfile: build.xml -load.properties: -init: [mkdir] Created dir: /home/langel/yuicompressor-2.4.2/build build.classes: [mkdir] Created dir: /home/langel/yuicompressor-2.4.2/build/classes [javac] Compiling 12 source files to /home/langel/yuicompressor-2.4.2/build/classes [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:120: cannot find symbol [javac] symbol : method isStrictMode() [javac] location: class org.mozilla.javascript.CompilerEnvirons [javac] if (compilerEnv.isStrictMode()) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:127: cannot find symbol [javac] symbol : method reportWarningAsError() [javac] location: class org.mozilla.javascript.CompilerEnvirons [javac] if (compilerEnv.reportWarningAsError()) { [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:568: cannot find symbol [javac] symbol : method isStrictMode() [javac] location: class org.mozilla.javascript.CompilerEnvirons [javac] if (compilerEnv.isStrictMode() && !body.hasConsistentReturnUsage()) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:568: cannot find symbol [javac] symbol : method hasConsistentReturnUsage() [javac] location: class org.mozilla.javascript.Node [javac] if (compilerEnv.isStrictMode() && !body.hasConsistentReturnUsage()) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:639: cannot find symbol [javac] symbol : variable PARENTHESIZED_PROP [javac] location: class org.mozilla.javascript.Node [javac] if (pn.getProp(Node.PARENTHESIZED_PROP) == null && [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:676: cannot find symbol [javac] symbol : method isStrictMode() [javac] location: class org.mozilla.javascript.CompilerEnvirons [javac] if (compilerEnv.isStrictMode() && !pn.hasSideEffects()) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:676: cannot find symbol [javac] symbol : method hasSideEffects() [javac] location: class org.mozilla.javascript.Node [javac] if (compilerEnv.isStrictMode() && !pn.hasSideEffects()) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1107: cannot find symbol [javac] symbol : variable END_RETURNS_VALUE [javac] location: class org.mozilla.javascript.Node [javac] if (functionEndFlags == Node.END_RETURNS_VALUE) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1110: cannot find symbol [javac] symbol : variable END_RETURNS [javac] location: class org.mozilla.javascript.Node [javac] functionEndFlags |= Node.END_RETURNS; [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1112: cannot find symbol [javac] symbol : variable END_RETURNS [javac] location: class org.mozilla.javascript.Node [javac] if (functionEndFlags == Node.END_RETURNS) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1115: cannot find symbol [javac] symbol : variable END_RETURNS_VALUE [javac] location: class org.mozilla.javascript.Node [javac] functionEndFlags |= Node.END_RETURNS_VALUE; [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1269: createVariables(int) in org.mozilla.javascript.IRFactory cannot be applied to (int,int) [javac] pn = nf.createVariables(Token.CONST, ts.getLineno()); [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1272: createVariables(int) in org.mozilla.javascript.IRFactory cannot be applied to (int,int) [javac] pn = nf.createVariables(Token.VAR, ts.getLineno()); [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1289: cannot find symbol [javac] symbol : method addConst(java.lang.String) [javac] location: class org.mozilla.javascript.ScriptOrFnNode [javac] if (!currentScriptOrFn.addConst(s)) { [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1293: 'void' type not allowed here [javac] if (currentScriptOrFn.addVar(s) != ScriptOrFnNode.DUPLICATE_CONST) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1293: cannot find symbol [javac] symbol : variable DUPLICATE_CONST [javac] location: class org.mozilla.javascript.ScriptOrFnNode [javac] if (currentScriptOrFn.addVar(s) != ScriptOrFnNode.DUPLICATE_CONST) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1299: incompatible types [javac] found : void [javac] required: int [javac] int dupState = currentScriptOrFn.addVar(s); [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1300: cannot find symbol [javac] symbol : variable DUPLICATE_CONST [javac] location: class org.mozilla.javascript.ScriptOrFnNode [javac] if (dupState == ScriptOrFnNode.DUPLICATE_CONST) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1302: cannot find symbol [javac] symbol : variable DUPLICATE_PARAMETER [javac] location: class org.mozilla.javascript.ScriptOrFnNode [javac] else if (dupState == ScriptOrFnNode.DUPLICATE_PARAMETER) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1304: cannot find symbol [javac] symbol : variable DUPLICATE_VAR [javac] location: class org.mozilla.javascript.ScriptOrFnNode [javac] else if (dupState == ScriptOrFnNode.DUPLICATE_VAR) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1330: cannot find symbol [javac] symbol : method isStrictMode() [javac] location: class org.mozilla.javascript.CompilerEnvirons [javac] if (compilerEnv.isStrictMode() && !pn.hasSideEffects()) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1330: cannot find symbol [javac] symbol : method hasSideEffects() [javac] location: class org.mozilla.javascript.Node [javac] if (compilerEnv.isStrictMode() && !pn.hasSideEffects()) [javac] ^ [javac] /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:2065: cannot find symbol [javac] symbol : variable PARENTHESIZED_PROP [javac] location: class org.mozilla.javascript.Node [javac] pn.putProp(Node.PARENTHESIZED_PROP, Boolean.TRUE); [javac] ^ [javac] 23 errors BUILD FAILED /home/langel/yuicompressor-2.4.2/build.xml:23: Compile failed; see the compiler error output for details. Total time: 2 seconds From dbhole at redhat.com Wed Feb 11 11:57:24 2009 From: dbhole at redhat.com (Deepak Bhole) Date: Wed, 11 Feb 2009 14:57:24 -0500 Subject: mozilla.javascript still encumbered...? In-Reply-To: <49932936.7060300@redhat.com> References: <49932936.7060300@redhat.com> Message-ID: <20090211195724.GA30628@redhat.com> * Lillian Angel [2009-02-11 14:39]: > Hi, > > I was attempting to build the yui-compressor tool[1], and I found that > IcedTea/OpenJDK is missing some mozilla.javascript[2] classes still. At the > moment, I don't have the time to start implementing these, but let me know > if anyone does. > > The tool does build with JDK 1.6.0. > > https://bugzilla.redhat.com/show_bug.cgi?id=485135 > > Cheers, > Lillian > > Looks like we need to upgrade rhino. 1.7R1 appears to have the new stuff. Just did a quick search for a couple of things: $ grep -rE "isStrictMode|reportWarningAsError|DUPLICATE_CONST" rhino1_7R1/src/ | awk '{print $1}' | sort -u rhino1_7R1/src/org/mozilla/javascript/CompilerEnvirons.java: rhino1_7R1/src/org/mozilla/javascript/Parser.java: Deepak > [1] > http://www.julienlecomte.net/yuicompressor/ > > [2] > [...yuicompressor-2.4.2]$ ant > Buildfile: build.xml > > -load.properties: > > -init: > [mkdir] Created dir: /home/langel/yuicompressor-2.4.2/build > > build.classes: > [mkdir] Created dir: /home/langel/yuicompressor-2.4.2/build/classes > [javac] Compiling 12 source files to > /home/langel/yuicompressor-2.4.2/build/classes > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:120: > cannot find symbol > [javac] symbol : method isStrictMode() > [javac] location: class org.mozilla.javascript.CompilerEnvirons > [javac] if (compilerEnv.isStrictMode()) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:127: > cannot find symbol > [javac] symbol : method reportWarningAsError() > [javac] location: class org.mozilla.javascript.CompilerEnvirons > [javac] if (compilerEnv.reportWarningAsError()) { > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:568: > cannot find symbol > [javac] symbol : method isStrictMode() > [javac] location: class org.mozilla.javascript.CompilerEnvirons > [javac] if (compilerEnv.isStrictMode() && > !body.hasConsistentReturnUsage()) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:568: > cannot find symbol > [javac] symbol : method hasConsistentReturnUsage() > [javac] location: class org.mozilla.javascript.Node > [javac] if (compilerEnv.isStrictMode() && > !body.hasConsistentReturnUsage()) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:639: > cannot find symbol > [javac] symbol : variable PARENTHESIZED_PROP > [javac] location: class org.mozilla.javascript.Node > [javac] if (pn.getProp(Node.PARENTHESIZED_PROP) == null && > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:676: > cannot find symbol > [javac] symbol : method isStrictMode() > [javac] location: class org.mozilla.javascript.CompilerEnvirons > [javac] if (compilerEnv.isStrictMode() && > !pn.hasSideEffects()) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:676: > cannot find symbol > [javac] symbol : method hasSideEffects() > [javac] location: class org.mozilla.javascript.Node > [javac] if (compilerEnv.isStrictMode() && > !pn.hasSideEffects()) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1107: > cannot find symbol > [javac] symbol : variable END_RETURNS_VALUE > [javac] location: class org.mozilla.javascript.Node > [javac] if (functionEndFlags == Node.END_RETURNS_VALUE) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1110: > cannot find symbol > [javac] symbol : variable END_RETURNS > [javac] location: class org.mozilla.javascript.Node > [javac] functionEndFlags |= Node.END_RETURNS; > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1112: > cannot find symbol > [javac] symbol : variable END_RETURNS > [javac] location: class org.mozilla.javascript.Node > [javac] if (functionEndFlags == Node.END_RETURNS) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1115: > cannot find symbol > [javac] symbol : variable END_RETURNS_VALUE > [javac] location: class org.mozilla.javascript.Node > [javac] functionEndFlags |= Node.END_RETURNS_VALUE; > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1269: > createVariables(int) in org.mozilla.javascript.IRFactory cannot be applied > to (int,int) > [javac] pn = nf.createVariables(Token.CONST, > ts.getLineno()); > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1272: > createVariables(int) in org.mozilla.javascript.IRFactory cannot be applied > to (int,int) > [javac] pn = nf.createVariables(Token.VAR, ts.getLineno()); > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1289: > cannot find symbol > [javac] symbol : method addConst(java.lang.String) > [javac] location: class org.mozilla.javascript.ScriptOrFnNode > [javac] if (!currentScriptOrFn.addConst(s)) { > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1293: > 'void' type not allowed here > [javac] if (currentScriptOrFn.addVar(s) != > ScriptOrFnNode.DUPLICATE_CONST) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1293: > cannot find symbol > [javac] symbol : variable DUPLICATE_CONST > [javac] location: class org.mozilla.javascript.ScriptOrFnNode > [javac] if (currentScriptOrFn.addVar(s) != > ScriptOrFnNode.DUPLICATE_CONST) > [javac] > ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1299: > incompatible types > [javac] found : void > [javac] required: int > [javac] int dupState = currentScriptOrFn.addVar(s); > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1300: > cannot find symbol > [javac] symbol : variable DUPLICATE_CONST > [javac] location: class org.mozilla.javascript.ScriptOrFnNode > [javac] if (dupState == ScriptOrFnNode.DUPLICATE_CONST) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1302: > cannot find symbol > [javac] symbol : variable DUPLICATE_PARAMETER > [javac] location: class org.mozilla.javascript.ScriptOrFnNode > [javac] else if (dupState == > ScriptOrFnNode.DUPLICATE_PARAMETER) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1304: > cannot find symbol > [javac] symbol : variable DUPLICATE_VAR > [javac] location: class org.mozilla.javascript.ScriptOrFnNode > [javac] else if (dupState == > ScriptOrFnNode.DUPLICATE_VAR) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1330: > cannot find symbol > [javac] symbol : method isStrictMode() > [javac] location: class org.mozilla.javascript.CompilerEnvirons > [javac] if (compilerEnv.isStrictMode() && > !pn.hasSideEffects()) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:1330: > cannot find symbol > [javac] symbol : method hasSideEffects() > [javac] location: class org.mozilla.javascript.Node > [javac] if (compilerEnv.isStrictMode() && > !pn.hasSideEffects()) > [javac] ^ > [javac] > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:2065: > cannot find symbol > [javac] symbol : variable PARENTHESIZED_PROP > [javac] location: class org.mozilla.javascript.Node > [javac] pn.putProp(Node.PARENTHESIZED_PROP, Boolean.TRUE); > [javac] ^ > [javac] 23 errors > > BUILD FAILED > /home/langel/yuicompressor-2.4.2/build.xml:23: Compile failed; see the > compiler error output for details. > > Total time: 2 seconds > From dbhole at redhat.com Wed Feb 11 11:58:17 2009 From: dbhole at redhat.com (Deepak Bhole) Date: Wed, 11 Feb 2009 14:58:17 -0500 Subject: mozilla.javascript still encumbered...? In-Reply-To: <20090211195724.GA30628@redhat.com> References: <49932936.7060300@redhat.com> <20090211195724.GA30628@redhat.com> Message-ID: <20090211195817.GB30628@redhat.com> * Deepak Bhole [2009-02-11 14:57]: > * Lillian Angel [2009-02-11 14:39]: > > Hi, > > > > I was attempting to build the yui-compressor tool[1], and I found that > > IcedTea/OpenJDK is missing some mozilla.javascript[2] classes still. At the > > moment, I don't have the time to start implementing these, but let me know > > if anyone does. > > > > The tool does build with JDK 1.6.0. > > > > https://bugzilla.redhat.com/show_bug.cgi?id=485135 > > > > Cheers, > > Lillian > > > > > > Looks like we need to upgrade rhino. 1.7R1 appears to have the new > stuff. Just did a quick search for a couple of things: > s/upgrade rhino/require the new rhino > $ grep -rE "isStrictMode|reportWarningAsError|DUPLICATE_CONST" rhino1_7R1/src/ | awk '{print $1}' | sort -u > rhino1_7R1/src/org/mozilla/javascript/CompilerEnvirons.java: > rhino1_7R1/src/org/mozilla/javascript/Parser.java: > > Deepak > > > [1] > > http://www.julienlecomte.net/yuicompressor/ > > > > [2] > > [...yuicompressor-2.4.2]$ ant > > Buildfile: build.xml > > > > -load.properties: > > > > -init: > > [mkdir] Created dir: /home/langel/yuicompressor-2.4.2/build > > > > build.classes: > > [mkdir] Created dir: /home/langel/yuicompressor-2.4.2/build/classes > > [javac] Compiling 12 source files to > > /home/langel/yuicompressor-2.4.2/build/classes > > [javac] > > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:120: > > cannot find symbol > > [javac] symbol : method isStrictMode() > > [javac] location: class org.mozilla.javascript.CompilerEnvirons > > [javac] if (compilerEnv.isStrictMode()) > > [javac] ^ > > [javac] > > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:127: > > cannot find symbol > > [javac] symbol : method reportWarningAsError() > > [javac] location: class org.mozilla.javascript.CompilerEnvirons > > [javac] if (compilerEnv.reportWarningAsError()) { > > [javac] ^ > > [javac] > > /home/langel/yuicompressor-2.4.2/src/org/mozilla/javascript/Parser.java:568: > > cannot find symbol > > [javac] symbol : method isStrictMode() > > [javac] location: class org.mozilla.javascript.CompilerEnvirons > > [javac] if (compilerEn