# HG changeset patch # User duke # Date 1499290806 -7200 # Node ID ca0e16b2d5d6668ee89396f818fa6f26b548560e # Parent ea7475564d076811483eb225d853c17c7a934398# Parent 8f5dd0fb0a6d7c97a8bca51e64260af47c9b03c2 Merge diff -r ea7475564d07 -r ca0e16b2d5d6 .hgtags-top-repo --- a/.hgtags-top-repo Thu Jun 15 13:44:42 2017 +0200 +++ b/.hgtags-top-repo Wed Jul 05 23:40:06 2017 +0200 @@ -426,3 +426,5 @@ 4c12464a907db4656c1033f56fa49cba643ac629 jdk-9+171 6558c37afe832582238d338578d598f30c6fdd75 jdk-10+10 2c25fc24103251f9711a1c280c31e1e41016d90f jdk-9+172 +6b750cdb823a029a25ff2e560302cc2d28a86cb6 jdk-10+11 +88d7fd969e7df0e07a53b201cfd29393ca33ede9 jdk-9+173 diff -r ea7475564d07 -r ca0e16b2d5d6 common/conf/jib-profiles.js --- a/common/conf/jib-profiles.js Thu Jun 15 13:44:42 2017 +0200 +++ b/common/conf/jib-profiles.js Wed Jul 05 23:40:06 2017 +0200 @@ -387,7 +387,7 @@ // on such hardware. if (input.build_cpu == "sparcv9") { var cpu_brand = $EXEC("bash -c \"kstat -m cpu_info | grep brand | head -n1 | awk '{ print \$2 }'\""); - if (cpu_brand.trim().match('SPARC-.7')) { + if (cpu_brand.trim().match('SPARC-.[78]')) { boot_jdk_revision = "8u20"; boot_jdk_subdirpart = "1.8.0_20"; } diff -r ea7475564d07 -r ca0e16b2d5d6 corba/.hgtags --- a/corba/.hgtags Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/.hgtags Wed Jul 05 23:40:06 2017 +0200 @@ -426,3 +426,5 @@ c62e5964cfcf144d8f72e9ba69757897785349a9 jdk-9+171 080c37fd77e2c4629b91059298e37758afbdbc46 jdk-10+10 95ed14547ca9246baed34f90ef3ca13217538a8c jdk-9+172 +8ef8a0f1c4dfea17e10125e1f885920538e63085 jdk-10+11 +534ba4f8cfcf12accc5b9adb943103f2ff79fe16 jdk-9+173 diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/javax/rmi/PortableRemoteObject.java --- a/corba/src/java.corba/share/classes/javax/rmi/PortableRemoteObject.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/javax/rmi/PortableRemoteObject.java Wed Jul 05 23:40:06 2017 +0200 @@ -62,6 +62,8 @@ * attempts to narrow it to conform to * the given interface. If the operation is successful the result will be an * object of the specified type, otherwise an exception will be thrown. + * + *

See also {@extLink rmi_iiop_guides RMI-IIOP developer's guides}.

*/ public class PortableRemoteObject { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/ACTIVITY_COMPLETED.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/ACTIVITY_COMPLETED.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/ACTIVITY_COMPLETED.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * the Activity, or that the Activity completed in a manner other than that * originally requested. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since J2SE 1.5 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/ACTIVITY_REQUIRED.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/ACTIVITY_REQUIRED.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/ACTIVITY_REQUIRED.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. 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 @@ -31,8 +31,8 @@ * Activity context was necessary to perform the invoked operation, but one * was not found associated with the calling thread. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since J2SE 1.5 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/BAD_CONTEXT.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_CONTEXT.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_CONTEXT.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -32,8 +32,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/BAD_INV_ORDER.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_INV_ORDER.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_INV_ORDER.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -34,8 +34,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/BAD_OPERATION.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_OPERATION.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_OPERATION.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -32,8 +32,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/BAD_PARAM.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_PARAM.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_PARAM.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -37,10 +37,9 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions - * @see meaning of - * minor codes + *

See also {@extLink jidlexception documentation on Java IDL exceptions}, + * {@extLink jidlexception_minorcodes meaning of minor codes} + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/BAD_QOS.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_QOS.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_QOS.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. 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 @@ -30,8 +30,8 @@ * support the quality of service required by an invocation parameter that * has a quality of service semantics associated with it. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since J2SE 1.5 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/BAD_TYPECODE.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_TYPECODE.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/BAD_TYPECODE.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -32,8 +32,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/Bounds.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/Bounds.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/Bounds.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. 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 @@ -30,8 +30,8 @@ * the legal bounds for the object that a method is trying * to access. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class Bounds extends org.omg.CORBA.UserException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/CODESET_INCOMPATIBLE.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/CODESET_INCOMPATIBLE.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/CODESET_INCOMPATIBLE.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. 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 @@ -29,8 +29,8 @@ * This exception is raised whenever meaningful communication is not possible * between client and server native code sets. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since J2SE 1.5 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/COMM_FAILURE.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/COMM_FAILURE.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/COMM_FAILURE.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -33,11 +33,11 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section meaning - * of minor codes to see the minor codes for this exception. + * See the section {@extLink jidlexception_minorcodes Minor Code Meanings} + * to see the minor codes for this exception. * - * @see meaning of - * minor codes + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/DATA_CONVERSION.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/DATA_CONVERSION.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/DATA_CONVERSION.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -35,11 +35,11 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section meaning - * of minor codes to see the minor codes for this exception. + * See the section {@extLink jidlexception_minorcodes Minor Code Meanings} + * to see the minor codes for this exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/FREE_MEM.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/FREE_MEM.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/FREE_MEM.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/IMP_LIMIT.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/IMP_LIMIT.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/IMP_LIMIT.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -36,8 +36,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INITIALIZE.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INITIALIZE.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INITIALIZE.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -34,8 +34,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INTERNAL.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INTERNAL.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INTERNAL.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -33,11 +33,11 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section meaning - * of minor codes to see the minor codes for this exception. + * See the section {@extLink jidlexception_minorcodes meaning of minor codes} + * to see the minor codes for this exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INTF_REPOS.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INTF_REPOS.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INTF_REPOS.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -34,8 +34,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INVALID_ACTIVITY.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INVALID_ACTIVITY.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INVALID_ACTIVITY.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. 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 @@ -32,8 +32,8 @@ * suspended. It is also raised when an attempted invocation is made that * is incompatible with the Activity's current state. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since J2SE 1.5 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INVALID_TRANSACTION.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INVALID_TRANSACTION.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INVALID_TRANSACTION.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. 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 @@ -34,8 +34,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 * */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INV_FLAG.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INV_FLAG.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INV_FLAG.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INV_IDENT.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INV_IDENT.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INV_IDENT.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -34,8 +34,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INV_OBJREF.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INV_OBJREF.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INV_OBJREF.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -37,11 +37,11 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section Minor - * Code Meanings to see the minor codes for this exception. + * See the section {@extLink jidlexception_minorcodes Minor Code Meanings} + * to see the minor codes for this exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/INV_POLICY.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/INV_POLICY.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/INV_POLICY.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class INV_POLICY extends SystemException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/MARSHAL.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/MARSHAL.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/MARSHAL.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -39,8 +39,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section Minor - * Code Meanings to see the minor codes for this exception. + * See the section {@extLink jidlexception_minorcodes Minor Code Meanings} + * to see the minor codes for this exception. * * @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/NO_IMPLEMENT.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/NO_IMPLEMENT.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/NO_IMPLEMENT.java Wed Jul 05 23:40:06 2017 +0200 @@ -36,8 +36,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section Minor - * Code Meanings to see the minor codes for this exception. + * See the section {extLink jidlexception_minorcodes Minor Code Meanings} + * to see the minor codes for this exception. * * @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/NO_MEMORY.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/NO_MEMORY.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/NO_MEMORY.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -32,8 +32,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/NO_PERMISSION.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/NO_PERMISSION.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/NO_PERMISSION.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -32,8 +32,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/NO_RESOURCES.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/NO_RESOURCES.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/NO_RESOURCES.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/NO_RESPONSE.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/NO_RESPONSE.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/NO_RESPONSE.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/OBJECT_NOT_EXIST.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/OBJECT_NOT_EXIST.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/OBJECT_NOT_EXIST.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -39,11 +39,11 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section Minor - * Code Meanings to see the minor codes for this exception. + * See the section {@extLink jidlexception_minorcodes Minor Code Meanings} + * to see the minor codes for this exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/OBJ_ADAPTER.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/OBJ_ADAPTER.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/OBJ_ADAPTER.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -34,11 +34,11 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section Minor - * Code Meanings to see the minor codes for this exception. + * See the section {@extLink jidlexception_minorcodes Minor Code Meanings} + * to see the minor codes for this exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since JDK1.2 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/ORB.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/ORB.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/ORB.java Wed Jul 05 23:40:06 2017 +0200 @@ -184,6 +184,8 @@ * Therefore, the implementation first checks the ${java.home}/conf directory for orb.properties, * and thereafter the ${java.home}/lib directory. * + *

See also {@extLink idl_guides IDL developer's guide}.

+ * * @since JDK1.2 */ abstract public class ORB { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/PERSIST_STORE.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/PERSIST_STORE.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/PERSIST_STORE.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class PERSIST_STORE extends SystemException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/REBIND.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/REBIND.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/REBIND.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * This exception is also raised if the current effective RebindPolicy has * a value of NO_RECONNECT and a connection must be reopened. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since J2SE 1.5 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/SystemException.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/SystemException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/SystemException.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -44,8 +44,8 @@ * declared in signatures of the Java methods mapped from operations in * IDL interfaces. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public abstract class SystemException extends java.lang.RuntimeException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/TIMEOUT.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/TIMEOUT.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/TIMEOUT.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2017, Oracle and/or its affiliates. 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 @@ -30,8 +30,8 @@ * specified time-to-live period has been exceeded. It is a standard system * exception because time-to-live QoS can be applied to any invocation. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @since J2SE 1.5 */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_MODE.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_MODE.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_MODE.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. 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 @@ -35,8 +35,8 @@ * a string describing the exception. * The OMG CORBA core 2.4 specification has details. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class TRANSACTION_MODE extends SystemException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_REQUIRED.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_REQUIRED.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_REQUIRED.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. 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 @@ -33,8 +33,8 @@ * a string describing the exception. * The OMG Transaction Service specfication has details. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class TRANSACTION_REQUIRED extends SystemException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_ROLLEDBACK.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_ROLLEDBACK.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_ROLLEDBACK.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. 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 @@ -36,8 +36,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class TRANSACTION_ROLLEDBACK extends SystemException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_UNAVAILABLE.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_UNAVAILABLE.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSACTION_UNAVAILABLE.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. 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 @@ -35,8 +35,8 @@ * a string describing the exception. * The OMG CORBA core 2.4 specification has details. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class TRANSACTION_UNAVAILABLE extends SystemException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/TRANSIENT.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSIENT.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/TRANSIENT.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -36,8 +36,8 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class TRANSIENT extends SystemException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/UNKNOWN.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/UNKNOWN.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/UNKNOWN.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -39,11 +39,11 @@ * what caused the exception, and a completion status. It may also contain * a string describing the exception. *

- * See the section Minor - * Code Meanings to see the minor codes for this exception. + * See the section {@extLink jidlexception_minorcodes Minor Code Meaning} + * to see the minor codes for this exception. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class UNKNOWN extends SystemException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/UnknownUserException.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/UnknownUserException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/UnknownUserException.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. 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 @@ -32,8 +32,8 @@ * UnknownUserException object. This is available from the * Environment object returned by the method Request.env. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

* @see Request */ diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/UserException.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/UserException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/UserException.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1995, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1995, 2017, Oracle and/or its affiliates. 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 @@ -31,8 +31,8 @@ * means that they need to * be declared in method signatures. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public abstract class UserException extends java.lang.Exception implements org.omg.CORBA.portable.IDLEntity { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/WrongTransaction.java --- a/corba/src/java.corba/share/classes/org/omg/CORBA/WrongTransaction.java Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/WrongTransaction.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. 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 @@ -34,8 +34,8 @@ * which the client originally sent the request. * See the OMG Transaction Service Specification for details. * - * @see documentation on - * Java IDL exceptions + *

See also {@extLink jidlexception documentation on Java IDL exceptions}. + *

*/ public final class WrongTransaction extends UserException { diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/doc-files/generatedfiles.html --- a/corba/src/java.corba/share/classes/org/omg/CORBA/doc-files/generatedfiles.html Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/doc-files/generatedfiles.html Wed Jul 05 23:40:06 2017 +0200 @@ -42,7 +42,7 @@ -

Helper Files

+

Helper Files

Helper files supply several static methods needed to manipulate the type. These include Any insert and extract operations for the type, @@ -57,7 +57,7 @@ is raised to indicate other kinds of errors. Trying to narrow a null will always succeed with a return value of null. -

Holder Files

+

Holder Files

Support for out and inout parameter passing modes requires the use of additional holder classes. These classes are available for all of the basic IDL datatypes in the org.omg.CORBA package @@ -74,7 +74,7 @@ the org.omg.CORBA.portable.Streamable interface. -

Operations Files

+

Operations Files

A non abstract IDL interface is mapped to two public Java interfaces: a signature interface and an operations interface. @@ -96,7 +96,7 @@ interface and operations interface hierarchies. -

Stubs

+

Stubs

For the mapping of a non-object-oriented language, there will be a programming interface to the stubs for each interface type. Generally, the stubs diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CORBA/package.html --- a/corba/src/java.corba/share/classes/org/omg/CORBA/package.html Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CORBA/package.html Wed Jul 05 23:40:06 2017 +0200 @@ -147,9 +147,7 @@ register_initial_reference(String id, org.omg.CORBA.Object obj) -

An example that uses some of these methods is -Getting Started with Java IDL. +

An example that uses some of these methods is {@extLink idl_getting_started Getting Started with Java IDL}.

Exceptions

@@ -158,9 +156,8 @@ then any code using that method must have a try/catch block and handle that exception when it is thrown. -

The documentation on Java -IDL exceptions has more information and explains the difference between +

The documentation on {@extLink jidlexception Java IDL exceptions } +has more information and explains the difference between system exceptions and user-defined exceptions.

The following is a list of the system exceptions (which are unchecked @@ -447,8 +444,8 @@ will take an object in the Java programming language. The helper class for a non-abstract interface that has at least one abstract base interface will provide both versions of the narrow method. -

The Hello World -tutorial uses a narrow method that looks like this: +

The {@extLink idl_guides Hello World tutorial} +uses a narrow method that looks like this:

         // create and initialize the ORB
         ORB orb = ORB.init(args, null);
@@ -548,6 +545,7 @@
 }
 
+

Value Type Helper Classes

A helper class for a value type includes different renderings of the same methods generated for non-value type methods. The main difference @@ -861,8 +859,8 @@ Related Documentation For overviews, guides, and a tutorial, please see: diff -r ea7475564d07 -r ca0e16b2d5d6 corba/src/java.corba/share/classes/org/omg/CosNaming/package.html --- a/corba/src/java.corba/share/classes/org/omg/CosNaming/package.html Thu Jun 15 13:44:42 2017 +0200 +++ b/corba/src/java.corba/share/classes/org/omg/CosNaming/package.html Wed Jul 05 23:40:06 2017 +0200 @@ -3,7 +3,7 @@ - @@ -41,13 +41,13 @@ - @@ -107,7 +107,7 @@ @@ -292,16 +292,16 @@ - + - + - + - + JVM Tool Interface - + - The JVM Tool Interface () - is a programming interface used by development and monitoring tools. - It provides both a way to inspect the state and + The JVM Tool Interface () + is a programming interface used by development and monitoring tools. + It provides both a way to inspect the state and to control the execution of applications running in the Java virtual machine (VM).

@@ -376,21 +376,21 @@ may not be available in all implementations of the Java virtual machine.

- is a two-way interface. + is a two-way interface. A client of , hereafter called an agent, can be notified of - interesting occurrences through events. + interesting occurrences through events. - can query and control the application through many - functions, - either in response to events or + can query and control the application through many + functions, + either in response to events or independent of them.

- Agents run in the same process with and communicate directly with + Agents run in the same process with and communicate directly with the virtual machine executing the application being examined. This communication is through a native interface (). The native in-process interface allows - maximal control with minimal intrusion on the part of a tool. + maximal control with minimal intrusion on the part of a tool. Typically, agents are relatively compact. They can be controlled by a separate process which implements the bulk of a tool's function without interfering with the target application's normal execution. @@ -400,12 +400,12 @@ Tools can be written directly to or indirectly through higher level interfaces. The Java Platform Debugger Architecture includes , but also - contains higher-level, out-of-process debugger interfaces. The higher-level - interfaces are more appropriate than for many tools. - For more information on the Java Platform Debugger Architecture, - see the - Java - Platform Debugger Architecture website. + contains higher-level, out-of-process debugger interfaces. The higher-level + interfaces are more appropriate than for many tools. + For more information on the Java Platform Debugger Architecture, + see the + Java + Platform Debugger Architecture website. @@ -424,16 +424,16 @@ - An agent is deployed in a platform specific manner but is typically the - platform equivalent of a dynamic library. On the Windows operating - system, for example, an agent library is a "Dynamic Linked Library" (DLL). + An agent is deployed in a platform specific manner but is typically the + platform equivalent of a dynamic library. On the Windows operating + system, for example, an agent library is a "Dynamic Linked Library" (DLL). On the Solaris Operating Environment, an agent library is a shared object (.so file).

An agent may be started at VM startup by specifying the agent library name using a command line option. - Some implementations may support a mechanism to + Some implementations may support a mechanism to start agents in the live phase. The details of how this is initiated are implementation specific. @@ -460,7 +460,7 @@ a function is exported, at the same point during VM execution as it would have called the dynamic entry point Agent_OnUnLoad. A statically loaded agent cannot be unloaded. The Agent_OnUnload_L function will still be - called to do any other agent shutdown related tasks. + called to do any other agent shutdown related tasks. If a statically linked agent L exports a function called Agent_OnUnLoad_L and a function called Agent_OnUnLoad, the Agent_OnUnLoad function will be ignored. @@ -472,19 +472,19 @@ Agent_OnAttach_L and a function called Agent_OnAttach, the Agent_OnAttach function will be ignored. - + The term "command-line option" is used below to mean options supplied in the JavaVMInitArgs argument to the JNI_CreateJavaVM function of the JNI Invocation API.

- One of the two following - command-line options is used on VM startup to + One of the two following + command-line options is used on VM startup to properly load and run agents. - These arguments identify the library containing + These arguments identify the library containing the agent as well as an options - string to be passed in at startup. + string to be passed in at startup.

-agentlib:<agent-lib-name>=<options>
@@ -494,10 +494,10 @@ Typically, the <agent-lib-name> is expanded to an operating system specific file name. The <options> will be passed to the agent on start-up. - For example, if the option - -agentlib:foo=opt1,opt2 is specified, the VM will attempt to + For example, if the option + -agentlib:foo=opt1,opt2 is specified, the VM will attempt to load the shared library foo.dll from the system PATH - under Windows or libfoo.so from the + under Windows or libfoo.so from the LD_LIBRARY_PATH under the Solaris operating environment. If the agent library is statically linked into the executable @@ -510,8 +510,8 @@ to load the library. No library name expansion will occur. The <options> will be passed to the agent on start-up. - For example, if the option - -agentpath:c:\myLibs\foo.dll=opt1,opt2 is specified, the VM will attempt to + For example, if the option + -agentpath:c:\myLibs\foo.dll=opt1,opt2 is specified, the VM will attempt to load the shared library c:\myLibs\foo.dll. If the agent library is statically linked into the executable then no actual loading takes place. @@ -523,13 +523,13 @@ in the library will be invoked. If the agent library is statically linked into the executable then the system will attempt to invoke the Agent_OnLoad_<agent-lib-name> entry point where - <agent-lib-name> is the basename of the + <agent-lib-name> is the basename of the agent. In the above example -agentpath:c:\myLibs\foo.dll=opt1,opt2, the system will attempt to find and call the Agent_OnLoad_foo start-up routine.

Libraries loaded with -agentlib: or -agentpath: will be searched for JNI native method implementations to facilitate the - use of Java programming language code in tools, as is needed for + use of Java programming language code in tools, as is needed for bytecode instrumentation.

The agent libraries will be searched after all other libraries have been @@ -537,11 +537,11 @@ implementations of non-agent methods can use the NativeMethodBind event).

- These switches do the above and nothing more - they do not change the - state of the VM or . No command line options are needed - to enable + These switches do the above and nothing more - they do not change the + state of the VM or . No command line options are needed + to enable or aspects of , this is handled programmatically - by the use of + by the use of capabilities. @@ -557,29 +557,29 @@ Agent_OnAttach or Agent_OnAttach_L for statically linked agents will be invoked. - Exactly one call to a start-up function is made per agent. + Exactly one call to a start-up function is made per agent. If an agent is started during the OnLoad phase then its agent library must export a start-up function with the following prototype: -JNIEXPORT jint JNICALL +JNIEXPORT jint JNICALL Agent_OnLoad(JavaVM *vm, char *options, void *reserved) Or for a statically linked agent named 'L': -JNIEXPORT jint JNICALL +JNIEXPORT jint JNICALL Agent_OnLoad_L(JavaVM *vm, char *options, void *reserved) - The VM will start the agent by calling this function. + The VM will start the agent by calling this function. It will be called early enough in VM initialization that:

  • system properties may be set before they have been used in the start-up of the VM
  • -
  • the full set of +
  • the full set of capabilities is still available (note that capabilities that configure the VM - may only be available at this time--see the + may only be available at this time--see the Capability function section)
  • no bytecodes have executed
  • no classes have been loaded
  • @@ -588,13 +588,13 @@

    The VM will call the Agent_OnLoad or Agent_OnLoad_<agent-lib-name> function with - <options> as the second argument - + <options> as the second argument - that is, using the command-line option examples, - "opt1,opt2" will be passed to the char *options + "opt1,opt2" will be passed to the char *options argument of Agent_OnLoad. The options argument is encoded as a modified UTF-8 string. - If =<options> is not specified, + If =<options> is not specified, a zero length string is passed to options. The lifespan of the options string is the Agent_OnLoad or Agent_OnLoad_<agent-lib-name> @@ -602,26 +602,26 @@ be copied. The period between when Agent_OnLoad is called and when it returns is called the OnLoad phase. - Since the VM is not initialized during the OnLoad + Since the VM is not initialized during the OnLoad phase, - the set of allowed operations + the set of allowed operations inside Agent_OnLoad is restricted (see the function descriptions for the - functionality available at this time). - The agent can safely process the options and set - event callbacks with . Once - the VM initialization event is received - (that is, the VMInit + functionality available at this time). + The agent can safely process the options and set + event callbacks with . Once + the VM initialization event is received + (that is, the VMInit callback is invoked), the agent can complete its initialization. Early startup is required so that agents can set the desired capabilities, many of which must be set before the VM is initialized. - In JVMDI, the -Xdebug command-line option provided - very coarse-grain control of capabilities. + In JVMDI, the -Xdebug command-line option provided + very coarse-grain control of capabilities. JVMPI implementations use various tricks to provide a single "JVMPI on" switch. - No reasonable command-line + No reasonable command-line option could provide the fine-grain of control required to balance needed capabilities vs - performance impact. + performance impact. Early startup is also needed so that agents can control the execution environment - modifying the file system and system properties to install their functionality. @@ -631,75 +631,75 @@ Agent_OnLoad_<agent-lib-name> is used to indicate an error. Any value other than zero indicates an error and causes termination of the VM. - + - A VM may support a mechanism that allows agents to be started in the VM during the live + A VM may support a mechanism that allows agents to be started in the VM during the live phase. The details of how this is supported, - are implementation specific. For example, a tool may use some platform specific mechanism, + are implementation specific. For example, a tool may use some platform specific mechanism, or implementation specific API, to attach to the running VM, and request it start a given agent.

    If an agent is started during the live phase then its agent library - must export a start-up function + must export a start-up function with the following prototype: -JNIEXPORT jint JNICALL +JNIEXPORT jint JNICALL Agent_OnAttach(JavaVM* vm, char *options, void *reserved) Or for a statically linked agent named 'L': -JNIEXPORT jint JNICALL +JNIEXPORT jint JNICALL Agent_OnAttach_L(JavaVM* vm, char *options, void *reserved) -

    - The VM will start the agent by calling this function. +

    + The VM will start the agent by calling this function. It will be called in the context of a thread that is attached to the VM. The first argument <vm> is the Java VM. The <options> argument is the startup options provided to the agent. <options> is encoded as a modified UTF-8 string. - If startup options were not provided, a zero length string is passed to - options. The lifespan of the options string is the + If startup options were not provided, a zero length string is passed to + options. The lifespan of the options string is the Agent_OnAttach or Agent_OnAttach_<agent-lib-name> call. If needed beyond this time the string or parts of the string must be copied.

    - Note that some capabilities + Note that some capabilities may not be available in the live phase.

    The Agent_OnAttach or Agent_OnAttach_<agent-lib-name > function initializes the agent and returns a value - to the VM to indicate if an error occurred. Any value other than zero indicates an error. - An error does not cause the VM to terminate. Instead the VM ignores the error, or takes - some implementation specific action -- for example it might print an error to standard error, + to the VM to indicate if an error occurred. Any value other than zero indicates an error. + An error does not cause the VM to terminate. Instead the VM ignores the error, or takes + some implementation specific action -- for example it might print an error to standard error, or record the error in a system log. - The library may optionally export a + The library may optionally export a shutdown function with the following prototype: -JNIEXPORT void JNICALL +JNIEXPORT void JNICALL Agent_OnUnload(JavaVM *vm) Or for a statically linked agent named 'L': -JNIEXPORT void JNICALL +JNIEXPORT void JNICALL Agent_OnUnload_L(JavaVM *vm) This function will be called by the VM when the library is about to be unloaded. The library will be unloaded (unless it is statically linked into the - executable) and this function will be called if some platform specific + executable) and this function will be called if some platform specific mechanism causes the unload (an unload mechanism is not specified in this document) - or the library is (in effect) unloaded by the termination of the VM whether through + or the library is (in effect) unloaded by the termination of the VM whether through normal termination or VM failure, including start-up failure. Uncontrolled shutdown is, of couse, an exception to this rule. - Note the distinction between this function and the + Note the distinction between this function and the VM Death event: for the VM Death event - to be sent, the VM must have run at least to the point of initialization and a valid + to be sent, the VM must have run at least to the point of initialization and a valid environment must exist which has set a callback for VMDeath and enabled the event. None of these are required for Agent_OnUnload or Agent_OnUnload_<agent-lib-name> and this function is also called if the library is unloaded for other reasons. - In the case that a VM Death event is sent, it will be sent before this + In the case that a VM Death event is sent, it will be sent before this function is called (assuming this function is called due to VM termination). This function can be used to clean-up resources allocated by the agent. @@ -709,17 +709,17 @@ or simply VMs launched deep within scripts, a JAVA_TOOL_OPTIONS variable is provided so that agents may be launched in these cases.

    - Platforms which support environment variables or other named strings, may support the - JAVA_TOOL_OPTIONS variable. This variable will be broken into options at white-space - boundaries. White-space characters include space, tab, carriage-return, new-line, - vertical-tab, and form-feed. Sequences of white-space characters are considered - equivalent to a single white-space character. No white-space is included in the options + Platforms which support environment variables or other named strings, may support the + JAVA_TOOL_OPTIONS variable. This variable will be broken into options at white-space + boundaries. White-space characters include space, tab, carriage-return, new-line, + vertical-tab, and form-feed. Sequences of white-space characters are considered + equivalent to a single white-space character. No white-space is included in the options unless quoted. Quoting is as follows:

      -
    • All characters enclosed between a pair of single quote marks (''), except a single +
    • All characters enclosed between a pair of single quote marks (''), except a single quote, are quoted.
    • Double quote characters have no special meaning inside a pair of single quote marks.
    • -
    • All characters enclosed between a pair of double quote marks (""), except a double +
    • All characters enclosed between a pair of double quote marks (""), except a double quote, are quoted.
    • Single quote characters have no special meaning inside a pair of double quote marks.
    • A quoted part can start or end anywhere in the variable.
    • @@ -727,24 +727,24 @@ the option like any other character and do not mark white-space boundaries.
    • The pair of quote marks is not included in the option.
    - JNI_CreateJavaVM (in the JNI Invocation API) will prepend these options to the options supplied - in its JavaVMInitArgs argument. Platforms may disable this feature in cases where security is - a concern; for example, the Reference Implementation disables this feature on Unix systems when - the effective user or group ID differs from the real ID. - This feature is intended to support the initialization of tools -- specifically including the - launching of native or Java programming language agents. Multiple tools may wish to use this - feature, so the variable should not be overwritten, instead, options should be appended to - the variable. Note that since the variable is processed at the time of the JNI Invocation + JNI_CreateJavaVM (in the JNI Invocation API) will prepend these options to the options supplied + in its JavaVMInitArgs argument. Platforms may disable this feature in cases where security is + a concern; for example, the Reference Implementation disables this feature on Unix systems when + the effective user or group ID differs from the real ID. + This feature is intended to support the initialization of tools -- specifically including the + launching of native or Java programming language agents. Multiple tools may wish to use this + feature, so the variable should not be overwritten, instead, options should be appended to + the variable. Note that since the variable is processed at the time of the JNI Invocation API create VM call, options processed by a launcher (e.g., VM selection options) will not be handled. The specification supports the use of multiple simultaneous agents. - Each agent has its own environment. + Each agent has its own environment. That is, the state is separate for each agent - changes to one environment do not affect the - others. The state of a + others. The state of a environment includes:
    • the event callbacks
    • @@ -752,7 +752,7 @@
    • the capabilities
    • the memory allocation/deallocation hooks
    - Although their state + Although their state is separate, agents inspect and modify the shared state of the VM, they also share the native environment in which they execute. As such, an agent can perturb the results of other agents or cause them @@ -761,30 +761,30 @@ of preventing destructive interactions between agents. Techniques to reduce the likelihood of these occurrences are beyond the scope of this document.

    - An agent creates a environment - by passing a version - as the interface ID to the JNI Invocation API function - + An agent creates a environment + by passing a version + as the interface ID to the JNI Invocation API function + GetEnv. See Accessing Functions - for more details on the creation and use of + for more details on the creation and use of environments. - Typically, environments are created by calling GetEnv from + Typically, environments are created by calling GetEnv from Agent_OnLoad. This interface does not include some events that one might expect in an interface with profiling support. Some examples include object allocation events and full speed - method enter and exit events. The interface instead provides support for + method enter and exit events. The interface instead provides support for bytecode instrumentation, the ability to alter the Java virtual machine bytecode instructions which comprise the target program. Typically, these alterations are to add "events" to the code of a method - for example, to add, at the beginning of a method, - a call to MyProfiler.methodEntered(). + a call to MyProfiler.methodEntered(). Since the changes are purely additive, they do not modify application state or behavior. Because the inserted agent code is standard bytecodes, the VM can run at full speed, - optimizing not only the target program but also the instrumentation. If the + optimizing not only the target program but also the instrumentation. If the instrumentation does not involve switching from bytecode execution, no expensive state transitions are needed. The result is high performance events. This approach also provides complete control to the agent: instrumentation can be @@ -792,14 +792,14 @@ can be conditional. Instrumentation can run entirely in Java programming language code or can call into the native agent. Instrumentation can simply maintain counters or can statistically sample events. -

    +

    Instrumentation can be inserted in one of three ways:

    • Static Instrumentation: The class file is instrumented before it is loaded into the VM - for example, by creating a duplicate directory of *.class files which have been modified to add the instrumentation. - This method is extremely awkward and, in general, an agent cannot know + This method is extremely awkward and, in general, an agent cannot know the origin of the class files which will be loaded.
    • @@ -817,21 +817,21 @@ function. Classes can be modified multiple times and can be returned to their original state. - The mechanism allows instrumentation which changes during the + The mechanism allows instrumentation which changes during the course of execution.
    -

    +

    The class modification functionality provided in this interface is intended to provide a mechanism for instrumentation (the event and the function) and, during development, for fix-and-continue debugging (the function). -

    - Care must be taken to avoid perturbing dependencies, especially when +

    + Care must be taken to avoid perturbing dependencies, especially when instrumenting core classes. For example, an approach to getting notification - of every object allocation is to instrument the constructor on + of every object allocation is to instrument the constructor on Object. Assuming that the constructor is initially empty, the constructor could be changed to: @@ -839,15 +839,15 @@ MyProfiler.allocationTracker(this); } - However, if this change was made using the + However, if this change was made using the - event then this might impact a typical VM as follows: + event then this might impact a typical VM as follows: the first created object will call the constructor causing a class load of MyProfiler; which will then cause object creation, and since MyProfiler isn't loaded yet, infinite recursion; resulting in a stack overflow. A refinement of this would be to delay invoking the tracking method until a safe time. For - example, trackAllocations could be set in the + example, trackAllocations could be set in the handler for the VMInit event. static boolean trackAllocations = false; @@ -881,17 +881,17 @@ uses modified UTF-8 to encode character strings. This is the same encoding used by JNI. - Modified UTF-8 differs - from standard UTF-8 in the representation of supplementary characters + Modified UTF-8 differs + from standard UTF-8 in the representation of supplementary characters and of the null character. See the - + Modified UTF-8 Strings section of the JNI specification for details. Since this interface provides access to the state of applications running in the - Java virtual machine; + Java virtual machine; terminology refers to the Java platform and not the native platform (unless stated otherwise). For example:

      @@ -903,20 +903,20 @@

    Sun, Sun Microsystems, the Sun logo, Java, and JVM - are trademarks or registered trademarks of Oracle + are trademarks or registered trademarks of Oracle and/or its affiliates, in the U.S. and other countries. - Native code accesses features - by calling functions. + Native code accesses features + by calling functions. Access to functions is by use of an interface pointer - in the same manner as - Java + in the same manner as + Java Native Interface (JNI) functions are accessed. - The interface pointer is called the + The interface pointer is called the environment pointer.

    An environment pointer is a pointer to an environment and has @@ -924,8 +924,8 @@ An environment has information about its connection. The first value in the environment is a pointer to the function table. The function table is an array of pointers to functions. - Every function pointer is at a predefined offset inside the - array. + Every function pointer is at a predefined offset inside the + array.

    When used from the C language: double indirection is used to access the functions; @@ -945,7 +945,7 @@ ... jvmtiError err = jvmti->GetLoadedClasses(&class_count, &classes); - Unless otherwise stated, all examples and declarations in this + Unless otherwise stated, all examples and declarations in this specification use the C language.

    A environment can be obtained through the JNI Invocation API @@ -955,24 +955,24 @@ ... (*jvm)->GetEnv(jvm, &jvmti, JVMTI_VERSION_1_0); - Each call to GetEnv + Each call to GetEnv creates a new connection and thus - a new environment. + a new environment. The version argument of GetEnv must be a version. The returned environment may have a different version than the requested version but the returned environment must be compatible. - GetEnv will return JNI_EVERSION if a + GetEnv will return JNI_EVERSION if a compatible version is not available, if is not supported or is not supported in the current VM configuration. Other interfaces may be added for creating environments in specific contexts. Each environment has its own state (for example, - desired events, - event handling functions, and - capabilities). - An environment is released with - . + desired events, + event handling functions, and + capabilities). + An environment is released with + . Thus, unlike JNI which has one environment per thread, environments work across threads and are created dynamically. @@ -980,12 +980,12 @@ functions always return an error code via the - function return value. + function return value. Some functions can return additional - values through pointers provided by the calling function. + values through pointers provided by the calling function. In some cases, functions allocate memory that your program must explicitly deallocate. This is indicated in the individual - function descriptions. Empty lists, arrays, sequences, etc are + function descriptions. Empty lists, arrays, sequences, etc are returned as NULL.

    In the event that the function encounters @@ -996,26 +996,26 @@ - functions identify objects with JNI references + functions identify objects with JNI references ( and ) and their derivatives ( and ). - References passed to - functions can be either global or local, but they must be - strong references. All references returned by functions are - local references--these local references are created + References passed to + functions can be either global or local, but they must be + strong references. All references returned by functions are + local references--these local references are created during the call. - Local references are a resource that must be managed (see the - - JNI Documentation). + Local references are a resource that must be managed (see the + + JNI Documentation). When threads return from native code all local references are freed. Note that some threads, including typical agent threads, will never return from native code. - A thread is ensured the ability to create sixteen local + A thread is ensured the ability to create sixteen local references without the need for any explicit management. For threads executing a limited number of calls before returning from native code - (for example, threads processing events), + (for example, threads processing events), it may be determined that no explicit management is needed. However, long running agent threads will need explicit @@ -1023,7 +1023,7 @@ PushLocalFrame and PopLocalFrame. Conversely, to preserve references beyond the return from native code, they must be converted to global references. - These rules do not apply to and + These rules do not apply to and as they are not s. @@ -1035,21 +1035,21 @@ - functions never throw exceptions; error conditions are - communicated via the + functions never throw exceptions; error conditions are + communicated via the function return value. - Any existing exception state is preserved across a call to a + Any existing exception state is preserved across a call to a function. See the - Java Exceptions section of the JNI specification for information on handling exceptions. - These functions provide for the allocation and deallocation of + These functions provide for the allocation and deallocation of memory used by functionality and can be used to provide working memory for agents. Memory managed by is not compatible with other memory @@ -1059,7 +1059,7 @@ Allocate - Allocate an area of memory through the allocator. + Allocate an area of memory through the allocator. The allocated memory should be freed with . @@ -1097,9 +1097,9 @@ Deallocate - Deallocate mem using the allocator. + Deallocate mem using the allocator. This function should - be used to deallocate any memory allocated and returned + be used to deallocate any memory allocated and returned by a function (including memory allocated with ). All allocated memory must be deallocated @@ -1143,60 +1143,60 @@

  • Why not alive?
    • New.
    • -
    • Terminated (Terminated (JVMTI_THREAD_STATE_TERMINATED)
-
  • Alive (Alive (JVMTI_THREAD_STATE_ALIVE)
    • Suspended?
        -
      • Suspended (Suspended (JVMTI_THREAD_STATE_SUSPENDED)
      • Not suspended
    • Interrupted?
        -
      • Interrupted (Interrupted (JVMTI_THREAD_STATE_INTERRUPTED)
      • Not interrupted.
    • In native?
        -
      • In native code (In native code (JVMTI_THREAD_STATE_IN_NATIVE)
      • In Java programming language code
    • What alive state?
        -
      • Runnable (Runnable (JVMTI_THREAD_STATE_RUNNABLE)
      • -
      • Blocked (Blocked (JVMTI_THREAD_STATE_BLOCKED_ON_MONITOR_ENTER)
      • -
      • Waiting (Waiting (JVMTI_THREAD_STATE_WAITING)
        • Timed wait?
            -
          • Indefinite (Indefinite (JVMTI_THREAD_STATE_WAITING_INDEFINITELY
          • -
          • Timed (Timed (JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT)
        • Why waiting?
            -
          • Object.wait (Object.wait (JVMTI_THREAD_STATE_IN_OBJECT_WAIT)
          • -
          • LockSupport.park (LockSupport.park (JVMTI_THREAD_STATE_PARKED)
          • -
          • Sleeping (Sleeping (JVMTI_THREAD_STATE_SLEEPING)
        • @@ -1210,7 +1210,7 @@

        - The answers are represented by the following bit vector. + The answers are represented by the following bit vector. Thread is alive. Zero if thread is new (not started) or terminated. @@ -1223,7 +1223,7 @@ Thread is waiting to enter a synchronization block/method or, - after an Object.wait(), waiting to re-enter a + after an Object.wait(), waiting to re-enter a synchronization block/method. @@ -1250,8 +1250,8 @@ Thread suspended. java.lang.Thread.suspend() - or a suspend function - (such as ) + or a suspend function + (such as ) has been called on the thread. If this bit is set, the other bits refer to the thread state before suspension. @@ -1313,7 +1313,7 @@ Rules

        There can be no more than one answer to a question, although there can be no - answer (because the answer is unknown, does not apply, or none of the answers is + answer (because the answer is unknown, does not apply, or none of the answers is correct). An answer is set only when the enclosing answers match. That is, no more than one of

          @@ -1322,32 +1322,32 @@
        • JVMTI_THREAD_STATE_WAITING
        can be set (a J2SE compliant implementation will always set - one of these if JVMTI_THREAD_STATE_ALIVE is set). - And if any of these are set, the enclosing answer - JVMTI_THREAD_STATE_ALIVE is set. + one of these if JVMTI_THREAD_STATE_ALIVE is set). + And if any of these are set, the enclosing answer + JVMTI_THREAD_STATE_ALIVE is set. No more than one of
        • JVMTI_THREAD_STATE_WAITING_INDEFINITELY
        • JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT
        can be set (a J2SE compliant implementation will always set - one of these if JVMTI_THREAD_STATE_WAITING is set). - And if either is set, the enclosing answers - JVMTI_THREAD_STATE_ALIVE and - JVMTI_THREAD_STATE_WAITING are set. + one of these if JVMTI_THREAD_STATE_WAITING is set). + And if either is set, the enclosing answers + JVMTI_THREAD_STATE_ALIVE and + JVMTI_THREAD_STATE_WAITING are set. No more than one of
        • JVMTI_THREAD_STATE_IN_OBJECT_WAIT
        • JVMTI_THREAD_STATE_PARKED
        • JVMTI_THREAD_STATE_SLEEPING
        - can be set. And if any of these is set, the enclosing answers - JVMTI_THREAD_STATE_ALIVE and - JVMTI_THREAD_STATE_WAITING are set. + can be set. And if any of these is set, the enclosing answers + JVMTI_THREAD_STATE_ALIVE and + JVMTI_THREAD_STATE_WAITING are set. Also, if JVMTI_THREAD_STATE_SLEEPING is set, then JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT is set. - If a state A is implemented using the mechanism of - state B then it is state A which + If a state A is implemented using the mechanism of + state B then it is state A which is returned by this function. For example, if Thread.sleep(long) is implemented using Object.wait(long) @@ -1364,16 +1364,16 @@

        And finally, JVMTI_THREAD_STATE_TERMINATED cannot be set unless - JVMTI_THREAD_STATE_ALIVE is not set. + JVMTI_THREAD_STATE_ALIVE is not set.

        The thread state representation is designed for extension in future versions of the specification; thread state values should be used accordingly, that is - they should not be used as ordinals. + they should not be used as ordinals. Most queries can be made by testing a single bit, if use in a switch statement is desired, the state bits should be masked with the interesting bits. - All bits not defined above are reserved for future use. + All bits not defined above are reserved for future use. A VM, compliant to the current specification, must set reserved bits to zero. - An agent should ignore reserved bits -- + An agent should ignore reserved bits -- they should not be assumed to be zero and thus should not be included in comparisons.

        Examples @@ -1390,8 +1390,8 @@ The state of a thread at a Object.wait(3000) would be: - JVMTI_THREAD_STATE_ALIVE + JVMTI_THREAD_STATE_WAITING + - JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT + + JVMTI_THREAD_STATE_ALIVE + JVMTI_THREAD_STATE_WAITING + + JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT + JVMTI_THREAD_STATE_MONITOR_WAITING The state of a thread suspended while runnable would be: @@ -1423,7 +1423,7 @@ To distinguish timed from untimed Object.wait: - if (state & JVMTI_THREAD_STATE_IN_OBJECT_WAIT) { + if (state & JVMTI_THREAD_STATE_IN_OBJECT_WAIT) { if (state & JVMTI_THREAD_STATE_WAITING_WITH_TIMEOUT) { printf("in Object.wait(long timeout)\n"); } else { @@ -1436,7 +1436,7 @@

        The thread state represented by java.lang.Thread.State returned from java.lang.Thread.getState() is a subset of the - information returned from this function. + information returned from this function. The corresponding java.lang.Thread.State can be determined by using the provided conversion masks. For example, this returns the name of the java.lang.Thread.State thread state: @@ -1466,7 +1466,7 @@ - The thread to query. + The thread to query. @@ -1484,15 +1484,15 @@ Get Current Thread - Get the current thread. + Get the current thread. The current thread is the Java programming language thread which has called the function. The function may return NULL in the start phase if the can_generate_early_vmstart capability is enabled and the java.lang.Thread class has not been initialized yet.

        - Note that most functions that take a thread - as an argument will accept NULL to mean + Note that most functions that take a thread + as an argument will accept NULL to mean the current thread. new @@ -1516,12 +1516,12 @@ Get all live threads. The threads are Java programming language threads; that is, threads that are attached to the VM. - A thread is live if java.lang.Thread.isAlive() + A thread is live if java.lang.Thread.isAlive() would return true, that is, the thread has been started and has not yet died. The universe of threads is determined by the context of the environment, which typically is all threads attached to the VM. - Note that this includes agent threads + Note that this includes agent threads (see ). jvmdi @@ -1549,8 +1549,8 @@ Suspend Thread - Suspend the specified thread. If the calling thread is specified, - this function will not return until some other thread calls + Suspend the specified thread. If the calling thread is specified, + this function will not return until some other thread calls . If the thread is currently suspended, this function does nothing and returns an error. @@ -1563,7 +1563,7 @@ - The thread to suspend. + The thread to suspend. @@ -1592,22 +1592,22 @@ The threads are Java programming language threads; native threads which are not attached to the VM are not Java programming language threads. - A thread is live if java.lang.Thread.isAlive() + A thread is live if java.lang.Thread.isAlive() would return true, that is, the thread has been started and has not yet died. - The universe of threads is determined + The universe of threads is determined by the context of the environment, which, typically, is all threads attached to the VM, - except critical VM internal threads and agent threads + except critical VM internal threads and agent threads (see ).

        - If the calling thread is specified, + If the calling thread is specified, all other threads are suspended first then the caller thread is suspended - - this function will not return until some other thread calls + this function will not return until some other thread calls .

        The list of actually - suspended threads is returned in + suspended threads is returned in . Suspension is as defined in . @@ -1662,13 +1662,13 @@ Suspend Thread List - Suspend the - threads specified in the - array. + Suspend the + threads specified in the + array. Threads may be resumed with or . - If the calling thread is specified in the + If the calling thread is specified in the array, this function will not return until some other thread resumes it. Errors encountered in the suspension of a thread @@ -1696,11 +1696,11 @@ jvmtiError - An agent supplied array of + An agent supplied array of elements. On return, filled with the error code for the suspend of the corresponding thread. - The error code will be + The error code will be if the thread was suspended by this call. Possible error codes are those specified @@ -1715,12 +1715,12 @@ Resume Thread - Resume a suspended thread. + Resume a suspended thread. Any threads currently suspended through a suspend function (eg. - ) + ) or java.lang.Thread.suspend() - will resume execution; + will resume execution; all other threads are unaffected. jvmdi @@ -1740,7 +1740,7 @@ Thread was not suspended. - The state of the thread has been modified, and is now inconsistent. + The state of the thread has been modified, and is now inconsistent. @@ -1748,12 +1748,12 @@ Resume Thread List - Resume the - threads specified in the - array. + Resume the + threads specified in the + array. Any thread suspended through a suspend function (eg. - ) + ) or java.lang.Thread.suspend() will resume execution. @@ -1777,11 +1777,11 @@ jvmtiError - An agent supplied array of + An agent supplied array of elements. On return, filled with the error code for the resume of the corresponding thread. - The error code will be + The error code will be if the thread was suspended by this call. Possible error codes are those specified @@ -1796,9 +1796,9 @@ Stop Thread - Send the specified asynchronous exception to the specified thread + Send the specified asynchronous exception to the specified thread (similar to java.lang.Thread.stop). - Normally, this function is used to kill the specified thread with an + Normally, this function is used to kill the specified thread with an instance of the exception ThreadDeath. jvmdi @@ -1883,7 +1883,7 @@ - Get thread information. The fields of the structure + Get thread information. The fields of the structure are filled in with details of the specified thread. jvmdi @@ -1910,8 +1910,8 @@ Get Owned Monitor Info - Get information about the monitors owned by the - specified thread. + Get information about the monitors owned by the + specified thread. jvmdiClone @@ -1943,7 +1943,7 @@ Get Owned Monitor Stack Depth Info - @@ -1954,18 +1954,18 @@ - The stack depth. Corresponds to the stack depth used in the + The stack depth. Corresponds to the stack depth used in the Stack Frame functions. That is, zero is the current frame, one is the frame which - called the current frame. And it is negative one if the - implementation cannot determine the stack depth (e.g., for + called the current frame. And it is negative one if the + implementation cannot determine the stack depth (e.g., for monitors acquired by JNI MonitorEnter). - Get information about the monitors owned by the - specified thread and the depth of the stack frame which locked them. + Get information about the monitors owned by the + specified thread and the depth of the stack frame which locked them. new @@ -2000,7 +2000,7 @@ Get Current Contended Monitor - Get the object, if any, whose monitor the specified thread is waiting to + Get the object, if any, whose monitor the specified thread is waiting to enter or waiting to regain through java.lang.Object.wait. jvmdi @@ -2057,7 +2057,7 @@ - The arg parameter passed to + The arg parameter passed to . @@ -2071,13 +2071,13 @@ The parameter is forwarded on to the start function (specified with ) as its single argument. - This function allows the creation of agent threads - for handling communication with another process or for handling events - without the need to load a special subclass of java.lang.Thread or - implementer of java.lang.Runnable. + This function allows the creation of agent threads + for handling communication with another process or for handling events + without the need to load a special subclass of java.lang.Thread or + implementer of java.lang.Runnable. Instead, the created thread can run entirely in native code. However, the created thread does require a newly created instance - of java.lang.Thread (referenced by the argument thread) to + of java.lang.Thread (referenced by the argument thread) to which it will be associated. The thread object can be created with JNI calls.

        @@ -2105,14 +2105,14 @@ added to the thread group and the thread is not seen on queries of the thread group at either the Java programming language or levels.

        - The thread is not visible to Java programming language queries but is - included in queries (for example, + The thread is not visible to Java programming language queries but is + included in queries (for example, and ).

        Upon execution of proc, the new thread will be attached to the - VM -- see the JNI documentation on - Attaching to the VM. jvmdiClone @@ -2152,8 +2152,8 @@ - - is less than + + is less than or greater than @@ -2169,7 +2169,7 @@ This value is NULL unless set with this function. Agents can allocate memory in which they store thread specific information. By setting thread-local storage it can then be - accessed with + accessed with .

        This function is called by the agent to set the value of the @@ -2188,10 +2188,10 @@ - - - value is set to NULL - + + + value is set to NULL + The value to be entered into the thread-local storage. @@ -2205,7 +2205,7 @@ Get Thread Local Storage Called by the agent to get the value of the thread-local - storage. + storage. jvmpi @@ -2220,10 +2220,10 @@ - Pointer through which the value of the thread local + Pointer through which the value of the thread local storage is returned. If thread-local storage has not been set with - the returned + the returned pointer is NULL. @@ -2294,8 +2294,8 @@ - Get information about the thread group. The fields of the - structure + Get information about the thread group. The fields of the + structure are filled in with details of the specified thread group. jvmdi @@ -2312,7 +2312,7 @@ jvmtiThreadGroupInfo On return, filled with information describing the specified - thread group. + thread group. @@ -2373,15 +2373,15 @@

        Stack frames are as described in , - That is, they correspond to method - invocations (including native methods) but do not correspond to platform native or + That is, they correspond to method + invocations (including native methods) but do not correspond to platform native or VM internal frames.

        A implementation may use method invocations to launch a thread and the corresponding frames may be included in the stack as presented by these functions -- that is, there may be frames shown deeper than main() and run(). - However this presentation must be consistent across all functionality which + However this presentation must be consistent across all functionality which uses stack frames or stack depth. @@ -2425,16 +2425,16 @@ jvmtiFrameInfo - On return, this agent allocated buffer is filled - with stack frame information. + On return, this agent allocated buffer is filled + with stack frame information. - On return, the number of records filled into + On return, the number of records filled into frame_buffer. - This will be + This will be min(max_frame_count, stackDepth). @@ -2445,7 +2445,7 @@ Get information about the stack of a thread. If is less than the depth of the stack, - the topmost frames are returned, + the topmost frames are returned, otherwise the entire stack is returned. The topmost frames, those most recently invoked, are at the beginning of the returned buffer.

        @@ -2457,23 +2457,23 @@ jint count; jvmtiError err; -err = (*jvmti)->GetStackTrace(jvmti, aThread, 0, 5, +err = (*jvmti)->GetStackTrace(jvmti, aThread, 0, 5, frames, &count); if (err == JVMTI_ERROR_NONE && count >= 1) { char *methodName; - err = (*jvmti)->GetMethodName(jvmti, frames[0].method, + err = (*jvmti)->GetMethodName(jvmti, frames[0].method, &methodName, NULL, NULL); if (err == JVMTI_ERROR_NONE) { printf("Executing method: %s", methodName); } } - + check example code.

        The need not be suspended - to call this function. + to call this function.

        The function can be used to map locations to line numbers. Note that @@ -2492,15 +2492,15 @@ - Begin retrieving frames at this depth. - If non-negative, count from the current frame, - the first frame retrieved is at depth start_depth. + Begin retrieving frames at this depth. + If non-negative, count from the current frame, + the first frame retrieved is at depth start_depth. For example, if zero, start from the current frame; if one, start from the caller of the current frame; if two, start from the caller of the caller of the current frame; and so on. If negative, count from below the oldest frame, - the first frame retrieved is at depth stackDepth + start_depth, - where stackDepth is the count of frames on the stack. + the first frame retrieved is at depth stackDepth + start_depth, + where stackDepth is the count of frames on the stack. For example, if negative one, only the oldest frame is retrieved; if negative two, start from the frame called by the oldest frame. @@ -2516,17 +2516,17 @@ jvmtiFrameInfo - On return, this agent allocated buffer is filled - with stack frame information. + On return, this agent allocated buffer is filled + with stack frame information. On return, points to the number of records filled in. - For non-negative start_depth, this will be + For non-negative start_depth, this will be min(max_frame_count, stackDepth - start_depth). - For negative start_depth, this will be + For negative start_depth, this will be min(max_frame_count, -start_depth). @@ -2546,23 +2546,23 @@ Get information about the stacks of all live threads (including agent threads). If is less than the depth of a stack, - the topmost frames are returned for that thread, + the topmost frames are returned for that thread, otherwise the entire stack is returned. The topmost frames, those most recently invoked, are at the beginning of the returned buffer.

        - All stacks are collected simultaneously, that is, no changes will occur to the + All stacks are collected simultaneously, that is, no changes will occur to the thread state or stacks between the sampling of one thread and the next. The threads need not be suspended. - + jvmtiStackInfo *stack_info; jint thread_count; int ti; jvmtiError err; -err = (*jvmti)->GetAllStackTraces(jvmti, MAX_FRAMES, &stack_info, &thread_count); +err = (*jvmti)->GetAllStackTraces(jvmti, MAX_FRAMES, &stack_info, &thread_count); if (err != JVMTI_ERROR_NONE) { - ... + ... } for (ti = 0; ti < thread_count; ++ti) { jvmtiStackInfo *infop = &stack_info[ti]; @@ -2577,9 +2577,9 @@ } } /* this one Deallocate call frees all data allocated by GetAllStackTraces */ -err = (*jvmti)->Deallocate(jvmti, stack_info); +err = (*jvmti)->Deallocate(jvmti, stack_info); - + check example code. @@ -2599,12 +2599,12 @@ jvmtiStackInfo - On return, this buffer is filled - with stack information for each thread. - The number of records is determined + On return, this buffer is filled + with stack information for each thread. + The number of records is determined by .

        - Note that this buffer is allocated to include the + Note that this buffer is allocated to include the buffers pointed to by . These buffers must not be separately deallocated. @@ -2625,11 +2625,11 @@ Get information about the stacks of the supplied threads. If is less than the depth of a stack, - the topmost frames are returned for that thread, + the topmost frames are returned for that thread, otherwise the entire stack is returned. The topmost frames, those most recently invoked, are at the beginning of the returned buffer.

        - All stacks are collected simultaneously, that is, no changes will occur to the + All stacks are collected simultaneously, that is, no changes will occur to the thread state or stacks between the sampling one thread and the next. The threads need not be suspended.

        @@ -2667,12 +2667,12 @@ jvmtiStackInfo - On return, this buffer is filled - with stack information for each thread. - The number of records is determined + On return, this buffer is filled + with stack information for each thread. + The number of records is determined by .

        - Note that this buffer is allocated to include the + Note that this buffer is allocated to include the buffers pointed to by . These buffers must not be separately deallocated. @@ -2703,8 +2703,8 @@ - If false, - + If false, + must be false. @@ -2713,7 +2713,7 @@ Return the stack showing - model of the stack; + model of the stack; otherwise, show the internal representation of the stack with inlined and optimized methods missing. If the virtual machine is using the Java Virtual Machine Specification stack model @@ -2734,9 +2734,9 @@ The agent passes in a buffer - large enough to hold max_count records of + large enough to hold max_count records of . This buffer must be - pre-allocated by the agent. + pre-allocated by the agent. @@ -2788,27 +2788,27 @@ Pop Frame Pop the current frame of thread's stack. - Popping a frame takes you to the previous frame. - When the thread is resumed, the execution + Popping a frame takes you to the previous frame. + When the thread is resumed, the execution state of the thread is reset to the state immediately before the called method was invoked. That is (using terminology):

        • the current frame is discarded as the previous frame becomes the current one
        • the operand stack is restored--the argument values are added back - and if the invoke was not invokestatic, + and if the invoke was not invokestatic, objectref is added back as well
        • the Java virtual machine PC is restored to the opcode of the invoke instruction
        Note however, that any changes to the arguments, which - occurred in the called method, remain; - when execution continues, the first instruction to - execute will be the invoke. + occurred in the called method, remain; + when execution continues, the first instruction to + execute will be the invoke.

        - Between calling PopFrame and resuming the - thread the state of the stack is undefined. - To pop frames beyond the first, + Between calling PopFrame and resuming the + thread the state of the stack is undefined. + To pop frames beyond the first, these three steps must be repeated:

        • suspend the thread via an event (step, breakpoint, ...)
        • @@ -2816,11 +2816,11 @@
        • resume the thread

        - A lock acquired by calling the called method - (if it is a synchronized method) + A lock acquired by calling the called method + (if it is a synchronized method) and locks acquired by entering synchronized - blocks within the called method are released. - Note: this does not apply to native locks or + blocks within the called method are released. + Note: this does not apply to native locks or java.util.concurrent.locks locks.

        Finally blocks are not executed. @@ -2829,7 +2829,7 @@

        The specified thread must be suspended (which implies it cannot be the current thread).

        - Both the called method and calling method must be non-native Java programming + Both the called method and calling method must be non-native Java programming language methods.

        No events are generated by this function. @@ -2892,7 +2892,7 @@ - On return, points to the index of the currently + On return, points to the index of the currently executing instruction. Is set to -1 if the frame is executing a native method. @@ -2906,11 +2906,11 @@ Notify Frame Pop - When the frame that is currently at + When the frame that is currently at is popped from the stack, generate a - event. See the + event. See the event for details. - Only frames corresponding to non-native Java programming language + Only frames corresponding to non-native Java programming language methods can receive notification.

        The specified thread must either be the current thread @@ -2922,7 +2922,7 @@ - + The thread of the frame for which the frame pop event will be generated. @@ -2935,7 +2935,7 @@ - + The frame at depth is executing a native method. @@ -2954,7 +2954,7 @@ The method which will return early is referred to as the called method. The called method is the current method (as defined by - ) + ) for the specified thread at the time the function is called.

        @@ -2962,17 +2962,17 @@ The return occurs when execution of Java programming language code is resumed on this thread. Between calling one of these functions and resumption - of thread execution, the state of the stack is undefined. + of thread execution, the state of the stack is undefined.

        - No further instructions are executed in the called method. + No further instructions are executed in the called method. Specifically, finally blocks are not executed. Note: this can cause inconsistent states in the application.

        - A lock acquired by calling the called method - (if it is a synchronized method) + A lock acquired by calling the called method + (if it is a synchronized method) and locks acquired by entering synchronized - blocks within the called method are released. - Note: this does not apply to native locks or + blocks within the called method are released. + Note: this does not apply to native locks or java.util.concurrent.locks locks.

        Events, such as , @@ -2989,7 +2989,7 @@ This function can be used to return from a method whose result type is Object - or a subclass of Object. + or a subclass of Object. new @@ -3005,7 +3005,7 @@ - The return value for the called frame. + The return value for the called frame. An object or NULL. @@ -3017,12 +3017,12 @@ Or the implementation is unable to provide this functionality on this frame. - - The result type of the called method is not + + The result type of the called method is not Object or a subclass of Object. - - The supplied is not compatible with the + + The supplied is not compatible with the result type of the called method. @@ -3039,8 +3039,8 @@ This function can be used to return from a method whose result type is int, short, - char, byte, or - boolean. + char, byte, or + boolean. new @@ -3067,10 +3067,10 @@ Or the implementation is unable to provide this functionality on this frame. - - The result type of the called method is not + + The result type of the called method is not int, short, - char, byte, or + char, byte, or boolean. @@ -3113,7 +3113,7 @@ Or the implementation is unable to provide this functionality on this frame. - + The result type of the called method is not long. @@ -3156,7 +3156,7 @@ Or the implementation is unable to provide this functionality on this frame. - + The result type of the called method is not float. @@ -3197,7 +3197,7 @@ Attempted to return early from a frame corresponding to a native method. Or the implementation is unable to provide this functionality on this frame. - + The result type of the called method is not double. @@ -3234,8 +3234,8 @@ Or the implementation is unable to provide this functionality on this frame. - - The called method has a result type. + + The called method has a result type. Thread was not the current thread and was not suspended. @@ -3254,12 +3254,12 @@ Functionality includes the ability to view the objects in the heap and to tag these objects. - + A tag is a value associated with an object. Tags are explicitly set by the agent using the function or by - callback functions such as . + callback functions such as .

        Tags are local to the environment; that is, the tags of one environment are not visible in another. @@ -3267,10 +3267,10 @@ Tags are jlong values which can be used simply to mark an object or to store a pointer to more detailed information. Objects which have not been tagged have a - tag of zero. + tag of zero. Setting a tag to zero makes the object untagged. - + Heap functions which iterate through the heap and recursively follow object references use agent supplied callback functions @@ -3278,7 +3278,7 @@

        These heap callback functions must adhere to the following restrictions -- These callbacks must not use JNI functions. - These callbacks must not use functions except + These callbacks must not use functions except callback safe functions which specifically allow such use (see the raw monitor, memory management, and environment local storage functions). @@ -3289,7 +3289,7 @@ be invoked at a time.

        The Heap Filter Flags can be used to prevent reporting - based on the tag status of an object or its class. + based on the tag status of an object or its class. If no flags are set (the jint is zero), objects will not be filtered out. @@ -3310,43 +3310,43 @@

        The Heap Visit Control Flags are returned by the heap callbacks - and can be used to abort the iteration. For the - Heap - Reference Callback, it can also be used + and can be used to abort the iteration. For the + Heap + Reference Callback, it can also be used to prune the graph of traversed references (JVMTI_VISIT_OBJECTS is not set). - If we are visiting an object and if this callback - was initiated by , + was initiated by , traverse the references of this object. Otherwise ignored. - + Abort the iteration. Ignore all other bits.

        - The Heap Reference Enumeration is provided by the - Heap - Reference Callback and - Primitive Field - Callback to + The Heap Reference Enumeration is provided by the + Heap + Reference Callback and + Primitive Field + Callback to describe the kind of reference being reported. - Reference from an object to its class. - + Reference from an object to the value of one of its instance fields. @@ -3361,11 +3361,11 @@ Reference from a class to its protection domain. - + - Reference from a class to one of its interfaces. + Reference from a class to one of its interfaces. Note: interfaces are defined via a constant pool reference, - so the referenced interfaces may also be reported with a + so the referenced interfaces may also be reported with a JVMTI_HEAP_REFERENCE_CONSTANT_POOL reference kind. @@ -3375,10 +3375,10 @@ Reference from a class to a resolved entry in the constant pool. - Reference from a class to its superclass. + Reference from a class to its superclass. A callback is not sent if the superclass is java.lang.Object. Note: loaded classes define superclasses via a constant pool - reference, so the referenced superclass may also be reported with + reference, so the referenced superclass may also be reported with a JVMTI_HEAP_REFERENCE_CONSTANT_POOL reference kind. @@ -3408,88 +3408,88 @@ Definitions for the single character type descriptors of primitive types. - 'Z' - Java programming language boolean - JNI jboolean - + 'B' - Java programming language byte - JNI jbyte - + 'C' - Java programming language char - JNI jchar - + 'S' - Java programming language short - JNI jshort - + 'I' - Java programming language int - JNI jint - + 'J' - Java programming language long - JNI jlong - + 'F' - Java programming language float - JNI jfloat - + 'D' - Java programming language double - JNI jdouble - + - - Reference information returned for - and + Reference information returned for + and references. - - For , the - referrer object is not a class or an inteface. - In this case, index is the index of the field - in the class of the referrer object. + + For , the + referrer object is not a class or an inteface. + In this case, index is the index of the field + in the class of the referrer object. This class is referred to below as C.

        For , the referrer object is a class (referred to below as C) or an interface (referred to below as I). - In this case, index is the index of the field in + In this case, index is the index of the field in that class or interface.

        - If the referrer object is not an interface, then the field - indices are determined as follows: + If the referrer object is not an interface, then the field + indices are determined as follows:

        • make a list of all the fields in C and its - superclasses, starting with all the fields in + superclasses, starting with all the fields in java.lang.Object and ending with all the fields in C.
        • -
        • Within this list, put +
        • Within this list, put the fields for a given class in the order returned by .
        • -
        • Assign the fields in this list indices - n, n+1, ..., in order, where n +
        • Assign the fields in this list indices + n, n+1, ..., in order, where n is the count of the fields in all the interfaces - implemented by C. - Note that C implements all interfaces + implemented by C. + Note that C implements all interfaces directly implemented by its superclasses; as well as all superinterfaces of these interfaces.
        - If the referrer object is an interface, then the field + If the referrer object is an interface, then the field indices are determined as follows:
          -
        • make a list of the fields directly declared in +
        • make a list of the fields directly declared in I.
        • -
        • Within this list, put +
        • Within this list, put the fields in the order returned by .
        • -
        • Assign the fields in this list indices - n, n+1, ..., in order, where n +
        • Assign the fields in this list indices + n, n+1, ..., in order, where n is the count of the fields in all the superinterfaces of I.
        @@ -3522,7 +3522,7 @@ Assume that called on C1 returns the fields of C1 in the - order: a, b; and that the fields of C2 are + order: a, b; and that the fields of C2 are returned in the order: q, r. An instance of class C1 will have the following field indices: @@ -3569,7 +3569,7 @@ The count of the fields in the interfaces implemented by C2 is three (n=3): p of I0, - x of I1 and y of I2 + x of I1 and y of I2 (an interface of C2). Note that the field p of I0 is only included once. @@ -3611,7 +3611,7 @@ The class C2 will have the same field indices. Note that a field may have a different index depending on the object that is viewing it -- for example field "a" above. - Note also: not all field indices may be visible from the + Note also: not all field indices may be visible from the callbacks, but all indices are shown for illustrative purposes.

        The interface I1 will have the @@ -3631,46 +3631,46 @@

  • - + - - Reference information returned for + Reference information returned for references. - + The array index. - - Reference information returned for + Reference information returned for references. - - The index into the constant pool of the class. See the description in + + The index into the constant pool of the class. See the description in . - - Reference information returned for + Reference information returned for references. @@ -3688,7 +3688,7 @@ - The depth of the frame. + The depth of the frame. @@ -3711,11 +3711,11 @@ - - Reference information returned for + Reference information returned for references. @@ -3733,7 +3733,7 @@ - The depth of the frame. + The depth of the frame. @@ -3744,8 +3744,8 @@ - Reference information returned for other references. @@ -3800,8 +3800,8 @@ - The information returned about referrers. @@ -3809,50 +3809,50 @@ jvmtiHeapReferenceInfoField - - The referrer information for - + + The referrer information for + and references. jvmtiHeapReferenceInfoArray - - The referrer information for + + The referrer information for For references. jvmtiHeapReferenceInfoConstantPool - - The referrer information for + + The referrer information for For references. jvmtiHeapReferenceInfoStackLocal - - The referrer information for + + The referrer information for For references. jvmtiHeapReferenceInfoJniLocal - - The referrer information for + + The referrer information for For references. jvmtiHeapReferenceInfoReserved - + reserved for future use. - @@ -3860,22 +3860,22 @@ The callback to be called to describe an - object in the heap. Used by the + object in the heap. Used by the function, ignored by the function. - + jvmtiHeapReferenceCallback The callback to be called to describe an - object reference. Used by the + object reference. Used by the function, ignored by the function. - + jvmtiPrimitiveFieldCallback @@ -3884,7 +3884,7 @@ The callback to be called to describe a primitive field. - + jvmtiArrayPrimitiveValueCallback @@ -3893,7 +3893,7 @@ The callback to be called to describe an array of primitive values. - + jvmtiStringPrimitiveValueCallback @@ -3901,7 +3901,7 @@ The callback to be called to describe a String value. - + jvmtiReservedCallback @@ -3909,7 +3909,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3917,7 +3917,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3925,7 +3925,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3933,7 +3933,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3941,7 +3941,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3949,7 +3949,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3957,7 +3957,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3965,7 +3965,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3973,7 +3973,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3981,7 +3981,7 @@ Reserved for future use.. - + jvmtiReservedCallback @@ -3989,7 +3989,7 @@ Reserved for future use.. - + @@ -4033,10 +4033,10 @@ - The tag of the class of object (zero if the class is not tagged). - If the object represents a runtime class, - the class_tag is the tag - associated with java.lang.Class + The tag of the class of object (zero if the class is not tagged). + If the object represents a runtime class, + the class_tag is the tag + associated with java.lang.Class (zero if java.lang.Class is not tagged). @@ -4051,7 +4051,7 @@ The object tag value, or zero if the object is not tagged. To set the tag value to be associated with the object - the agent sets the jlong pointed to by the parameter. + the agent sets the jlong pointed to by the parameter. @@ -4063,17 +4063,17 @@ - The user supplied data that was passed into the iteration function. - - - - + The user supplied data that was passed into the iteration function. + + + + Heap Reference Callback - Agent supplied callback function. + Agent supplied callback function. Describes a reference from an object or the VM (the referrer) to another object (the referree) or a heap root to a referree.

    @@ -4097,12 +4097,12 @@ jvmtiHeapReferenceInfo - Details about the reference. + Details about the reference. Set when the reference_kind is , , , - , + , , or . Otherwise NULL. @@ -4111,9 +4111,9 @@ - The tag of the class of referree object (zero if the class is not tagged). - If the referree object represents a runtime class, - the class_tag is the tag + The tag of the class of referree object (zero if the class is not tagged). + If the referree object represents a runtime class, + the class_tag is the tag associated with java.lang.Class (zero if java.lang.Class is not tagged). @@ -4131,14 +4131,14 @@ - Size of the referree object (in bytes). + Size of the referree object (in bytes). See . - Points to the referree object tag value, or zero if the object is not + Points to the referree object tag value, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -4147,14 +4147,14 @@ - Points to the tag of the referrer object, or + Points to the tag of the referrer object, or points to the zero if the referrer - object is not tagged. + object is not tagged. NULL if the referrer in not an object (that is, this callback is reporting a heap root). To set the tag value to be associated with the referrer object the agent sets the jlong pointed to by the parameter. - If this callback is reporting a reference from an object to itself, + If this callback is reporting a reference from an object to itself, referrer_tag_ptr == tag_ptr. @@ -4167,7 +4167,7 @@ - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -4177,7 +4177,7 @@ Primitive Field Callback - Agent supplied callback function which + Agent supplied callback function which describes a primitive field of an object (the object). A primitive field is a field whose type is a primitive type. This callback will describe a static field if the object is a class, @@ -4195,7 +4195,7 @@ jvmtiHeapReferenceKind - The kind of field -- instance or static ( or + The kind of field -- instance or static ( or ). @@ -4210,17 +4210,17 @@ - The tag of the class of the object (zero if the class is not tagged). - If the object represents a runtime class, the - object_class_tag is the tag - associated with java.lang.Class + The tag of the class of the object (zero if the class is not tagged). + If the object represents a runtime class, the + object_class_tag is the tag + associated with java.lang.Class (zero if java.lang.Class is not tagged). - Points to the tag of the object, or zero if the object is not + Points to the tag of the object, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -4241,7 +4241,7 @@ - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -4251,7 +4251,7 @@ Array Primitive Value Callback - Agent supplied callback function. + Agent supplied callback function. Describes the values in an array of a primitive type.

    This function should return a bit vector of the desired @@ -4266,20 +4266,20 @@ - The tag of the class of the array object (zero if the class is not tagged). + The tag of the class of the array object (zero if the class is not tagged). - Size of the array (in bytes). + Size of the array (in bytes). See . - Points to the tag of the array object, or zero if the object is not + Points to the tag of the array object, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -4307,7 +4307,7 @@ - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -4317,7 +4317,7 @@ String Primitive Value Callback - Agent supplied callback function. + Agent supplied callback function. Describes the value of a java.lang.String.

    This function should return a bit vector of the desired @@ -4332,21 +4332,21 @@ - The tag of the class of the String class (zero if the class is not tagged). + The tag of the class of the String class (zero if the class is not tagged). Is this needed? - Size of the string (in bytes). + Size of the string (in bytes). See . - Points to the tag of the String object, or zero if the object is not + Points to the tag of the String object, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -4361,15 +4361,15 @@ - The length of the string. - The length is equal to the number of 16-bit Unicode + The length of the string. + The length is equal to the number of 16-bit Unicode characters in the string. - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -4388,27 +4388,27 @@ Follow References - - This function initiates a traversal over the objects that are + + This function initiates a traversal over the objects that are directly and indirectly reachable from the specified object or, - if initial_object is not specified, all objects + if initial_object is not specified, all objects reachable from the heap roots. - The heap root are the set of system classes, - JNI globals, references from thread stacks, and other objects used as roots - for the purposes of garbage collection. + The heap root are the set of system classes, + JNI globals, references from thread stacks, and other objects used as roots + for the purposes of garbage collection.

    This function operates by traversing the reference graph. Let A, B, ... represent objects. When a reference from A to B is traversed, - when a reference from a heap root to B is traversed, - or when B is specified as the , + when a reference from a heap root to B is traversed, + or when B is specified as the , then B is said to be visited. - A reference from A to B is not traversed until A + A reference from A to B is not traversed until A is visited. References are reported in the same order that the references are traversed. - Object references are reported by invoking the agent supplied + Object references are reported by invoking the agent supplied callback function . - In a reference from A to B, A is known + In a reference from A to B, A is known as the referrer and B as the referree. The callback is invoked exactly once for each reference from a referrer; this is true even if there are reference cycles or multiple paths to @@ -4416,10 +4416,10 @@ There may be more than one reference between a referrer and a referree, each reference is reported. These references may be distinguished by examining the - reference_kind and - reference_info parameters of the callback.

    @@ -4456,10 +4456,10 @@ whether the callback will be invoked, it does not influence which objects are visited nor does it influence whether other callbacks will be invoked. - However, the + However, the visit control flags returned by - do determine if the objects referenced by the + do determine if the objects referenced by the current object as visited. The heap filter flags and provided as parameters to this function @@ -4468,7 +4468,7 @@ For example, if the only callback that was set is and klass is set to the array of bytes class, then only arrays of byte will be - reported. + reported. The table below summarizes this:

    @@ -4547,22 +4547,22 @@

    During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new - + - This bit vector of + This bit vector of heap filter flags. restricts the objects for which the callback function is called. This applies to both the object and primitive callbacks. @@ -4575,7 +4575,7 @@ class - Callbacks are only reported when the object is an instance of + Callbacks are only reported when the object is an instance of this class. Objects which are instances of a subclass of klass are not reported. @@ -4599,14 +4599,14 @@ Structure defining the set of callback functions. - + NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -4623,12 +4623,12 @@ Iterate Through Heap - - Initiate an iteration over all objects in the heap. - This includes both reachable and + + Initiate an iteration over all objects in the heap. + This includes both reachable and unreachable objects. Objects are visited in no particular order.

    - Heap objects are reported by invoking the agent supplied + Heap objects are reported by invoking the agent supplied callback function . References between objects are not reported. If only reachable objects are desired, or if object reference information @@ -4642,7 +4642,7 @@ . A primitive field is reported after the object with that field is visited; - it is reported by invoking the agent supplied + it is reported by invoking the agent supplied callback function .

    @@ -4660,7 +4660,7 @@ For example, if the only callback that was set is and klass is set to the array of bytes class, then only arrays of byte will be - reported. The table below summarizes this (contrast this with + reported. The table below summarizes this (contrast this with ):

    @@ -4739,11 +4739,11 @@

    During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new @@ -4754,7 +4754,7 @@ - This bit vector of + This bit vector of heap filter flags. restricts the objects for which the callback function is called. This applies to both the object and primitive callbacks. @@ -4766,7 +4766,7 @@ callbacks are not limited to instances of a particular class - Callbacks are only reported when the object is an instance of + Callbacks are only reported when the object is an instance of this class. Objects which are instances of a subclass of klass are not reported. @@ -4781,14 +4781,14 @@ Structure defining the set callback functions. - + NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -4803,7 +4803,7 @@ Get Tag Retrieve the tag associated with an object. - The tag is a long value typically used to store a + The tag is a long value typically used to store a unique identifier or pointer to object information. The tag is set with . @@ -4824,7 +4824,7 @@ - On return, the referenced long is set to the value + On return, the referenced long is set to the value of the tag. @@ -4837,7 +4837,7 @@ Set Tag Set the tag associated with an object. - The tag is a long value typically used to store a + The tag is a long value typically used to store a unique identifier or pointer to object information. The tag is visible with . @@ -4895,7 +4895,7 @@ - Return the number of objects with any of the tags + Return the number of objects with any of the tags in . @@ -4905,7 +4905,7 @@ this information is not returned - Returns the array of objects with any of the tags + Returns the array of objects with any of the tags in . @@ -4936,13 +4936,13 @@ This function does not return until the garbage collection is finished.

    - Although garbage collection is as complete - as possible there is no guarantee that all + Although garbage collection is as complete + as possible there is no guarantee that all - events will have been - sent by the time that this function - returns. In particular, an object may be - prevented from being freed because it + events will have been + sent by the time that this function + returns. In particular, an object may be + prevented from being freed because it is awaiting finalization. new @@ -4960,7 +4960,7 @@ - These functions and data types were introduced in the original + These functions and data types were introduced in the original version 1.0 and have been superseded by more powerful and flexible versions @@ -4970,7 +4970,7 @@

    • - Allow access to primitive values (the value of Strings, arrays, + Allow access to primitive values (the value of Strings, arrays, and primitive fields)
    • @@ -5034,13 +5034,13 @@ Reference from an object to its class. - + Reference from an object to the value of one of its instance fields. For references of this kind the referrer_index parameter to the jvmtiObjectReferenceCallback is the index of the - the instance field. The index is based on the order of all the + the instance field. The index is based on the order of all the object's fields. This includes all fields of the directly declared static and instance fields in the class, and includes all fields (both public and private) fields declared in superclasses and superinterfaces. @@ -5063,7 +5063,7 @@ Reference from a class to its protection domain. - + Reference from a class to one of its interfaces. @@ -5072,7 +5072,7 @@ For references of this kind the referrer_index parameter to the jvmtiObjectReferenceCallback is the index of the - the static field. The index is based on the order of all the + the static field. The index is based on the order of all the object's fields. This includes all fields of the directly declared static and instance fields in the class, and includes all fields (both public and private) fields declared in superclasses and superinterfaces. @@ -5095,11 +5095,11 @@ - Continue the iteration. + Continue the iteration. If this is a reference iteration, follow the references of this object. - + - Continue the iteration. + Continue the iteration. If this is a reference iteration, ignore the references of this object. @@ -5125,9 +5125,9 @@ - The tag of the class of object (zero if the class is not tagged). - If the object represents a runtime class, - the class_tag is the tag + The tag of the class of object (zero if the class is not tagged). + If the object represents a runtime class, + the class_tag is the tag associated with java.lang.Class (zero if java.lang.Class is not tagged). @@ -5143,82 +5143,82 @@ The object tag value, or zero if the object is not tagged. To set the tag value to be associated with the object - the agent sets the jlong pointed to by the parameter. - - - - - - The user supplied data that was passed into the iteration function. - - - - - - - jvmtiIterationControl - Heap Root Object Callback - - Agent supplied callback function. - Describes (but does not pass in) an object that is a root for the purposes - of garbage collection. -

      - Return value should be JVMTI_ITERATION_CONTINUE to continue iteration, - JVMTI_ITERATION_IGNORE to continue iteration without pursuing - references from referree object or JVMTI_ITERATION_ABORT to stop iteration. -

      - See the heap callback - function restrictions. - - - - jvmtiHeapRootKind - - The kind of heap root. - - - - - - The tag of the class of object (zero if the class is not tagged). - If the object represents a runtime class, the class_tag is the tag - associated with java.lang.Class - (zero if java.lang.Class is not tagged). - - - - - - Size of the object (in bytes). See . - - - - - - The object tag value, or zero if the object is not tagged. - To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. - The user supplied data that was passed into the iteration function. - - - - + The user supplied data that was passed into the iteration function. + + + + + + + jvmtiIterationControl + Heap Root Object Callback + + Agent supplied callback function. + Describes (but does not pass in) an object that is a root for the purposes + of garbage collection. +

      + Return value should be JVMTI_ITERATION_CONTINUE to continue iteration, + JVMTI_ITERATION_IGNORE to continue iteration without pursuing + references from referree object or JVMTI_ITERATION_ABORT to stop iteration. +

      + See the heap callback + function restrictions. + + + + jvmtiHeapRootKind + + The kind of heap root. + + + + + + The tag of the class of object (zero if the class is not tagged). + If the object represents a runtime class, the class_tag is the tag + associated with java.lang.Class + (zero if java.lang.Class is not tagged). + + + + + + Size of the object (in bytes). See . + + + + + + The object tag value, or zero if the object is not tagged. + To set the tag value to be associated with the object + the agent sets the jlong pointed to by the parameter. + + + + + + The user supplied data that was passed into the iteration function. + + + + jvmtiIterationControl Stack Reference Object Callback Agent supplied callback function. - Describes (but does not pass in) an object on the stack that is a root for + Describes (but does not pass in) an object on the stack that is a root for the purposes of garbage collection.

      Return value should be JVMTI_ITERATION_CONTINUE to continue iteration, - JVMTI_ITERATION_IGNORE to continue iteration without pursuing + JVMTI_ITERATION_IGNORE to continue iteration without pursuing references from referree object or JVMTI_ITERATION_ABORT to stop iteration.

      See the heap callback @@ -5235,9 +5235,9 @@ - The tag of the class of object (zero if the class is not tagged). - If the object represents a runtime class, the class_tag is the tag - associated with java.lang.Class + The tag of the class of object (zero if the class is not tagged). + If the object represents a runtime class, the class_tag is the tag + associated with java.lang.Class (zero if java.lang.Class is not tagged). @@ -5264,7 +5264,7 @@ - The depth of the frame. + The depth of the frame. @@ -5282,7 +5282,7 @@ - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -5292,12 +5292,12 @@ jvmtiIterationControl Object Reference Callback - Agent supplied callback function. + Agent supplied callback function. Describes a reference from an object (the referrer) to another object (the referree).

      Return value should be JVMTI_ITERATION_CONTINUE to continue iteration, - JVMTI_ITERATION_IGNORE to continue iteration without pursuing + JVMTI_ITERATION_IGNORE to continue iteration without pursuing references from referree object or JVMTI_ITERATION_ABORT to stop iteration.

      See the heap callback @@ -5313,24 +5313,24 @@ - The tag of the class of referree object (zero if the class is not tagged). + The tag of the class of referree object (zero if the class is not tagged). If the referree object represents a runtime class, - the class_tag is the tag - associated with java.lang.Class + the class_tag is the tag + associated with java.lang.Class (zero if java.lang.Class is not tagged). - Size of the referree object (in bytes). + Size of the referree object (in bytes). See . - The referree object tag value, or zero if the object is not + The referree object tag value, or zero if the object is not tagged. To set the tag value to be associated with the object the agent sets the jlong pointed to by the parameter. @@ -5345,11 +5345,11 @@ - + For references of type JVMTI_REFERENCE_FIELD or JVMTI_REFERENCE_STATIC_FIELD the index - of the field in the referrer object. The index is based on the - order of all the object's fields - see JVMTI_REFERENCE_FIELD or JVMTI_REFERENCE_STATIC_FIELD @@ -5362,7 +5362,7 @@ For references of type JVMTI_REFERENCE_CONSTANT_POOL the index into the constant pool of the class - see - JVMTI_REFERENCE_CONSTANT_POOL for further + JVMTI_REFERENCE_CONSTANT_POOL for further description.

      For references of other kinds the referrer_index is @@ -5372,7 +5372,7 @@ - The user supplied data that was passed into the iteration function. + The user supplied data that was passed into the iteration function. @@ -5380,17 +5380,17 @@ Iterate Over Objects Reachable From Object - + This function iterates over all objects that are directly and indirectly reachable from the specified object. For each object A (known - as the referrer) with a reference to object B the specified + as the referrer) with a reference to object B the specified callback function is called to describe the object reference. The callback is called exactly once for each reference from a referrer; this is true even if there are reference cycles or multiple paths to the referrer. There may be more than one reference between a referrer and a referree, - These may be distinguished by the + These may be distinguished by the and . The callback for an object will always occur after the callback for @@ -5401,18 +5401,18 @@

      During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new - + @@ -5427,14 +5427,14 @@ The callback to be called to describe each object reference. - + NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -5447,9 +5447,9 @@ This function iterates over the root objects and all objects that are directly and indirectly reachable from the root objects. - The root objects comprise the set of system classes, - JNI globals, references from thread stacks, and other objects used as roots - for the purposes of garbage collection. + The root objects comprise the set of system classes, + JNI globals, references from thread stacks, and other objects used as roots + for the purposes of garbage collection.

      For each root the or callback is called. @@ -5462,7 +5462,7 @@ this is true even if there are reference cycles or multiple paths to the referrer. There may be more than one reference between a referrer and a referree, - These may be distinguished by the + These may be distinguished by the and . The callback for an object will always occur after the callback for @@ -5472,26 +5472,26 @@ references which are reported.

      Roots are always reported to the profiler before any object references - are reported. In other words, the + are reported. In other words, the callback will not be called until the appropriate callback has been called - for all roots. If the callback is + for all roots. If the callback is specified as NULL then this function returns after reporting the root objects to the profiler.

      During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new - + jvmtiHeapRootCallback @@ -5502,7 +5502,7 @@ JVMTI_HEAP_ROOT_JNI_GLOBAL, JVMTI_HEAP_ROOT_SYSTEM_CLASS, JVMTI_HEAP_ROOT_MONITOR, - JVMTI_HEAP_ROOT_THREAD, or + JVMTI_HEAP_ROOT_THREAD, or JVMTI_HEAP_ROOT_OTHER. @@ -5532,7 +5532,7 @@ NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -5542,14 +5542,14 @@ Iterate Over Heap - - Iterate over all objects in the heap. This includes both reachable and + + Iterate over all objects in the heap. This includes both reachable and unreachable objects.

      The parameter indicates the objects for which the callback function is called. If this parameter - is JVMTI_HEAP_OBJECT_TAGGED then the callback will only be - called for every object that is tagged. If the parameter is + is JVMTI_HEAP_OBJECT_TAGGED then the callback will only be + called for every object that is tagged. If the parameter is JVMTI_HEAP_OBJECT_UNTAGGED then the callback will only be for objects that are not tagged. If the parameter is JVMTI_HEAP_OBJECT_EITHER then the callback will be @@ -5558,11 +5558,11 @@

      During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new @@ -5591,7 +5591,7 @@ NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -5602,15 +5602,15 @@ Iterate Over Instances Of Class - Iterate over all objects in the heap that are instances of the specified class. - This includes direct instances of the specified class and + Iterate over all objects in the heap that are instances of the specified class. + This includes direct instances of the specified class and instances of all subclasses of the specified class. This includes both reachable and unreachable objects.

      The parameter indicates the objects for which the callback function is called. If this parameter - is JVMTI_HEAP_OBJECT_TAGGED then the callback will only be - called for every object that is tagged. If the parameter is + is JVMTI_HEAP_OBJECT_TAGGED then the callback will only be + called for every object that is tagged. If the parameter is JVMTI_HEAP_OBJECT_UNTAGGED then the callback will only be called for objects that are not tagged. If the parameter is JVMTI_HEAP_OBJECT_EITHER then the callback will be @@ -5619,11 +5619,11 @@

      During the execution of this function the state of the heap does not change: no objects are allocated, no objects are - garbage collected, and the state of objects (including - held values) does not change. - As a result, threads executing Java + garbage collected, and the state of objects (including + held values) does not change. + As a result, threads executing Java programming language code, threads attempting to resume the - execution of Java programming language code, and threads + execution of Java programming language code, and threads attempting to execute JNI functions are typically stalled. new @@ -5649,7 +5649,7 @@ The iterator function to be called for each - instance matching + instance matching the . @@ -5659,7 +5659,7 @@ NULL is passed as the user supplied data - User supplied data to be passed to the callback. + User supplied data to be passed to the callback. @@ -5672,19 +5672,19 @@ - These functions are used to retrieve or set the value of a local variable. + These functions are used to retrieve or set the value of a local variable. The variable is identified by the depth of the frame containing its - value and the variable's slot number within that frame. - The mapping of variables to - slot numbers can be obtained with the function + value and the variable's slot number within that frame. + The mapping of variables to + slot numbers can be obtained with the function . Get Local Variable - Object - This function can be used to retrieve the value of a local - variable whose type is Object or a subclass of Object. + This function can be used to retrieve the value of a local + variable whose type is Object or a subclass of Object. jvmdi @@ -5712,7 +5712,7 @@ - On return, points to the variable's value. + On return, points to the variable's value. @@ -5720,11 +5720,11 @@ Invalid slot. - + The variable type is not Object or a subclass of Object. - + Not a visible frame @@ -5736,7 +5736,7 @@ This function can be used to retrieve the value of the local object variable at slot 0 (the "this" object) from non-static frames. This function can retrieve the "this" object from - native method frames, whereas GetLocalObject() would + native method frames, whereas GetLocalObject() would return JVMTI_ERROR_OPAQUE_FRAME in those cases. new @@ -5759,7 +5759,7 @@ - On return, points to the variable's value. + On return, points to the variable's value. @@ -5772,10 +5772,10 @@ Get Local Variable - Int - This function can be used to retrieve the value of a local + This function can be used to retrieve the value of a local variable whose type is int, - short, char, byte, or - boolean. + short, char, byte, or + boolean. jvmdi @@ -5803,7 +5803,7 @@ - On return, points to the variable's value. + On return, points to the variable's value. @@ -5811,13 +5811,13 @@ Invalid slot. - - The variable type is not + + The variable type is not int, short, - char, byte, or + char, byte, or boolean. - + Not a visible frame @@ -5826,8 +5826,8 @@ Get Local Variable - Long - This function can be used to retrieve the value of a local - variable whose type is long. + This function can be used to retrieve the value of a local + variable whose type is long. jvmdi @@ -5855,7 +5855,7 @@ - On return, points to the variable's value. + On return, points to the variable's value. @@ -5863,10 +5863,10 @@ Invalid slot. - + The variable type is not long. - + Not a visible frame @@ -5875,8 +5875,8 @@ Get Local Variable - Float - This function can be used to retrieve the value of a local - variable whose type is float. + This function can be used to retrieve the value of a local + variable whose type is float. jvmdi @@ -5904,7 +5904,7 @@ - On return, points to the variable's value. + On return, points to the variable's value. @@ -5912,10 +5912,10 @@ Invalid slot. - + The variable type is not float. - + Not a visible frame @@ -5924,8 +5924,8 @@ Get Local Variable - Double - This function can be used to retrieve the value of a local - variable whose type is long. + This function can be used to retrieve the value of a local + variable whose type is long. jvmdi @@ -5953,7 +5953,7 @@ - On return, points to the variable's value. + On return, points to the variable's value. @@ -5961,10 +5961,10 @@ Invalid slot. - + The variable type is not double. - + Not a visible frame @@ -5973,8 +5973,8 @@ Set Local Variable - Object - This function can be used to set the value of a local - variable whose type is Object or a subclass of Object. + This function can be used to set the value of a local + variable whose type is Object or a subclass of Object. jvmdi @@ -6015,7 +6015,7 @@ Object or a subclass of Object. - The supplied is not compatible + The supplied is not compatible with the variable type. @@ -6027,10 +6027,10 @@ Set Local Variable - Int - This function can be used to set the value of a local + This function can be used to set the value of a local variable whose type is int, - short, char, byte, or - boolean. + short, char, byte, or + boolean. jvmdi @@ -6066,10 +6066,10 @@ Invalid slot. - - The variable type is not + + The variable type is not int, short, - char, byte, or + char, byte, or boolean. @@ -6081,8 +6081,8 @@ Set Local Variable - Long - This function can be used to set the value of a local - variable whose type is long. + This function can be used to set the value of a local + variable whose type is long. jvmdi @@ -6118,7 +6118,7 @@ Invalid slot. - + The variable type is not long. @@ -6130,8 +6130,8 @@ Set Local Variable - Float - This function can be used to set the value of a local - variable whose type is float. + This function can be used to set the value of a local + variable whose type is float. jvmdi @@ -6167,7 +6167,7 @@ Invalid slot. - + The variable type is not float. @@ -6179,8 +6179,8 @@ Set Local Variable - Double - This function can be used to set the value of a local - variable whose type is double. + This function can be used to set the value of a local + variable whose type is double. jvmdi @@ -6216,7 +6216,7 @@ Invalid slot. - + The variable type is not double. @@ -6267,7 +6267,7 @@ - + The designated bytecode already has a breakpoint. @@ -6304,7 +6304,7 @@ - + There's no breakpoint at the designated bytecode. @@ -6325,14 +6325,14 @@ by klass and field is about to be accessed. An event will be generated for each access of the field - until it is canceled with + until it is canceled with . Field accesses from Java programming language code or from JNI code are watched, fields modified by other means are not watched. Note that users should be aware that their own field accesses will trigger the watch. A field can only have one field access watch set. - Modification of a field is not considered an access--use + Modification of a field is not considered an access--use to monitor modifications. @@ -6356,7 +6356,7 @@ - + The designated field is already being watched for accesses. @@ -6365,8 +6365,8 @@ Clear Field Access Watch - Cancel a field access watch previously set by - , on the + Cancel a field access watch previously set by + , on the field specified by klass and field. @@ -6391,7 +6391,7 @@ - + The designated field is not being watched for accesses. @@ -6405,7 +6405,7 @@ by klass and field is about to be modified. An event will be generated for each modification of the field - until it is canceled with + until it is canceled with . Field modifications from Java programming language code or from JNI code are watched, fields modified by other means are not watched. @@ -6433,7 +6433,7 @@ - + The designated field is already being watched for modifications. @@ -6443,8 +6443,8 @@ Clear Field Modification Watch - Cancel a field modification watch previously set by - , on the + Cancel a field modification watch previously set by + , on the field specified by klass and field. @@ -6469,7 +6469,7 @@ - + The designated field is not being watched for modifications. @@ -6857,9 +6857,9 @@ class_count_ptr, and the array itself via classes_ptr.

      - Array classes of all types (including arrays of primitive types) are - included in the returned list. Primitive classes (for example, - java.lang.Integer.TYPE) are not included in this list. + Array classes of all types (including arrays of primitive types) are + included in the returned list. Primitive classes (for example, + java.lang.Integer.TYPE) are not included in this list. jvmdi @@ -6887,8 +6887,8 @@ Get Classloader Classes Returns an array of those classes for which this class loader has - been recorded as an initiating loader. Each - class in the returned array was created by this class loader, + been recorded as an initiating loader. Each + class in the returned array was created by this class loader, either by defining it directly or by delegation to another class loader. See .

      @@ -6930,14 +6930,14 @@ Get Class Signature - For the class indicated by klass, return the - JNI - type signature + For the class indicated by klass, return the + JNI + type signature and the generic signature of the class. For example, java.util.List is "Ljava/util/List;" and int[] is "[I" The returned name for primitive classes - is the type signature character of the corresponding primitive type. + is the type signature character of the corresponding primitive type. For example, java.lang.Integer.TYPE is "I". jvmdiClone @@ -6952,7 +6952,7 @@ - + the signature is not returned @@ -6962,14 +6962,14 @@ - + the generic signature is not returned On return, points to the generic signature of the class, encoded as a modified UTF-8 string. If there is no generic signature attribute for the class, then, - on return, points to NULL. + on return, points to NULL. @@ -6980,7 +6980,7 @@ Get Class Status - Get the status of the class. Zero or more of the following bits can be + Get the status of the class. Zero or more of the following bits can be set. @@ -6999,7 +6999,7 @@ Class is an array. If set, all other bits are zero. - Class is a primitive class (for example, java.lang.Integer.TYPE). + Class is a primitive class (for example, java.lang.Integer.TYPE). If set, all other bits are zero. @@ -7017,7 +7017,7 @@ - On return, points to the current state of this class as one or + On return, points to the current state of this class as one or more of the class status flags. @@ -7030,11 +7030,11 @@ Get Source File Name For the class indicated by klass, return the source file - name via source_name_ptr. The returned string - is a file name only and never contains a directory name. + name via source_name_ptr. The returned string + is a file name only and never contains a directory name.

      - For primitive classes (for example, java.lang.Integer.TYPE) - and for arrays this function returns + For primitive classes (for example, java.lang.Integer.TYPE) + and for arrays this function returns . jvmdi @@ -7057,7 +7057,7 @@ - + Class information does not include a source file name. This includes cases where the class is an array class or primitive class. @@ -7072,17 +7072,17 @@ via modifiers_ptr. Access flags are defined in .

      - If the class is an array class, then its public, private, and protected - modifiers are the same as those of its component type. For arrays of - primitives, this component type is represented by one of the primitive - classes (for example, java.lang.Integer.TYPE). + If the class is an array class, then its public, private, and protected + modifiers are the same as those of its component type. For arrays of + primitives, this component type is represented by one of the primitive + classes (for example, java.lang.Integer.TYPE).

      - If the class is a primitive class, its public modifier is always true, - and its protected and private modifiers are always false. + If the class is a primitive class, its public modifier is always true, + and its protected and private modifiers are always false.

      - If the class is an array class or a primitive class then its final - modifier is always true and its interface modifier is always false. - The values of its other modifiers are not determined by this specification. + If the class is an array class or a primitive class then its final + modifier is always true and its interface modifier is always false. + The values of its other modifiers are not determined by this specification. jvmdi @@ -7112,7 +7112,7 @@ For the class indicated by klass, return a count of methods via method_count_ptr and a list of - method IDs via methods_ptr. The method list contains + method IDs via methods_ptr. The method list contains constructors and static initializers as well as true methods. Only directly declared methods are returned (not inherited methods). An empty method list is returned for array classes and primitive classes @@ -7185,7 +7185,7 @@ - + is not prepared. @@ -7194,7 +7194,7 @@ Get Implemented Interfaces - Return the direct super-interfaces of this class. For a class, this + Return the direct super-interfaces of this class. For a class, this function returns the interfaces declared in its implements clause. For an interface, this function returns the interfaces declared in its extends clause. @@ -7225,7 +7225,7 @@ - + is not prepared. @@ -7234,10 +7234,10 @@ Get Class Version Numbers - For the class indicated by klass, + For the class indicated by klass, return the minor and major version numbers, as defined in - . + . new @@ -7253,7 +7253,7 @@ On return, points to the value of the - minor_version item of the + minor_version item of the Class File Format. Note: to be consistent with the Class File Format, the minor version number is the first parameter. @@ -7263,13 +7263,13 @@ On return, points to the value of the - major_version item of the + major_version item of the Class File Format. - + The class is a primitive or array class. @@ -7278,13 +7278,13 @@ Get Constant Pool - For the class indicated by klass, + For the class indicated by klass, return the raw bytes of the constant pool in the format of the - constant_pool item of + constant_pool item of . The format of the constant pool may differ between versions - of the Class File Format, so, the - minor and major + of the Class File Format, so, the + minor and major class version numbers should be checked for compatibility.

      @@ -7294,17 +7294,17 @@ more or fewer entries than the defining constant pool. Entries may be in a different order. The constant pool returned by GetConstantPool() will match the - constant pool used by + constant pool used by GetBytecodes(). That is, the bytecodes returned by GetBytecodes() will have constant pool indices which refer to constant pool entries returned by GetConstantPool(). - Note that since - and can change + Note that since + and can change the constant pool, the constant pool returned by this function - can change accordingly. Thus, the correspondence between + can change accordingly. Thus, the correspondence between GetConstantPool() and GetBytecodes() does not hold if there - is an intervening class retransformation or redefinition. + is an intervening class retransformation or redefinition. The value of a constant pool entry used by a given bytecode will match that of the defining class file (even if the indices don't match). Constant pool entries which are not used directly or indirectly by @@ -7342,13 +7342,13 @@ On return, points to the raw constant pool, that is the bytes - defined by the constant_pool item of the + defined by the constant_pool item of the Class File Format - + The class is a primitive or array class. @@ -7360,7 +7360,7 @@ Determines whether a class object reference represents an interface. The jboolean result is JNI_TRUE if the "class" is actually an interface, - JNI_FALSE otherwise. + JNI_FALSE otherwise. jvmdi @@ -7390,7 +7390,7 @@ Determines whether a class object reference represents an array. The jboolean result is JNI_TRUE if the class is an array, - JNI_FALSE otherwise. + JNI_FALSE otherwise. jvmdi @@ -7420,11 +7420,11 @@ Determines whether a class is modifiable. If a class is modifiable ( returns JNI_TRUE) the class can be - redefined with (assuming + redefined with (assuming the agent possesses the capability) or - retransformed with (assuming + retransformed with (assuming the agent possesses the capability). @@ -7433,7 +7433,7 @@ redefined nor retransformed.

      Primitive classes (for example, java.lang.Integer.TYPE), - array classes, and some implementation defined classes are never modifiable. + array classes, and some implementation defined classes are never modifiable.

      new @@ -7511,11 +7511,11 @@ Get Source Debug Extension - For the class indicated by klass, return the debug + For the class indicated by klass, return the debug extension via source_debug_extension_ptr. - The returned string + The returned string contains exactly the debug extension information present in the - class file of klass. + class file of klass. jvmdi @@ -7537,7 +7537,7 @@ - + Class information does not include a debug extension. @@ -7546,15 +7546,15 @@ Retransform Classes - This function facilitates the + This function facilitates the bytecode instrumentation of already loaded classes. To replace the class definition without reference to the existing - bytecodes, as one might do when recompiling from source for + bytecodes, as one might do when recompiling from source for fix-and-continue debugging, function should be used instead.

      - When classes are initially loaded or when they are + When classes are initially loaded or when they are redefined, the initial class file bytes can be transformed with the event. @@ -7562,16 +7562,16 @@ (whether or not a transformation has previously occurred). This retransformation follows these steps:

        -
      • starting from the initial class file bytes +
      • starting from the initial class file bytes
      • for each retransformation incapable agent which received a ClassFileLoadHook event during the previous - load or redefine, the bytes it returned + load or redefine, the bytes it returned (via the new_class_data parameter) - are reused as the output of the transformation; + are reused as the output of the transformation; note that this is equivalent to reapplying the previous transformation, unaltered. except that the ClassFileLoadHook event @@ -7589,7 +7589,7 @@
      See the event for more details.

      - The initial class file bytes represent the bytes passed to + The initial class file bytes represent the bytes passed to ClassLoader.defineClass or RedefineClasses (before any transformations were applied), however they may not exactly match them. @@ -7601,13 +7601,13 @@ order may not be preserved.

      Retransformation can cause new versions of methods to be installed. - Old method versions may become + Old method versions may become obsolete - The new method version will be used on new invokes. + The new method version will be used on new invokes. If a method has active stack frames, those active frames continue to - run the bytecodes of the original method version. -

      - This function does not cause any initialization except that which + run the bytecodes of the original method version. +

      + This function does not cause any initialization except that which would occur under the customary JVM semantics. In other words, retransforming a class does not cause its initializers to be run. The values of static fields will remain as they were @@ -7620,7 +7620,7 @@ All attributes are updated.

      Instances of the retransformed class are not affected -- fields retain their - previous values. + previous values. Tags on the instances are also unaffected.

      @@ -7629,8 +7629,8 @@ will be sent.

      The retransformation may change method bodies, the constant pool and attributes. - The retransformation must not add, remove or rename fields or methods, change the - signatures of methods, change modifiers, or change inheritance. + The retransformation must not add, remove or rename fields or methods, change the + signatures of methods, change modifiers, or change inheritance. These restrictions may be lifted in future versions. See the error return description below for information on error codes returned if an unsupported retransformation is attempted. @@ -7640,7 +7640,7 @@ If any error code is returned other than JVMTI_ERROR_NONE, none of the classes to be retransformed will have a new definition installed. When this function returns (with the error code of JVMTI_ERROR_NONE) - all of the classes to be retransformed will have their new definitions installed. + all of the classes to be retransformed will have their new definitions installed. new @@ -7663,7 +7663,7 @@ - One of the cannot be modified. + One of the cannot be modified. See . @@ -7676,7 +7676,7 @@ A retransformed class file is malformed (The VM would return a ClassFormatError). - The retransformed class file definitions would lead to a circular definition + The retransformed class file definitions would lead to a circular definition (the VM would return a ClassCircularityError). @@ -7739,22 +7739,22 @@ This function is used to replace the definition of a class with a new definition, as might be needed in fix-and-continue debugging. - Where the existing class file bytes are to be transformed, for + Where the existing class file bytes are to be transformed, for example in bytecode instrumentation, should be used.

      Redefinition can cause new versions of methods to be installed. - Old method versions may become + Old method versions may become obsolete - The new method version will be used on new invokes. + The new method version will be used on new invokes. If a method has active stack frames, those active frames continue to - run the bytecodes of the original method version. - If resetting of stack frames is desired, use + run the bytecodes of the original method version. + If resetting of stack frames is desired, use to pop frames with obsolete method versions.

      - This function does not cause any initialization except that which + This function does not cause any initialization except that which would occur under the customary JVM semantics. In other words, redefining a class does not cause its initializers to be run. The values of static fields will remain as they were @@ -7767,7 +7767,7 @@ All attributes are updated.

      Instances of the redefined class are not affected -- fields retain their - previous values. + previous values. Tags on the instances are also unaffected.

      @@ -7776,8 +7776,8 @@ will be sent (if enabled), but no other events will be sent.

      The redefinition may change method bodies, the constant pool and attributes. - The redefinition must not add, remove or rename fields or methods, change the - signatures of methods, change modifiers, or change inheritance. + The redefinition must not add, remove or rename fields or methods, change the + signatures of methods, change modifiers, or change inheritance. These restrictions may be lifted in future versions. See the error return description below for information on error codes returned if an unsupported redefinition is attempted. @@ -7788,7 +7788,7 @@ If any error code is returned other than JVMTI_ERROR_NONE, none of the classes to be redefined will have a new definition installed. When this function returns (with the error code of JVMTI_ERROR_NONE) - all of the classes to be redefined will have their new definitions installed. + all of the classes to be redefined will have their new definitions installed. jvmdi @@ -7827,7 +7827,7 @@ A new class file is malformed (The VM would return a ClassFormatError). - The new class file definitions would lead to a circular definition + The new class file definitions would lead to a circular definition (the VM would return a ClassCircularityError). @@ -7876,7 +7876,7 @@ For the object indicated by object, return via size_ptr the size of the object. This size is an implementation-specific approximation of - the amount of storage consumed by this object. + the amount of storage consumed by this object. It may include some or all of the object's overhead, and thus is useful for comparison within an implementation but not between implementations. @@ -7909,11 +7909,11 @@ For the object indicated by object, return via hash_code_ptr a hash code. This hash code could be used to maintain a hash table of object references, - however, on some implementations this can cause significant performance - impacts--in most cases - tags + however, on some implementations this can cause significant performance + impacts--in most cases + tags will be a more efficient means of associating information with objects. - This function guarantees + This function guarantees the same hash code value for a particular object throughout its life jvmdi @@ -7979,7 +7979,7 @@ Get information about the object's monitor. - The fields of the structure + The fields of the structure are filled in with information about usage of the monitor. Decide and then clarify suspend requirements. @@ -7999,7 +7999,7 @@ jvmtiMonitorUsage - On return, filled with monitor information for the + On return, filled with monitor information for the specified object. @@ -8014,7 +8014,7 @@ Return the list of object monitors.

      - Note: details about each monitor can be examined with + Note: details about each monitor can be examined with . new @@ -8025,7 +8025,7 @@ - On return, pointer to the number + On return, pointer to the number of monitors returned in monitors_ptr. @@ -8056,7 +8056,7 @@ .

      Field signatures are defined in the - JNI Specification + JNI Specification and are referred to as field descriptors in . @@ -8098,14 +8098,14 @@ - + the generic signature is not returned On return, points to the generic signature of the field, encoded as a modified UTF-8 string. If there is no generic signature attribute for the field, then, - on return, points to NULL. + on return, points to NULL. @@ -8187,7 +8187,7 @@ For the field indicated by klass and field, return a value indicating whether the field is synthetic via is_synthetic_ptr. - Synthetic fields are generated by the compiler but not present in the + Synthetic fields are generated by the compiler but not present in the original source code. jvmdi @@ -8241,7 +8241,7 @@ An original method version which is not equivalent to the new method version is called obsolete and is assigned a new method ID; the original method ID now refers to the new method version. - A method ID can be tested for obsolescence with + A method ID can be tested for obsolescence with . @@ -8253,8 +8253,8 @@ signature_ptr.

      Method signatures are defined in the - JNI Specification - and are referred to as method descriptors in + JNI Specification + and are referred to as method descriptors in . Note this is different than method signatures as defined in the Java Language Specification. @@ -8291,14 +8291,14 @@ - + the generic signature is not returned On return, points to the generic signature of the method, encoded as a modified UTF-8 string. If there is no generic signature attribute for the method, then, - on return, points to NULL. + on return, points to NULL. @@ -8379,7 +8379,7 @@ For the method indicated by method, return the number of local variable slots used by the method, including the local variables used to pass parameters to the - method on its invocation. + method on its invocation.

      See max_locals in . @@ -8465,7 +8465,7 @@ For the method indicated by method, return a table of source line number entries. The size of the table is returned via entry_count_ptr and the table itself is - returned via table_ptr. + returned via table_ptr. jvmdi @@ -8498,7 +8498,7 @@ - + Class information does not include line numbers. @@ -8510,10 +8510,10 @@ For the method indicated by method, return the beginning and ending addresses through start_location_ptr and end_location_ptr. In a - conventional byte code indexing scheme, + conventional byte code indexing scheme, start_location_ptr will always point to zero - and end_location_ptr - will always point to the byte code count minus one. + and end_location_ptr + will always point to the byte code count minus one. jvmdi @@ -8534,9 +8534,9 @@ - On return, points to the first location, or + On return, points to the first location, or -1 if location information is not available. - If the information is available and + If the information is available and returns then this will always be zero. @@ -8551,7 +8551,7 @@ - + Class information does not include method sizes. @@ -8571,7 +8571,7 @@ The length of the valid section for this local variable. - The last code array index where the local variable is valid + The last code array index where the local variable is valid is start_location + length. @@ -8596,7 +8596,7 @@ The local variable's generic signature, encoded as a modified UTF-8 string. - The value of this field will be NULL for any local + The value of this field will be NULL for any local variable which does not have a generic type. @@ -8722,7 +8722,7 @@ For the method indicated by method, return a value indicating whether the method is synthetic via is_synthetic_ptr. - Synthetic methods are generated by the compiler but not present in the + Synthetic methods are generated by the compiler but not present in the original source code. jvmdi @@ -8793,7 +8793,7 @@ This function modifies the failure handling of native method resolution by allowing retry with a prefix applied to the name. - When used with the + When used with the ClassFileLoadHook event, it enables native methods to be instrumented. @@ -8805,7 +8805,7 @@ native boolean foo(int x);

      - We could transform the class file (with the + We could transform the class file (with the ClassFileLoadHook event) so that this becomes: boolean foo(int x) { @@ -8823,28 +8823,28 @@ better but would make these examples less readable.

      The wrapper will allow data to be collected on the native - method call, but now the problem becomes linking up the - wrapped method with the native implementation. - That is, the method wrapped_foo needs to be + method call, but now the problem becomes linking up the + wrapped method with the native implementation. + That is, the method wrapped_foo needs to be resolved to the native implementation of foo, which might be: Java_somePackage_someClass_foo(JNIEnv* env, jint x)

      This function allows the prefix to be specified and the - proper resolution to occur. + proper resolution to occur. Specifically, when the standard resolution fails, the resolution is retried taking the prefix into consideration. There are two ways that resolution occurs, explicit resolution with the JNI function RegisterNatives - and the normal automatic resolution. For - RegisterNatives, the VM will attempt this + and the normal automatic resolution. For + RegisterNatives, the VM will attempt this association: method(foo) -> nativeImplementation(foo)

      When this fails, the resolution will be retried with - the specified prefix prepended to the method name, + the specified prefix prepended to the method name, yielding the correct resolution: method(wrapped_foo) -> nativeImplementation(foo) @@ -8854,7 +8854,7 @@ method(wrapped_foo) -> nativeImplementation(wrapped_foo)

      When this fails, the resolution will be retried with - the specified prefix deleted from the implementation name, + the specified prefix deleted from the implementation name, yielding the correct resolution: method(wrapped_foo) -> nativeImplementation(foo) @@ -8863,7 +8863,7 @@ resolution fails, native methods can be wrapped selectively.

      Since each environment is independent and - can do its own transformation of the bytecodes, more + can do its own transformation of the bytecodes, more than one layer of wrappers may be applied. Thus each environment needs its own prefix. Since transformations are applied in order, the prefixes, if applied, will @@ -8871,21 +8871,21 @@ The order of transformation application is described in the event. Thus if three environments applied - wrappers, foo might become + wrappers, foo might become $env3_$env2_$env1_foo. But if, say, the second environment did not apply a wrapper to - foo it would be just - $env3_$env1_foo. To be able to + foo it would be just + $env3_$env1_foo. To be able to efficiently determine the sequence of prefixes, an intermediate prefix is only applied if its non-native - wrapper exists. Thus, in the last example, even though + wrapper exists. Thus, in the last example, even though $env1_foo is not a native method, the - $env1_ prefix is applied since + $env1_ prefix is applied since $env1_foo exists.

      Since the prefixes are used at resolution time and since resolution may be arbitrarily delayed, a - native method prefix must remain set as long as there + native method prefix must remain set as long as there are corresponding prefixed native methods. new @@ -8918,7 +8918,7 @@ For a meta-agent that performs multiple independent class file transformations (for example as a proxy for another layer of agents) this function allows each transformation - to have its own prefix. + to have its own prefix. The prefixes are applied in the order supplied and are processed in the same manor as described for the application of prefixes from multiple environments @@ -8929,13 +8929,13 @@ disables prefixing in this environment.

      and this function - are the two ways to set the prefixes. - Calling SetNativeMethodPrefix with - a prefix is the same as calling this function with - of 1. - Calling SetNativeMethodPrefix with - NULL is the same as calling this function with - of 0. + are the two ways to set the prefixes. + Calling SetNativeMethodPrefix with + a prefix is the same as calling this function with + of 1. + Calling SetNativeMethodPrefix with + NULL is the same as calling this function with + of 0. new @@ -9014,16 +9014,16 @@ - + Not monitor owner - + Raw Monitor Enter - Gain exclusive ownership of a raw monitor. + Gain exclusive ownership of a raw monitor. The same thread may enter a monitor more then once. The thread must exit @@ -9064,7 +9064,7 @@ - + Not monitor owner @@ -9075,9 +9075,9 @@ Wait for notification of the raw monitor.

      - Causes the current thread to wait until either another thread calls - or - + Causes the current thread to wait until either another thread calls + or + for the specified raw monitor, or the specified timeout has elapsed. @@ -9102,10 +9102,10 @@ - + Not monitor owner - + Wait was interrupted, try again @@ -9151,7 +9151,7 @@ - + Not monitor owner @@ -9161,7 +9161,7 @@ Get Raw Monitor Use - The fields of the structure + The fields of the structure are filled in with information about usage of the raw monitor. new @@ -9178,7 +9178,7 @@ jvmtiMonitorUsage - On return, filled with monitor information for the + On return, filled with monitor information for the specified raw monitor. @@ -9192,7 +9192,7 @@ Return the list of raw monitors.

      - Note: details about each monitor can be examined with + Note: details about each monitor can be examined with . new @@ -9203,7 +9203,7 @@ - On return, pointer to the number + On return, pointer to the number of monitors returned in monitors_ptr. @@ -9223,13 +9223,13 @@ - Provides the ability to intercept and resend + Provides the ability to intercept and resend Java Native Interface (JNI) function calls by manipulating the JNI function table. - See JNI + See JNI Functions in the Java Native Interface Specification.

      - The following example illustrates intercepting the + The following example illustrates intercepting the NewGlobalRef JNI call in order to count reference creation. @@ -9274,19 +9274,19 @@ check that the example compiles and executes. - + Set JNI Function Table - Set the JNI function table + Set the JNI function table in all current and future JNI environments. As a result, all future JNI calls are directed to the specified functions. Use to get the function table to pass to this function. - For this function to take effect the the updated table entries must be + For this function to take effect the the updated table entries must be used by the JNI clients. Since the table is defined const some compilers may optimize - away the access to the table, thus preventing this function from taking + away the access to the table, thus preventing this function from taking effect. The table is copied--changes to the local copy of the table have no effect. @@ -9310,16 +9310,16 @@ - + Get JNI Function Table Get the JNI function table. The JNI function table is copied into allocated memory. - If + If has been called, the modified (not the original) function table is returned. - Only the function table is copied, no other aspects of the environment + Only the function table is copied, no other aspects of the environment are copied. See the examples above. @@ -9332,7 +9332,7 @@ jniNativeInterface - On return, *function_table + On return, *function_table points a newly allocated copy of the JNI function table. @@ -9354,13 +9354,13 @@ table have no effect. This is an atomic action, all callbacks are set at once. No events are sent before this function is called. - When an entry is NULL or when the event is beyond + When an entry is NULL or when the event is beyond no event is sent. - Details on events are + Details on events are described later in this document. An event must be enabled and have a callback in order to be - sent--the order in which this function and - + sent--the order in which this function and + are called does not affect the result. new @@ -9391,28 +9391,28 @@ Set Event Notification Mode - Control the generation of events. + Control the generation of events. - If is JVMTI_ENABLE, + If is JVMTI_ENABLE, the event will be enabled - If is JVMTI_DISABLE, + If is JVMTI_DISABLE, the event will be disabled If thread is NULL, - the event is enabled or disabled globally; otherwise, it is - enabled or disabled for a particular thread. - An event is generated for + the event is enabled or disabled globally; otherwise, it is + enabled or disabled for a particular thread. + An event is generated for a particular thread if it is enabled either at the thread or global - levels. + levels.

      See below for information on specific events.

      The following events cannot be controlled at the thread - level through this function. + level through this function.

      • @@ -9424,13 +9424,13 @@

      - Initially, no events are enabled at either the thread level + Initially, no events are enabled at either the thread level or the global level.

      Any needed capabilities (see Event Enabling Capabilities below) must be possessed before calling this function.

      - Details on events are + Details on events are described below. jvmdiClone @@ -9472,10 +9472,10 @@ is non-NULL and is not live (has not been started or is now dead). - thread level control was attempted on events which do not + thread level control was attempted on events which do not permit thread level control. - + The Required Event Enabling Capability is not possessed. @@ -9484,14 +9484,14 @@ Generate Events - Generate events to represent the current state of the VM. - For example, if is + Generate events to represent the current state of the VM. + For example, if is JVMTI_EVENT_COMPILED_METHOD_LOAD, a event will be sent for each currently compiled method. Methods that were loaded and now have been unloaded are not sent. - The history of what events have previously been sent does not - effect what events are sent by this function--for example, + The history of what events have previously been sent does not + effect what events are sent by this function--for example, all currently compiled methods will be sent each time this function is called.

      @@ -9502,14 +9502,14 @@ Attempts to execute Java programming language code or JNI functions may be paused until this function returns - so neither should be called from the thread sending the event. - This function returns only after the missed events have been + This function returns only after the missed events have been sent, processed and have returned. The event may be sent on a different thread than the thread on which the event occurred. - The callback for the event must be set with - + The callback for the event must be set with + and the event must be enabled with - + or the events will not occur. If the VM no longer has the information to generate some or all of the requested events, the events are simply not sent - @@ -9538,13 +9538,13 @@ - - is + + is JVMTI_EVENT_COMPILED_METHOD_LOAD and is false. - + is other than JVMTI_EVENT_COMPILED_METHOD_LOAD or JVMTI_EVENT_DYNAMIC_CODE_GENERATED. @@ -9566,63 +9566,63 @@ - Java programming language primitive type - byte. + Java programming language primitive type - byte. JNI type jbyte. - Java programming language primitive type - char. + Java programming language primitive type - char. JNI type jchar. - Java programming language primitive type - short. + Java programming language primitive type - short. JNI type jshort. - Java programming language primitive type - int. + Java programming language primitive type - int. JNI type . - Java programming language primitive type - long. + Java programming language primitive type - long. JNI type . - Java programming language primitive type - float. + Java programming language primitive type - float. JNI type . - Java programming language primitive type - double. + Java programming language primitive type - double. JNI type . - Java programming language primitive type - boolean. + Java programming language primitive type - boolean. JNI type . - Java programming language object type - java.lang.Object. + Java programming language object type - java.lang.Object. JNI type . Returned values are JNI local references and must be managed. - Java programming language object type - java.lang.Thread. + Java programming language object type - java.lang.Thread. type . Returned values are JNI local references and must be managed. - Java programming language object type - java.lang.Class. + Java programming language object type - java.lang.Class. JNI type . Returned values are JNI local references and must be managed. - Union of all Java programming language primitive and object types - + Union of all Java programming language primitive and object types - JNI type . Returned values which represent object types are JNI local references and must be managed. - Java programming language field identifier - + Java programming language field identifier - JNI type . - Java programming language method identifier - + Java programming language method identifier - JNI type . @@ -9757,7 +9757,7 @@ jvmtiParamInfo - Array of + Array of parameters (jvmtiEnv *jvmti_env excluded) @@ -9840,7 +9840,7 @@ jvmtiParamInfo - Array of + Array of parameters (jvmtiEnv *jvmti_env excluded) @@ -9876,7 +9876,7 @@ Extension Event This is the implementation-specific event. - The event handler is set with + The event handler is set with .

      Event handlers for extension events must be declared varargs to match this definition. @@ -9927,9 +9927,9 @@ Identifies which callback to set. - This index is the + This index is the - field of + field of . @@ -9939,18 +9939,18 @@ disable the event - If callback is non-NULL, + If callback is non-NULL, set callback to be the event callback function and enable the event. - + is not an - - returned by + returned by @@ -9962,30 +9962,30 @@ The capabilities functions allow you to change the - functionality available to --that is, - which + functionality available to --that is, + which functions can be called, what events can be generated, and what functionality these events and functions can provide.

      - The "Capabilities" section of each function and event describe which + The "Capabilities" section of each function and event describe which capabilities, if any, they are associated with. "Required Functionality" means it is available for use and no capabilities must be added to use it. "Optional Functionality" means the agent must possess the capability - before it can be used. + before it can be used. To possess a capability, the agent must add the capability. "Optional Features" describe capabilities which, if added, extend the feature set.

      - The potentially available capabilities of each implementation are different. + The potentially available capabilities of each implementation are different. Depending on the implementation, a capability:

      • may never be added
      • may be added in either the OnLoad or live phase in any environment
      • may be added only during the OnLoad phase
      • may be possessed by only one environment at a time
      • -
      • may be possessed by only one environment at a time, +
      • may be possessed by only one environment at a time, and only during the OnLoad phase
      • and so on ...
      @@ -9993,24 +9993,24 @@ time, and/or memory footprint. Note that the overhead of using a capability is completely different than the overhead of possessing a capability. Take single stepping as an example. When single stepping is on (that - is, when the event is enabled and thus actively sending events) - the overhead of sending and processing an event - on each instruction is huge in any implementation. - However, the overhead of possessing the capability may be small or large, + is, when the event is enabled and thus actively sending events) + the overhead of sending and processing an event + on each instruction is huge in any implementation. + However, the overhead of possessing the capability may be small or large, depending on the implementation. Also, when and if a capability is potentially available depends on the implementation. Some examples:
        -
      • One VM might perform all execution by compiling bytecodes into +
      • One VM might perform all execution by compiling bytecodes into native code and be unable to generate single step instructions. In this implementation the capability can not be added.
      • Another VM may be able to switch execution to a single stepping - interpreter at any time. In this implementation, having the capability has no + interpreter at any time. In this implementation, having the capability has no overhead and could be added at any time.
      • Yet another VM might be able to choose a bytecode compiling or single stepping capable interpreted execution engine at start up, but be unable to switch between them. - In this implementation the capability would need to be added + In this implementation the capability would need to be added during the OnLoad phase (before bytecode - execution begins) and would have a large impact on execution speed + execution begins) and would have a large impact on execution speed even if single stepping was never used.
      • Still another VM might be able to add an "is single stepping on" check into compiled bytecodes or a generated interpreter. Again in this implementation @@ -10019,30 +10019,30 @@

      Each environment - has its own set of capabilities. + has its own set of capabilities. Initially, that set is empty. Any desired capability must be added. - If possible, capabilities should be added during the OnLoad phase. For most - virtual machines certain capabilities require special set up for + If possible, capabilities should be added during the OnLoad phase. For most + virtual machines certain capabilities require special set up for the virtual machine and this set up must happen - during the OnLoad phase, before the virtual machine begins execution. + during the OnLoad phase, before the virtual machine begins execution. Once a capability is added, it can only be removed if explicitly relinquished by the environment.

      - The agent can, + The agent can, determine what capabilities this VM can potentially provide, add the capabilities to be used, release capabilities which are no longer needed, and - examine the currently available + examine the currently available capabilities. For example, a freshly started agent (in the OnLoad function) - wants to enable all possible capabilities. + wants to enable all possible capabilities. Note that, in general, this is not advisable as the agent may suffer a performance penalty for functionality it is not using. The code might look like this in C: @@ -10055,9 +10055,9 @@ err = (*jvmti)->AddCapabilities(jvmti, &capa); For example, if an agent wants to check if it can get - the bytecodes of a method (that is, it wants to check - if it previously added this capability and has not - relinquished it), the code might + the bytecodes of a method (that is, it wants to check + if it previously added this capability and has not + relinquished it), the code might look like this in C: jvmtiCapabilities capa; @@ -10065,13 +10065,13 @@ err = (*jvmti)->GetCapabilities(jvmti, &capa); if (err == JVMTI_ERROR_NONE) { - if (capa.can_get_bytecodes) { ... } } + if (capa.can_get_bytecodes) { ... } } - The functions in this category use this capabilities structure + The functions in this category use this capabilities structure which contains boolean flags corresponding to each capability: @@ -10099,14 +10099,14 @@ - Can test if a field or method is synthetic - + Can test if a field or method is synthetic - and - Can get information about ownership of monitors - + Can get information about ownership of monitors - @@ -10167,19 +10167,19 @@ - Can get exception thrown and + Can get exception thrown and exception catch events - Can set and thus get + Can set and thus get events - Can set and thus get + Can set and thus get events @@ -10206,65 +10206,65 @@ thread CPU time - Can generate method entry events on entering a method - Can generate method exit events on leaving a method - Can generate ClassFileLoadHook events for every loaded class. - Can generate events when a method is compiled or unloaded - Can generate events on monitor activity - Can generate events on VM allocation of an object - Can generate events when a native method is bound to its implementation - Can generate events when garbage collection begins or ends - Can generate events when the garbage collector frees an object @@ -10298,16 +10298,16 @@ Can retransform classes with . - In addition to the restrictions imposed by the specific + In addition to the restrictions imposed by the specific implementation on this capability (see the Capability section), - this capability must be set before the + this capability must be set before the event is enabled for the first time in this environment. - An environment that possesses this capability at the time that + An environment that possesses this capability at the time that ClassFileLoadHook is enabled for the first time is said to be retransformation capable. - An environment that does not possess this capability at the time that + An environment that does not possess this capability at the time that ClassFileLoadHook is enabled for the first time is said to be retransformation incapable. @@ -10322,7 +10322,7 @@ - Can generate events when the VM is unable to allocate memory from + Can generate events when the VM is unable to allocate memory from the Java platform heap. See . @@ -10355,11 +10355,11 @@ Get Potential Capabilities - Returns via the + Returns via the features that can potentially be possessed by this environment at this time. The returned capabilities differ from the complete set of capabilities - implemented by the VM in two cases: another environment possesses + implemented by the VM in two cases: another environment possesses capabilities that can only be possessed by one environment, or the current phase is live, and certain capabilities can only be added during the OnLoad phase. @@ -10402,7 +10402,7 @@ conditional implementations would be used or are even a good idea. The thought is that release documentation for the implementation would be the best means of exposing this information. - Unless new arguments are presented, I intend to remove this + Unless new arguments are presented, I intend to remove this function in the next revision.

      @@ -10412,15 +10412,15 @@ . The returned estimates are in percentage of additional overhead, thus a time impact of 100 mean the application might run - at half the speed. + at half the speed. The estimates are very rough approximations and are not guaranteed. Note also, that the estimates are of the impact of having the capability available--when and if it is used the impact may be much greater. - Estimates can be for a single capability or for a set of + Estimates can be for a single capability or for a set of capabilities. Note that the costs are not necessarily additive, - adding support for one capability might make another available - for free or conversely having two capabilities at once may + adding support for one capability might make another available + for free or conversely having two capabilities at once may have multiplicative impact. Estimates are relative to the current set of capabilities - that is, how much more impact given the currently possessed capabilities. @@ -10460,7 +10460,7 @@ - + The desired capabilities are not even potentially available. @@ -10470,7 +10470,7 @@ Add Capabilities - Set new capabilities by adding the capabilities + Set new capabilities by adding the capabilities whose values are set to one (1) in *. All previous capabilities are retained. @@ -10493,7 +10493,7 @@ - + The desired capabilities are not even potentially available. @@ -10547,7 +10547,7 @@ Get Capabilities - Returns via the optional + Returns via the optional features which this environment currently possesses. Each possessed capability is indicated by a one (1) in the corresponding field of the capabilities @@ -10578,16 +10578,16 @@ - - + + These functions provide timing information. - The resolution at which the time is updated is not specified. - They provides nanosecond precision, but not necessarily nanosecond accuracy. + The resolution at which the time is updated is not specified. + They provides nanosecond precision, but not necessarily nanosecond accuracy. Details about the timers, such as their maximum values, can be accessed with - the timer information functions. + the timer information functions. @@ -10621,7 +10621,7 @@ jvmtiTimerKind The kind of timer. - On a platform that does not distinguish between user and system time, JVMTI_TIMER_TOTAL_CPU is returned. @@ -10659,12 +10659,12 @@ Get Current Thread CPU Timer Information - Get information about the - timer. - The fields of the structure + Get information about the + timer. + The fields of the structure are filled in with details about the timer. This information is specific to the platform and the implementation of - and thus + and thus does not vary by thread nor does it vary during a particular invocation of the VM.

      @@ -10696,15 +10696,15 @@ Get Current Thread CPU Time - Return the CPU time utilized by the current thread. + Return the CPU time utilized by the current thread.

      Note that the function provides CPU time for any thread, including - the current thread. GetCurrentThreadCpuTime + the current thread. GetCurrentThreadCpuTime exists to support platforms which cannot - supply CPU time for threads other than the current + supply CPU time for threads other than the current thread or which have more accurate information for - the current thread (see + the current thread (see vs ). On many platforms this call will be equivalent to: @@ -10717,13 +10717,13 @@ Can get current thread CPU time.

      - If this capability is enabled after threads have started, + If this capability is enabled after threads have started, the implementation may choose any time up - to and including the time that the capability is enabled + to and including the time that the capability is enabled as the point where CPU time collection starts.

      - This capability must be potentially available on any - platform where + This capability must be potentially available on any + platform where can_get_thread_cpu_time is potentially available. @@ -10733,7 +10733,7 @@ On return, points to the CPU time used by this thread - in nanoseconds. + in nanoseconds. This is an unsigned value. If tested or printed as a jlong (signed value) it may appear to be a negative number. @@ -10746,12 +10746,12 @@ Get Thread CPU Timer Information - Get information about the - timer. - The fields of the structure + Get information about the + timer. + The fields of the structure are filled in with details about the timer. This information is specific to the platform and the implementation of - and thus + and thus does not vary by thread nor does it vary during a particular invocation of the VM.

      @@ -10783,19 +10783,19 @@ Get Thread CPU Time - Return the CPU time utilized by the specified thread. + Return the CPU time utilized by the specified thread.

      Get information about this timer with - . + . new Can get thread CPU time.

      - If this capability is enabled after threads have started, + If this capability is enabled after threads have started, the implementation may choose any time up - to and including the time that the capability is enabled + to and including the time that the capability is enabled as the point where CPU time collection starts. @@ -10810,7 +10810,7 @@ On return, points to the CPU time used by the specified thread - in nanoseconds. + in nanoseconds. This is an unsigned value. If tested or printed as a jlong (signed value) it may appear to be a negative number. @@ -10823,9 +10823,9 @@ Get Timer Information - Get information about the - timer. - The fields of the structure + Get information about the + timer. + The fields of the structure are filled in with details about the timer. This information will not change during a particular invocation of the VM. @@ -10848,7 +10848,7 @@ Get Time - Return the current value of the system timer, in nanoseconds. + Return the current value of the system timer, in nanoseconds.

      The value returned represents nanoseconds since some fixed but arbitrary time (perhaps in the future, so values may be @@ -10857,7 +10857,7 @@ how frequently values change.

      Get information about this timer with - . + . new @@ -10866,7 +10866,7 @@ - On return, points to the time in nanoseconds. + On return, points to the time in nanoseconds. This is an unsigned value. If tested or printed as a jlong (signed value) it may appear to be a negative number. @@ -10881,7 +10881,7 @@ Returns the number of processors available to the Java virtual machine.

      - This value may change during a particular invocation of the virtual machine. + This value may change during a particular invocation of the virtual machine. Applications that are sensitive to the number of available processors should therefore occasionally poll this property. @@ -10893,7 +10893,7 @@ On return, points to the maximum number of processors available to the - virtual machine; never smaller than one. + virtual machine; never smaller than one. @@ -10914,18 +10914,18 @@ Add To Bootstrap Class Loader Search - This function can be used to cause instrumentation classes to be defined by the + This function can be used to cause instrumentation classes to be defined by the bootstrap class loader. See . After the bootstrap - class loader unsuccessfully searches for a class, the specified platform-dependent - search path will be searched as well. Only one segment may be specified in - the . This function may be called multiple times to add multiple segments, + class loader unsuccessfully searches for a class, the specified platform-dependent + search path will be searched as well. Only one segment may be specified in + the . This function may be called multiple times to add multiple segments, the segments will be searched in the order that this function was called.

      - In the OnLoad phase the function may be used to specify any platform-dependent + In the OnLoad phase the function may be used to specify any platform-dependent search path segment to be searched after the bootstrap class loader unsuccessfully searches for a class. The segment is typically a directory or JAR file. -

      +

      In the live phase the may be used to specify any platform-dependent path to a JAR file. The agent should take care that the JAR file does not @@ -10953,7 +10953,7 @@ - + is an invalid path. In the live phase, anything other than an existing JAR file is an invalid path. @@ -10965,15 +10965,15 @@ This function can be used to cause instrumentation classes to be defined by the system class loader. See . - After the class loader unsuccessfully searches for a class, the specified platform-dependent search - path will be searched as well. Only one segment may be specified in the - . This function may be called multiple times to add multiple segments, the + After the class loader unsuccessfully searches for a class, the specified platform-dependent search + path will be searched as well. Only one segment may be specified in the + . This function may be called multiple times to add multiple segments, the segments will be searched in the order that this function was called.

      - In the OnLoad phase the function may be used to specify any platform-dependent + In the OnLoad phase the function may be used to specify any platform-dependent search path segment to be searched after the system class loader unsuccessfully searches for a class. The segment is typically a directory or JAR file. -

      +

      In the live phase the is a platform-dependent path to a JAR file to be searched after the system class loader unsuccessfully searches for a class. The agent should @@ -10981,9 +10981,9 @@ defined by the system class loader for the purposes of instrumentation.

      In the live phase the system class loader supports adding a JAR file to be searched if - the system class loader implements a method name appendToClassPathForInstrumentation - which takes a single parameter of type java.lang.String. The method is not required - to have public access. + the system class loader implements a method name appendToClassPathForInstrumentation + which takes a single parameter of type java.lang.String. The method is not required + to have public access.

      specifies that a subsequent attempt to resolve a symbolic reference that the Java virtual machine has previously unsuccessfully attempted @@ -11012,7 +11012,7 @@ Operation not supported by the system class loader. - + @@ -11028,7 +11028,7 @@ Get System Properties - The list of VM system property keys which may be used with + The list of VM system property keys which may be used with is returned. It is strongly recommended that virtual machines provide the following property keys: @@ -11043,15 +11043,15 @@ Provides access to system properties defined by and used by the VM. Properties set on the command-line are included. - This allows getting and setting of these properties + This allows getting and setting of these properties before the VM even begins executing bytecodes. - Since this is a VM view of system properties, the set of available + Since this is a VM view of system properties, the set of available properties will usually be different than that in java.lang.System.getProperties. - JNI method invocation may be used to access + JNI method invocation may be used to access java.lang.System.getProperties.

      - The set of properties may grow during execution. + The set of properties may grow during execution. new @@ -11066,7 +11066,7 @@ - On return, points to an array of property keys, encoded as + On return, points to an array of property keys, encoded as modified UTF-8 strings. @@ -11078,25 +11078,25 @@ Get System Property - Return a VM system property value given the property key. + Return a VM system property value given the property key.

      The function returns the set of property keys which may be used. The properties which can be retrieved may grow during execution.

      - Since this is a VM view of system properties, the values - of properties may differ from that returned by + Since this is a VM view of system properties, the values + of properties may differ from that returned by java.lang.System.getProperty(String). - A typical VM might copy the values of the VM system + A typical VM might copy the values of the VM system properties into the Properties held by java.lang.System during the initialization of that class. Thereafter any changes to the VM system - properties (with ) + properties (with ) or the java.lang.System system properties (with java.lang.System.setProperty(String,String)) would cause the values to diverge. - JNI method invocation may be used to access + JNI method invocation may be used to access java.lang.System.getProperty(String). new @@ -11119,7 +11119,7 @@ - + This property is not available. Use to find available properties. @@ -11129,7 +11129,7 @@ Set System Property - Set a VM system property value. + Set a VM system property value.

      The function returns the set of property keys, some of these may be settable. @@ -11161,7 +11161,7 @@ - + This property is not available or is not writeable. @@ -11177,7 +11177,7 @@ Get Phase - Return the current phase of VM execution. + Return the current phase of VM execution. The phases proceed in sequence: @@ -11193,7 +11193,7 @@ VMStart event. - Start phase: when the VMStart event + Start phase: when the VMStart event is sent and until the VMInit event is sent. @@ -11222,8 +11222,8 @@

      Most events are sent only in the live phase. The following events operate in others phases: - - + + new @@ -11245,7 +11245,7 @@ Shutdown a connection created with JNI GetEnv (see Environments). - Dispose of any resources held by the environment. + Dispose of any resources held by the environment. What resources are reclaimed? What is undone? Breakpoints,watchpoints removed? @@ -11255,7 +11255,7 @@ Memory allocated by this environment via calls to functions is not released, this can be done explicitly by the agent by calling . - Raw monitors created by this environment are not destroyed, + Raw monitors created by this environment are not destroyed, this can be done explicitly by the agent by calling . The state of threads waiting on raw monitors created by this environment @@ -11294,7 +11294,7 @@ This value is NULL unless set with this function. Agents can allocate memory in which they store environment specific information. By setting environment-local storage it can then be - accessed with + accessed with .

      Called by the agent to set the value of the @@ -11307,10 +11307,10 @@ - - - value is set to NULL - + + + value is set to NULL + The value to be entered into the environment-local storage. @@ -11324,7 +11324,7 @@ Get Environment Local Storage Called by the agent to get the value of the environment-local - storage. + storage. new @@ -11333,10 +11333,10 @@ - Pointer through which the value of the environment local + Pointer through which the value of the environment local storage is returned. If environment-local storage has not been set with - returned + returned pointer is NULL. @@ -11349,7 +11349,7 @@ Get Version Number Return the version via version_ptr. - The return value is the version identifier. + The return value is the version identifier. The version identifier includes major, minor and micro version as well as the interface type. @@ -11362,10 +11362,10 @@ - Mask to extract interface type. + Mask to extract interface type. The value of the version returned by this function masked with JVMTI_VERSION_MASK_INTERFACE_TYPE is always - JVMTI_VERSION_INTERFACE_JVMTI + JVMTI_VERSION_INTERFACE_JVMTI since this is a function. @@ -11409,11 +11409,11 @@ Get Error Name - Return the symbolic name for an - error code. -

      - For example - GetErrorName(env, JVMTI_ERROR_NONE, &err_name) + Return the symbolic name for an + error code. +

      + For example + GetErrorName(env, JVMTI_ERROR_NONE, &err_name) would return in err_name the string "JVMTI_ERROR_NONE". @@ -11459,7 +11459,7 @@ Control verbose output. - This is the output which typically is sent to stderr. + This is the output which typically is sent to stderr. new @@ -11488,18 +11488,18 @@ Although the greatest functionality is achieved with location information referencing the virtual machine bytecode index, the definition of - jlocation has intentionally been left unconstrained to allow VM + jlocation has intentionally been left unconstrained to allow VM implementations that do not have this information.

      This function describes the representation of jlocation used in this VM. - If the returned format is , + If the returned format is , jlocations can be used as in indices into the array returned by - . + . - jlocation values represent virtual machine - bytecode indices--that is, offsets into the + jlocation values represent virtual machine + bytecode indices--that is, offsets into the virtual machine code for a method. @@ -11534,16 +11534,16 @@ Every function returns a jvmtiError error code.

      - It is the responsibility of the agent to call functions with + It is the responsibility of the agent to call functions with valid parameters and in the proper context (calling thread is attached, - phase is correct, etc.). - Detecting some error conditions may be difficult, inefficient, or + phase is correct, etc.). + Detecting some error conditions may be difficult, inefficient, or impossible for an implementation. - The errors listed in + The errors listed in Function Specific Required Errors must be detected by the implementation. All other errors represent the recommended response to the error - condition. + condition. @@ -11559,7 +11559,7 @@ Pointer is unexpectedly NULL. - The function attempted to allocate memory and no more memory was + The function attempted to allocate memory and no more memory was available for allocation. @@ -11651,7 +11651,7 @@ The following errors are returned by some functions. They are returned in the event of invalid parameters passed by the - agent or usage in an invalid context. + agent or usage in an invalid context. An implementation is not required to detect these errors. @@ -11726,7 +11726,7 @@ declared in the old class version. - The class name defined in the new class file is + The class name defined in the new class file is different from the name in the old class object. @@ -11745,33 +11745,33 @@ programs.

      To handle events, designate a set of callback functions with - . - For each event the corresponding callback function will be + . + For each event the corresponding callback function will be called. Arguments to the callback function provide additional - information about the event. + information about the event.

      - The callback function is usually called from within an application - thread. The implementation does not + The callback function is usually called from within an application + thread. The implementation does not queue events in any way. This means - that event callback functions must be written - carefully. Here are some general guidelines. See + that event callback functions must be written + carefully. Here are some general guidelines. See the individual event descriptions for further suggestions.

        -
      • Any exception thrown during the execution of an event callback can +
      • Any exception thrown during the execution of an event callback can overwrite any current pending exception in the current application thread. Care must be taken to preserve a pending exception when an event callback makes a JNI call that might generate an exception.
      • Event callback functions must be re-entrant. The implementation does - not queue events. If an agent needs to process events one at a time, it - can use a raw monitor inside the + not queue events. If an agent needs to process events one at a time, it + can use a raw monitor inside the event callback functions to serialize event processing.
      • Event callback functions that execute JNI's FindClass function to load - classes need to note that FindClass locates the class loader associated + classes need to note that FindClass locates the class loader associated with the current native method. For the purposes of class loading, an event callback that includes a JNI environment as a parameter to the callback will treated as if it is a native call, where the native method @@ -11779,8 +11779,8 @@

      - Some events identify objects with JNI references. - All references + Some events identify objects with JNI references. + All references in events are JNI local references and will become invalid after the event callback returns. Unless stated otherwise, memory referenced by pointers sent in event @@ -11791,13 +11791,13 @@ Events are sent at the time they occur. The specification for each event includes the set of phases in which it can be sent; - if an event triggering activity occurs during another phase, no event - is sent. + if an event triggering activity occurs during another phase, no event + is sent.

      A thread that generates an event does not change its execution status (for example, the event does not cause the thread to be suspended). If an agent wishes the event to result in suspension, then the agent - is responsible for explicitly suspending the thread with + is responsible for explicitly suspending the thread with .

      If an event is enabled in multiple environments, the event will be sent @@ -11810,26 +11810,26 @@

      • If the event requires a capability, that capability must - be added with + be added with .
      • - A callback for the event must be set with + A callback for the event must be set with .
      • The event must be enabled with - . + .
      - In many situations it is possible for multiple events to occur - at the same location in one thread. When this happens, all the events + In many situations it is possible for multiple events to occur + at the same location in one thread. When this happens, all the events are reported through the event callbacks in the order specified in this section.

      - If the current location is at the entry point of a method, the + If the current location is at the entry point of a method, the event is reported before any other event at the current location in the same thread.

      @@ -11839,39 +11839,39 @@ exceptionCatch event is reported before any other event at the current location in the same thread.

      - If a singleStep event or - breakpoint event is triggered at the - current location, the event is defined to occur - immediately before the code at the current location is executed. - These events are reported before any events which are triggered - by the execution of code at the current location in the same - thread (specifically: + If a singleStep event or + breakpoint event is triggered at the + current location, the event is defined to occur + immediately before the code at the current location is executed. + These events are reported before any events which are triggered + by the execution of code at the current location in the same + thread (specifically: exception, fieldAccess, and fieldModification). - If both a step and breakpoint event are triggered for the same thread and + If both a step and breakpoint event are triggered for the same thread and location, the step event is reported before the breakpoint event.

      If the current location is the exit point of a method (that is, the last - location before returning to the caller), the - event and + location before returning to the caller), the + event and the event (if requested) are reported after all other events at the current location in the same - thread. There is no specified ordering of these two events + thread. There is no specified ordering of these two events with respect to each other.

      Co-located events can be triggered during the processing of some other event by the agent at the same location in the same thread. - If such an event, of type y, is triggered during the processing of - an event of type x, and if x - precedes y in the ordering specified above, the co-located event + If such an event, of type y, is triggered during the processing of + an event of type x, and if x + precedes y in the ordering specified above, the co-located event y is reported for the current thread and location. If x does not precede y, y is not reported for the current thread and location. - For example, if a breakpoint is set at the current location + For example, if a breakpoint is set at the current location during the processing of , - that breakpoint will be reported before the thread moves off the current + that breakpoint will be reported before the thread moves off the current location. -

      The following events are never considered to be co-located with +

      The following events are never considered to be co-located with other events.

      • @@ -11887,7 +11887,7 @@ The event callback structure below is used to specify the handler function for events. It is set with the - function. + function. Single step events allow the agent to trace thread execution at the finest granularity allowed by the VM. A single step event is - generated whenever a thread reaches a new location. - Typically, single step events represent the completion of one VM - instruction as defined in . However, some implementations - may define locations differently. In any case the + generated whenever a thread reaches a new location. + Typically, single step events represent the completion of one VM + instruction as defined in . However, some implementations + may define locations differently. In any case the method and location parameters uniquely identify the current location and allow - the mapping to source file and line number when that information is + the mapping to source file and line number when that information is available.

        No single step events are generated from within native methods. @@ -11910,7 +11910,7 @@ - + JNIEnv @@ -11953,14 +11953,14 @@ designated as a breakpoint with . The method and location parameters uniquely identify the current location and allow - the mapping to source file and line number when that information is + the mapping to source file and line number when that information is available. jvmdi - + JNIEnv @@ -12000,18 +12000,18 @@ id="FieldAccess" const="JVMTI_EVENT_FIELD_ACCESS" filtered="thread" num="63"> Field access events are generated whenever a thread accesses - a field that was designated as a watchpoint + a field that was designated as a watchpoint with . - The method and location + The method and location parameters uniquely identify the current location and allow - the mapping to source file and line number when that information is - available. + the mapping to source file and line number when that information is + available. jvmdi - + JNIEnv @@ -12070,18 +12070,18 @@ id="FieldModification" const="JVMTI_EVENT_FIELD_MODIFICATION" filtered="thread" num="64"> Field modification events are generated whenever a thread modifies - a field that was designated as a watchpoint + a field that was designated as a watchpoint with . - The method and location + The method and location parameters uniquely identify the current location and allow - the mapping to source file and line number when that information is - available. + the mapping to source file and line number when that information is + available. jvmdi - + JNIEnv @@ -12151,25 +12151,25 @@ - Frame pop events are generated upon exit from a single method + Frame pop events are generated upon exit from a single method in a single frame as specified in a call to . This is true whether termination is caused by executing its return instruction - or by throwing an exception to its caller + or by throwing an exception to its caller (see ). - However, frame pops caused by the + However, frame pops caused by the function are not reported.

        The location reported by - identifies the executable location in the returning method, - immediately prior to the return. + identifies the executable location in the returning method, + immediately prior to the return. jvmdi - + JNIEnv @@ -12209,24 +12209,24 @@ - Method entry events are generated upon entry of Java + Method entry events are generated upon entry of Java programming language methods (including native methods).

        The location reported by identifies the initial executable location in - the method. + the method.

        Enabling method entry or exit events will significantly degrade performance on many platforms and is thus not advised for performance critical usage (such as profiling). - Bytecode instrumentation should be + Bytecode instrumentation should be used in these cases. jvmdi - + JNIEnv @@ -12259,25 +12259,25 @@ - Method exit events are generated upon exit from Java + Method exit events are generated upon exit from Java programming language methods (including native methods). This is true whether termination is caused by executing its return instruction - or by throwing an exception to its caller + or by throwing an exception to its caller (see ).

        The method field uniquely identifies the - method being entered or exited. The frame field provides + method being entered or exited. The frame field provides access to the stack frame for the method.

        The location reported by - identifies the executable location in the returning method - immediately prior to the return. + identifies the executable location in the returning method + immediately prior to the return.

        Enabling method entry or exit events will significantly degrade performance on many platforms and is thus not advised for performance critical usage (such as profiling). - Bytecode instrumentation should be + Bytecode instrumentation should be used in these cases. jvmdi @@ -12322,7 +12322,7 @@ The return value of the method being exited. - Undefined and should not be used if + Undefined and should not be used if is true. @@ -12333,18 +12333,18 @@ - A Native Method Bind event is sent when a VM binds a + A Native Method Bind event is sent when a VM binds a Java programming language native method - to the address of a function that implements the native method. + to the address of a function that implements the native method. This will occur when the native method is called for the first time and also occurs when the JNI function RegisterNatives is called. This event allows the bind to be redirected to an agent-specified - proxy function. + proxy function. This event is not sent when the native method is unbound. - Typically, this proxy function will need to be specific to a + Typically, this proxy function will need to be specific to a particular method or, to handle the general case, automatically - generated assembly code, since after instrumentation code is - executed the function at the original binding + generated assembly code, since after instrumentation code is + executed the function at the original binding address will usually be invoked. The original binding can be restored or the redirection changed by use of the JNI function RegisterNatives. @@ -12363,7 +12363,7 @@ The JNI environment of the event (current) thread - Will be NULL if sent during the primordial + Will be NULL if sent during the primordial phase. @@ -12407,7 +12407,7 @@ id="Exception" const="JVMTI_EVENT_EXCEPTION" filtered="thread" num="58"> Exception events are generated whenever an exception is first detected - in a Java programming language method. + in a Java programming language method. Where "exception" means any java.lang.Throwable. The exception may have been thrown by a Java programming language or native method, but in the case of native methods, the event is not generated @@ -12416,20 +12416,20 @@ no exception event is generated.

        The method and location - parameters uniquely identify the current location + parameters uniquely identify the current location (where the exception was detected) and allow - the mapping to source file and line number when that information is + the mapping to source file and line number when that information is available. The exception field identifies the thrown exception object. The catch_method and catch_location identify the location of the catch clause, if any, that handles the thrown exception. If there is no such catch clause, each field is set to 0. There is no guarantee that the thread will ever reach this catch clause. If there are native methods on the call stack - between the throw location and the catch clause, the exception may + between the throw location and the catch clause, the exception may be reset by one of those native methods. Similarly, exceptions that are reported as uncaught (catch_klass et al. set to 0) may in fact be caught by native code. - Agents can check for these occurrences by monitoring + Agents can check for these occurrences by monitoring events. Note that finally clauses are implemented as catch and re-throw. Therefore they will be reported in the catch location. @@ -12438,7 +12438,7 @@ - + JNIEnv @@ -12505,18 +12505,18 @@ Where "exception" means any java.lang.Throwable. If the exception is caught in a Java programming language method, the event is generated when the catch clause is reached. If the exception is caught in a native - method, the event is generated as soon as control is returned to a Java programming language + method, the event is generated as soon as control is returned to a Java programming language method. Exception catch events are generated for any exception for which a throw was detected in a Java programming language method. Note that finally clauses are implemented as catch and re-throw. Therefore they will generate exception catch events.

        The method and location - parameters uniquely identify the current location - and allow the mapping to source file and line number when that information is - available. For exceptions caught in a Java programming language method, the + parameters uniquely identify the current location + and allow the mapping to source file and line number when that information is + available. For exceptions caught in a Java programming language method, the exception object identifies the exception object. Exceptions - caught in native methods are not necessarily available by the time the + caught in native methods are not necessarily available by the time the exception catch is reported, so the exception field is set to NULL. @@ -12524,7 +12524,7 @@ - + JNIEnv @@ -12570,11 +12570,11 @@ id="ThreadStart" const="JVMTI_EVENT_THREAD_START" num="52" phase="start"> Thread start events are generated by a new thread before its initial - method executes. + method executes.

        A thread may be listed in the array returned by - before its thread start event is generated. + before its thread start event is generated. It is possible for other events to be generated on a thread before its thread start event.

        @@ -12583,7 +12583,7 @@ jvmdi - + JNIEnv @@ -12602,14 +12602,14 @@ + id="ThreadEnd" const="JVMTI_EVENT_THREAD_END" filtered="thread" num="53" phase="start"> Thread end events are generated by a terminating thread - after its initial method has finished execution. + after its initial method has finished execution.

        A thread may be listed in the array returned by - after its thread end event is generated. + after its thread end event is generated. No events are generated on a thread after its thread end event.

        @@ -12618,7 +12618,7 @@ jvmdi - + JNIEnv @@ -12641,15 +12641,15 @@ A class load event is generated when a class is first loaded. The order of class load events generated by a particular thread are guaranteed - to match the order of class loading within that thread. + to match the order of class loading within that thread. Array class creation does not generate a class load event. - The creation of a primitive class (for example, java.lang.Integer.TYPE) + The creation of a primitive class (for example, java.lang.Integer.TYPE) does not generate a class load event.

        This event is sent at an early stage in loading the class. As a result the class should be used carefully. Note, for example, that methods and fields are not yet loaded, so queries for methods, - fields, subclasses, and so on will not give correct results. + fields, subclasses, and so on will not give correct results. See "Loading of Classes and Interfaces" in the Java Language Specification. For most purposes the event will @@ -12658,7 +12658,7 @@ jvmdi - + JNIEnv @@ -12687,7 +12687,7 @@ id="ClassUnload" const="JVMTI_EVENT_CLASS_UNLOAD" num="57"> A class unload event is generated when the class is about to be unloaded. - Class unload events take place during garbage collection and must be + Class unload events take place during garbage collection and must be handled extremely carefully. The garbage collector holds many locks and has suspended all other threads, so the event handler cannot depend on the ability to acquire any locks. The class unload event handler should @@ -12704,7 +12704,7 @@ jvmdi - + JNIEnv @@ -12733,16 +12733,16 @@ id="ClassPrepare" const="JVMTI_EVENT_CLASS_PREPARE" filtered="thread" phase="start" num="56"> A class prepare event is generated when class preparation is complete. - At this point, class fields, methods, and implemented interfaces are - available, and no code from the class has been executed. Since array - classes never have fields or methods, class prepare events are not - generated for them. Class prepare events are not generated for - primitive classes (for example, java.lang.Integer.TYPE). + At this point, class fields, methods, and implemented interfaces are + available, and no code from the class has been executed. Since array + classes never have fields or methods, class prepare events are not + generated for them. Class prepare events are not generated for + primitive classes (for example, java.lang.Integer.TYPE). jvmdi - + JNIEnv @@ -12771,14 +12771,14 @@ This event is sent when the VM obtains class file data, but before it constructs - the in-memory representation for that class. - This event is also sent when the class is being modified by the + the in-memory representation for that class. + This event is also sent when the class is being modified by the function or the function, called in any environment. The agent can instrument the existing class file data sent by the VM to include profiling/debugging hooks. - See the description of + See the description of bytecode instrumentation for usage information.

        @@ -12788,28 +12788,28 @@ can_generate_all_class_hook_events are enabled then this event may be sent in the primordial phase. - Otherwise, this event may be sent before the VM is initialized (the start + Otherwise, this event may be sent before the VM is initialized (the start phase). Some classes might not be compatible with the function (eg. ROMized classes or implementation defined classes) and this event will not be generated for these classes.

        - The agent must allocate the space for the modified + The agent must allocate the space for the modified class file data buffer - using the memory allocation function + using the memory allocation function because the VM is responsible for freeing the new class file data buffer using .

        - If the agent wishes to modify the class file, it must set + If the agent wishes to modify the class file, it must set new_class_data to point to the newly instrumented class file data buffer and set - new_class_data_len to the length of that + new_class_data_len to the length of that buffer before returning from this call. If no modification is desired, the agent simply does not set new_class_data. If multiple agents have enabled this event the results are chained. That is, if - new_class_data has been set, it becomes the + new_class_data has been set, it becomes the class_data for the next agent.

        When handling a class load in the live phase, then the @@ -12827,13 +12827,13 @@

      • retransformation incapable - environments, in the + environments, in the order in which they were created
      • retransformation capable - environments, in the + environments, in the order in which they were created
      @@ -12869,7 +12869,7 @@ - The class loader loading the class. + The class loader loading the class. NULL if the bootstrap class loader. @@ -12972,7 +12972,7 @@ with other events, but the preceding events should be handled carefully, if at all, because the VM has not completed its initialization. The thread start event for the - main application thread is guaranteed not to occur until after the + main application thread is guaranteed not to occur until after the handler for the VM initialization event returns.

      In the case of VM start-up failure, this event will not be sent. @@ -13001,7 +13001,7 @@ - The VM death event notifies the agent of the termination of the VM. + The VM death event notifies the agent of the termination of the VM. No events will occur after the VMDeath event.

      In the case of VM start-up failure, this event will not be sent. @@ -13032,7 +13032,7 @@ followed by a new CompiledMethodLoad event. Note that a single method may have multiple compiled forms, and that this event will be sent for each form. - Note also that several methods may be inlined into a single + Note also that several methods may be inlined into a single address range, and that this event will be sent for each method.

      These events can be sent after their initial occurrence with @@ -13049,7 +13049,7 @@ - Corresponding location. See + Corresponding location. See for the meaning of location. @@ -13095,7 +13095,7 @@ jvmtiAddrLocationMap Map from native addresses to location. - The native address range of each entry is from + The native address range of each entry is from to start_address-1 of the next entry. NULL if mapping information cannot be supplied. @@ -13104,10 +13104,10 @@ - VM-specific compilation information. + VM-specific compilation information. The referenced compile information is managed by the VM and must not depend on the agent for collection. - A VM implementation defines the content and lifetime + A VM implementation defines the content and lifetime of the information. @@ -13119,9 +13119,9 @@ Sent when a compiled method is unloaded from memory. This event might not be sent on the thread which performed the unload. - This event may be sent sometime after the unload occurs, but + This event may be sent sometime after the unload occurs, but will be sent before the memory is reused - by a newly generated compiled method. This event may be sent after + by a newly generated compiled method. This event may be sent after the class is unloaded. jvmpi @@ -13139,7 +13139,7 @@ Compiled method being unloaded. - For identification of the compiled method only -- the class + For identification of the compiled method only -- the class may be unloaded and therefore the method should not be used as an argument to further JNI or functions. @@ -13148,7 +13148,7 @@ Address where compiled method code was loaded. - For identification of the compiled method only -- + For identification of the compiled method only -- the space may have been reclaimed. @@ -13236,7 +13236,7 @@ - JNI local reference to the thread + JNI local reference to the thread attempting to enter the monitor @@ -13367,28 +13367,28 @@ since="1.1"> Sent when a VM resource needed by a running application has been exhausted. - Except as required by the optional capabilities, the set of resources + Except as required by the optional capabilities, the set of resources which report exhaustion is implementation dependent.

      The following bit flags define the properties of the resource exhaustion: - After this event returns, the VM will throw a java.lang.OutOfMemoryError. - + - The VM was unable to allocate memory from the Java + The VM was unable to allocate memory from the Java platform heap. The heap is the runtime data area from which memory for all class instances and arrays are allocated. - + The VM was unable to create a thread. - + new @@ -13398,7 +13398,7 @@ heap. - Can generate events when the VM is unable to + Can generate events when the VM is unable to create a thread. @@ -13416,8 +13416,8 @@ Flags defining the properties of the of resource exhaustion - as specified by the - Resource + as specified by the + Resource Exhaustion Flags. @@ -13440,16 +13440,16 @@ - Sent when a method causes the virtual machine to allocate an + Sent when a method causes the virtual machine to allocate an Object visible to Java programming language code and the allocation is not detectable by other intrumentation mechanisms. Generally object allocation should be detected by instrumenting the bytecodes of allocating methods. Object allocation generated in native code by JNI function - calls should be detected using + calls should be detected using JNI function interception. - Some methods might not have associated bytecodes and are not - native methods, they instead are executed directly by the + Some methods might not have associated bytecodes and are not + native methods, they instead are executed directly by the VM. These methods should send this event. Virtual machines which are incapable of bytecode instrumentation for some or all of their methods can send this event. @@ -13539,7 +13539,7 @@ - A Garbage Collection Start event is sent when a + A Garbage Collection Start event is sent when a garbage collection pause begins. Only stop-the-world collections are reported--that is, collections during which all threads cease to modify the state of the Java virtual machine. @@ -13550,8 +13550,8 @@ specifically allow such use (see the raw monitor, memory management, and environment local storage functions).

      - This event is always sent as a matched pair with - + This event is always sent as a matched pair with + (assuming both events are enabled) and no garbage collection events will occur between them. @@ -13580,11 +13580,11 @@ and the handler for the Garbage Collection Finish event simply notifies the raw monitor

      - This event is always sent as a matched pair with + This event is always sent as a matched pair with (assuming both events are enabled). The most important use of this event is to provide timing information, - and thus additional information is not required. However, + and thus additional information is not required. However, information about the collection which is "free" should be included - what that information is needs to be determined. @@ -13613,7 +13613,7 @@

    - Though this seemed trivial to implement. + Though this seemed trivial to implement. In the RI it appears this will be quite complex. @@ -13659,54 +13659,54 @@ - Holds a Java programming language int. + Holds a Java programming language int. Signed 32 bits. - Holds a Java programming language long. + Holds a Java programming language long. Signed 64 bits. - Holds a Java programming language float. + Holds a Java programming language float. 32 bits. - Holds a Java programming language double. + Holds a Java programming language double. 64 bits. - Holds a Java programming language object. + Holds a Java programming language object. - Holds a Java programming language class. + Holds a Java programming language class. - Is a union of all primitive types and jobject. Thus, holds any Java - programming language value. + Is a union of all primitive types and jobject. Thus, holds any Java + programming language value. - Identifies a Java programming language field. + Identifies a Java programming language field. jfieldIDs returned by functions and events may be safely stored. - Identifies a Java programming language method, initializer, or constructor. + Identifies a Java programming language method, initializer, or constructor. jmethodIDs returned by functions and events may be safely stored. However, if the class is unloaded, they become invalid and must not be used. @@ -13715,7 +13715,7 @@ Pointer to the JNI function table. Pointer to this (JNIEnv *) - is a JNI environment. + is a JNI environment. @@ -13723,9 +13723,9 @@ - The environment pointer. + The environment pointer. See the Function Section. - jvmtiEnv points to the + jvmtiEnv points to the function table pointer. @@ -13744,8 +13744,8 @@ typedef jlong jlocation; - A 64 bit value, representing a monotonically increasing - executable position within a method. + A 64 bit value, representing a monotonically increasing + executable position within a method. -1 indicates a native method. See for the format on a given VM. @@ -13763,10 +13763,10 @@ Holds an error return code. See the Error section for possible values. -typedef enum { - JVMTI_ERROR_NONE = 0, +typedef enum { + JVMTI_ERROR_NONE = 0, JVMTI_ERROR_INVALID_THREAD = 10, - ... + ... } jvmtiError; @@ -13775,13 +13775,13 @@ An identifier for an event type. See the Event section for possible values. - It is guaranteed that future versions of this specification will + It is guaranteed that future versions of this specification will never assign zero as an event type identifier. -typedef enum { - JVMTI_EVENT_SINGLE_STEP = 1, - JVMTI_EVENT_BREAKPOINT = 2, - ... +typedef enum { + JVMTI_EVENT_SINGLE_STEP = 1, + JVMTI_EVENT_BREAKPOINT = 2, + ... } jvmtiEvent; @@ -13793,16 +13793,16 @@ typedef struct { jvmtiEventVMInit VMInit; jvmtiEventVMDeath VMDeath; - ... + ... } jvmtiEventCallbacks; - See event callbacks + See event callbacks for the complete structure.

    Where, for example, the VM initialization callback is defined: typedef void (JNICALL *jvmtiEventVMInit) - (jvmtiEnv *jvmti_env, + (jvmtiEnv *jvmti_env, JNIEnv* jni_env, jthread thread); @@ -13813,8 +13813,8 @@ typedef struct JNINativeInterface_ jniNativeInterface; Typedef for the JNI function table JNINativeInterface - defined in the - + defined in the + JNI Specification. The JNI reference implementation defines this with an underscore. @@ -13826,13 +13826,13 @@ JVMDI requires that the agent suspend threads before calling - certain sensitive functions. JVMPI requires garbage collection to be - disabled before calling certain sensitive functions. + certain sensitive functions. JVMPI requires garbage collection to be + disabled before calling certain sensitive functions. It was suggested that rather than have this requirement, that VM place itself in a suitable state before performing an operation. This makes considerable sense since each VM knows its requirements and can most easily arrange a - safe state. + safe state.

    The ability to externally suspend/resume threads will, of course, remain. The ability to enable/disable garbage collection will not. @@ -13840,19 +13840,19 @@ This issue is resolved--suspend will not be required. The spec has been updated to reflect this. - + There are a variety of approaches to sampling call stacks. The biggest bifurcation is between VM controlled and agent - controlled. + controlled.

    This issue is resolved--agent controlled sampling will be the approach. - + JVMDI represents threads as jthread. JVMPI primarily - uses JNIEnv* to represent threads. + uses JNIEnv* to represent threads.

    The Expert Group has chosen jthread as the representation for threads in . @@ -13863,26 +13863,26 @@ The JNI spec allows an implementation to depend on jclass/jmethodID - pairs, rather than simply a jmethodID, to reference a method. - JVMDI, for consistency, choose the same representation. + pairs, rather than simply a jmethodID, to reference a method. + JVMDI, for consistency, choose the same representation. JVMPI, however, specifies that a jmethodID alone maps to a method. Both of the Sun J2SE virtual machines (Classic and HotSpot) store pointers in jmethodIDs, and as a result, a jmethodID is sufficient. In fact, any JVM implementation that supports JVMPI must have - such a representation. + such a representation. will use jmethodID as a unique representation of a method (no jclass is used). - There should be efficiency gains, particularly in + There should be efficiency gains, particularly in functionality like stack dumping, to this representation.

    Note that fields were not used in JVMPI and that the access profile - of fields differs from methods--for implementation efficiency - reasons, a jclass/jfieldID pair will still be needed for field + of fields differs from methods--for implementation efficiency + reasons, a jclass/jfieldID pair will still be needed for field reference. - Functions return local references. + Functions return local references. @@ -13900,37 +13900,37 @@ - A hint of the percentage of objects that will be tagged would + A hint of the percentage of objects that will be tagged would help the VM pick a good implementation. - How difficult or easy would be to extend the monitor_info category to include + How difficult or easy would be to extend the monitor_info category to include

    -  - current number of monitors 
    -  - enumeration of monitors 
    -  - enumeration of threads waiting on a given monitor 
    +  - current number of monitors
    +  - enumeration of monitors
    +  - enumeration of threads waiting on a given monitor
         
    - The reason for my question is the fact that current get_monitor_info support - requires the agent to specify a given thread to get the info which is probably - OK in the profiling/debugging space, while in the monitoring space the agent - could be watching the monitor list and then decide which thread to ask for - the info. You might ask why is this important for monitoring .... I think it + The reason for my question is the fact that current get_monitor_info support + requires the agent to specify a given thread to get the info which is probably + OK in the profiling/debugging space, while in the monitoring space the agent + could be watching the monitor list and then decide which thread to ask for + the info. You might ask why is this important for monitoring .... I think it can aid in the detection/prediction of application contention caused by hot-locks. - The specification is an evolving document with major, minor, + The specification is an evolving document with major, minor, and micro version numbers. A released version of the specification is uniquely identified by its major and minor version. - The functions, events, and capabilities in this specification + The functions, events, and capabilities in this specification indicate a "Since" value which is the major and minor version in which it was introduced. - The version of the specification implemented by the VM can - be retrieved at runtime with the + The version of the specification implemented by the VM can + be retrieved at runtime with the function. @@ -14024,9 +14024,9 @@ get/set annotation, iterate live objects/heap. Add heap profiling functions place holder added: heap roots. - Heap profiling event added: object free. - Heap profiling event redesigned: vm object allocation. - Heap profiling event placeholders added: garbage collection start/finish. + Heap profiling event added: object free. + Heap profiling event redesigned: vm object allocation. + Heap profiling event placeholders added: garbage collection start/finish. Native method bind event added. @@ -14158,7 +14158,7 @@ One character XML fix. - Change function parameter names to be consistent with + Change function parameter names to be consistent with event parameters (fooBarBaz becomes foo_bar_baz). @@ -14215,8 +14215,8 @@ Define the data type jvmtiEventCallbacks. - Zero length allocations return NULL. - Keep SetAllocationHooks in JVMDI, but remove from . + Zero length allocations return NULL. + Keep SetAllocationHooks in JVMDI, but remove from . Add JVMTI_THREAD_STATUS_FLAG_INTERRUPTED. @@ -14234,7 +14234,7 @@ Changes per June 11th Expert Group meeting -- - Overhaul Heap functionality: single callback, + Overhaul Heap functionality: single callback, remove GetHeapRoots, add reachable iterators, and rename "annotation" to "tag". NULL thread parameter on most functions is current @@ -14250,8 +14250,8 @@ Clean up issues sections. Rename GetClassName back to GetClassSignature and fix description. - Add generic signature to GetClassSignature, - GetFieldSignature, GetMethodSignature, and + Add generic signature to GetClassSignature, + GetFieldSignature, GetMethodSignature, and GetLocalVariableTable. Elide EstimateCostOfCapabilities. Clarify that the system property functions operate @@ -14338,7 +14338,7 @@ Split can_get_source_info into can_get_source_file_name, can_get_line_numbers, and can_get_source_debug_extension. PopFrame cannot have a native calling method. - Removed incorrect statement in GetClassloaderClasses + Removed incorrect statement in GetClassloaderClasses (see ). @@ -14370,7 +14370,7 @@ Rename JVMTI_REFERENCE_ARRAY to JVMTI_REFERENCE_ARRAY_ELEMENT. - Steal java.lang.Runtime.availableProcessors() wording for + Steal java.lang.Runtime.availableProcessors() wording for AvailableProcessors(). Guarantee that zero will never be an event ID. Remove some issues which are no longer issues. @@ -14395,7 +14395,7 @@ Remove the ClassUnload event. - Heap reference iterator callbacks return an enum that + Heap reference iterator callbacks return an enum that allows outgoing object references to be ignored. Allow JNIEnv as a param type to extension events/functions. @@ -14403,23 +14403,23 @@ Fix a typo. - Remove all metadata functions: GetClassMetadata, + Remove all metadata functions: GetClassMetadata, GetFieldMetadata, and GetMethodMetadata. - Mark the functions Allocate. Deallocate, RawMonitor*, - SetEnvironmentLocalStorage, and GetEnvironmentLocalStorage + Mark the functions Allocate. Deallocate, RawMonitor*, + SetEnvironmentLocalStorage, and GetEnvironmentLocalStorage as safe for use in heap callbacks and GC events. - Add pass through opaque user data pointer to heap iterate + Add pass through opaque user data pointer to heap iterate functions and callbacks. In the CompiledMethodUnload event, send the code address. Add GarbageCollectionOccurred event. Add constant pool reference kind. Mark the functions CreateRawMonitor and DestroyRawMonitor as safe for use in heap callbacks and GC events. - Clarify: VMDeath, GetCurrentThreadCpuTimerInfo, + Clarify: VMDeath, GetCurrentThreadCpuTimerInfo, GetThreadCpuTimerInfo, IterateOverReachableObjects, IterateOverObjectsReachableFromObject, GetTime and JVMTI_ERROR_NULL_POINTER. @@ -14434,8 +14434,8 @@ SetEventNotificationMode, add: error attempted inappropriate thread level control. Remove jvmtiExceptionHandlerEntry. - Fix handling of native methods on the stack -- - location_ptr param of GetFrameLocation, remove + Fix handling of native methods on the stack -- + location_ptr param of GetFrameLocation, remove JVMTI_ERROR_OPAQUE_FRAME from GetFrameLocation, jvmtiFrameInfo.location, and jlocation. Remove typo (from JVMPI) implying that the MonitorWaited @@ -14456,7 +14456,7 @@ Remove MonitorContendedExit. Added JNIEnv parameter to VMObjectAlloc. - Clarified definition of class_tag and referrer_index + Clarified definition of class_tag and referrer_index parameters to heap callbacks. @@ -14483,13 +14483,13 @@ Require NotifyFramePop to act on suspended threads. - Add capabilities + Add capabilities (can_redefine_any_class - and + and can_generate_all_class_hook_events) - and an error () + >can_generate_all_class_hook_events) + and an error () which allow some classes to be unmodifiable. @@ -14573,11 +14573,11 @@ Bump major.minor version numbers to "1.0". - Clarify interaction between ForceGarbageCollection + Clarify interaction between ForceGarbageCollection and ObjectFree. - Restrict AddToBootstrapClassLoaderSearch and + Restrict AddToBootstrapClassLoaderSearch and SetSystemProperty to the OnLoad phase only. @@ -14604,8 +14604,8 @@ Add "since" version marker. Add AddToSystemClassLoaderSearch. Allow AddToBootstrapClassLoaderSearch be used in live phase. - Fix historic rubbish in the descriptions of the heap_object_callback - parameter of IterateOverHeap and IterateOverInstancesOfClass functions; + Fix historic rubbish in the descriptions of the heap_object_callback + parameter of IterateOverHeap and IterateOverInstancesOfClass functions; disallow NULL for this parameter. Clarify, correct and make consistent: wording about current thread, opaque frames and insufficient number of frames in PopFrame. @@ -14629,19 +14629,19 @@ Allow agents be started in the live phase. - Added paragraph about deploying agents. + Added paragraph about deploying agents. Add specification description to SetNativeMethodPrefix(es). - Better define the conditions on GetConstantPool. + Better define the conditions on GetConstantPool. Break out the GetClassVersionNumber function from GetConstantPool. - Clean-up the references to the VM Spec. + Clean-up the references to the VM Spec. Allow SetNativeMethodPrefix(es) in any phase. - Add clarifications about the impact of redefinition on GetConstantPool. + Add clarifications about the impact of redefinition on GetConstantPool. Various clarifications to SetNativeMethodPrefix(es). @@ -14655,7 +14655,7 @@ Add . Revamp the bytecode instrumentation documentation. - Change to no longer + Change to no longer require the can_redefine_classes capability. @@ -14668,7 +14668,7 @@ Add new heap functionity which supports reporting primitive values, allows setting the referrer tag, and has more powerful filtering: - FollowReferences, IterateThroughHeap, and their associated + FollowReferences, IterateThroughHeap, and their associated callbacks, structs, enums, and constants. @@ -14737,10 +14737,10 @@ Better phrasing. - Match the referrer_index for static fields in Object Reference Callback + Match the referrer_index for static fields in Object Reference Callback with the Reference Implementation (and all other known implementations); that is, make it match the definition for instance fields. - In GetThreadListStackTraces, add JVMTI_ERROR_INVALID_THREAD to cover + In GetThreadListStackTraces, add JVMTI_ERROR_INVALID_THREAD to cover an invalid thread in the list; and specify that not started threads return empty stacks. @@ -14756,10 +14756,10 @@ Changed spec to return -1 for monitor stack depth for the - implementation which can not determine stack depth. + implementation which can not determine stack depth. - Corrections for readability and accuracy courtesy of Alan Pratt of IBM. + Corrections for readability and accuracy courtesy of Alan Pratt of IBM. List the object relationships reported in FollowReferences. diff -r ea7475564d07 -r ca0e16b2d5d6 hotspot/test/compiler/arraycopy/TestACSameSrcDst.java --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/hotspot/test/compiler/arraycopy/TestACSameSrcDst.java Wed Jul 05 23:40:06 2017 +0200 @@ -0,0 +1,106 @@ +/* + * Copyright (c) 2017, Red Hat, 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 Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * @test + * @bug 8179678 + * @summary ArrayCopy with same src and dst can cause incorrect execution or compiler crash + * + * @run main/othervm -XX:CompileCommand=compileonly,TestACSameSrcDst::test* TestACSameSrcDst + * + */ + +public class TestACSameSrcDst { + + static int test1(int[] src, int[] dst) { + System.arraycopy(src, 5, dst, 0, 10); + // this shouldn't be transformed to src[5] because the copy + // can modify src[5] if src and dst are the same. + return dst[0]; + } + + static int test2(int[] src) { + System.arraycopy(src, 0, src, 0, 10); + // same source and destination. If load from destination is + // transformed to load of source, the compiler performs that + // optimization in an infinite loop. + return src[0]; + } + + static int test3() { + int[] src = new int[15]; + src[5] = 0x42; + System.arraycopy(src, 5, src, 0, 10); + // That load can't bypass the arraycopy + return src[0]; + } + + static int test4() { + int[] src = new int[15]; + System.arraycopy(src, 0, src, 5, 10); + return src[0]; + } + + // The dst[0] load can't bypass the arraycopy. After ArrayCopyNode + // is expanded, C2 looks for a stub call on the control paths of + // the array copy subgraph to decide whether the load's memory + // input can bypass the arraycopy. This test verifies the case of + // a source array that's not declared as an array. + static int test5(Object src, int l, boolean flag) { + int[] dst = new int[10]; + if (flag) { + dst[0] = 0x42; + System.arraycopy(src, 0, dst, 0, l); + return dst[0]; + } + return 0; + } + + public static void main(String[] args) { + int[] array = new int[15]; + for (int i = 0; i < 20000; i++) { + int res; + for (int j = 0; j < array.length; j++) { + array[j] = j; + } + int expected = array[5]; + res = test1(array, array); + if (res != expected) { + throw new RuntimeException("bad result: " + res + " != " + expected); + } + test2(array); + res = test3(); + if (res != 0x42) { + throw new RuntimeException("bad result: " + res + " != " + 0x42); + } + test4(); + for (int j = 0; j < array.length; j++) { + array[j] = j; + } + res = test5(array, 10, (i%2) == 0); + if (res != 0) { + throw new RuntimeException("bad result: " + res + " != " + 0); + } + } + } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/.hgtags --- a/jaxp/.hgtags Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/.hgtags Wed Jul 05 23:40:06 2017 +0200 @@ -426,3 +426,5 @@ c27321c889cf4c8e465a61b84572c00ef7ee6004 jdk-9+171 bd4b2c8835f35760a51c1475b03a16cc20c62973 jdk-10+10 eedb6e54c8bd6197ecba5fc0d8568bac8ae852dd jdk-9+172 +95bab8bf9201ae8bfdf28e164bf33b78e49477e7 jdk-10+11 +9788347e0629d0cb3a0e55a903494ff741d4fa15 jdk-9+173 diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReferenceType.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReferenceType.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/bcel/internal/generic/ReferenceType.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -262,6 +261,7 @@ * @deprecated use getFirstCommonSuperclass(ReferenceType t) which has * slightly changed semantics. */ + @Deprecated public ReferenceType firstCommonSuperclass(ReferenceType t) { if (this.equals(Type.NULL)) return t; if (t.equals(Type.NULL)) return this; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltSets.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltSets.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/lib/ExsltSets.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,7 +22,7 @@ */ package com.sun.org.apache.xalan.internal.lib; -import com.sun.org.apache.xml.internal.utils.DOMHelper; +import com.sun.org.apache.xml.internal.utils.DOM2Helper; import com.sun.org.apache.xpath.internal.NodeSet; import java.util.HashMap; import java.util.Map; @@ -72,8 +72,8 @@ for (int i = 0; i < nl1.getLength(); i++) { Node testNode = nl1.item(i); - if (DOMHelper.isNodeAfter(testNode, endNode) - && !DOMHelper.isNodeTheSame(testNode, endNode)) + if (DOM2Helper.isNodeAfter(testNode, endNode) + && !DOM2Helper.isNodeTheSame(testNode, endNode)) leadNodes.addElement(testNode); } return leadNodes; @@ -107,8 +107,8 @@ for (int i = 0; i < nl1.getLength(); i++) { Node testNode = nl1.item(i); - if (DOMHelper.isNodeAfter(startNode, testNode) - && !DOMHelper.isNodeTheSame(startNode, testNode)) + if (DOM2Helper.isNodeAfter(startNode, testNode) + && !DOM2Helper.isNodeTheSame(startNode, testNode)) trailNodes.addElement(testNode); } return trailNodes; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1426,24 +1422,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - } diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_de.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_de.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_de.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1426,24 +1422,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_es.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_es.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_es.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1425,25 +1421,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - } diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_fr.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_fr.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_fr.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1425,25 +1421,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_it.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_it.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_it.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1425,25 +1421,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ja.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ja.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ja.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1425,25 +1421,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ko.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ko.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_ko.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1015,7 +1011,7 @@ "\uC2DC\uC2A4\uD15C \uC18D\uC131 org.xml.sax.parser\uAC00 \uC9C0\uC815\uB418\uC9C0 \uC54A\uC558\uC2B5\uB2C8\uB2E4."}, { ER_PARSER_ARG_CANNOT_BE_NULL, - "\uAD6C\uBB38\uBD84\uC11D\uAE30 \uC778\uC218\uB294 \uB110\uC774 \uC544\uB2C8\uC5B4\uC57C \uD569\uB2C8\uB2E4."}, + "\uAD6C\uBB38 \uBD84\uC11D\uAE30 \uC778\uC218\uB294 \uB110\uC774 \uC544\uB2C8\uC5B4\uC57C \uD569\uB2C8\uB2E4."}, { ER_FEATURE, "\uAE30\uB2A5: {0}"}, @@ -1252,7 +1248,7 @@ "\uD2B9\uC218 \uCDA9\uB3CC\uC774 \uBC1C\uACAC\uB428: {0}. \uC2A4\uD0C0\uC77C\uC2DC\uD2B8\uC5D0\uC11C \uBC1C\uACAC\uB41C \uB9C8\uC9C0\uB9C9 \uD56D\uBAA9\uC774 \uC0AC\uC6A9\uB429\uB2C8\uB2E4."}, { WG_PARSING_AND_PREPARING, - "========= \uAD6C\uBB38\uBD84\uC11D \uD6C4 {0} \uC900\uBE44 \uC911 =========="}, + "========= \uAD6C\uBB38 \uBD84\uC11D \uD6C4 {0} \uC900\uBE44 \uC911 =========="}, { WG_ATTR_TEMPLATE, "\uC18D\uC131 \uD15C\uD50C\uB9AC\uD2B8, {0}"}, @@ -1357,7 +1353,7 @@ { "optionOUT", " [-OUT outputFileName]"}, { "optionLXCIN", " [-LXCIN compiledStylesheetFileNameIn]"}, { "optionLXCOUT", " [-LXCOUT compiledStylesheetFileNameOutOut]"}, - { "optionPARSER", " [-PARSER \uAD6C\uBB38\uBD84\uC11D\uAE30 \uC5F0\uACB0\uC758 \uC804\uCCB4 \uD074\uB798\uC2A4 \uC774\uB984]"}, + { "optionPARSER", " [-PARSER \uAD6C\uBB38 \uBD84\uC11D\uAE30 \uC5F0\uACB0\uC758 \uC804\uCCB4 \uD074\uB798\uC2A4 \uC774\uB984]"}, { "optionE", " [-E(\uC5D4\uD2F0\uD2F0 \uCC38\uC870 \uD655\uC7A5 \uC548\uD568)]"}, { "optionV", " [-E(\uC5D4\uD2F0\uD2F0 \uCC38\uC870 \uD655\uC7A5 \uC548\uD568)]"}, { "optionQC", " [-QC(\uC790\uB3D9 \uD328\uD134 \uCDA9\uB3CC \uACBD\uACE0)]"}, @@ -1378,9 +1374,9 @@ { "optionHTML", " [-HTML(HTML \uD3EC\uB9F7\uD130 \uC0AC\uC6A9)]"}, { "optionPARAM", " [-PARAM \uC774\uB984 \uD45C\uD604\uC2DD(\uC2A4\uD0C0\uC77C\uC2DC\uD2B8 \uB9E4\uAC1C\uBCC0\uC218 \uC124\uC815)]"}, { "noParsermsg1", "XSL \uD504\uB85C\uC138\uC2A4\uB97C \uC2E4\uD328\uD588\uC2B5\uB2C8\uB2E4."}, - { "noParsermsg2", "** \uAD6C\uBB38\uBD84\uC11D\uAE30\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC74C **"}, + { "noParsermsg2", "** \uAD6C\uBB38 \uBD84\uC11D\uAE30\uB97C \uCC3E\uC744 \uC218 \uC5C6\uC74C **"}, { "noParsermsg3", "\uD074\uB798\uC2A4 \uACBD\uB85C\uB97C \uD655\uC778\uD558\uC2ED\uC2DC\uC624."}, - { "noParsermsg4", "IBM\uC758 Java\uC6A9 XML \uAD6C\uBB38\uBD84\uC11D\uAE30\uAC00 \uC5C6\uC744 \uACBD\uC6B0 \uB2E4\uC74C \uC704\uCE58\uC5D0\uC11C \uB2E4\uC6B4\uB85C\uB4DC\uD560 \uC218 \uC788\uC2B5\uB2C8\uB2E4."}, + { "noParsermsg4", "IBM\uC758 Java\uC6A9 XML \uAD6C\uBB38 \uBD84\uC11D\uAE30\uAC00 \uC5C6\uC744 \uACBD\uC6B0 \uB2E4\uC74C \uC704\uCE58\uC5D0\uC11C \uB2E4\uC6B4\uB85C\uB4DC\uD560 \uC218 \uC788\uC2B5\uB2C8\uB2E4."}, { "noParsermsg5", "IBM AlphaWorks: http://www.alphaworks.ibm.com/formula/xml"}, { "optionURIRESOLVER", " [-URIRESOLVER \uC804\uCCB4 \uD074\uB798\uC2A4 \uC774\uB984(URI \uBD84\uC11D\uC5D0 \uC0AC\uC6A9\uD560 URIResolver)]"}, { "optionENTITYRESOLVER", " [-ENTITYRESOLVER \uC804\uCCB4 \uD074\uB798\uC2A4 \uC774\uB984(\uC5D4\uD2F0\uD2F0 \uBD84\uC11D\uC5D0 \uC0AC\uC6A9\uD560 EntityResolver)]"}, @@ -1425,25 +1421,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_pt_BR.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_pt_BR.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_pt_BR.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1425,25 +1421,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_sv.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_sv.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_sv.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -482,7 +478,7 @@ {"ER0000" , "{0}" }, { ER_NO_CURLYBRACE, - "Fel: Uttryck f\u00E5r inte inneh\u00E5lla '{'"}, + "Fel: Uttryck kan inte inneh\u00E5lla '{'"}, { ER_ILLEGAL_ATTRIBUTE , "{0} har ett otill\u00E5tet attribut: {1}"}, @@ -1426,24 +1422,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_CN.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_CN.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_CN.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1425,25 +1421,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_TW.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_TW.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/res/XSLTErrorResources_zh_TW.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -22,9 +21,6 @@ package com.sun.org.apache.xalan.internal.res; import java.util.ListResourceBundle; -import java.util.Locale; -import java.util.MissingResourceException; -import java.util.ResourceBundle; /** * Set up error messages. @@ -1425,25 +1421,4 @@ /** String for use when formatting of the error string failed. */ public static final String FORMAT_FAILED = "FORMAT_FAILED"; - - /** General error string. */ - public static final String ERROR_STRING = "#error"; - - /** String to prepend to error messages. */ - public static final String ERROR_HEADER = "Error: "; - - /** String to prepend to warning messages. */ - public static final String WARNING_HEADER = "Warning: "; - - /** String to specify the XSLT module. */ - public static final String XSL_HEADER = "XSLT "; - - /** String to specify the XML parser module. */ - public static final String XML_HEADER = "XML "; - - /** I don't think this is used any more. - * @deprecated */ - public static final String QUERY_HEADER = "PATTERN "; - - - } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ForwardPositionIterator.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ForwardPositionIterator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/ForwardPositionIterator.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -60,6 +59,7 @@ * @deprecated This class exists only for backwards compatibility with old * translets. New code should not reference it. */ +@Deprecated public final class ForwardPositionIterator extends DTMAxisIteratorBase { private DTMAxisIterator _source; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/KeyIndex.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/KeyIndex.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/KeyIndex.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -115,6 +115,7 @@ * Merge the current value's nodeset set by lookupKey() with _nodes. * @deprecated */ + @Deprecated public void merge(KeyIndex other) { if (other == null) return; @@ -136,6 +137,7 @@ * key() function. * @deprecated */ + @Deprecated public void lookupId(Object value) { // Clear _nodes array _nodes = null; @@ -205,6 +207,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public void lookupKey(Object value) { IntegerArray nodes = _index.get(value); _nodes = (nodes != null) ? (IntegerArray) nodes.clone() : null; @@ -217,6 +220,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public int next() { if (_nodes == null) return DTMAxisIterator.END; @@ -313,6 +317,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public DTMAxisIterator reset() { _position = 0; return this; @@ -324,6 +329,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public int getLast() { return (_nodes == null) ? 0 : _nodes.cardinality(); } @@ -334,6 +340,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public int getPosition() { return _position; } @@ -344,6 +351,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public void setMark() { _markedPosition = _position; } @@ -354,6 +362,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public void gotoMark() { _position = _markedPosition; } @@ -365,6 +374,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public DTMAxisIterator setStartNode(int start) { if (start == DTMAxisIterator.END) { _nodes = null; @@ -382,6 +392,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public int getStartNode() { return 0; } @@ -392,6 +403,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public boolean isReverse() { return(false); } @@ -402,6 +414,7 @@ * deprecated.

    * @deprecated */ + @Deprecated public DTMAxisIterator cloneIterator() { KeyIndex other = new KeyIndex(0); other._index = _index; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecord.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecord.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecord.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -49,6 +48,7 @@ * @deprecated This field continues to exist for binary compatibility. * New code should not refer to it. */ + @Deprecated private static final Collator DEFAULT_COLLATOR = Collator.getInstance(); /** @@ -56,6 +56,7 @@ * @deprecated This field continues to exist for binary compatibility. * New code should not refer to it. */ + @Deprecated protected Collator _collator = DEFAULT_COLLATOR; protected Collator[] _collators; @@ -64,6 +65,7 @@ * @deprecated This field continues to exist for binary compatibility. * New code should not refer to it. */ + @Deprecated protected Locale _locale; protected CollatorFactory _collatorFactory; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecordFactory.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecordFactory.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/dom/NodeSortRecordFactory.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -55,6 +54,7 @@ * @deprecated This constructor is no longer used in generated code. It * exists only for backwards compatibility. */ + @Deprecated public NodeSortRecordFactory(DOM dom, String className, Translet translet, String order[], String type[]) throws TransletException diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/BasisLibrary.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/BasisLibrary.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/runtime/BasisLibrary.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -100,6 +100,7 @@ * @deprecated This method exists only for backwards compatibility with old * translets. New code should not reference it. */ + @Deprecated public static int positionF(DTMAxisIterator iterator) { return iterator.isReverse() ? iterator.getLast() - iterator.getPosition() + 1 diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrImpl.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrImpl.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/AttrImpl.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -516,6 +515,7 @@ * @deprecated Previous working draft of DOM Level 2. New method * is getOwnerElement(). */ + @Deprecated public Element getElement() { // if we have an owner, ownerNode is our ownerElement, otherwise it's // our ownerDocument and we don't have an ownerElement diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CoreDocumentImpl.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CoreDocumentImpl.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/CoreDocumentImpl.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2009, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -832,6 +832,7 @@ * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public void setEncoding(String value) { setXmlEncoding(value); } @@ -849,6 +850,7 @@ * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public String getEncoding() { return getXmlEncoding(); } @@ -890,6 +892,7 @@ * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public void setVersion(String value) { setXmlVersion(value); } @@ -908,6 +911,7 @@ * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public String getVersion() { return getXmlVersion(); } @@ -932,6 +936,7 @@ * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public void setStandalone(boolean value) { setXmlStandalone(value); } @@ -950,6 +955,7 @@ * compatibility with older applications. New applications * should never call this method. */ + @Deprecated public boolean getStandalone() { return getXmlStandalone(); } diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentImpl.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentImpl.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/DeferredDocumentImpl.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -369,6 +369,7 @@ * Creates an element node with a URI in the table and type information. * @deprecated */ + @Deprecated public int createDeferredElement(String elementURI, String elementName, Object type) { @@ -389,6 +390,7 @@ * Creates an element node in the table. * @deprecated */ + @Deprecated public int createDeferredElement(String elementName) { return createDeferredElement(null, elementName); } @@ -474,6 +476,7 @@ * Sets an attribute on an element node. * @deprecated */ + @Deprecated public int setDeferredAttribute(int elementNodeIndex, String attrName, String attrURI, String attrValue, boolean specified) { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeImpl.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeImpl.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/dom/NodeImpl.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -763,6 +763,7 @@ * @since DOM Level 3 * @deprecated */ + @Deprecated public short compareTreePosition(Node other) { // Questions of clarification for this method - to be answered by the // DOM WG. Current assumptions listed - LM diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ItemPSVI.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ItemPSVI.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/ItemPSVI.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -116,6 +115,7 @@ * * @deprecated Use getSchemaValue().getNormalizedValue() instead */ + @Deprecated public String getSchemaNormalizedValue(); /** @@ -127,6 +127,7 @@ * * @deprecated Use getSchemaValue().getActualValue() instead */ + @Deprecated public Object getActualNormalizedValue() throws XSException; @@ -146,6 +147,7 @@ * * @deprecated Use getSchemaValue().getActualValueType() instead */ + @Deprecated public short getActualNormalizedValueType() throws XSException; @@ -182,6 +184,7 @@ * * @deprecated Use getSchemaValue().getListValueTypes() instead */ + @Deprecated public ShortList getItemValueTypes() throws XSException; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeDeclaration.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeDeclaration.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeDeclaration.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -55,6 +54,7 @@ * * @deprecated Use getValueConstraintValue().getNormalizedValue() instead */ + @Deprecated public String getConstraintValue(); /** @@ -67,6 +67,7 @@ * * @deprecated Use getValueConstraintValue().getActualValue() instead */ + @Deprecated public Object getActualVC() throws XSException; @@ -86,6 +87,7 @@ * * @deprecated Use getValueConstraintValue().getActualValueType() instead */ + @Deprecated public short getActualVCType() throws XSException; @@ -104,6 +106,7 @@ * * @deprecated Use getValueConstraintValue().getListValueTypes() instead */ + @Deprecated public ShortList getItemValueTypes() throws XSException; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeUse.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeUse.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSAttributeUse.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -48,6 +47,7 @@ * * @deprecated Use getValueConstraintValue().getNormalizedValue() instead */ + @Deprecated public String getConstraintValue(); /** @@ -60,6 +60,7 @@ * * @deprecated Use getValueConstraintValue().getActualValue() instead */ + @Deprecated public Object getActualVC() throws XSException; @@ -79,6 +80,7 @@ * * @deprecated Use getValueConstraintValue().getActualValueType() instead */ + @Deprecated public short getActualVCType() throws XSException; @@ -97,6 +99,7 @@ * * @deprecated Use getValueConstraintValue().getListValueTypes() instead */ + @Deprecated public ShortList getItemValueTypes() throws XSException; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSElementDeclaration.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSElementDeclaration.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xerces/internal/xs/XSElementDeclaration.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -56,6 +55,7 @@ * * @deprecated Use getValueConstraintValue().getNormalizedValue() instead */ + @Deprecated public String getConstraintValue(); /** @@ -68,6 +68,7 @@ * * @deprecated Use getValueConstraintValue().getActualValue() instead */ + @Deprecated public Object getActualVC() throws XSException; @@ -87,6 +88,7 @@ * * @deprecated Use getValueConstraintValue().getActualValueType() instead */ + @Deprecated public short getActualVCType() throws XSException; @@ -105,6 +107,7 @@ * * @deprecated Use getValueConstraintValue().getListValueTypes() instead */ + @Deprecated public ShortList getItemValueTypes() throws XSException; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineParser.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineParser.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/dtm/ref/CoroutineParser.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -45,6 +44,7 @@ * coroutine protocol was not being used and was complicating design. * See {@link IncrementalSAXSource}. * */ +@Deprecated public interface CoroutineParser { /** @return the coroutine ID number for this CoroutineParser object. diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/BaseMarkupSerializer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/BaseMarkupSerializer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/BaseMarkupSerializer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -128,6 +128,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public abstract class BaseMarkupSerializer implements ContentHandler, DocumentHandler, LexicalHandler, DTDHandler, DeclHandler, DOMSerializer, Serializer diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -42,6 +41,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public interface DOMSerializer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializerImpl.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializerImpl.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/DOMSerializerImpl.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -76,6 +75,7 @@ * @deprecated As of JDK 9, Xerces 2.9.0, replaced by * {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl} */ +@Deprecated public class DOMSerializerImpl implements LSSerializer, DOMConfiguration { // TODO: When DOM Level 3 goes to REC replace method calls using diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/ElementState.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/ElementState.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/ElementState.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -36,6 +36,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class ElementState { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/EncodingInfo.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/EncodingInfo.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/EncodingInfo.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -37,6 +36,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class EncodingInfo { // name of encoding as registered with IANA; diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Encodings.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Encodings.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Encodings.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -42,6 +42,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated class Encodings { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLSerializer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLSerializer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLSerializer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -92,6 +92,7 @@ * @author Assaf Arkin * @see Serializer */ +@Deprecated public class HTMLSerializer extends BaseMarkupSerializer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLdtd.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLdtd.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/HTMLdtd.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -51,6 +51,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public final class HTMLdtd { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/IndentPrinter.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/IndentPrinter.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/IndentPrinter.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -39,6 +38,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class IndentPrinter extends Printer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/LineSeparator.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/LineSeparator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/LineSeparator.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -32,6 +31,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public final class LineSeparator { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Method.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Method.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Method.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -32,6 +31,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public final class Method { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/OutputFormat.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/OutputFormat.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/OutputFormat.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -65,6 +64,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class OutputFormat { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Printer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Printer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Printer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -47,6 +46,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class Printer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Serializer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Serializer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/Serializer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -67,6 +66,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public interface Serializer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactory.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactory.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactory.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017 Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -42,6 +42,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public abstract class SerializerFactory { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactoryImpl.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactoryImpl.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/SerializerFactoryImpl.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -41,6 +40,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated final class SerializerFactoryImpl extends SerializerFactory { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/TextSerializer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/TextSerializer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/TextSerializer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -65,6 +64,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class TextSerializer extends BaseMarkupSerializer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XHTMLSerializer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XHTMLSerializer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XHTMLSerializer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -39,6 +38,7 @@ * @author Assaf Arkin * @see Serializer */ +@Deprecated public class XHTMLSerializer extends HTMLSerializer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XML11Serializer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XML11Serializer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XML11Serializer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -84,6 +83,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class XML11Serializer extends XMLSerializer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XMLSerializer.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XMLSerializer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serialize/XMLSerializer.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -95,6 +94,7 @@ * {@link com.sun.org.apache.xml.internal.serialize.DOMSerializerImpl} is replaced * by {@link com.sun.org.apache.xml.internal.serializer.dom3.LSSerializerImpl}. */ +@Deprecated public class XMLSerializer extends BaseMarkupSerializer { diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TreeWalker.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TreeWalker.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/TreeWalker.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -17,13 +17,12 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + package com.sun.org.apache.xml.internal.serializer; -import com.sun.org.apache.xalan.internal.utils.SecuritySupport; -import java.io.File; - -import com.sun.org.apache.xml.internal.serializer.utils.AttList; -import com.sun.org.apache.xml.internal.serializer.utils.DOM2Helper; +import com.sun.org.apache.xml.internal.utils.AttList; +import com.sun.org.apache.xml.internal.utils.DOM2Helper; +import javax.xml.transform.Result; import org.w3c.dom.Comment; import org.w3c.dom.Element; import org.w3c.dom.EntityReference; @@ -31,7 +30,6 @@ import org.w3c.dom.Node; import org.w3c.dom.ProcessingInstruction; import org.w3c.dom.Text; - import org.xml.sax.ContentHandler; import org.xml.sax.Locator; import org.xml.sax.ext.LexicalHandler; @@ -58,12 +56,6 @@ */ final private SerializationHandler m_Serializer; - // ARGHH!! JAXP Uses Xerces without setting the namespace processing to ON! - // DOM2Helper m_dh = new DOM2Helper(); - - /** DomHelper for this TreeWalker */ - final protected DOM2Helper m_dh; - /** Locator object for this TreeWalker */ final private LocatorImpl m_locator = new LocatorImpl(); @@ -78,7 +70,7 @@ } public TreeWalker(ContentHandler ch) { - this(ch,null); + this(ch, null); } /** * Constructor. @@ -99,8 +91,6 @@ if (systemId != null) { m_locator.setSystemId(systemId); } - - m_dh = new DOM2Helper(); } /** @@ -209,7 +199,7 @@ this.m_contentHandler.endDocument(); } - /** Flag indicating whether following text to be processed is raw text */ + // Flag indicating whether following text to be processed is raw text boolean nextIsRaw = false; /** @@ -313,7 +303,6 @@ final int colon = attrName.indexOf(':'); final String prefix; - // System.out.println("TreeWalker#startNode: attr["+i+"] = "+attrName+", "+attr.getNodeValue()); if (attrName.equals("xmlns") || attrName.startsWith("xmlns:")) { // Use "" instead of null, as Xerces likes "" for the @@ -335,13 +324,13 @@ } } - String ns = m_dh.getNamespaceOfNode(node); + String ns = DOM2Helper.getNamespaceOfNode(node); if(null == ns) ns = ""; this.m_contentHandler.startElement(ns, - m_dh.getLocalNameOfNode(node), + DOM2Helper.getLocalNameOfNode(node), node.getNodeName(), - new AttList(atts, m_dh)); + new AttList(atts)); break; case Node.PROCESSING_INSTRUCTION_NODE : { @@ -389,9 +378,9 @@ { nextIsRaw = false; - m_contentHandler.processingInstruction(javax.xml.transform.Result.PI_DISABLE_OUTPUT_ESCAPING, ""); + m_contentHandler.processingInstruction(Result.PI_DISABLE_OUTPUT_ESCAPING, ""); dispatachChars(node); - m_contentHandler.processingInstruction(javax.xml.transform.Result.PI_ENABLE_OUTPUT_ESCAPING, ""); + m_contentHandler.processingInstruction(Result.PI_ENABLE_OUTPUT_ESCAPING, ""); } else { @@ -436,12 +425,12 @@ break; case Node.ELEMENT_NODE : - String ns = m_dh.getNamespaceOfNode(node); + String ns = DOM2Helper.getNamespaceOfNode(node); if(null == ns) ns = ""; this.m_contentHandler.endElement(ns, - m_dh.getLocalNameOfNode(node), - node.getNodeName()); + DOM2Helper.getLocalNameOfNode(node), + node.getNodeName()); if (m_Serializer == null) { // Don't bother with endPrefixMapping calls if the ContentHandler is a diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/AttList.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/AttList.java Thu Jun 15 13:44:42 2017 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,264 +0,0 @@ -/* - * reserved comment block - * DO NOT REMOVE OR ALTER! - */ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.sun.org.apache.xml.internal.serializer.utils; - -import org.w3c.dom.Attr; -import org.w3c.dom.NamedNodeMap; -import org.w3c.dom.Node; - -import org.xml.sax.Attributes; - -/** - * Wraps a DOM attribute list in a SAX Attributes. - * - * This class is a copy of the one in com.sun.org.apache.xml.internal.utils. - * It exists to cut the serializers dependancy on that package. - * A minor changes from that package are: - * DOMHelper reference changed to DOM2Helper, class is not "public" - * - * This class is not a public API, it is only public because it is - * used in com.sun.org.apache.xml.internal.serializer. - * - * @xsl.usage internal - */ -public final class AttList implements Attributes -{ - - /** List of attribute nodes */ - NamedNodeMap m_attrs; - - /** Index of last attribute node */ - int m_lastIndex; - - // ARGHH!! JAXP Uses Xerces without setting the namespace processing to ON! - // DOM2Helper m_dh = new DOM2Helper(); - - /** Local reference to DOMHelper */ - DOM2Helper m_dh; - -// /** -// * Constructor AttList -// * -// * -// * @param attrs List of attributes this will contain -// */ -// public AttList(NamedNodeMap attrs) -// { -// -// m_attrs = attrs; -// m_lastIndex = m_attrs.getLength() - 1; -// m_dh = new DOM2Helper(); -// } - - /** - * Constructor AttList - * - * - * @param attrs List of attributes this will contain - * @param dh DOMHelper - */ - public AttList(NamedNodeMap attrs, DOM2Helper dh) - { - - m_attrs = attrs; - m_lastIndex = m_attrs.getLength() - 1; - m_dh = dh; - } - - /** - * Get the number of attribute nodes in the list - * - * - * @return number of attribute nodes - */ - public int getLength() - { - return m_attrs.getLength(); - } - - /** - * Look up an attribute's Namespace URI by index. - * - * @param index The attribute index (zero-based). - * @return The Namespace URI, or the empty string if none - * is available, or null if the index is out of - * range. - */ - public String getURI(int index) - { - String ns = m_dh.getNamespaceOfNode(((Attr) m_attrs.item(index))); - if(null == ns) - ns = ""; - return ns; - } - - /** - * Look up an attribute's local name by index. - * - * @param index The attribute index (zero-based). - * @return The local name, or the empty string if Namespace - * processing is not being performed, or null - * if the index is out of range. - */ - public String getLocalName(int index) - { - return m_dh.getLocalNameOfNode(((Attr) m_attrs.item(index))); - } - - /** - * Look up an attribute's qualified name by index. - * - * - * @param i The attribute index (zero-based). - * - * @return The attribute's qualified name - */ - public String getQName(int i) - { - return ((Attr) m_attrs.item(i)).getName(); - } - - /** - * Get the attribute's node type by index - * - * - * @param i The attribute index (zero-based) - * - * @return the attribute's node type - */ - public String getType(int i) - { - return "CDATA"; // for the moment - } - - /** - * Get the attribute's node value by index - * - * - * @param i The attribute index (zero-based) - * - * @return the attribute's node value - */ - public String getValue(int i) - { - return ((Attr) m_attrs.item(i)).getValue(); - } - - /** - * Get the attribute's node type by name - * - * - * @param name Attribute name - * - * @return the attribute's node type - */ - public String getType(String name) - { - return "CDATA"; // for the moment - } - - /** - * Look up an attribute's type by Namespace name. - * - * @param uri The Namespace URI, or the empty String if the - * name has no Namespace URI. - * @param localName The local name of the attribute. - * @return The attribute type as a string, or null if the - * attribute is not in the list or if Namespace - * processing is not being performed. - */ - public String getType(String uri, String localName) - { - return "CDATA"; // for the moment - } - - /** - * Look up an attribute's value by name. - * - * - * @param name The attribute node's name - * - * @return The attribute node's value - */ - public String getValue(String name) - { - Attr attr = ((Attr) m_attrs.getNamedItem(name)); - return (null != attr) - ? attr.getValue() : null; - } - - /** - * Look up an attribute's value by Namespace name. - * - * @param uri The Namespace URI, or the empty String if the - * name has no Namespace URI. - * @param localName The local name of the attribute. - * @return The attribute value as a string, or null if the - * attribute is not in the list. - */ - public String getValue(String uri, String localName) - { - Node a=m_attrs.getNamedItemNS(uri,localName); - return (a==null) ? null : a.getNodeValue(); - } - - /** - * Look up the index of an attribute by Namespace name. - * - * @param uri The Namespace URI, or the empty string if - * the name has no Namespace URI. - * @param localPart The attribute's local name. - * @return The index of the attribute, or -1 if it does not - * appear in the list. - */ - public int getIndex(String uri, String localPart) - { - for(int i=m_attrs.getLength()-1;i>=0;--i) - { - Node a=m_attrs.item(i); - String u=a.getNamespaceURI(); - if( (u==null ? uri==null : u.equals(uri)) - && - a.getLocalName().equals(localPart) ) - return i; - } - return -1; - } - - /** - * Look up the index of an attribute by raw XML 1.0 name. - * - * @param qName The qualified (prefixed) name. - * @return The index of the attribute, or -1 if it does not - * appear in the list. - */ - public int getIndex(String qName) - { - for(int i=m_attrs.getLength()-1;i>=0;--i) - { - Node a=m_attrs.item(i); - if(a.getNodeName().equals(qName) ) - return i; - } - return -1; - } -} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/DOM2Helper.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/serializer/utils/DOM2Helper.java Thu Jun 15 13:44:42 2017 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,135 +0,0 @@ -/* - * reserved comment block - * DO NOT REMOVE OR ALTER! - */ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.sun.org.apache.xml.internal.serializer.utils; - -import java.io.IOException; - -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.ParserConfigurationException; -import javax.xml.transform.TransformerException; - -import org.w3c.dom.Attr; -import org.w3c.dom.Document; -import org.w3c.dom.Element; -import org.w3c.dom.Node; - -import org.xml.sax.InputSource; - -/** - * This class provides a DOM level 2 "helper", which provides services currently - * not provided be the DOM standard. - * - * This class is a copy of the one in com.sun.org.apache.xml.internal.utils. - * It exists to cut the serializers dependancy on that package. - * - * The differences from the original class are: - * it doesn't extend DOMHelper, not depricated, - * dropped method isNodeAfter(Node node1, Node node2) - * dropped method parse(InputSource) - * dropped method supportSAX() - * dropped method setDocument(doc) - * dropped method checkNode(Node) - * dropped method getDocument() - * dropped method getElementByID(String id, Document doc) - * dropped method getParentOfNode(Node node) - * dropped field Document m_doc; - * made class non-public - * - * This class is not a public API, it is only public because it is - * used in com.sun.org.apache.xml.internal.serializer. - * - * @xsl.usage internal - */ -public final class DOM2Helper -{ - - /** - * Construct an instance. - */ - public DOM2Helper(){} - - /** - * Returns the local name of the given node, as defined by the - * XML Namespaces specification. This is prepared to handle documents - * built using DOM Level 1 methods by falling back upon explicitly - * parsing the node name. - * - * @param n Node to be examined - * - * @return String containing the local name, or null if the node - * was not assigned a Namespace. - */ - public String getLocalNameOfNode(Node n) - { - - String name = n.getLocalName(); - - return (null == name) ? getLocalNameOfNodeFallback(n) : name; - } - - /** - * Returns the local name of the given node. If the node's name begins - * with a namespace prefix, this is the part after the colon; otherwise - * it's the full node name. - * - * This method is copied from com.sun.org.apache.xml.internal.utils.DOMHelper - * - * @param n the node to be examined. - * - * @return String containing the Local Name - */ - private String getLocalNameOfNodeFallback(Node n) - { - - String qname = n.getNodeName(); - int index = qname.indexOf(':'); - - return (index < 0) ? qname : qname.substring(index + 1); - } - - /** - * Returns the Namespace Name (Namespace URI) for the given node. - * In a Level 2 DOM, you can ask the node itself. Note, however, that - * doing so conflicts with our decision in getLocalNameOfNode not - * to trust the that the DOM was indeed created using the Level 2 - * methods. If Level 1 methods were used, these two functions will - * disagree with each other. - *

    - * TODO: Reconcile with getLocalNameOfNode. - * - * @param n Node to be examined - * - * @return String containing the Namespace URI bound to this DOM node - * at the time the Node was created. - */ - public String getNamespaceOfNode(Node n) - { - return n.getNamespaceURI(); - } - - /** Field m_useDOM2getNamespaceURI is a compile-time flag which - * gates some of the parser options used to build a DOM -- but - * that code is commented out at this time and nobody else - * references it, so I've commented this out as well. */ - //private boolean m_useDOM2getNamespaceURI = false; -} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/AttList.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/AttList.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/AttList.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -40,26 +39,9 @@ /** Index of last attribute node */ int m_lastIndex; - // ARGHH!! JAXP Uses Xerces without setting the namespace processing to ON! + // JAXP Uses Xerces without setting the namespace processing to ON! // DOM2Helper m_dh = new DOM2Helper(); - /** Local reference to DOMHelper */ - DOMHelper m_dh; - -// /** -// * Constructor AttList -// * -// * -// * @param attrs List of attributes this will contain -// */ -// public AttList(NamedNodeMap attrs) -// { -// -// m_attrs = attrs; -// m_lastIndex = m_attrs.getLength() - 1; -// m_dh = new DOM2Helper(); -// } - /** * Constructor AttList * @@ -67,12 +49,10 @@ * @param attrs List of attributes this will contain * @param dh DOMHelper */ - public AttList(NamedNodeMap attrs, DOMHelper dh) + public AttList(NamedNodeMap attrs) { - m_attrs = attrs; m_lastIndex = m_attrs.getLength() - 1; - m_dh = dh; } /** @@ -96,7 +76,7 @@ */ public String getURI(int index) { - String ns = m_dh.getNamespaceOfNode(((Attr) m_attrs.item(index))); + String ns = DOM2Helper.getNamespaceOfNode(((Attr) m_attrs.item(index))); if(null == ns) ns = ""; return ns; @@ -112,7 +92,7 @@ */ public String getLocalName(int index) { - return m_dh.getLocalNameOfNode(((Attr) m_attrs.item(index))); + return DOM2Helper.getLocalNameOfNode(((Attr) m_attrs.item(index))); } /** diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOM2Helper.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOM2Helper.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOM2Helper.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,6 +1,5 @@ /* - * reserved comment block - * DO NOT REMOVE OR ALTER! + * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved. */ /* * Licensed to the Apache Software Foundation (ASF) under one or more @@ -18,298 +17,327 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - package com.sun.org.apache.xml.internal.utils; -import java.io.IOException; - -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.ParserConfigurationException; -import javax.xml.transform.TransformerException; - +import com.sun.org.apache.xml.internal.dtm.ref.DTMNodeProxy; import org.w3c.dom.Attr; -import org.w3c.dom.Document; -import org.w3c.dom.Element; +import org.w3c.dom.NamedNodeMap; import org.w3c.dom.Node; -import org.xml.sax.InputSource; /** - * @deprecated Since the introduction of the DTM, this class will be removed. - * This class provides a DOM level 2 "helper", which provides services currently - * not provided be the DOM standard. + * This class provides a DOM level 2 "helper", which provides several services. + * + * The original class extended DOMHelper that was deprecated and then removed. */ -public class DOM2Helper extends DOMHelper -{ - - /** - * Construct an instance. - */ - public DOM2Helper(){} +public final class DOM2Helper { - /** - * Check node to see if it was created by a DOM implementation - * that this helper is intended to support. This is currently - * disabled, and assumes all nodes are acceptable rather than checking - * that they implement com.sun.org.apache.xerces.internal.dom.NodeImpl. - * - * @param node The node to be tested. - * - * @throws TransformerException if the node is not one which this - * DOM2Helper can support. If we return without throwing the exception, - * the node is compatable. - * @xsl.usage internal - */ - public void checkNode(Node node) throws TransformerException - { - - // if(!(node instanceof com.sun.org.apache.xerces.internal.dom.NodeImpl)) - // throw new TransformerException(XSLMessages.createXPATHMessage(XPATHErrorResources.ER_XERCES_CANNOT_HANDLE_NODES, new Object[]{((Object)node).getClass()})); //"DOM2Helper can not handle nodes of type" - //+((Object)node).getClass()); - } + /** + * Construct an instance. + */ + private DOM2Helper() { + } - /** - * Returns true if the DOM implementation handled by this helper - * supports the SAX ContentHandler interface. - * - * @return true (since Xerces does). - */ - public boolean supportsSAX() - { - return true; - } - - /** Field m_doc: Document Node for the document this helper is currently - * accessing or building - * @see #setDocument - * @see #getDocument - * */ - private Document m_doc; + /** + * Returns the local name of the given node, as defined by the XML + * Namespaces specification. This is prepared to handle documents built + * using DOM Level 1 methods by falling back upon explicitly parsing the + * node name. + * + * @param n Node to be examined + * + * @return String containing the local name, or null if the node was not + * assigned a Namespace. + */ + public static String getLocalNameOfNode(Node n) { - /** - * Specify which document this helper is currently operating on. - * - * @param doc The DOM Document node for this document. - * @see #getDocument - */ - public void setDocument(Document doc) - { - m_doc = doc; - } + String name = n.getLocalName(); - /** - * Query which document this helper is currently operating on. - * - * @return The DOM Document node for this document. - * @see #setDocument - */ - public Document getDocument() - { - return m_doc; - } + return (null == name) ? getLocalNameOfNodeFallback(n) : name; + } - /** - * Parse an XML document. - * - *

    Right now the Xerces DOMParser class is used. This needs - * fixing, either via jaxp, or via some other, standard method.

    - * - *

    The application can use this method to instruct the SAX parser - * to begin parsing an XML document from any valid input - * source (a character stream, a byte stream, or a URI).

    - * - *

    Applications may not invoke this method while a parse is in - * progress (they should create a new Parser instead for each - * additional XML document). Once a parse is complete, an - * application may reuse the same Parser object, possibly with a - * different input source.

    - * - * @param source The input source for the top-level of the - * XML document. - * - * @throws TransformerException if any checked exception is thrown. - * @xsl.usage internal - */ - public void parse(InputSource source) throws TransformerException - { + /** + * Returns the local name of the given node. If the node's name begins with + * a namespace prefix, this is the part after the colon; otherwise it's the + * full node name. + * + * This method is copied from + * com.sun.org.apache.xml.internal.utils.DOMHelper + * + * @param n the node to be examined. + * + * @return String containing the Local Name + */ + private static String getLocalNameOfNodeFallback(Node n) { - try - { - - // I guess I should use JAXP factory here... when it's legal. - // com.sun.org.apache.xerces.internal.parsers.DOMParser parser - // = new com.sun.org.apache.xerces.internal.parsers.DOMParser(); - DocumentBuilderFactory builderFactory = - DocumentBuilderFactory.newInstance(); - - builderFactory.setNamespaceAware(true); - builderFactory.setValidating(true); + String qname = n.getNodeName(); + int index = qname.indexOf(':'); - DocumentBuilder parser = builderFactory.newDocumentBuilder(); - - /* - // domParser.setFeature("http://apache.org/xml/features/dom/create-entity-ref-nodes", getShouldExpandEntityRefs()? false : true); - if(m_useDOM2getNamespaceURI) - { - parser.setFeature("http://apache.org/xml/features/dom/defer-node-expansion", true); - parser.setFeature("http://xml.org/sax/features/namespaces", true); - } - else - { - parser.setFeature("http://apache.org/xml/features/dom/defer-node-expansion", false); - } - - parser.setFeature("http://apache.org/xml/features/allow-java-encodings", true); - */ + return (index < 0) ? qname : qname.substring(index + 1); + } - parser.setErrorHandler( - new com.sun.org.apache.xml.internal.utils.DefaultErrorHandler()); - - // if(null != m_entityResolver) - // { - // System.out.println("Setting the entity resolver."); - // parser.setEntityResolver(m_entityResolver); - // } - setDocument(parser.parse(source)); - } - catch (org.xml.sax.SAXException se) - { - throw new TransformerException(se); - } - catch (ParserConfigurationException pce) - { - throw new TransformerException(pce); - } - catch (IOException ioe) - { - throw new TransformerException(ioe); + /** + * Returns the Namespace Name (Namespace URI) for the given node. In a Level + * 2 DOM, you can ask the node itself. Note, however, that doing so + * conflicts with our decision in getLocalNameOfNode not to trust the that + * the DOM was indeed created using the Level 2 methods. If Level 1 methods + * were used, these two functions will disagree with each other. + *

    + * TODO: Reconcile with getLocalNameOfNode. + * + * @param n Node to be examined + * + * @return String containing the Namespace URI bound to this DOM node at the + * time the Node was created. + */ + public static String getNamespaceOfNode(Node n) { + return n.getNamespaceURI(); } - // setDocument(((com.sun.org.apache.xerces.internal.parsers.DOMParser)parser).getDocument()); - } + /** + * Figure out whether node2 should be considered as being later in the + * document than node1, in Document Order as defined by the XPath model. + * This may not agree with the ordering defined by other XML applications. + *

    + * There are some cases where ordering isn't defined, and neither are the + * results of this function -- though we'll generally return true. + * + * @param node1 DOM Node to perform position comparison on. + * @param node2 DOM Node to perform position comparison on . + * + * @return false if node2 comes before node1, otherwise return true. You can + * think of this as + * {@code (node1.documentOrderPosition <= node2.documentOrderPosition)}. + */ + public static boolean isNodeAfter(Node node1, Node node2) { + if (node1 == node2 || isNodeTheSame(node1, node2)) { + return true; + } + + // Default return value, if there is no defined ordering + boolean isNodeAfter = true; + + Node parent1 = getParentOfNode(node1); + Node parent2 = getParentOfNode(node2); - /** - * Given an XML ID, return the element. This requires assistance from the - * DOM and parser, and is meaningful only in the context of a DTD - * or schema which declares attributes as being of type ID. This - * information may or may not be available in all parsers, may or - * may not be available for specific documents, and may or may not - * be available when validation is not turned on. - * - * @param id The ID to search for, as a String. - * @param doc The document to search within, as a DOM Document node. - * @return DOM Element node with an attribute of type ID whose value - * uniquely matches the requested id string, or null if there isn't - * such an element or if the DOM can't answer the question for other - * reasons. - */ - public Element getElementByID(String id, Document doc) - { - return doc.getElementById(id); - } + // Optimize for most common case + if (parent1 == parent2 || isNodeTheSame(parent1, parent2)) // then we know they are siblings + { + if (null != parent1) { + isNodeAfter = isNodeAfterSibling(parent1, node1, node2); + } + } else { + // General strategy: Figure out the lengths of the two + // ancestor chains, reconcile the lengths, and look for + // the lowest common ancestor. If that ancestor is one of + // the nodes being compared, it comes before the other. + // Otherwise perform a sibling compare. + // + // NOTE: If no common ancestor is found, ordering is undefined + // and we return the default value of isNodeAfter. + // Count parents in each ancestor chain + int nParents1 = 2, nParents2 = 2; // include node & parent obtained above + + while (parent1 != null) { + nParents1++; + + parent1 = getParentOfNode(parent1); + } + + while (parent2 != null) { + nParents2++; - /** - * Figure out whether node2 should be considered as being later - * in the document than node1, in Document Order as defined - * by the XPath model. This may not agree with the ordering defined - * by other XML applications. - *

    - * There are some cases where ordering isn't defined, and neither are - * the results of this function -- though we'll generally return true. - *

    - * TODO: Make sure this does the right thing with attribute nodes!!! - * - * @param node1 DOM Node to perform position comparison on. - * @param node2 DOM Node to perform position comparison on . - * - * @return false if node2 comes before node1, otherwise return true. - * You can think of this as - * (node1.documentOrderPosition <= node2.documentOrderPosition). - */ - public static boolean isNodeAfter(Node node1, Node node2) - { + parent2 = getParentOfNode(parent2); + } + + // Initially assume scan for common ancestor starts with + // the input nodes. + Node startNode1 = node1, startNode2 = node2; + + // If one ancestor chain is longer, adjust its start point + // so we're comparing at the same depths + if (nParents1 < nParents2) { + // Adjust startNode2 to depth of startNode1 + int adjust = nParents2 - nParents1; + + for (int i = 0; i < adjust; i++) { + startNode2 = getParentOfNode(startNode2); + } + } else if (nParents1 > nParents2) { + // adjust startNode1 to depth of startNode2 + int adjust = nParents1 - nParents2; + + for (int i = 0; i < adjust; i++) { + startNode1 = getParentOfNode(startNode1); + } + } + + Node prevChild1 = null, prevChild2 = null; // so we can "back up" - // Assume first that the nodes are DTM nodes, since discovering node - // order is massivly faster for the DTM. - if(node1 instanceof DOMOrder && node2 instanceof DOMOrder) - { - int index1 = ((DOMOrder) node1).getUid(); - int index2 = ((DOMOrder) node2).getUid(); + // Loop up the ancestor chain looking for common parent + while (null != startNode1) { + if (startNode1 == startNode2 || isNodeTheSame(startNode1, startNode2)) // common parent? + { + if (null == prevChild1) // first time in loop? + { + + // Edge condition: one is the ancestor of the other. + isNodeAfter = (nParents1 < nParents2) ? true : false; - return index1 <= index2; - } - else - { + break; // from while loop + } else { + // Compare ancestors below lowest-common as siblings + isNodeAfter = isNodeAfterSibling(startNode1, prevChild1, + prevChild2); + + break; // from while loop + } + } // end if(startNode1 == startNode2) - // isNodeAfter will return true if node is after countedNode - // in document order. The base isNodeAfter is sloooow (relatively). - return DOMHelper.isNodeAfter(node1, node2); - } - } + // Move up one level and try again + prevChild1 = startNode1; + startNode1 = getParentOfNode(startNode1); + prevChild2 = startNode2; + startNode2 = getParentOfNode(startNode2); + } // end while(parents exist to examine) + } // end big else (not immediate siblings) + + return isNodeAfter; + } // end isNodeAfter(Node node1, Node node2) - /** - * Get the XPath-model parent of a node. This version takes advantage - * of the DOM Level 2 Attr.ownerElement() method; the base version we - * would otherwise inherit is prepared to fall back on exhaustively - * walking the document to find an Attr's parent. - * - * @param node Node to be examined - * - * @return the DOM parent of the input node, if there is one, or the - * ownerElement if the input node is an Attr, or null if the node is - * a Document, a DocumentFragment, or an orphan. - */ - public static Node getParentOfNode(Node node) - { - Node parent=node.getParentNode(); - if(parent==null && (Node.ATTRIBUTE_NODE == node.getNodeType()) ) - parent=((Attr) node).getOwnerElement(); - return parent; - } + /** + * Use DTMNodeProxy to determine whether two nodes are the same. + * + * @param node1 The first DOM node to compare. + * @param node2 The second DOM node to compare. + * @return true if the two nodes are the same. + */ + public static boolean isNodeTheSame(Node node1, Node node2) { + if (node1 instanceof DTMNodeProxy && node2 instanceof DTMNodeProxy) { + return ((DTMNodeProxy) node1).equals((DTMNodeProxy) node2); + } else { + return (node1 == node2); + } + } + + /** + * Get the XPath-model parent of a node. This version takes advantage of the + * DOM Level 2 Attr.ownerElement() method; the base version we would + * otherwise inherit is prepared to fall back on exhaustively walking the + * document to find an Attr's parent. + * + * @param node Node to be examined + * + * @return the DOM parent of the input node, if there is one, or the + * ownerElement if the input node is an Attr, or null if the node is a + * Document, a DocumentFragment, or an orphan. + */ + public static Node getParentOfNode(Node node) { + Node parent = node.getParentNode(); + if (parent == null && (Node.ATTRIBUTE_NODE == node.getNodeType())) { + parent = ((Attr) node).getOwnerElement(); + } + return parent; + } + + /** + * Figure out if child2 is after child1 in document order. + *

    + * Warning: Some aspects of "document order" are not well defined. For + * example, the order of attributes is considered meaningless in XML, and + * the order reported by our model will be consistent for a given invocation + * but may not match that of either the source file or the serialized + * output. + * + * @param parent Must be the parent of both child1 and child2. + * @param child1 Must be the child of parent and not equal to child2. + * @param child2 Must be the child of parent and not equal to child1. + * @return true if child 2 is after child1 in document order. + */ + private static boolean isNodeAfterSibling(Node parent, Node child1, + Node child2) { + + boolean isNodeAfterSibling = false; + short child1type = child1.getNodeType(); + short child2type = child2.getNodeType(); + + if ((Node.ATTRIBUTE_NODE != child1type) + && (Node.ATTRIBUTE_NODE == child2type)) { + + // always sort attributes before non-attributes. + isNodeAfterSibling = false; + } else if ((Node.ATTRIBUTE_NODE == child1type) + && (Node.ATTRIBUTE_NODE != child2type)) { - /** - * Returns the local name of the given node, as defined by the - * XML Namespaces specification. This is prepared to handle documents - * built using DOM Level 1 methods by falling back upon explicitly - * parsing the node name. - * - * @param n Node to be examined - * - * @return String containing the local name, or null if the node - * was not assigned a Namespace. - */ - public String getLocalNameOfNode(Node n) - { + // always sort attributes before non-attributes. + isNodeAfterSibling = true; + } else if (Node.ATTRIBUTE_NODE == child1type) { + NamedNodeMap children = parent.getAttributes(); + int nNodes = children.getLength(); + boolean found1 = false, found2 = false; + + // Count from the start until we find one or the other. + for (int i = 0; i < nNodes; i++) { + Node child = children.item(i); - String name = n.getLocalName(); + if (child1 == child || isNodeTheSame(child1, child)) { + if (found2) { + isNodeAfterSibling = false; + + break; + } - return (null == name) ? super.getLocalNameOfNode(n) : name; - } + found1 = true; + } else if (child2 == child || isNodeTheSame(child2, child)) { + if (found1) { + isNodeAfterSibling = true; + + break; + } - /** - * Returns the Namespace Name (Namespace URI) for the given node. - * In a Level 2 DOM, you can ask the node itself. Note, however, that - * doing so conflicts with our decision in getLocalNameOfNode not - * to trust the that the DOM was indeed created using the Level 2 - * methods. If Level 1 methods were used, these two functions will - * disagree with each other. - *

    - * TODO: Reconcile with getLocalNameOfNode. - * - * @param n Node to be examined - * - * @return String containing the Namespace URI bound to this DOM node - * at the time the Node was created. - */ - public String getNamespaceOfNode(Node n) - { - return n.getNamespaceURI(); - } + found2 = true; + } + } + } else { + // TODO: Check performance of alternate solution: + // There are two choices here: Count from the start of + // the document until we find one or the other, or count + // from one until we find or fail to find the other. + // Either can wind up scanning all the siblings in the worst + // case, which on a wide document can be a lot of work but + // is more typically is a short list. + // Scanning from the start involves two tests per iteration, + // but it isn't clear that scanning from the middle doesn't + // yield more iterations on average. + // We should run some testcases. + Node child = parent.getFirstChild(); + boolean found1 = false, found2 = false; + + while (null != child) { - /** Field m_useDOM2getNamespaceURI is a compile-time flag which - * gates some of the parser options used to build a DOM -- but - * that code is commented out at this time and nobody else - * references it, so I've commented this out as well. */ - //private boolean m_useDOM2getNamespaceURI = false; + // Node child = children.item(i); + if (child1 == child || isNodeTheSame(child1, child)) { + if (found2) { + isNodeAfterSibling = false; + + break; + } + + found1 = true; + } else if (child2 == child || isNodeTheSame(child2, child)) { + if (found1) { + isNodeAfterSibling = true; + + break; + } + + found2 = true; + } + + child = child.getNextSibling(); + } + } + + return isNodeAfterSibling; + } // end isNodeAfterSibling(Node parent, Node child1, Node child2) } diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMHelper.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMHelper.java Thu Jun 15 13:44:42 2017 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,1330 +0,0 @@ -/* - * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. - */ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -/* - * $Id: DOMHelper.java,v 1.2.4.1 2005/09/15 08:15:40 suresh_emailid Exp $ - */ -package com.sun.org.apache.xml.internal.utils; - -import com.sun.org.apache.xml.internal.dtm.ref.DTMNodeProxy; -import com.sun.org.apache.xml.internal.res.XMLErrorResources; -import com.sun.org.apache.xml.internal.res.XMLMessages; -import java.util.HashMap; -import java.util.Map; -import java.util.Vector; -import javax.xml.XMLConstants; -import javax.xml.parsers.DocumentBuilder; -import javax.xml.parsers.DocumentBuilderFactory; -import javax.xml.parsers.ParserConfigurationException; -import org.w3c.dom.Attr; -import org.w3c.dom.DOMImplementation; -import org.w3c.dom.Document; -import org.w3c.dom.DocumentType; -import org.w3c.dom.Element; -import org.w3c.dom.Entity; -import org.w3c.dom.NamedNodeMap; -import org.w3c.dom.Node; -import org.w3c.dom.Text; - -/** - * @deprecated Since the introduction of the DTM, this class will be removed. - * This class provides a front-end to DOM implementations, providing - * a number of utility functions that either aren't yet standardized - * by the DOM spec or that are defined in optional DOM modules and - * hence may not be present in all DOMs. - */ -public class DOMHelper -{ - - /** - * DOM Level 1 did not have a standard mechanism for creating a new - * Document object. This function provides a DOM-implementation-independent - * abstraction for that for that concept. It's typically used when - * outputting a new DOM as the result of an operation. - *

    - * TODO: This isn't directly compatable with DOM Level 2. - * The Level 2 createDocument call also creates the root - * element, and thus requires that you know what that element will be - * before creating the Document. We should think about whether we want - * to change this code, and the callers, so we can use the DOM's own - * method. (It's also possible that DOM Level 3 may relax this - * sequence, but you may give up some intelligence in the DOM by - * doing so; the intent was that knowing the document type and root - * element might let the DOM automatically switch to a specialized - * subclass for particular kinds of documents.) - * - * @param isSecureProcessing state of the secure processing feature. - * @return The newly created DOM Document object, with no children, or - * null if we can't find a DOM implementation that permits creating - * new empty Documents. - */ - public static Document createDocument(boolean isSecureProcessing) - { - - try - { - - // Use an implementation of the JAVA API for XML Parsing 1.0 to - // create a DOM Document node to contain the result. - DocumentBuilderFactory dfactory = DocumentBuilderFactory.newInstance(); - - dfactory.setNamespaceAware(true); - dfactory.setValidating(true); - - if (isSecureProcessing) - { - try - { - dfactory.setFeature(XMLConstants.FEATURE_SECURE_PROCESSING, true); - } - catch (ParserConfigurationException pce) {} - } - - DocumentBuilder docBuilder = dfactory.newDocumentBuilder(); - Document outNode = docBuilder.newDocument(); - - return outNode; - } - catch (ParserConfigurationException pce) - { - throw new RuntimeException( - XMLMessages.createXMLMessage( - XMLErrorResources.ER_CREATEDOCUMENT_NOT_SUPPORTED, null)); //"createDocument() not supported in XPathContext!"); - - // return null; - } - } - - /** - * DOM Level 1 did not have a standard mechanism for creating a new - * Document object. This function provides a DOM-implementation-independent - * abstraction for that for that concept. It's typically used when - * outputting a new DOM as the result of an operation. - * - * @return The newly created DOM Document object, with no children, or - * null if we can't find a DOM implementation that permits creating - * new empty Documents. - */ - public static Document createDocument() - { - return createDocument(false); - } - - /** - * Tells, through the combination of the default-space attribute - * on xsl:stylesheet, xsl:strip-space, xsl:preserve-space, and the - * xml:space attribute, whether or not extra whitespace should be stripped - * from the node. Literal elements from template elements should - * not be tested with this function. - * @param textNode A text node from the source tree. - * @return true if the text node should be stripped of extra whitespace. - * - * @throws javax.xml.transform.TransformerException - * @xsl.usage advanced - */ - public boolean shouldStripSourceNode(Node textNode) - throws javax.xml.transform.TransformerException - { - - // return (null == m_envSupport) ? false : m_envSupport.shouldStripSourceNode(textNode); - return false; - } - - /** - * Supports the XPath function GenerateID by returning a unique - * identifier string for any given DOM Node. - *

    - * Warning: The base implementation uses the Node object's hashCode(), - * which is NOT guaranteed to be unique. If that method hasn't been - * overridden in this DOM ipmlementation, most Java implementions will - * derive it from the object's address and should be OK... but if - * your DOM uses a different definition of hashCode (eg hashing the - * contents of the subtree), or if your DOM may have multiple objects - * that represent a single Node in the data structure (eg via proxying), - * you may need to find another way to assign a unique identifier. - *

    - * Also, be aware that if nodes are destroyed and recreated, there is - * an open issue regarding whether an ID may be reused. Currently - * we're assuming that the input document is stable for the duration - * of the XPath/XSLT operation, so this shouldn't arise in this context. - *

    - * (DOM Level 3 is investigating providing a unique node "key", but - * that won't help Level 1 and Level 2 implementations.) - * - * @param node whose identifier you want to obtain - * - * @return a string which should be different for every Node object. - */ - public String getUniqueID(Node node) - { - return "N" + Integer.toHexString(node.hashCode()).toUpperCase(); - } - - /** - * Figure out whether node2 should be considered as being later - * in the document than node1, in Document Order as defined - * by the XPath model. This may not agree with the ordering defined - * by other XML applications. - *

    - * There are some cases where ordering isn't defined, and neither are - * the results of this function -- though we'll generally return true. - * - * TODO: Make sure this does the right thing with attribute nodes!!! - * - * @param node1 DOM Node to perform position comparison on. - * @param node2 DOM Node to perform position comparison on . - * - * @return false if node2 comes before node1, otherwise return true. - * You can think of this as - * (node1.documentOrderPosition <= node2.documentOrderPosition). - */ - public static boolean isNodeAfter(Node node1, Node node2) - { - if (node1 == node2 || isNodeTheSame(node1, node2)) - return true; - - // Default return value, if there is no defined ordering - boolean isNodeAfter = true; - - Node parent1 = getParentOfNode(node1); - Node parent2 = getParentOfNode(node2); - - // Optimize for most common case - if (parent1 == parent2 || isNodeTheSame(parent1, parent2)) // then we know they are siblings - { - if (null != parent1) - isNodeAfter = isNodeAfterSibling(parent1, node1, node2); - else - { - // If both parents are null, ordering is not defined. - // We're returning a value in lieu of throwing an exception. - // Not a case we expect to arise in XPath, but beware if you - // try to reuse this method. - - // We can just fall through in this case, which allows us - // to hit the debugging code at the end of the function. - //return isNodeAfter; - } - } - else - { - - // General strategy: Figure out the lengths of the two - // ancestor chains, reconcile the lengths, and look for - // the lowest common ancestor. If that ancestor is one of - // the nodes being compared, it comes before the other. - // Otherwise perform a sibling compare. - // - // NOTE: If no common ancestor is found, ordering is undefined - // and we return the default value of isNodeAfter. - - // Count parents in each ancestor chain - int nParents1 = 2, nParents2 = 2; // include node & parent obtained above - - while (parent1 != null) - { - nParents1++; - - parent1 = getParentOfNode(parent1); - } - - while (parent2 != null) - { - nParents2++; - - parent2 = getParentOfNode(parent2); - } - - // Initially assume scan for common ancestor starts with - // the input nodes. - Node startNode1 = node1, startNode2 = node2; - - // If one ancestor chain is longer, adjust its start point - // so we're comparing at the same depths - if (nParents1 < nParents2) - { - // Adjust startNode2 to depth of startNode1 - int adjust = nParents2 - nParents1; - - for (int i = 0; i < adjust; i++) - { - startNode2 = getParentOfNode(startNode2); - } - } - else if (nParents1 > nParents2) - { - // adjust startNode1 to depth of startNode2 - int adjust = nParents1 - nParents2; - - for (int i = 0; i < adjust; i++) - { - startNode1 = getParentOfNode(startNode1); - } - } - - Node prevChild1 = null, prevChild2 = null; // so we can "back up" - - // Loop up the ancestor chain looking for common parent - while (null != startNode1) - { - if (startNode1 == startNode2 || isNodeTheSame(startNode1, startNode2)) // common parent? - { - if (null == prevChild1) // first time in loop? - { - - // Edge condition: one is the ancestor of the other. - isNodeAfter = (nParents1 < nParents2) ? true : false; - - break; // from while loop - } - else - { - // Compare ancestors below lowest-common as siblings - isNodeAfter = isNodeAfterSibling(startNode1, prevChild1, - prevChild2); - - break; // from while loop - } - } // end if(startNode1 == startNode2) - - // Move up one level and try again - prevChild1 = startNode1; - startNode1 = getParentOfNode(startNode1); - prevChild2 = startNode2; - startNode2 = getParentOfNode(startNode2); - } // end while(parents exist to examine) - } // end big else (not immediate siblings) - - // WARNING: The following diagnostic won't report the early - // "same node" case. Fix if/when needed. - - /* -- please do not remove... very useful for diagnostics -- - System.out.println("node1 = "+node1.getNodeName()+"("+node1.getNodeType()+")"+ - ", node2 = "+node2.getNodeName() - +"("+node2.getNodeType()+")"+ - ", isNodeAfter = "+isNodeAfter); */ - return isNodeAfter; - } // end isNodeAfter(Node node1, Node node2) - - /** - * Use DTMNodeProxy to determine whether two nodes are the same. - * - * @param node1 The first DOM node to compare. - * @param node2 The second DOM node to compare. - * @return true if the two nodes are the same. - */ - public static boolean isNodeTheSame(Node node1, Node node2) - { - if (node1 instanceof DTMNodeProxy && node2 instanceof DTMNodeProxy) - return ((DTMNodeProxy)node1).equals((DTMNodeProxy)node2); - else - return (node1 == node2); - } - - /** - * Figure out if child2 is after child1 in document order. - *

    - * Warning: Some aspects of "document order" are not well defined. - * For example, the order of attributes is considered - * meaningless in XML, and the order reported by our model will - * be consistant for a given invocation but may not - * match that of either the source file or the serialized output. - * - * @param parent Must be the parent of both child1 and child2. - * @param child1 Must be the child of parent and not equal to child2. - * @param child2 Must be the child of parent and not equal to child1. - * @return true if child 2 is after child1 in document order. - */ - private static boolean isNodeAfterSibling(Node parent, Node child1, - Node child2) - { - - boolean isNodeAfterSibling = false; - short child1type = child1.getNodeType(); - short child2type = child2.getNodeType(); - - if ((Node.ATTRIBUTE_NODE != child1type) - && (Node.ATTRIBUTE_NODE == child2type)) - { - - // always sort attributes before non-attributes. - isNodeAfterSibling = false; - } - else if ((Node.ATTRIBUTE_NODE == child1type) - && (Node.ATTRIBUTE_NODE != child2type)) - { - - // always sort attributes before non-attributes. - isNodeAfterSibling = true; - } - else if (Node.ATTRIBUTE_NODE == child1type) - { - NamedNodeMap children = parent.getAttributes(); - int nNodes = children.getLength(); - boolean found1 = false, found2 = false; - - // Count from the start until we find one or the other. - for (int i = 0; i < nNodes; i++) - { - Node child = children.item(i); - - if (child1 == child || isNodeTheSame(child1, child)) - { - if (found2) - { - isNodeAfterSibling = false; - - break; - } - - found1 = true; - } - else if (child2 == child || isNodeTheSame(child2, child)) - { - if (found1) - { - isNodeAfterSibling = true; - - break; - } - - found2 = true; - } - } - } - else - { - // TODO: Check performance of alternate solution: - // There are two choices here: Count from the start of - // the document until we find one or the other, or count - // from one until we find or fail to find the other. - // Either can wind up scanning all the siblings in the worst - // case, which on a wide document can be a lot of work but - // is more typically is a short list. - // Scanning from the start involves two tests per iteration, - // but it isn't clear that scanning from the middle doesn't - // yield more iterations on average. - // We should run some testcases. - Node child = parent.getFirstChild(); - boolean found1 = false, found2 = false; - - while (null != child) - { - - // Node child = children.item(i); - if (child1 == child || isNodeTheSame(child1, child)) - { - if (found2) - { - isNodeAfterSibling = false; - - break; - } - - found1 = true; - } - else if (child2 == child || isNodeTheSame(child2, child)) - { - if (found1) - { - isNodeAfterSibling = true; - - break; - } - - found2 = true; - } - - child = child.getNextSibling(); - } - } - - return isNodeAfterSibling; - } // end isNodeAfterSibling(Node parent, Node child1, Node child2) - - //========================================================== - // SECTION: Namespace resolution - //========================================================== - - /** - * Get the depth level of this node in the tree (equals 1 for - * a parentless node). - * - * @param n Node to be examined. - * @return the number of ancestors, plus one - * @xsl.usage internal - */ - public short getLevel(Node n) - { - - short level = 1; - - while (null != (n = getParentOfNode(n))) - { - level++; - } - - return level; - } - - /** - * Given an XML Namespace prefix and a context in which the prefix - * is to be evaluated, return the Namespace Name this prefix was - * bound to. Note that DOM Level 3 is expected to provide a version of - * this which deals with the DOM's "early binding" behavior. - * - * Default handling: - * - * @param prefix String containing namespace prefix to be resolved, - * without the ':' which separates it from the localname when used - * in a Node Name. The empty sting signifies the default namespace - * at this point in the document. - * @param namespaceContext Element which provides context for resolution. - * (We could extend this to work for other nodes by first seeking their - * nearest Element ancestor.) - * - * @return a String containing the Namespace URI which this prefix - * represents in the specified context. - */ - public String getNamespaceForPrefix(String prefix, Element namespaceContext) - { - - int type; - Node parent = namespaceContext; - String namespace = null; - - if (prefix.equals("xml")) - { - namespace = QName.S_XMLNAMESPACEURI; // Hardcoded, per Namespace spec - } - else if(prefix.equals("xmlns")) - { - // Hardcoded in the DOM spec, expected to be adopted by - // Namespace spec. NOTE: Namespace declarations _must_ use - // the xmlns: prefix; other prefixes declared as belonging - // to this namespace will not be recognized and should - // probably be rejected by parsers as erroneous declarations. - namespace = "http://www.w3.org/2000/xmlns/"; - } - else - { - // Attribute name for this prefix's declaration - String declname=(prefix=="") - ? "xmlns" - : "xmlns:"+prefix; - - // Scan until we run out of Elements or have resolved the namespace - while ((null != parent) && (null == namespace) - && (((type = parent.getNodeType()) == Node.ELEMENT_NODE) - || (type == Node.ENTITY_REFERENCE_NODE))) - { - if (type == Node.ELEMENT_NODE) - { - - // Look for the appropriate Namespace Declaration attribute, - // either "xmlns:prefix" or (if prefix is "") "xmlns". - // TODO: This does not handle "implicit declarations" - // which may be created when the DOM is edited. DOM Level - // 3 will define how those should be interpreted. But - // this issue won't arise in freshly-parsed DOMs. - - // NOTE: declname is set earlier, outside the loop. - Attr attr=((Element)parent).getAttributeNode(declname); - if(attr!=null) - { - namespace = attr.getNodeValue(); - break; - } - } - - parent = getParentOfNode(parent); - } - } - - return namespace; - } - - /** - * An experiment for the moment. - */ - Map m_NSInfos = new HashMap<>(); - - /** Object to put into the m_NSInfos table that tells that a node has not been - * processed, but has xmlns namespace decls. */ - protected static final NSInfo m_NSInfoUnProcWithXMLNS = new NSInfo(false, - true); - - /** Object to put into the m_NSInfos table that tells that a node has not been - * processed, but has no xmlns namespace decls. */ - protected static final NSInfo m_NSInfoUnProcWithoutXMLNS = new NSInfo(false, - false); - - /** Object to put into the m_NSInfos table that tells that a node has not been - * processed, and has no xmlns namespace decls, and has no ancestor decls. */ - protected static final NSInfo m_NSInfoUnProcNoAncestorXMLNS = - new NSInfo(false, false, NSInfo.ANCESTORNOXMLNS); - - /** Object to put into the m_NSInfos table that tells that a node has been - * processed, and has xmlns namespace decls. */ - protected static final NSInfo m_NSInfoNullWithXMLNS = new NSInfo(true, - true); - - /** Object to put into the m_NSInfos table that tells that a node has been - * processed, and has no xmlns namespace decls. */ - protected static final NSInfo m_NSInfoNullWithoutXMLNS = new NSInfo(true, - false); - - /** Object to put into the m_NSInfos table that tells that a node has been - * processed, and has no xmlns namespace decls. and has no ancestor decls. */ - protected static final NSInfo m_NSInfoNullNoAncestorXMLNS = - new NSInfo(true, false, NSInfo.ANCESTORNOXMLNS); - - /** Vector of node (odd indexes) and NSInfos (even indexes) that tell if - * the given node is a candidate for ancestor namespace processing. */ - protected Vector m_candidateNoAncestorXMLNS = new Vector(); - - /** - * Returns the namespace of the given node. Differs from simply getting - * the node's prefix and using getNamespaceForPrefix in that it attempts - * to cache some of the data in NSINFO objects, to avoid repeated lookup. - * TODO: Should we consider moving that logic into getNamespaceForPrefix? - * - * @param n Node to be examined. - * - * @return String containing the Namespace Name (uri) for this node. - * Note that this is undefined for any nodes other than Elements and - * Attributes. - */ - public String getNamespaceOfNode(Node n) - { - - String namespaceOfPrefix; - boolean hasProcessedNS; - NSInfo nsInfo; - short ntype = n.getNodeType(); - - if (Node.ATTRIBUTE_NODE != ntype) - { - nsInfo = m_NSInfos.get(n); - hasProcessedNS = (nsInfo == null) ? false : nsInfo.m_hasProcessedNS; - } - else - { - hasProcessedNS = false; - nsInfo = null; - } - - if (hasProcessedNS) - { - namespaceOfPrefix = nsInfo.m_namespace; - } - else - { - namespaceOfPrefix = null; - - String nodeName = n.getNodeName(); - int indexOfNSSep = nodeName.indexOf(':'); - String prefix; - - if (Node.ATTRIBUTE_NODE == ntype) - { - if (indexOfNSSep > 0) - { - prefix = nodeName.substring(0, indexOfNSSep); - } - else - { - - // Attributes don't use the default namespace, so if - // there isn't a prefix, we're done. - return namespaceOfPrefix; - } - } - else - { - prefix = (indexOfNSSep >= 0) - ? nodeName.substring(0, indexOfNSSep) : ""; - } - - boolean ancestorsHaveXMLNS = false; - boolean nHasXMLNS = false; - - if (prefix.equals("xml")) - { - namespaceOfPrefix = QName.S_XMLNAMESPACEURI; - } - else - { - int parentType; - Node parent = n; - - while ((null != parent) && (null == namespaceOfPrefix)) - { - if ((null != nsInfo) - && (nsInfo.m_ancestorHasXMLNSAttrs - == NSInfo.ANCESTORNOXMLNS)) - { - break; - } - - parentType = parent.getNodeType(); - - if ((null == nsInfo) || nsInfo.m_hasXMLNSAttrs) - { - boolean elementHasXMLNS = false; - - if (parentType == Node.ELEMENT_NODE) - { - NamedNodeMap nnm = parent.getAttributes(); - - for (int i = 0; i < nnm.getLength(); i++) - { - Node attr = nnm.item(i); - String aname = attr.getNodeName(); - - if (aname.charAt(0) == 'x') - { - boolean isPrefix = aname.startsWith("xmlns:"); - - if (aname.equals("xmlns") || isPrefix) - { - if (n == parent) - nHasXMLNS = true; - - elementHasXMLNS = true; - ancestorsHaveXMLNS = true; - - String p = isPrefix ? aname.substring(6) : ""; - - if (p.equals(prefix)) - { - namespaceOfPrefix = attr.getNodeValue(); - - break; - } - } - } - } - } - - if ((Node.ATTRIBUTE_NODE != parentType) && (null == nsInfo) - && (n != parent)) - { - nsInfo = elementHasXMLNS - ? m_NSInfoUnProcWithXMLNS : m_NSInfoUnProcWithoutXMLNS; - - m_NSInfos.put(parent, nsInfo); - } - } - - if (Node.ATTRIBUTE_NODE == parentType) - { - parent = getParentOfNode(parent); - } - else - { - m_candidateNoAncestorXMLNS.addElement(parent); - m_candidateNoAncestorXMLNS.addElement(nsInfo); - - parent = parent.getParentNode(); - } - - if (null != parent) - { - nsInfo = m_NSInfos.get(parent); - } - } - - int nCandidates = m_candidateNoAncestorXMLNS.size(); - - if (nCandidates > 0) - { - if ((false == ancestorsHaveXMLNS) && (null == parent)) - { - for (int i = 0; i < nCandidates; i += 2) - { - Object candidateInfo = m_candidateNoAncestorXMLNS.elementAt(i - + 1); - - if (candidateInfo == m_NSInfoUnProcWithoutXMLNS) - { - m_NSInfos.put((Node)m_candidateNoAncestorXMLNS.elementAt(i), - m_NSInfoUnProcNoAncestorXMLNS); - } - else if (candidateInfo == m_NSInfoNullWithoutXMLNS) - { - m_NSInfos.put((Node)m_candidateNoAncestorXMLNS.elementAt(i), - m_NSInfoNullNoAncestorXMLNS); - } - } - } - - m_candidateNoAncestorXMLNS.removeAllElements(); - } - } - - if (Node.ATTRIBUTE_NODE != ntype) - { - if (null == namespaceOfPrefix) - { - if (ancestorsHaveXMLNS) - { - if (nHasXMLNS) - m_NSInfos.put(n, m_NSInfoNullWithXMLNS); - else - m_NSInfos.put(n, m_NSInfoNullWithoutXMLNS); - } - else - { - m_NSInfos.put(n, m_NSInfoNullNoAncestorXMLNS); - } - } - else - { - m_NSInfos.put(n, new NSInfo(namespaceOfPrefix, nHasXMLNS)); - } - } - } - - return namespaceOfPrefix; - } - - /** - * Returns the local name of the given node. If the node's name begins - * with a namespace prefix, this is the part after the colon; otherwise - * it's the full node name. - * - * @param n the node to be examined. - * - * @return String containing the Local Name - */ - public String getLocalNameOfNode(Node n) - { - - String qname = n.getNodeName(); - int index = qname.indexOf(':'); - - return (index < 0) ? qname : qname.substring(index + 1); - } - - /** - * Returns the element name with the namespace prefix (if any) replaced - * by the Namespace URI it was bound to. This is not a standard - * representation of a node name, but it allows convenient - * single-string comparison of the "universal" names of two nodes. - * - * @param elem Element to be examined. - * - * @return String in the form "namespaceURI:localname" if the node - * belongs to a namespace, or simply "localname" if it doesn't. - * @see #getExpandedAttributeName - */ - public String getExpandedElementName(Element elem) - { - - String namespace = getNamespaceOfNode(elem); - - return (null != namespace) - ? namespace + ":" + getLocalNameOfNode(elem) - : getLocalNameOfNode(elem); - } - - /** - * Returns the attribute name with the namespace prefix (if any) replaced - * by the Namespace URI it was bound to. This is not a standard - * representation of a node name, but it allows convenient - * single-string comparison of the "universal" names of two nodes. - * - * @param attr Attr to be examined - * - * @return String in the form "namespaceURI:localname" if the node - * belongs to a namespace, or simply "localname" if it doesn't. - * @see #getExpandedElementName - */ - public String getExpandedAttributeName(Attr attr) - { - - String namespace = getNamespaceOfNode(attr); - - return (null != namespace) - ? namespace + ":" + getLocalNameOfNode(attr) - : getLocalNameOfNode(attr); - } - - //========================================================== - // SECTION: DOM Helper Functions - //========================================================== - - /** - * Tell if the node is ignorable whitespace. Note that this can - * be determined only in the context of a DTD or other Schema, - * and that DOM Level 2 has nostandardized DOM API which can - * return that information. - * @deprecated - * - * @param node Node to be examined - * - * @return CURRENTLY HARDCODED TO FALSE, but should return true if - * and only if the node is of type Text, contains only whitespace, - * and does not appear as part of the #PCDATA content of an element. - * (Note that determining this last may require allowing for - * Entity References.) - */ - public boolean isIgnorableWhitespace(Text node) - { - - boolean isIgnorable = false; // return value - - // TODO: I can probably do something to figure out if this - // space is ignorable from just the information in - // the DOM tree. - // -- You need to be able to distinguish whitespace - // that is #PCDATA from whitespace that isn't. That requires - // DTD support, which won't be standardized until DOM Level 3. - return isIgnorable; - } - - /** - * Get the first unparented node in the ancestor chain. - * @deprecated - * - * @param node Starting node, to specify which chain to chase - * - * @return the topmost ancestor. - */ - public Node getRoot(Node node) - { - - Node root = null; - - while (node != null) - { - root = node; - node = getParentOfNode(node); - } - - return root; - } - - /** - * Get the root node of the document tree, regardless of - * whether or not the node passed in is a document node. - *

    - * TODO: This doesn't handle DocumentFragments or "orphaned" subtrees - * -- it's currently returning ownerDocument even when the tree is - * not actually part of the main Document tree. We should either - * rewrite the description to say that it finds the Document node, - * or change the code to walk up the ancestor chain. - - * - * @param n Node to be examined - * - * @return the Document node. Note that this is not the correct answer - * if n was (or was a child of) a DocumentFragment or an orphaned node, - * as can arise if the DOM has been edited rather than being generated - * by a parser. - */ - public Node getRootNode(Node n) - { - int nt = n.getNodeType(); - return ( (Node.DOCUMENT_NODE == nt) || (Node.DOCUMENT_FRAGMENT_NODE == nt) ) - ? n : n.getOwnerDocument(); - } - - /** - * Test whether the given node is a namespace decl node. In DOM Level 2 - * this can be done in a namespace-aware manner, but in Level 1 DOMs - * it has to be done by testing the node name. - * - * @param n Node to be examined. - * - * @return boolean -- true iff the node is an Attr whose name is - * "xmlns" or has the "xmlns:" prefix. - */ - public boolean isNamespaceNode(Node n) - { - - if (Node.ATTRIBUTE_NODE == n.getNodeType()) - { - String attrName = n.getNodeName(); - - return (attrName.startsWith("xmlns:") || attrName.equals("xmlns")); - } - - return false; - } - - /** - * Obtain the XPath-model parent of a DOM node -- ownerElement for Attrs, - * parent for other nodes. - *

    - * Background: The DOM believes that you must be your Parent's - * Child, and thus Attrs don't have parents. XPath said that Attrs - * do have their owning Element as their parent. This function - * bridges the difference, either by using the DOM Level 2 ownerElement - * function or by using a "silly and expensive function" in Level 1 - * DOMs. - *

    - * (There's some discussion of future DOMs generalizing ownerElement - * into ownerNode and making it work on all types of nodes. This - * still wouldn't help the users of Level 1 or Level 2 DOMs) - *

    - * - * @param node Node whose XPath parent we want to obtain - * - * @return the parent of the node, or the ownerElement if it's an - * Attr node, or null if the node is an orphan. - * - * @throws RuntimeException if the Document has no root element. - * This can't arise if the Document was created - * via the DOM Level 2 factory methods, but is possible if other - * mechanisms were used to obtain it - */ - public static Node getParentOfNode(Node node) throws RuntimeException - { - Node parent; - short nodeType = node.getNodeType(); - - if (Node.ATTRIBUTE_NODE == nodeType) - { - Document doc = node.getOwnerDocument(); - /* - TBD: - if(null == doc) - { - throw new RuntimeException(XSLMessages.createXPATHMessage(XPATHErrorResources.ER_CHILD_HAS_NO_OWNER_DOCUMENT, null));//"Attribute child does not have an owner document!"); - } - */ - - // Given how expensive the tree walk may be, we should first ask - // whether this DOM can answer the question for us. The additional - // test does slow down Level 1 DOMs slightly. DOMHelper2, which - // is currently specialized for Xerces, assumes it can use the - // Level 2 solution. We might want to have an intermediate stage, - // which would assume DOM Level 2 but not assume Xerces. - // - // (Shouldn't have to check whether impl is null in a compliant DOM, - // but let's be paranoid for a moment...) - DOMImplementation impl=doc.getImplementation(); - if(impl!=null && impl.hasFeature("Core","2.0")) - { - parent=((Attr)node).getOwnerElement(); - return parent; - } - - // DOM Level 1 solution, as fallback. Hugely expensive. - - Element rootElem = doc.getDocumentElement(); - - if (null == rootElem) - { - throw new RuntimeException( - XMLMessages.createXMLMessage( - XMLErrorResources.ER_CHILD_HAS_NO_OWNER_DOCUMENT_ELEMENT, - null)); //"Attribute child does not have an owner document element!"); - } - - parent = locateAttrParent(rootElem, node); - - } - else - { - parent = node.getParentNode(); - - // if((Node.DOCUMENT_NODE != nodeType) && (null == parent)) - // { - // throw new RuntimeException("Child does not have parent!"); - // } - } - - return parent; - } - - /** - * Given an ID, return the element. This can work only if the document - * is interpreted in the context of a DTD or Schema, since otherwise - * we don't know which attributes are or aren't IDs. - *

    - * Note that DOM Level 1 had no ability to retrieve this information. - * DOM Level 2 introduced it but does not promise that it will be - * supported in all DOMs; those which can't support it will always - * return null. - *

    - * TODO: getElementByID is currently unimplemented. Support DOM Level 2? - * - * @param id The unique identifier to be searched for. - * @param doc The document to search within. - * @return CURRENTLY HARDCODED TO NULL, but it should be: - * The node which has this unique identifier, or null if there - * is no such node or this DOM can't reliably recognize it. - */ - public Element getElementByID(String id, Document doc) - { - return null; - } - - /** - * The getUnparsedEntityURI function returns the URI of the unparsed - * entity with the specified name in the same document as the context - * node (see [3.3 Unparsed Entities]). It returns the empty string if - * there is no such entity. - *

    - * XML processors may choose to use the System Identifier (if one - * is provided) to resolve the entity, rather than the URI in the - * Public Identifier. The details are dependent on the processor, and - * we would have to support some form of plug-in resolver to handle - * this properly. Currently, we simply return the System Identifier if - * present, and hope that it a usable URI or that our caller can - * map it to one. - * TODO: Resolve Public Identifiers... or consider changing function name. - *

    - * If we find a relative URI - * reference, XML expects it to be resolved in terms of the base URI - * of the document. The DOM doesn't do that for us, and it isn't - * entirely clear whether that should be done here; currently that's - * pushed up to a higher levelof our application. (Note that DOM Level - * 1 didn't store the document's base URI.) - * TODO: Consider resolving Relative URIs. - *

    - * (The DOM's statement that "An XML processor may choose to - * completely expand entities before the structure model is passed - * to the DOM" refers only to parsed entities, not unparsed, and hence - * doesn't affect this function.) - * - * @param name A string containing the Entity Name of the unparsed - * entity. - * @param doc Document node for the document to be searched. - * - * @return String containing the URI of the Unparsed Entity, or an - * empty string if no such entity exists. - */ - public String getUnparsedEntityURI(String name, Document doc) - { - - String url = ""; - DocumentType doctype = doc.getDoctype(); - - if (null != doctype) - { - NamedNodeMap entities = doctype.getEntities(); - if(null == entities) - return url; - Entity entity = (Entity) entities.getNamedItem(name); - if(null == entity) - return url; - - String notationName = entity.getNotationName(); - - if (null != notationName) // then it's unparsed - { - // The draft says: "The XSLT processor may use the public - // identifier to generate a URI for the entity instead of the URI - // specified in the system identifier. If the XSLT processor does - // not use the public identifier to generate the URI, it must use - // the system identifier; if the system identifier is a relative - // URI, it must be resolved into an absolute URI using the URI of - // the resource containing the entity declaration as the base - // URI [RFC2396]." - // So I'm falling a bit short here. - url = entity.getSystemId(); - - if (null == url) - { - url = entity.getPublicId(); - } - else - { - // This should be resolved to an absolute URL, but that's hard - // to do from here. - } - } - } - - return url; - } - - /** - * Support for getParentOfNode; walks a DOM tree until it finds - * the Element which owns the Attr. This is hugely expensive, and - * if at all possible you should use the DOM Level 2 Attr.ownerElement() - * method instead. - *

    - * The DOM Level 1 developers expected that folks would keep track - * of the last Element they'd seen and could recover the info from - * that source. Obviously that doesn't work very well if the only - * information you've been presented with is the Attr. The DOM Level 2 - * getOwnerElement() method fixes that, but only for Level 2 and - * later DOMs. - * - * @param elem Element whose subtree is to be searched for this Attr - * @param attr Attr whose owner is to be located. - * - * @return the first Element whose attribute list includes the provided - * attr. In modern DOMs, this will also be the only such Element. (Early - * DOMs had some hope that Attrs might be sharable, but this idea has - * been abandoned.) - */ - private static Node locateAttrParent(Element elem, Node attr) - { - - Node parent = null; - - // This should only be called for Level 1 DOMs, so we don't have to - // worry about namespace issues. In later levels, it's possible - // for a DOM to have two Attrs with the same NodeName but - // different namespaces, and we'd need to get getAttributeNodeNS... - // but later levels also have Attr.getOwnerElement. - Attr check=elem.getAttributeNode(attr.getNodeName()); - if(check==attr) - parent = elem; - - if (null == parent) - { - for (Node node = elem.getFirstChild(); null != node; - node = node.getNextSibling()) - { - if (Node.ELEMENT_NODE == node.getNodeType()) - { - parent = locateAttrParent((Element) node, attr); - - if (null != parent) - break; - } - } - } - - return parent; - } - - /** - * The factory object used for creating nodes - * in the result tree. - */ - protected Document m_DOMFactory = null; - - /** - * Store the factory object required to create DOM nodes - * in the result tree. In fact, that's just the result tree's - * Document node... - * - * @param domFactory The DOM Document Node within whose context - * the result tree will be built. - */ - public void setDOMFactory(Document domFactory) - { - this.m_DOMFactory = domFactory; - } - - /** - * Retrieve the factory object required to create DOM nodes - * in the result tree. - * - * @return The result tree's DOM Document Node. - */ - public Document getDOMFactory() - { - - if (null == this.m_DOMFactory) - { - this.m_DOMFactory = createDocument(); - } - - return this.m_DOMFactory; - } - - /** - * Get the textual contents of the node. See - * getNodeData(Node,FastStringBuffer) for discussion of how - * whitespace nodes are handled. - * - * @param node DOM Node to be examined - * @return String containing a concatenation of all the - * textual content within that node. - * @see #getNodeData(Node,FastStringBuffer) - * - */ - public static String getNodeData(Node node) - { - - FastStringBuffer buf = StringBufferPool.get(); - String s; - - try - { - getNodeData(node, buf); - - s = (buf.length() > 0) ? buf.toString() : ""; - } - finally - { - StringBufferPool.free(buf); - } - - return s; - } - - /** - * Retrieve the text content of a DOM subtree, appending it into a - * user-supplied FastStringBuffer object. Note that attributes are - * not considered part of the content of an element. - *

    - * There are open questions regarding whitespace stripping. - * Currently we make no special effort in that regard, since the standard - * DOM doesn't yet provide DTD-based information to distinguish - * whitespace-in-element-context from genuine #PCDATA. Note that we - * should probably also consider xml:space if/when we address this. - * DOM Level 3 may solve the problem for us. - * - * @param node Node whose subtree is to be walked, gathering the - * contents of all Text or CDATASection nodes. - * @param buf FastStringBuffer into which the contents of the text - * nodes are to be concatenated. - */ - public static void getNodeData(Node node, FastStringBuffer buf) - { - - switch (node.getNodeType()) - { - case Node.DOCUMENT_FRAGMENT_NODE : - case Node.DOCUMENT_NODE : - case Node.ELEMENT_NODE : - { - for (Node child = node.getFirstChild(); null != child; - child = child.getNextSibling()) - { - getNodeData(child, buf); - } - } - break; - case Node.TEXT_NODE : - case Node.CDATA_SECTION_NODE : - buf.append(node.getNodeValue()); - break; - case Node.ATTRIBUTE_NODE : - buf.append(node.getNodeValue()); - break; - case Node.PROCESSING_INSTRUCTION_NODE : - // warning(XPATHErrorResources.WG_PARSING_AND_PREPARING); - break; - default : - // ignore - break; - } - } -} diff -r ea7475564d07 -r ca0e16b2d5d6 jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMOrder.java --- a/jaxp/src/java.xml/share/classes/com/sun/org/apache/xml/internal/utils/DOMOrder.java Thu Jun 15 13:44:42 2017 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,42 +0,0 @@ -/* - * reserved comment block - * DO NOT REMOVE OR ALTER! - */ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.sun.org.apache.xml.internal.utils; - -/** - * @deprecated Since the introduction of the DTM, this class will be removed. - * Nodes that implement this index can return a document order index. - * Eventually, this will be replaced by DOM 3 methods. - * (compareDocumentOrder and/or compareTreePosition.) - */ -public interface DOMOrder -{ - - /** - * Get the UID (document order index). - * - * @return integer whose relative value corresponds to document order - * -- that is, if node1.getUid() excludes = Arrays.asList( + "deploy.jar", + "javaws.jar", + "plugin.jar", + "cldrdata.jar", + "localedata.jar" + ); + private static void usage() { + System.out.println("ListPackages [-o ] [-jdkinternals] []*"); + } + + private static final Set EXPORTED_PACKAGES = new HashSet<>(); + + public static void main(String... args) throws IOException { + List paths = new ArrayList<>(); + Path outFile = null; + boolean jdkinternals = false; + int i=0; + while (i < args.length) { + String arg = args[i++]; + if (arg.equals("-o")) { + outFile = Paths.get(args[i++]); + } else if (arg.equals("-jdkinternals")) { + jdkinternals = true; + } else { + Path p = Paths.get(arg); + if (Files.notExists(p)) + throw new IllegalArgumentException(p + " not exist"); + paths.add(p); + } + } + if (paths.isEmpty()) { + usage(); + System.exit(1); + } + + // Get the exported APIs from the current JDK releases + Path javaHome = Paths.get(System.getProperty("java.home")); + ModuleFinder.ofSystem().findAll() + .stream() + .map(ModuleReference::descriptor) + .filter(md -> !md.name().equals("jdk.unsupported")) + .flatMap(md -> md.exports().stream()) + .filter(exp -> !exp.isQualified()) + .map(ModuleDescriptor.Exports::source) + .forEach(EXPORTED_PACKAGES::add); + + ListPackages listPackages = new ListPackages(paths); + Stream pkgs = listPackages.packages().stream(); + if (jdkinternals) { + pkgs = pkgs.filter(pn -> !EXPORTED_PACKAGES.contains(pn)); + } + if (outFile != null) { + try (OutputStream out = Files.newOutputStream(outFile); + PrintStream pw = new PrintStream(out)) { + write(pw, pkgs); + } + } else { + write(System.out, pkgs); + } + } + + + private static void write(PrintStream pw, Stream packages) { + pw.println("# This file is auto-generated by ListPackages tool on " + + LocalDateTime.now().toString()); + packages.sorted().forEach(pw::println); + } + + private final Set packages = new HashSet<>(); + ListPackages(List dirs) throws IOException { + for (Path p : dirs) { + packages.addAll(list(p)); + } + } + + Set packages() { + return packages; + } + + private Set list(Path javaHome) throws IOException { + Path jrt = javaHome.resolve("lib").resolve("modules"); + Path jre = javaHome.resolve("jre"); + + if (Files.exists(jrt)) { + return listModularRuntime(javaHome); + } else if (Files.exists(jre.resolve("lib").resolve("rt.jar"))) { + return listLegacyRuntime(javaHome); + } + throw new IllegalArgumentException("invalid " + javaHome); + } + + private Set listModularRuntime(Path javaHome) throws IOException { + Map env = new HashMap<>(); + env.put("java.home", javaHome.toString()); + FileSystem fs = FileSystems.newFileSystem(URI.create("jrt:/"), env); + Path root = fs.getPath("packages"); + return Files.walk(root, 1) + .map(Path::getFileName) + .map(Path::toString) + .collect(Collectors.toSet()); + } + + private Set listLegacyRuntime(Path javaHome) throws IOException { + List dirs = new ArrayList<>(); + Path jre = javaHome.resolve("jre"); + Path lib = javaHome.resolve("lib"); + + dirs.add(jre.resolve("lib")); + dirs.add(jre.resolve("lib").resolve("ext")); + dirs.add(lib.resolve("tools.jar")); + dirs.add(lib.resolve("jconsole.jar")); + Set packages = new HashSet<>(); + for (Path d : dirs) { + Files.find(d, 1, (Path p, BasicFileAttributes attr) + -> p.getFileName().toString().endsWith(".jar") && + !excludes.contains(p.getFileName().toString())) + .map(ListPackages::walkJarFile) + .forEach(packages::addAll); + } + return packages; + } + + static Set walkJarFile(Path jarfile) { + try (JarFile jf = new JarFile(jarfile.toFile())) { + return jf.stream() + .map(JarEntry::getName) + .filter(n -> n.endsWith(".class")) + .map(ListPackages::toPackage) + .collect(Collectors.toSet()); + } catch (IOException e) { + throw new UncheckedIOException(e); + } + } + + static String toPackage(String name) { + int i = name.lastIndexOf('/'); + if (i < 0) { + System.err.format("Warning: unnamed package %s%n", name); + } + return i >= 0 ? name.substring(0, i).replace("/", ".") : ""; + } +} diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/RuntimePermission.java --- a/jdk/src/java.base/share/classes/java/lang/RuntimePermission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/RuntimePermission.java Wed Jul 05 23:40:06 2017 +0200 @@ -403,6 +403,7 @@ * * @author Marianne Mueller * @author Roland Schemers + * @since 1.2 */ public final class RuntimePermission extends BasicPermission { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/invoke/LambdaForm.java --- a/jdk/src/java.base/share/classes/java/lang/invoke/LambdaForm.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/invoke/LambdaForm.java Wed Jul 05 23:40:06 2017 +0200 @@ -1092,13 +1092,24 @@ final MemberName member; private @Stable MethodHandle resolvedHandle; @Stable MethodHandle invoker; + private final MethodHandleImpl.Intrinsic intrinsicName; NamedFunction(MethodHandle resolvedHandle) { - this(resolvedHandle.internalMemberName(), resolvedHandle); + this(resolvedHandle.internalMemberName(), resolvedHandle, MethodHandleImpl.Intrinsic.NONE); + } + NamedFunction(MethodHandle resolvedHandle, MethodHandleImpl.Intrinsic intrinsic) { + this(resolvedHandle.internalMemberName(), resolvedHandle, intrinsic); } NamedFunction(MemberName member, MethodHandle resolvedHandle) { + this(member, resolvedHandle, MethodHandleImpl.Intrinsic.NONE); + } + NamedFunction(MemberName member, MethodHandle resolvedHandle, MethodHandleImpl.Intrinsic intrinsic) { this.member = member; this.resolvedHandle = resolvedHandle; + this.intrinsicName = intrinsic; + assert(resolvedHandle == null || + resolvedHandle.intrinsicName() == MethodHandleImpl.Intrinsic.NONE || + resolvedHandle.intrinsicName() == intrinsic) : resolvedHandle.intrinsicName() + " != " + intrinsic; // The following assert is almost always correct, but will fail for corner cases, such as PrivateInvokeTest. //assert(!isInvokeBasic(member)); } @@ -1111,6 +1122,7 @@ // necessary to pass BigArityTest this.member = Invokers.invokeBasicMethod(basicInvokerType); } + this.intrinsicName = MethodHandleImpl.Intrinsic.NONE; assert(isInvokeBasic(member)); } @@ -1263,8 +1275,7 @@ } public MethodHandleImpl.Intrinsic intrinsicName() { - return resolvedHandle == null ? MethodHandleImpl.Intrinsic.NONE - : resolvedHandle.intrinsicName(); + return intrinsicName; } } @@ -1741,15 +1752,15 @@ Name[] idNames = new Name[] { argument(0, L_TYPE), argument(1, type) }; idForm = new LambdaForm(2, idNames, 1, Kind.IDENTITY); idForm.compileToBytecode(); - idFun = new NamedFunction(idMem, MethodHandleImpl.makeIntrinsic( - idMem.getInvocationType(), idForm, MethodHandleImpl.Intrinsic.IDENTITY)); + idFun = new NamedFunction(idMem, SimpleMethodHandle.make(idMem.getInvocationType(), idForm), + MethodHandleImpl.Intrinsic.IDENTITY); Object zeValue = Wrapper.forBasicType(btChar).zero(); Name[] zeNames = new Name[] { argument(0, L_TYPE), new Name(idFun, zeValue) }; zeForm = new LambdaForm(1, zeNames, 1, Kind.ZERO); zeForm.compileToBytecode(); - zeFun = new NamedFunction(zeMem, MethodHandleImpl.makeIntrinsic( - zeMem.getInvocationType(), zeForm, MethodHandleImpl.Intrinsic.ZERO)); + zeFun = new NamedFunction(zeMem, SimpleMethodHandle.make(zeMem.getInvocationType(), zeForm), + MethodHandleImpl.Intrinsic.ZERO); } LF_zero[ord] = zeForm; diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormEditor.java --- a/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormEditor.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/invoke/LambdaFormEditor.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2017, Oracle and/or its affiliates. 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 @@ -541,7 +541,7 @@ // adjust the arguments MethodHandle aload = MethodHandles.arrayElementGetter(erasedArrayType); for (int i = 0; i < arrayLength; i++) { - Name loadArgument = new Name(aload, spreadParam, i); + Name loadArgument = new Name(new NamedFunction(aload, Intrinsic.ARRAY_LOAD), spreadParam, i); buf.insertExpression(exprPos + i, loadArgument); buf.replaceParameterByCopy(pos + i, exprPos + i); } @@ -604,7 +604,8 @@ for (int i = 0; i < collectorArity; i++) { newParams[i] = new Name(pos + i, argType); } - Name callCombiner = new Name(arrayCollector, (Object[]) /*...*/ newParams); + Name callCombiner = new Name(new NamedFunction(arrayCollector, Intrinsic.NEW_ARRAY), + (Object[]) /*...*/ newParams); // insert the new expression int exprPos = lambdaForm.arity(); diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java --- a/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/invoke/MethodHandleImpl.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. 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 @@ -592,7 +592,7 @@ names[nameCursor++] = new Name(getFunction(NF_checkSpreadArgument), array, spreadArgCount); for (int j = 0; j < spreadArgCount; i++, j++) { indexes[i] = nameCursor; - names[nameCursor++] = new Name(aload, array, j); + names[nameCursor++] = new Name(new NamedFunction(aload, Intrinsic.ARRAY_LOAD), array, j); } } else if (i < indexes.length) { indexes[i] = argIndex; @@ -937,7 +937,7 @@ names[PROFILE] = new Name(getFunction(NF_profileBoolean), names[CALL_TEST], names[GET_COUNTERS]); } // call selectAlternative - names[SELECT_ALT] = new Name(getConstantHandle(MH_selectAlternative), names[TEST], names[GET_TARGET], names[GET_FALLBACK]); + names[SELECT_ALT] = new Name(new NamedFunction(getConstantHandle(MH_selectAlternative), Intrinsic.SELECT_ALTERNATIVE), names[TEST], names[GET_TARGET], names[GET_FALLBACK]); // call target or fallback invokeArgs[0] = names[SELECT_ALT]; @@ -1008,7 +1008,7 @@ Object[] args = new Object[invokeBasic.type().parameterCount()]; args[0] = names[GET_COLLECT_ARGS]; System.arraycopy(names, ARG_BASE, args, 1, ARG_LIMIT-ARG_BASE); - names[BOXED_ARGS] = new Name(makeIntrinsic(invokeBasic, Intrinsic.GUARD_WITH_CATCH), args); + names[BOXED_ARGS] = new Name(new NamedFunction(invokeBasic, Intrinsic.GUARD_WITH_CATCH), args); // t_{i+1}:L=MethodHandleImpl.guardWithCatch(target:L,exType:L,catcher:L,t_{i}:L); Object[] gwcArgs = new Object[] {names[GET_TARGET], names[GET_CLASS], names[GET_CATCHER], names[BOXED_ARGS]}; @@ -1896,7 +1896,7 @@ Object[] args = new Object[invokeBasic.type().parameterCount()]; args[0] = names[GET_COLLECT_ARGS]; System.arraycopy(names, ARG_BASE, args, 1, ARG_LIMIT - ARG_BASE); - names[BOXED_ARGS] = new Name(makeIntrinsic(invokeBasic, Intrinsic.LOOP), args); + names[BOXED_ARGS] = new Name(new NamedFunction(invokeBasic, Intrinsic.LOOP), args); // t_{i+1}:L=MethodHandleImpl.loop(localTypes:L,clauses:L,t_{i}:L); Object[] lArgs = @@ -2133,7 +2133,7 @@ Object[] args = new Object[invokeBasic.type().parameterCount()]; args[0] = names[GET_COLLECT_ARGS]; System.arraycopy(names, ARG_BASE, args, 1, ARG_LIMIT-ARG_BASE); - names[BOXED_ARGS] = new Name(makeIntrinsic(invokeBasic, Intrinsic.TRY_FINALLY), args); + names[BOXED_ARGS] = new Name(new NamedFunction(invokeBasic, Intrinsic.TRY_FINALLY), args); // t_{i+1}:L=MethodHandleImpl.tryFinally(target:L,exType:L,catcher:L,t_{i}:L); Object[] tfArgs = new Object[] {names[GET_TARGET], names[GET_CLEANUP], names[BOXED_ARGS]}; @@ -2225,9 +2225,8 @@ return IMPL_LOOKUP.findStatic(MethodHandleImpl.class, "fillNewTypedArray", MethodType.methodType(Object[].class, Object[].class, Integer.class, Object[].class)); case MH_selectAlternative: - return makeIntrinsic(IMPL_LOOKUP.findStatic(MethodHandleImpl.class, "selectAlternative", - MethodType.methodType(MethodHandle.class, boolean.class, MethodHandle.class, MethodHandle.class)), - Intrinsic.SELECT_ALTERNATIVE); + return IMPL_LOOKUP.findStatic(MethodHandleImpl.class, "selectAlternative", + MethodType.methodType(MethodHandle.class, boolean.class, MethodHandle.class, MethodHandle.class)); case MH_countedLoopPred: return IMPL_LOOKUP.findStatic(MethodHandleImpl.class, "countedLoopPredicate", MethodType.methodType(boolean.class, int.class, int.class)); diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/invoke/package-info.java --- a/jdk/src/java.base/share/classes/java/lang/invoke/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/invoke/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2017, Oracle and/or its affiliates. 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 @@ -44,13 +44,13 @@ * * * - *

    Summary of relevant Java Virtual Machine changes

    + *

    Summary of relevant Java Virtual Machine changes

    * The following low-level information summarizes relevant parts of the * Java Virtual Machine specification. For full details, please see the * current version of that specification. * * Each occurrence of an {@code invokedynamic} instruction is called a dynamic call site. - *

    {@code invokedynamic} instructions

    + *

    {@code invokedynamic} instructions

    * A dynamic call site is originally in an unlinked state. In this state, there is * no target method for the call site to invoke. *

    @@ -77,7 +77,8 @@ *

    * The bootstrap method is invoked on at least three values: *

      - *
    • a {@code MethodHandles.Lookup}, a lookup object on the caller class in which dynamic call site occurs
    • + *
    • a {@code MethodHandles.Lookup}, a lookup object on the caller class + * in which dynamic call site occurs
    • *
    • a {@code String}, the method name mentioned in the call site
    • *
    • a {@code MethodType}, the resolved type descriptor of the call
    • *
    • optionally, between 1 and 251 additional static arguments taken from the constant pool
    • @@ -165,17 +166,27 @@ * Given these rules, here are examples of legal bootstrap method declarations, * given various numbers {@code N} of extra arguments. * The first rows (marked {@code *}) will work for any number of extra arguments. - *
    - * - * - * - * - * - * - * - * - * - * + *
    Nsample bootstrap method
    *CallSite bootstrap(Lookup caller, String name, MethodType type, Object... args)
    *CallSite bootstrap(Object... args)
    *CallSite bootstrap(Object caller, Object... nameAndTypeWithArgs)
    0CallSite bootstrap(Lookup caller, String name, MethodType type)
    0CallSite bootstrap(Lookup caller, Object... nameAndType)
    1CallSite bootstrap(Lookup caller, String name, MethodType type, Object arg)
    2CallSite bootstrap(Lookup caller, String name, MethodType type, Object... args)
    2CallSite bootstrap(Lookup caller, String name, MethodType type, String... args)
    2CallSite bootstrap(Lookup caller, String name, MethodType type, String x, int y)
    + * + * + * + * + * + * + * + * + * + * + * + * + * *
    Static argument types
    NSample bootstrap method
    *CallSite bootstrap(Lookup caller, String name, MethodType type, Object... args)
    * + * CallSite bootstrap(Object... args)
    * + * CallSite bootstrap(Object caller, Object... nameAndTypeWithArgs)
    0 + * CallSite bootstrap(Lookup caller, String name, MethodType type)
    0 + * CallSite bootstrap(Lookup caller, Object... nameAndType)
    1 + * CallSite bootstrap(Lookup caller, String name, MethodType type, Object arg)
    2 + * CallSite bootstrap(Lookup caller, String name, MethodType type, Object... args)
    2 + * CallSite bootstrap(Lookup caller, String name, MethodType type, String... args)
    2CallSite bootstrap(Lookup caller, String name, MethodType type, String x, int y)
    * The last example assumes that the extra arguments are of type * {@code CONSTANT_String} and {@code CONSTANT_Integer}, respectively. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/module/package-info.java --- a/jdk/src/java.base/share/classes/java/lang/module/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/module/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -27,7 +27,7 @@ * Classes to support module descriptors and creating configurations of modules * by means of resolution and service binding. * - *

    Resolution

    + *

    Resolution

    * *

    Resolution is the process of computing the transitive closure of a set * of root modules over a set of observable modules by resolving the @@ -97,7 +97,7 @@ * resolved so that it reads all other modules in the resulting configuration and * all modules in parent configurations.

    * - *

    Service binding

    + *

    Service binding

    * *

    Service binding is the process of augmenting a graph of resolved modules * from the set of observable modules induced by the service-use dependence diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/package-info.java --- a/jdk/src/java.base/share/classes/java/lang/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. 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 @@ -57,7 +57,7 @@ * by the {@code throw} statement. Subclasses of {@code Throwable} * represent errors and exceptions. * - * + * *

    Character Encodings

    * * The specification of the {@link java.nio.charset.Charset diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/reflect/Array.java --- a/jdk/src/java.base/share/classes/java/lang/reflect/Array.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/reflect/Array.java Wed Jul 05 23:40:06 2017 +0200 @@ -36,6 +36,7 @@ * conversion would occur. * * @author Nakul Saraiya + * @since 1.1 */ public final class Array { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/reflect/Constructor.java --- a/jdk/src/java.base/share/classes/java/lang/reflect/Constructor.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/reflect/Constructor.java Wed Jul 05 23:40:06 2017 +0200 @@ -59,6 +59,7 @@ * * @author Kenneth Russell * @author Nakul Saraiya + * @since 1.1 */ public final class Constructor extends Executable { private Class clazz; diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/reflect/Field.java --- a/jdk/src/java.base/share/classes/java/lang/reflect/Field.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/reflect/Field.java Wed Jul 05 23:40:06 2017 +0200 @@ -60,6 +60,7 @@ * * @author Kenneth Russell * @author Nakul Saraiya + * @since 1.1 */ public final class Field extends AccessibleObject implements Member { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/reflect/InvocationTargetException.java --- a/jdk/src/java.base/share/classes/java/lang/reflect/InvocationTargetException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/reflect/InvocationTargetException.java Wed Jul 05 23:40:06 2017 +0200 @@ -38,6 +38,7 @@ * * @see Method * @see Constructor + * @since 1.1 */ public class InvocationTargetException extends ReflectiveOperationException { /** diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/reflect/Member.java --- a/jdk/src/java.base/share/classes/java/lang/reflect/Member.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/reflect/Member.java Wed Jul 05 23:40:06 2017 +0200 @@ -35,6 +35,7 @@ * @see Constructor * * @author Nakul Saraiya + * @since 1.1 */ public interface Member { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/reflect/Method.java --- a/jdk/src/java.base/share/classes/java/lang/reflect/Method.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/reflect/Method.java Wed Jul 05 23:40:06 2017 +0200 @@ -63,6 +63,7 @@ * * @author Kenneth Russell * @author Nakul Saraiya + * @since 1.1 */ public final class Method extends Executable { private Class clazz; diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/lang/reflect/Modifier.java --- a/jdk/src/java.base/share/classes/java/lang/reflect/Modifier.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/lang/reflect/Modifier.java Wed Jul 05 23:40:06 2017 +0200 @@ -43,6 +43,7 @@ * * @author Nakul Saraiya * @author Kenneth Russell + * @since 1.1 */ public class Modifier { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/math/BigDecimal.java --- a/jdk/src/java.base/share/classes/java/math/BigDecimal.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/math/BigDecimal.java Wed Jul 05 23:40:06 2017 +0200 @@ -222,6 +222,7 @@ * @author Mike Cowlishaw * @author Joseph D. Darcy * @author Sergey V. Kuksenko + * @since 1.1 */ public class BigDecimal extends Number implements Comparable { /** diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/net/InetAddress.java --- a/jdk/src/java.base/share/classes/java/net/InetAddress.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/net/InetAddress.java Wed Jul 05 23:40:06 2017 +0200 @@ -75,7 +75,7 @@ *
    * * - * + * * - * + * * diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/net/NetPermission.java --- a/jdk/src/java.base/share/classes/java/net/NetPermission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/net/NetPermission.java Wed Jul 05 23:40:06 2017 +0200 @@ -167,6 +167,7 @@ * * @author Marianne Mueller * @author Roland Schemers + * @since 1.2 */ public final class NetPermission extends BasicPermission { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/net/SocketOptions.java --- a/jdk/src/java.base/share/classes/java/net/SocketOptions.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/net/SocketOptions.java Wed Jul 05 23:40:06 2017 +0200 @@ -40,6 +40,7 @@ * DatagramSocket and MulticastSocket. * * @author David Brown + * @since 1.1 */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/net/SocketPermission.java --- a/jdk/src/java.base/share/classes/java/net/SocketPermission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/net/SocketPermission.java Wed Jul 05 23:40:06 2017 +0200 @@ -142,6 +142,7 @@ * * @author Marianne Mueller * @author Roland Schemers + * @since 1.2 * * @serial exclude */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/net/URI.java --- a/jdk/src/java.base/share/classes/java/net/URI.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/net/URI.java Wed Jul 05 23:40:06 2017 +0200 @@ -253,32 +253,32 @@ * which are taken from that specification, are used below to describe these * constraints: * - *
    Description of unicast and multicast address types
    unicast
    unicastAn identifier for a single interface. A packet sent to * a unicast address is delivered to the interface identified by * that address. @@ -94,7 +94,7 @@ * IP address loops around and becomes IP input on the local * host. This address is often used when testing a * client.
    multicast
    multicastAn identifier for a set of interfaces (typically belonging * to different nodes). A packet sent to a multicast address is * delivered to all interfaces identified by that address.
    + *
    * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * *
    Describes categories alpha,digit,alphanum,unreserved,punct,reserved,escaped,and other
    alpha
    alphaThe US-ASCII alphabetic characters, * {@code 'A'} through {@code 'Z'} * and {@code 'a'} through {@code 'z'}
    digit
    digitThe US-ASCII decimal digit characters, * {@code '0'} through {@code '9'}
    alphanum
    alphanumAll alpha and digit characters
    unreserved    
    unreserved    All alphanum characters together with those in the string * {@code "_-!.~'()*"}
    punct
    punctThe characters in the string {@code ",;:$&+="}
    reserved
    reservedAll punct characters together with those in the string * {@code "?/[]@"}
    escaped
    escapedEscaped octets, that is, triplets consisting of the percent * character ({@code '%'}) followed by two hexadecimal digits * ({@code '0'}-{@code '9'}, {@code 'A'}-{@code 'F'}, and * {@code 'a'}-{@code 'f'})
    other
    otherThe Unicode characters that are not in the US-ASCII character set, * are not control characters (according to the {@link * java.lang.Character#isISOControl(char) Character.isISOControl} diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/net/doc-files/net-properties.html --- a/jdk/src/java.base/share/classes/java/net/doc-files/net-properties.html Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/net/doc-files/net-properties.html Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,6 @@ + - Networking Properties -

    Networking Properties

    -

    There are a few standard system properties used to +

    Networking Properties

    +

    There are a few standard system properties used to alter the mechanisms and behavior of the various classes of the java.net package. Some are checked only once at startup of the VM, and therefore are best set using the -D option of the java command, @@ -39,7 +39,7 @@ The purpose of this document is to list and detail all of these properties.

    If there is no special note, a property value is checked every time it is used.

    - +

    IPv4 / IPv6

    • java.net.preferIPv4Stack (default: false)
      @@ -62,7 +62,7 @@ returned by the operating system.

    Both of these properties are checked only once, at startup.

    - +

    Proxies

    A proxy server allows indirect connection to network services and is used mainly for security (to get through firewalls) and @@ -155,7 +155,7 @@ globally through their user interface). Note that this property is checked only once at startup.

    - +

    Misc HTTP properties

    • http.agent (default: “Java/<version>”)
      @@ -214,7 +214,7 @@

    All these properties are checked only once at startup.

    - +

    Address Cache

    The java.net package, when doing name resolution, uses an address cache for both security and performance reasons. Any address diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/nio/channels/package-info.java --- a/jdk/src/java.base/share/classes/java/nio/channels/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/nio/channels/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2017, Oracle and/or its affiliates. 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 @@ -28,33 +28,46 @@ * performing I/O operations, such as files and sockets; defines selectors, for * multiplexed, non-blocking I/O operations. * - * + * * - *

    - * - * + *
    ChannelsDescription
    {@link java.nio.channels.Channel}
    + * + * + * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * - * - * + * + * + * * - * + * * - * + * * - * + * * - * + * * *
    Lists channels and their descriptions
    ChannelsDescription
    {@link java.nio.channels.Channel}A nexus for I/O operations
      {@link java.nio.channels.ReadableByteChannel}
    + *   {@link java.nio.channels.ReadableByteChannel}Can read into a buffer
        {@link java.nio.channels.ScatteringByteChannel}  
    + *     {@link java.nio.channels.ScatteringByteChannel}  Can read into a sequence of buffers
      {@link java.nio.channels.WritableByteChannel}
    + *   {@link java.nio.channels.WritableByteChannel}Can write from a buffer
        {@link java.nio.channels.GatheringByteChannel}
    + *     {@link java.nio.channels.GatheringByteChannel}Can write from a sequence of buffers
      {@link java.nio.channels.ByteChannel}
    + *   {@link java.nio.channels.ByteChannel}Can read/write to/from a buffer
        {@link java.nio.channels.SeekableByteChannel}A {@code ByteChannel} connected to an entity that contains a variable-length sequence of bytes
      {@link java.nio.channels.AsynchronousChannel}
    + *     {@link java.nio.channels.SeekableByteChannel}A {@code ByteChannel} connected to an entity that contains a variable-length + * sequence of bytes
    + *   {@link java.nio.channels.AsynchronousChannel}Supports asynchronous I/O operations.
        {@link java.nio.channels.AsynchronousByteChannel}
    + *     {@link java.nio.channels.AsynchronousByteChannel}Can read and write bytes asynchronously
      {@link java.nio.channels.NetworkChannel}
    + *   {@link java.nio.channels.NetworkChannel}A channel to a network socket
        {@link java.nio.channels.MulticastChannel}
    + *     {@link java.nio.channels.MulticastChannel}Can join Internet Protocol (IP) multicast groups
    {@link java.nio.channels.Channels}
    {@link java.nio.channels.Channels}Utility methods for channel/stream interoperation
    * @@ -109,13 +122,19 @@ * be constructed that uses a given charset to encode characters into bytes and * write them to a given writable byte channel. * - *
    - * - * + *
    File channelsDescription
    {@link java.nio.channels.FileChannel}
    + * + * + * + * * - * + * * - * + * * *
    + * Lists file channels and their descriptions
    File channelsDescription
    + * {@link java.nio.channels.FileChannel}Reads, writes, maps, and manipulates files
    {@link java.nio.channels.FileLock}
    + * {@link java.nio.channels.FileLock}A lock on a (region of a) file
    {@link java.nio.MappedByteBuffer}  
    + * {@link java.nio.MappedByteBuffer}  A direct byte buffer mapped to a region of a file
    * @@ -136,27 +155,35 @@ * file channel connected to the same underlying file as the {@link java.io} * class. * - * - *
    - * - * + * + *
    Multiplexed, non-blocking I/O

    Description

    {@link java.nio.channels.SelectableChannel}
    + * + * + * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * *
    + * Lists multiplexed, non-blocking channels and their descriptions
    Multiplexed, non-blocking I/ODescription
    {@link java.nio.channels.SelectableChannel}A channel that can be multiplexed
      {@link java.nio.channels.DatagramChannel}
    + *   {@link java.nio.channels.DatagramChannel}A channel to a datagram-oriented socket
      {@link java.nio.channels.Pipe.SinkChannel}
    + *   {@link java.nio.channels.Pipe.SinkChannel}The write end of a pipe
      {@link java.nio.channels.Pipe.SourceChannel}
    + *   {@link java.nio.channels.Pipe.SourceChannel}The read end of a pipe
      {@link java.nio.channels.ServerSocketChannel}  
    + *   {@link java.nio.channels.ServerSocketChannel}  A channel to a stream-oriented listening socket
      {@link java.nio.channels.SocketChannel}
    + *   {@link java.nio.channels.SocketChannel}A channel for a stream-oriented connecting socket
    {@link java.nio.channels.Selector}
    {@link java.nio.channels.Selector}A multiplexor of selectable channels
    {@link java.nio.channels.SelectionKey}
    {@link java.nio.channels.SelectionKey}A token representing the registration
    of a channel * with a selector
    {@link java.nio.channels.Pipe}
    {@link java.nio.channels.Pipe}Two channels that form a unidirectional pipe
    * @@ -222,19 +249,27 @@ * directly; custom channel classes should extend the appropriate {@link * java.nio.channels.SelectableChannel} subclasses defined in this package. * - * + * * - *
    - * - * + *
    Asynchronous I/ODescription
    {@link java.nio.channels.AsynchronousFileChannel}
    + * + * + * * - * + * * - * + * * - * + * * - * + * * *
    + * Lists asynchronous channels and their descriptions
    + * Asynchronous I/ODescription
    + * {@link java.nio.channels.AsynchronousFileChannel}An asynchronous channel for reading, writing, and manipulating a file
    {@link java.nio.channels.AsynchronousSocketChannel}
    + * {@link java.nio.channels.AsynchronousSocketChannel}An asynchronous channel to a stream-oriented connecting socket
    {@link java.nio.channels.AsynchronousServerSocketChannel}  
    + * {@link java.nio.channels.AsynchronousServerSocketChannel}  An asynchronous channel to a stream-oriented listening socket
    {@link java.nio.channels.CompletionHandler}
    + * {@link java.nio.channels.CompletionHandler}A handler for consuming the result of an asynchronous operation
    {@link java.nio.channels.AsynchronousChannelGroup}
    + * {@link java.nio.channels.AsynchronousChannelGroup}A grouping of asynchronous channels for the purpose of resource sharing
    * @@ -277,7 +312,6 @@ * so that sophisticated users can take advantage of operating-system-specific * asynchronous I/O mechanisms when very high performance is required. * - *
    *

    Unless otherwise noted, passing a {@code null} argument to a constructor * or method in any class or interface in this package will cause a {@link * java.lang.NullPointerException NullPointerException} to be thrown. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/nio/charset/package-info.java --- a/jdk/src/java.base/share/classes/java/nio/charset/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/nio/charset/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -27,17 +27,19 @@ * Defines charsets, decoders, and encoders, for translating between * bytes and Unicode characters. * - *

    - * - * + *
    Class nameDescription
    {@link java.nio.charset.Charset}
    + * + * + * * - * + * * - * + * * - * + * * - * + * * * *
    Summary of charsets, decoders, and encoders in this package
    Class nameDescriptiPath + *
    {@link java.nio.charset.Charset}A named mapping between characters
    and bytes
    {@link java.nio.charset.CharsetDecoder}
    {@link java.nio.charset.CharsetDecoder}Decodes bytes into characters
    {@link java.nio.charset.CharsetEncoder}  
    {@link java.nio.charset.CharsetEncoder}Encodes characters into bytes
    {@link java.nio.charset.CoderResult}  
    {@link java.nio.charset.CoderResult}Describes coder results
    {@link java.nio.charset.CodingErrorAction}  
    {@link java.nio.charset.CodingErrorAction}Describes actions to take when
    coding errors are detected
    diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/nio/file/attribute/package-info.java --- a/jdk/src/java.base/share/classes/java/nio/file/attribute/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/nio/file/attribute/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -26,25 +26,41 @@ /** * Interfaces and classes providing access to file and file system attributes. * - *
    - * - * + *
    Attribute viewsDescription
    {@link java.nio.file.attribute.AttributeView}
    + * + * + * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * *
    Attribute views
    Attribute viewsDescription
    {@link java.nio.file.attribute.AttributeView}Can read or update non-opaque values associated with objects in a file system
      {@link java.nio.file.attribute.FileAttributeView}
    + *   {@link java.nio.file.attribute.FileAttributeView}Can read or update file attributes
        {@link java.nio.file.attribute.BasicFileAttributeView}  
    + *      + * {@link java.nio.file.attribute.BasicFileAttributeView}  Can read or update a basic set of file attributes
          {@link java.nio.file.attribute.PosixFileAttributeView}  
    + *        + * {@link java.nio.file.attribute.PosixFileAttributeView}  Can read or update POSIX defined file attributes
          {@link java.nio.file.attribute.DosFileAttributeView}  
    + *        + * {@link java.nio.file.attribute.DosFileAttributeView}  Can read or update FAT file attributes
        {@link java.nio.file.attribute.FileOwnerAttributeView}  
    + *      + * {@link java.nio.file.attribute.FileOwnerAttributeView}  Can read or update the owner of a file
         {@link java.nio.file.attribute.AclFileAttributeView}  
    + *       + * {@link java.nio.file.attribute.AclFileAttributeView}  Can read or update Access Control Lists
        {@link java.nio.file.attribute.UserDefinedFileAttributeView}  
    + *      + * {@link java.nio.file.attribute.UserDefinedFileAttributeView}  Can read or update user-defined file attributes
      {@link java.nio.file.attribute.FileStoreAttributeView}
    + *   {@link java.nio.file.attribute.FileStoreAttributeView}Can read or update file system attributes
    * diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/nio/file/package-info.java --- a/jdk/src/java.base/share/classes/java/nio/file/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/nio/file/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2017, Oracle and/or its affiliates. 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 @@ -33,7 +33,7 @@ * package is used by service provider implementors wishing to extend the * platform default provider, or to construct other provider implementations.

    * - *

    Symbolic Links

    + *

    Symbolic Links

    *

    Many operating systems and file systems support for symbolic links. * A symbolic link is a special file that serves as a reference to another file. * For the most part, symbolic links are transparent to applications and @@ -45,7 +45,7 @@ * that are semantically close but support for these other types of links is * not included in this package.

    * - *

    Interoperability

    + *

    Interoperability

    *

    The {@link java.io.File} class defines the {@link java.io.File#toPath * toPath} method to construct a {@link java.nio.file.Path} by converting * the abstract path represented by the {@code java.io.File} object. The resulting @@ -65,7 +65,7 @@ * or on some other machine. The exact nature of any such inconsistencies are * system-dependent and are therefore unspecified.

    * - *

    Synchronized I/O File Integrity

    + *

    Synchronized I/O File Integrity

    *

    The {@link java.nio.file.StandardOpenOption#SYNC SYNC} and {@link * java.nio.file.StandardOpenOption#DSYNC DSYNC} options are used when opening a file * to require that updates to the file are written synchronously to the underlying diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/nio/package-info.java --- a/jdk/src/java.base/share/classes/java/nio/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/nio/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2017, Oracle and/or its affiliates. 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 @@ -60,30 +60,33 @@ * the contents of which can be used to extend the platform's default * implementations or to construct alternative implementations. * - * + * * - *

    - * - * + *
    BuffersDescription
    {@link java.nio.Buffer}
    + * + * + * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * - * + * * *
    Description of the various buffers
    BuffersDescription
    {@link java.nio.Buffer}Position, limit, and capacity; *
    clear, flip, rewind, and mark/reset
      {@link java.nio.ByteBuffer}
      {@link java.nio.ByteBuffer}Get/put, compact, views; allocate, wrap
        {@link java.nio.MappedByteBuffer}  
    + *     {@link java.nio.MappedByteBuffer}  A byte buffer mapped to a file
      {@link java.nio.CharBuffer}
      {@link java.nio.CharBuffer}Get/put, compact; allocate, wrap
      {@link java.nio.DoubleBuffer}
      {@link java.nio.DoubleBuffer}    ' '
      {@link java.nio.FloatBuffer}
      {@link java.nio.FloatBuffer}    ' '
      {@link java.nio.IntBuffer}
      {@link java.nio.IntBuffer}    ' '
      {@link java.nio.LongBuffer}
      {@link java.nio.LongBuffer}    ' '
      {@link java.nio.ShortBuffer}
      {@link java.nio.ShortBuffer}    ' '
    {@link java.nio.ByteOrder}
    {@link java.nio.ByteOrder}Typesafe enumeration for byte orders
    * diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/AccessControlContext.java --- a/jdk/src/java.base/share/classes/java/security/AccessControlContext.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/AccessControlContext.java Wed Jul 05 23:40:06 2017 +0200 @@ -74,6 +74,7 @@ * @see AccessController * * @author Roland Schemers + * @since 1.2 */ public final class AccessControlContext { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/AccessControlException.java --- a/jdk/src/java.base/share/classes/java/security/AccessControlException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/AccessControlException.java Wed Jul 05 23:40:06 2017 +0200 @@ -38,6 +38,7 @@ * * @author Li Gong * @author Roland Schemers + * @since 1.2 */ public class AccessControlException extends SecurityException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/AccessController.java --- a/jdk/src/java.base/share/classes/java/security/AccessController.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/AccessController.java Wed Jul 05 23:40:06 2017 +0200 @@ -259,6 +259,7 @@ * * @author Li Gong * @author Roland Schemers + * @since 1.2 */ public final class AccessController { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/AlgorithmParameterGenerator.java --- a/jdk/src/java.base/share/classes/java/security/AlgorithmParameterGenerator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/AlgorithmParameterGenerator.java Wed Jul 05 23:40:06 2017 +0200 @@ -61,11 +61,17 @@ * * *

    In case the client does not explicitly initialize the - * AlgorithmParameterGenerator - * (via a call to an {@code init} method), each provider must supply (and - * document) a default initialization. For example, the Sun provider uses a - * default modulus prime size of 1024 bits for the generation of DSA - * parameters. + * AlgorithmParameterGenerator (via a call to an {@code init} method), + * each provider must supply (and document) a default initialization. + * See the Keysize Restriction sections of the + * + * JDK Providers + * document for information on the AlgorithmParameterGenerator defaults + * used by JDK providers. + * However, note that defaults may vary across different providers. + * Additionally, the default value for a provider may change in a future + * version. Therefore, it is recommended to explicitly initialize the + * AlgorithmParameterGenerator instead of relying on provider-specific defaults. * *

    Every implementation of the Java platform is required to support the * following standard {@code AlgorithmParameterGenerator} algorithms and diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/AlgorithmParameterGeneratorSpi.java --- a/jdk/src/java.base/share/classes/java/security/AlgorithmParameterGeneratorSpi.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/AlgorithmParameterGeneratorSpi.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. 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 @@ -39,8 +39,15 @@ *

    In case the client does not explicitly initialize the * AlgorithmParameterGenerator (via a call to an {@code engineInit} * method), each provider must supply (and document) a default initialization. - * For example, the Sun provider uses a default modulus prime size of 1024 - * bits for the generation of DSA parameters. + * See the Keysize Restriction sections of the + * + * JDK Providers + * document for information on the AlgorithmParameterGenerator defaults + * used by JDK providers. + * However, note that defaults may vary across different providers. + * Additionally, the default value for a provider may change in a future + * version. Therefore, it is recommended to explicitly initialize the + * AlgorithmParameterGenerator instead of relying on provider-specific defaults. * * @author Jan Luehe * diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/AllPermission.java --- a/jdk/src/java.base/share/classes/java/security/AllPermission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/AllPermission.java Wed Jul 05 23:40:06 2017 +0200 @@ -51,6 +51,7 @@ * * * @author Roland Schemers + * @since 1.2 * * @serial exclude */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/BasicPermission.java --- a/jdk/src/java.base/share/classes/java/security/BasicPermission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/BasicPermission.java Wed Jul 05 23:40:06 2017 +0200 @@ -62,6 +62,7 @@ * * @author Marianne Mueller * @author Roland Schemers + * @since 1.2 */ public abstract class BasicPermission extends Permission diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Certificate.java --- a/jdk/src/java.base/share/classes/java/security/Certificate.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Certificate.java Wed Jul 05 23:40:06 2017 +0200 @@ -56,6 +56,7 @@ * the certificate and satisfy itself of its validity. * * @author Benjamin Renaud + * @since 1.1 * @deprecated A new certificate handling package is created in the Java platform. * This Certificate interface is entirely deprecated and * is here to allow for a smooth transition to the new diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/CodeSource.java --- a/jdk/src/java.base/share/classes/java/security/CodeSource.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/CodeSource.java Wed Jul 05 23:40:06 2017 +0200 @@ -44,6 +44,7 @@ * * @author Li Gong * @author Roland Schemers + * @since 1.2 */ public class CodeSource implements java.io.Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/DigestException.java --- a/jdk/src/java.base/share/classes/java/security/DigestException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/DigestException.java Wed Jul 05 23:40:06 2017 +0200 @@ -29,6 +29,7 @@ * This is the generic Message Digest exception. * * @author Benjamin Renaud + * @since 1.1 */ public class DigestException extends GeneralSecurityException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/DigestInputStream.java --- a/jdk/src/java.base/share/classes/java/security/DigestInputStream.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/DigestInputStream.java Wed Jul 05 23:40:06 2017 +0200 @@ -59,6 +59,7 @@ * @see DigestOutputStream * * @author Benjamin Renaud + * @since 1.2 */ public class DigestInputStream extends FilterInputStream { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/DigestOutputStream.java --- a/jdk/src/java.base/share/classes/java/security/DigestOutputStream.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/DigestOutputStream.java Wed Jul 05 23:40:06 2017 +0200 @@ -51,6 +51,7 @@ * @see DigestInputStream * * @author Benjamin Renaud + * @since 1.2 */ public class DigestOutputStream extends FilterOutputStream { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/GeneralSecurityException.java --- a/jdk/src/java.base/share/classes/java/security/GeneralSecurityException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/GeneralSecurityException.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * security-related exception classes that extend from it. * * @author Jan Luehe + * @since 1.2 */ public class GeneralSecurityException extends Exception { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Guard.java --- a/jdk/src/java.base/share/classes/java/security/Guard.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Guard.java Wed Jul 05 23:40:06 2017 +0200 @@ -38,6 +38,7 @@ * * @author Roland Schemers * @author Li Gong + * @since 1.2 */ public interface Guard { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/GuardedObject.java --- a/jdk/src/java.base/share/classes/java/security/GuardedObject.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/GuardedObject.java Wed Jul 05 23:40:06 2017 +0200 @@ -44,6 +44,7 @@ * * @author Roland Schemers * @author Li Gong + * @since 1.2 */ public class GuardedObject implements java.io.Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Identity.java --- a/jdk/src/java.base/share/classes/java/security/Identity.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Identity.java Wed Jul 05 23:40:06 2017 +0200 @@ -51,6 +51,7 @@ * @see Principal * * @author Benjamin Renaud + * @since 1.1 * @deprecated This class is no longer used. Its functionality has been * replaced by {@code java.security.KeyStore}, the * {@code java.security.cert} package, and diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/IdentityScope.java --- a/jdk/src/java.base/share/classes/java/security/IdentityScope.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/IdentityScope.java Wed Jul 05 23:40:06 2017 +0200 @@ -55,6 +55,7 @@ * @see Key * * @author Benjamin Renaud + * @since 1.1 * * @deprecated This class is no longer used. Its functionality has been * replaced by {@code java.security.KeyStore}, the diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/InvalidKeyException.java --- a/jdk/src/java.base/share/classes/java/security/InvalidKeyException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/InvalidKeyException.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * length, uninitialized, etc). * * @author Benjamin Renaud + * @since 1.1 */ public class InvalidKeyException extends KeyException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/InvalidParameterException.java --- a/jdk/src/java.base/share/classes/java/security/InvalidParameterException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/InvalidParameterException.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * to a method. * * @author Benjamin Renaud + * @since 1.1 */ public class InvalidParameterException extends IllegalArgumentException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Key.java --- a/jdk/src/java.base/share/classes/java/security/Key.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Key.java Wed Jul 05 23:40:06 2017 +0200 @@ -97,6 +97,7 @@ * @see Signer * * @author Benjamin Renaud + * @since 1.1 */ public interface Key extends java.io.Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/KeyException.java --- a/jdk/src/java.base/share/classes/java/security/KeyException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/KeyException.java Wed Jul 05 23:40:06 2017 +0200 @@ -33,6 +33,7 @@ * @see KeyManagementException * * @author Benjamin Renaud + * @since 1.1 */ public class KeyException extends GeneralSecurityException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/KeyManagementException.java --- a/jdk/src/java.base/share/classes/java/security/KeyManagementException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/KeyManagementException.java Wed Jul 05 23:40:06 2017 +0200 @@ -38,6 +38,7 @@ * * * @author Benjamin Renaud + * @since 1.1 * * @see Key * @see KeyException diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/KeyPair.java --- a/jdk/src/java.base/share/classes/java/security/KeyPair.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/KeyPair.java Wed Jul 05 23:40:06 2017 +0200 @@ -36,6 +36,7 @@ * @see PrivateKey * * @author Benjamin Renaud + * @since 1.1 */ public final class KeyPair implements java.io.Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/KeyPairGenerator.java --- a/jdk/src/java.base/share/classes/java/security/KeyPairGenerator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/KeyPairGenerator.java Wed Jul 05 23:40:06 2017 +0200 @@ -95,8 +95,15 @@ *

    In case the client does not explicitly initialize the KeyPairGenerator * (via a call to an {@code initialize} method), each provider must * supply (and document) a default initialization. - * For example, the Sun provider uses a default modulus size (keysize) - * of 1024 bits for DSA key pairs. + * See the Keysize Restriction sections of the + * + * JDK Providers + * document for information on the KeyPairGenerator defaults used by + * JDK providers. + * However, note that defaults may vary across different providers. + * Additionally, the default value for a provider may change in a future + * version. Therefore, it is recommended to explicitly initialize the + * KeyPairGenerator instead of relying on provider-specific defaults. * *

    Note that this class is abstract and extends from * {@code KeyPairGeneratorSpi} for historical reasons. @@ -121,6 +128,7 @@ * other algorithms are supported. * * @author Benjamin Renaud + * @since 1.1 * * @see java.security.spec.AlgorithmParameterSpec */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/KeyPairGeneratorSpi.java --- a/jdk/src/java.base/share/classes/java/security/KeyPairGeneratorSpi.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/KeyPairGeneratorSpi.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2017, Oracle and/or its affiliates. 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 @@ -39,10 +39,18 @@ *

    In case the client does not explicitly initialize the KeyPairGenerator * (via a call to an {@code initialize} method), each provider must * supply (and document) a default initialization. - * For example, the Sun provider uses a default modulus size (keysize) - * of 1024 bits. + * See the Keysize Restriction sections of the + * + * JDK Providers + * document for information on the KeyPairGenerator defaults used by + * JDK providers. + * However, note that defaults may vary across different providers. + * Additionally, the default value for a provider may change in a future + * version. Therefore, it is recommended to explicitly initialize the + * KeyPairGenerator instead of relying on provider-specific defaults. * * @author Benjamin Renaud + * @since 1.2 * * * @see KeyPairGenerator diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/MessageDigest.java --- a/jdk/src/java.base/share/classes/java/security/MessageDigest.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/MessageDigest.java Wed Jul 05 23:40:06 2017 +0200 @@ -96,6 +96,7 @@ * other algorithms are supported. * * @author Benjamin Renaud + * @since 1.1 * * @see DigestInputStream * @see DigestOutputStream diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/MessageDigestSpi.java --- a/jdk/src/java.base/share/classes/java/security/MessageDigestSpi.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/MessageDigestSpi.java Wed Jul 05 23:40:06 2017 +0200 @@ -43,6 +43,7 @@ *

    Implementations are free to implement the Cloneable interface. * * @author Benjamin Renaud + * @since 1.2 * * * @see MessageDigest diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/NoSuchAlgorithmException.java --- a/jdk/src/java.base/share/classes/java/security/NoSuchAlgorithmException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/NoSuchAlgorithmException.java Wed Jul 05 23:40:06 2017 +0200 @@ -30,6 +30,7 @@ * requested but is not available in the environment. * * @author Benjamin Renaud + * @since 1.1 */ public class NoSuchAlgorithmException extends GeneralSecurityException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/NoSuchProviderException.java --- a/jdk/src/java.base/share/classes/java/security/NoSuchProviderException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/NoSuchProviderException.java Wed Jul 05 23:40:06 2017 +0200 @@ -30,6 +30,7 @@ * requested but is not available in the environment. * * @author Benjamin Renaud + * @since 1.1 */ public class NoSuchProviderException extends GeneralSecurityException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Permission.java --- a/jdk/src/java.base/share/classes/java/security/Permission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Permission.java Wed Jul 05 23:40:06 2017 +0200 @@ -60,6 +60,7 @@ * * @author Marianne Mueller * @author Roland Schemers + * @since 1.2 */ public abstract class Permission implements Guard, java.io.Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/PermissionCollection.java --- a/jdk/src/java.base/share/classes/java/security/PermissionCollection.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/PermissionCollection.java Wed Jul 05 23:40:06 2017 +0200 @@ -91,6 +91,7 @@ * * * @author Roland Schemers + * @since 1.2 */ public abstract class PermissionCollection implements java.io.Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Permissions.java --- a/jdk/src/java.base/share/classes/java/security/Permissions.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Permissions.java Wed Jul 05 23:40:06 2017 +0200 @@ -75,6 +75,7 @@ * * @author Marianne Mueller * @author Roland Schemers + * @since 1.2 * * @serial exclude */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Policy.java --- a/jdk/src/java.base/share/classes/java/security/Policy.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Policy.java Wed Jul 05 23:40:06 2017 +0200 @@ -78,6 +78,7 @@ * * @author Roland Schemers * @author Gary Ellison + * @since 1.2 * @see java.security.Provider * @see java.security.ProtectionDomain * @see java.security.Permission diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Principal.java --- a/jdk/src/java.base/share/classes/java/security/Principal.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Principal.java Wed Jul 05 23:40:06 2017 +0200 @@ -35,6 +35,7 @@ * @see java.security.cert.X509Certificate * * @author Li Gong + * @since 1.1 */ public interface Principal { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/PrivateKey.java --- a/jdk/src/java.base/share/classes/java/security/PrivateKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/PrivateKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -54,6 +54,7 @@ * * @author Benjamin Renaud * @author Josh Bloch + * @since 1.1 */ public interface PrivateKey extends Key, javax.security.auth.Destroyable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/PrivilegedAction.java --- a/jdk/src/java.base/share/classes/java/security/PrivilegedAction.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/PrivilegedAction.java Wed Jul 05 23:40:06 2017 +0200 @@ -34,6 +34,7 @@ * throw checked exceptions must use {@code PrivilegedExceptionAction} * instead. * + * @since 1.2 * @see AccessController * @see AccessController#doPrivileged(PrivilegedAction) * @see PrivilegedExceptionAction diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/PrivilegedActionException.java --- a/jdk/src/java.base/share/classes/java/security/PrivilegedActionException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/PrivilegedActionException.java Wed Jul 05 23:40:06 2017 +0200 @@ -43,6 +43,7 @@ * cause, and may be accessed via the {@link Throwable#getCause()} * method, as well as the aforementioned "legacy method." * + * @since 1.2 * @see PrivilegedExceptionAction * @see AccessController#doPrivileged(PrivilegedExceptionAction) * @see AccessController#doPrivileged(PrivilegedExceptionAction,AccessControlContext) diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/PrivilegedExceptionAction.java --- a/jdk/src/java.base/share/classes/java/security/PrivilegedExceptionAction.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/PrivilegedExceptionAction.java Wed Jul 05 23:40:06 2017 +0200 @@ -35,6 +35,7 @@ * computations that do not throw * checked exceptions should use {@code PrivilegedAction} instead. * + * @since 1.2 * @see AccessController * @see AccessController#doPrivileged(PrivilegedExceptionAction) * @see AccessController#doPrivileged(PrivilegedExceptionAction, diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/ProtectionDomain.java --- a/jdk/src/java.base/share/classes/java/security/ProtectionDomain.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/ProtectionDomain.java Wed Jul 05 23:40:06 2017 +0200 @@ -59,6 +59,7 @@ * @author Li Gong * @author Roland Schemers * @author Gary Ellison + * @since 1.2 */ public class ProtectionDomain { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Provider.java --- a/jdk/src/java.base/share/classes/java/security/Provider.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Provider.java Wed Jul 05 23:40:06 2017 +0200 @@ -102,6 +102,7 @@ * * @author Benjamin Renaud * @author Andreas Sterbenz + * @since 1.1 */ public abstract class Provider extends Properties { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/ProviderException.java --- a/jdk/src/java.base/share/classes/java/security/ProviderException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/ProviderException.java Wed Jul 05 23:40:06 2017 +0200 @@ -32,6 +32,7 @@ * throw specialized, provider-specific runtime errors. * * @author Benjamin Renaud + * @since 1.1 */ public class ProviderException extends RuntimeException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/PublicKey.java --- a/jdk/src/java.base/share/classes/java/security/PublicKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/PublicKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -34,6 +34,7 @@ * See, for example, the DSAPublicKey interface in * {@code java.security.interfaces}. * + * @since 1.1 * @see Key * @see PrivateKey * @see Certificate diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/SecureClassLoader.java --- a/jdk/src/java.base/share/classes/java/security/SecureClassLoader.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/SecureClassLoader.java Wed Jul 05 23:40:06 2017 +0200 @@ -39,6 +39,7 @@ * * @author Li Gong * @author Roland Schemers + * @since 1.2 */ public class SecureClassLoader extends ClassLoader { /* diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/SecureRandom.java --- a/jdk/src/java.base/share/classes/java/security/SecureRandom.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/SecureRandom.java Wed Jul 05 23:40:06 2017 +0200 @@ -143,6 +143,7 @@ * * @author Benjamin Renaud * @author Josh Bloch + * @since 1.1 */ public class SecureRandom extends java.util.Random { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Security.java --- a/jdk/src/java.base/share/classes/java/security/Security.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Security.java Wed Jul 05 23:40:06 2017 +0200 @@ -45,6 +45,7 @@ * {@code conf/security/java.security} in the Java installation directory. * * @author Benjamin Renaud + * @since 1.1 */ public final class Security { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/SecurityPermission.java --- a/jdk/src/java.base/share/classes/java/security/SecurityPermission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/SecurityPermission.java Wed Jul 05 23:40:06 2017 +0200 @@ -333,6 +333,7 @@ * * @author Marianne Mueller * @author Roland Schemers + * @since 1.2 */ public final class SecurityPermission extends BasicPermission { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Signature.java --- a/jdk/src/java.base/share/classes/java/security/Signature.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Signature.java Wed Jul 05 23:40:06 2017 +0200 @@ -113,6 +113,7 @@ * other algorithms are supported. * * @author Benjamin Renaud + * @since 1.1 * */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/SignatureException.java --- a/jdk/src/java.base/share/classes/java/security/SignatureException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/SignatureException.java Wed Jul 05 23:40:06 2017 +0200 @@ -29,6 +29,7 @@ * This is the generic Signature exception. * * @author Benjamin Renaud + * @since 1.1 */ public class SignatureException extends GeneralSecurityException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/SignatureSpi.java --- a/jdk/src/java.base/share/classes/java/security/SignatureSpi.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/SignatureSpi.java Wed Jul 05 23:40:06 2017 +0200 @@ -44,6 +44,7 @@ * of a particular signature algorithm. * * @author Benjamin Renaud + * @since 1.2 * * * @see Signature diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/SignedObject.java --- a/jdk/src/java.base/share/classes/java/security/SignedObject.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/SignedObject.java Wed Jul 05 23:40:06 2017 +0200 @@ -114,6 +114,7 @@ * @see Signature * * @author Li Gong + * @since 1.2 */ public final class SignedObject implements Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/Signer.java --- a/jdk/src/java.base/share/classes/java/security/Signer.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/Signer.java Wed Jul 05 23:40:06 2017 +0200 @@ -38,6 +38,7 @@ * @see Identity * * @author Benjamin Renaud + * @since 1.1 * * @deprecated This class is no longer used. Its functionality has been * replaced by {@code java.security.KeyStore}, the diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/UnresolvedPermission.java --- a/jdk/src/java.base/share/classes/java/security/UnresolvedPermission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/UnresolvedPermission.java Wed Jul 05 23:40:06 2017 +0200 @@ -96,6 +96,7 @@ * * * @author Roland Schemers + * @since 1.2 */ public final class UnresolvedPermission extends Permission diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/UnresolvedPermissionCollection.java --- a/jdk/src/java.base/share/classes/java/security/UnresolvedPermissionCollection.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/UnresolvedPermissionCollection.java Wed Jul 05 23:40:06 2017 +0200 @@ -43,6 +43,7 @@ * * * @author Roland Schemers + * @since 1.2 * * @serial include */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/acl/Acl.java --- a/jdk/src/java.base/share/classes/java/security/acl/Acl.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/acl/Acl.java Wed Jul 05 23:40:06 2017 +0200 @@ -82,6 +82,7 @@ * @see java.security.acl.Acl#getPermissions * * @author Satish Dharmaraj + * @since 1.1 * * @deprecated This package has been replaced by {@code java.security.Policy} * and related classes since 1.2. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/acl/AclEntry.java --- a/jdk/src/java.base/share/classes/java/security/acl/AclEntry.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/acl/AclEntry.java Wed Jul 05 23:40:06 2017 +0200 @@ -50,6 +50,7 @@ * @see java.security.acl.Acl * * @author Satish Dharmaraj + * @since 1.1 * * @deprecated This package has been replaced by {@code java.security.Policy} * and related classes since 1.2. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/acl/AclNotFoundException.java --- a/jdk/src/java.base/share/classes/java/security/acl/AclNotFoundException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/acl/AclNotFoundException.java Wed Jul 05 23:40:06 2017 +0200 @@ -30,6 +30,7 @@ * non-existent ACL (Access Control List). * * @author Satish Dharmaraj + * @since 1.1 * * @deprecated This package has been replaced by {@code java.security.Policy} * and related classes since 1.2. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/acl/Group.java --- a/jdk/src/java.base/share/classes/java/security/acl/Group.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/acl/Group.java Wed Jul 05 23:40:06 2017 +0200 @@ -39,6 +39,7 @@ * Principal or Group. * * @author Satish Dharmaraj + * @since 1.1 * * @deprecated This package has been replaced by {@code java.security.Policy} * and related classes since 1.2. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/acl/LastOwnerException.java --- a/jdk/src/java.base/share/classes/java/security/acl/LastOwnerException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/acl/LastOwnerException.java Wed Jul 05 23:40:06 2017 +0200 @@ -32,6 +32,7 @@ * @see java.security.acl.Owner#deleteOwner * * @author Satish Dharmaraj + * @since 1.1 * * @deprecated This package has been replaced by {@code java.security.Policy} * and related classes since 1.2. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/acl/NotOwnerException.java --- a/jdk/src/java.base/share/classes/java/security/acl/NotOwnerException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/acl/NotOwnerException.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * the object, but the Principal attempting the modification is not an owner. * * @author Satish Dharmaraj + * @since 1.1 * * @deprecated This package has been replaced by {@code java.security.Policy} * and related classes since 1.2. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/acl/Owner.java --- a/jdk/src/java.base/share/classes/java/security/acl/Owner.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/acl/Owner.java Wed Jul 05 23:40:06 2017 +0200 @@ -34,6 +34,7 @@ * interface.) The initial owner Principal should be specified as an * argument to the constructor of the class implementing this interface. * + * @since 1.1 * @see java.security.acl.Acl * * @deprecated This package has been replaced by {@code java.security.Policy} diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/acl/Permission.java --- a/jdk/src/java.base/share/classes/java/security/acl/Permission.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/acl/Permission.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * a particular type of access to a resource. * * @author Satish Dharmaraj + * @since 1.1 * * @deprecated This package has been replaced by {@code java.security.Policy} * and related classes since 1.2. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/CRLException.java --- a/jdk/src/java.base/share/classes/java/security/cert/CRLException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/CRLException.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * CRL (Certificate Revocation List) Exception. * * @author Hemma Prafullchandra + * @since 1.2 */ public class CRLException extends GeneralSecurityException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/Certificate.java --- a/jdk/src/java.base/share/classes/java/security/cert/Certificate.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/Certificate.java Wed Jul 05 23:40:06 2017 +0200 @@ -57,6 +57,7 @@ * @see CertificateFactory * * @author Hemma Prafullchandra + * @since 1.2 */ public abstract class Certificate implements java.io.Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/CertificateEncodingException.java --- a/jdk/src/java.base/share/classes/java/security/cert/CertificateEncodingException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/CertificateEncodingException.java Wed Jul 05 23:40:06 2017 +0200 @@ -30,6 +30,7 @@ * occurs while attempting to encode a certificate. * * @author Hemma Prafullchandra + * @since 1.2 */ public class CertificateEncodingException extends CertificateException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/CertificateException.java --- a/jdk/src/java.base/share/classes/java/security/cert/CertificateException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/CertificateException.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * This exception indicates one of a variety of certificate problems. * * @author Hemma Prafullchandra + * @since 1.2 * @see Certificate */ public class CertificateException extends GeneralSecurityException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/CertificateExpiredException.java --- a/jdk/src/java.base/share/classes/java/security/cert/CertificateExpiredException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/CertificateExpiredException.java Wed Jul 05 23:40:06 2017 +0200 @@ -32,6 +32,7 @@ * of the certificate. * * @author Hemma Prafullchandra + * @since 1.2 */ public class CertificateExpiredException extends CertificateException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/CertificateNotYetValidException.java --- a/jdk/src/java.base/share/classes/java/security/cert/CertificateNotYetValidException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/CertificateNotYetValidException.java Wed Jul 05 23:40:06 2017 +0200 @@ -32,6 +32,7 @@ * validity period. * * @author Hemma Prafullchandra + * @since 1.2 */ public class CertificateNotYetValidException extends CertificateException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/CertificateParsingException.java --- a/jdk/src/java.base/share/classes/java/security/cert/CertificateParsingException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/CertificateParsingException.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * are found in the Certificate. * * @author Hemma Prafullchandra + * @since 1.2 */ public class CertificateParsingException extends CertificateException { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/X509CRL.java --- a/jdk/src/java.base/share/classes/java/security/cert/X509CRL.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/X509CRL.java Wed Jul 05 23:40:06 2017 +0200 @@ -103,6 +103,7 @@ * } * * @author Hemma Prafullchandra + * @since 1.2 * * * @see CRL diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/X509CRLEntry.java --- a/jdk/src/java.base/share/classes/java/security/cert/X509CRLEntry.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/X509CRLEntry.java Wed Jul 05 23:40:06 2017 +0200 @@ -62,6 +62,7 @@ * @see X509Extension * * @author Hemma Prafullchandra + * @since 1.2 */ public abstract class X509CRLEntry implements X509Extension { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/X509Certificate.java --- a/jdk/src/java.base/share/classes/java/security/cert/X509Certificate.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/X509Certificate.java Wed Jul 05 23:40:06 2017 +0200 @@ -95,6 +95,7 @@ * * * @author Hemma Prafullchandra + * @since 1.2 * * * @see Certificate diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/cert/X509Extension.java --- a/jdk/src/java.base/share/classes/java/security/cert/X509Extension.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/cert/X509Extension.java Wed Jul 05 23:40:06 2017 +0200 @@ -65,6 +65,7 @@ * be handled by a Class that understands the extension. * * @author Hemma Prafullchandra + * @since 1.2 */ public interface X509Extension { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/interfaces/DSAKey.java --- a/jdk/src/java.base/share/classes/java/security/interfaces/DSAKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/interfaces/DSAKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -35,6 +35,7 @@ * * @author Benjamin Renaud * @author Josh Bloch + * @since 1.1 */ public interface DSAKey { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/interfaces/DSAKeyPairGenerator.java --- a/jdk/src/java.base/share/classes/java/security/interfaces/DSAKeyPairGenerator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/interfaces/DSAKeyPairGenerator.java Wed Jul 05 23:40:06 2017 +0200 @@ -65,6 +65,7 @@ *

    Note: Some earlier implementations of this interface may not support * larger sizes of DSA parameters such as 2048 and 3072-bit. * + * @since 1.1 * @see java.security.KeyPairGenerator */ public interface DSAKeyPairGenerator { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/interfaces/DSAParams.java --- a/jdk/src/java.base/share/classes/java/security/interfaces/DSAParams.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/interfaces/DSAParams.java Wed Jul 05 23:40:06 2017 +0200 @@ -38,6 +38,7 @@ * * @author Benjamin Renaud * @author Josh Bloch + * @since 1.1 */ public interface DSAParams { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/interfaces/DSAPrivateKey.java --- a/jdk/src/java.base/share/classes/java/security/interfaces/DSAPrivateKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/interfaces/DSAPrivateKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -37,6 +37,7 @@ * @see DSAPublicKey * * @author Benjamin Renaud + * @since 1.1 */ public interface DSAPrivateKey extends DSAKey, java.security.PrivateKey { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/interfaces/DSAPublicKey.java --- a/jdk/src/java.base/share/classes/java/security/interfaces/DSAPublicKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/interfaces/DSAPublicKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -37,6 +37,7 @@ * @see DSAPrivateKey * * @author Benjamin Renaud + * @since 1.1 */ public interface DSAPublicKey extends DSAKey, java.security.PublicKey { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/interfaces/RSAPrivateCrtKey.java --- a/jdk/src/java.base/share/classes/java/security/interfaces/RSAPrivateCrtKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/interfaces/RSAPrivateCrtKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -32,6 +32,7 @@ * using the Chinese Remainder Theorem (CRT) information values. * * @author Jan Luehe + * @since 1.2 * * * @see RSAPrivateKey diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/interfaces/RSAPrivateKey.java --- a/jdk/src/java.base/share/classes/java/security/interfaces/RSAPrivateKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/interfaces/RSAPrivateKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * The interface to an RSA private key. * * @author Jan Luehe + * @since 1.2 * * * @see RSAPrivateCrtKey diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/interfaces/RSAPublicKey.java --- a/jdk/src/java.base/share/classes/java/security/interfaces/RSAPublicKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/interfaces/RSAPublicKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * The interface to an RSA public key. * * @author Jan Luehe + * @since 1.2 * */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/spec/RSAPrivateCrtKeySpec.java --- a/jdk/src/java.base/share/classes/java/security/spec/RSAPrivateCrtKeySpec.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/spec/RSAPrivateCrtKeySpec.java Wed Jul 05 23:40:06 2017 +0200 @@ -33,6 +33,7 @@ * efficiency. * * @author Jan Luehe + * @since 1.2 * * * @see java.security.Key diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/spec/RSAPrivateKeySpec.java --- a/jdk/src/java.base/share/classes/java/security/spec/RSAPrivateKeySpec.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/spec/RSAPrivateKeySpec.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * This class specifies an RSA private key. * * @author Jan Luehe + * @since 1.2 * * * @see java.security.Key diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/security/spec/RSAPublicKeySpec.java --- a/jdk/src/java.base/share/classes/java/security/spec/RSAPublicKeySpec.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/security/spec/RSAPublicKeySpec.java Wed Jul 05 23:40:06 2017 +0200 @@ -31,6 +31,7 @@ * This class specifies an RSA public key. * * @author Jan Luehe + * @since 1.2 * * * @see java.security.Key diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/BreakIterator.java --- a/jdk/src/java.base/share/classes/java/text/BreakIterator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/BreakIterator.java Wed Jul 05 23:40:06 2017 +0200 @@ -221,6 +221,7 @@ * and the next is a word; otherwise, it's the material between words.) * * + * @since 1.1 * @see CharacterIterator * */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/CharacterIterator.java --- a/jdk/src/java.base/share/classes/java/text/CharacterIterator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/CharacterIterator.java Wed Jul 05 23:40:06 2017 +0200 @@ -98,6 +98,7 @@ * } * } * + * @since 1.1 * @see StringCharacterIterator * @see AttributedCharacterIterator */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/ChoiceFormat.java --- a/jdk/src/java.base/share/classes/java/text/ChoiceFormat.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/ChoiceFormat.java Wed Jul 05 23:40:06 2017 +0200 @@ -163,6 +163,7 @@ * @see DecimalFormat * @see MessageFormat * @author Mark Davis + * @since 1.1 */ public class ChoiceFormat extends NumberFormat { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/CollationElementIterator.java --- a/jdk/src/java.base/share/classes/java/text/CollationElementIterator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/CollationElementIterator.java Wed Jul 05 23:40:06 2017 +0200 @@ -104,6 +104,7 @@ * @see Collator * @see RuleBasedCollator * @author Helena Shih, Laura Werner, Richard Gillam + * @since 1.1 */ public final class CollationElementIterator { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/CollationKey.java --- a/jdk/src/java.base/share/classes/java/text/CollationKey.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/CollationKey.java Wed Jul 05 23:40:06 2017 +0200 @@ -95,6 +95,7 @@ * @see Collator * @see RuleBasedCollator * @author Helena Shih + * @since 1.1 */ public abstract class CollationKey implements Comparable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/Collator.java --- a/jdk/src/java.base/share/classes/java/text/Collator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/Collator.java Wed Jul 05 23:40:06 2017 +0200 @@ -123,6 +123,7 @@ * @see CollationElementIterator * @see Locale * @author Helena Shih, Laura Werner, Richard Gillam + * @since 1.1 */ public abstract class Collator diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/DateFormat.java --- a/jdk/src/java.base/share/classes/java/text/DateFormat.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/DateFormat.java Wed Jul 05 23:40:06 2017 +0200 @@ -167,6 +167,7 @@ * @see java.util.GregorianCalendar * @see java.util.TimeZone * @author Mark Davis, Chen-Lieh Huang, Alan Liu + * @since 1.1 */ public abstract class DateFormat extends Format { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/DateFormatSymbols.java --- a/jdk/src/java.base/share/classes/java/text/DateFormatSymbols.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/DateFormatSymbols.java Wed Jul 05 23:40:06 2017 +0200 @@ -98,6 +98,7 @@ * @see SimpleDateFormat * @see java.util.SimpleTimeZone * @author Chen-Lieh Huang + * @since 1.1 */ public class DateFormatSymbols implements Serializable, Cloneable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/DecimalFormat.java --- a/jdk/src/java.base/share/classes/java/text/DecimalFormat.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/DecimalFormat.java Wed Jul 05 23:40:06 2017 +0200 @@ -381,6 +381,7 @@ * @see ParsePosition * @author Mark Davis * @author Alan Liu + * @since 1.1 */ public class DecimalFormat extends NumberFormat { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/DecimalFormatSymbols.java --- a/jdk/src/java.base/share/classes/java/text/DecimalFormatSymbols.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/DecimalFormatSymbols.java Wed Jul 05 23:40:06 2017 +0200 @@ -60,6 +60,7 @@ * @see DecimalFormat * @author Mark Davis * @author Alan Liu + * @since 1.1 */ public class DecimalFormatSymbols implements Cloneable, Serializable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/FieldPosition.java --- a/jdk/src/java.base/share/classes/java/text/FieldPosition.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/FieldPosition.java Wed Jul 05 23:40:06 2017 +0200 @@ -68,6 +68,7 @@ * formatToCharacterIterator. * * @author Mark Davis + * @since 1.1 * @see java.text.Format */ public class FieldPosition { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/Format.java --- a/jdk/src/java.base/share/classes/java/text/Format.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/Format.java Wed Jul 05 23:40:06 2017 +0200 @@ -129,6 +129,7 @@ * @see java.text.DateFormat * @see java.text.MessageFormat * @author Mark Davis + * @since 1.1 */ public abstract class Format implements Serializable, Cloneable { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/MessageFormat.java --- a/jdk/src/java.base/share/classes/java/text/MessageFormat.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/MessageFormat.java Wed Jul 05 23:40:06 2017 +0200 @@ -344,6 +344,7 @@ * @see SimpleDateFormat * * @author Mark Davis + * @since 1.1 */ public class MessageFormat extends Format { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/NumberFormat.java --- a/jdk/src/java.base/share/classes/java/text/NumberFormat.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/NumberFormat.java Wed Jul 05 23:40:06 2017 +0200 @@ -185,6 +185,7 @@ * @see ChoiceFormat * @author Mark Davis * @author Helena Shih + * @since 1.1 */ public abstract class NumberFormat extends Format { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/ParseException.java --- a/jdk/src/java.base/share/classes/java/text/ParseException.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/ParseException.java Wed Jul 05 23:40:06 2017 +0200 @@ -45,6 +45,7 @@ * @see java.text.Format * @see java.text.FieldPosition * @author Mark Davis + * @since 1.1 */ public class ParseException extends Exception { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/ParsePosition.java --- a/jdk/src/java.base/share/classes/java/text/ParsePosition.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/ParsePosition.java Wed Jul 05 23:40:06 2017 +0200 @@ -51,6 +51,7 @@ * records the current position. * * @author Mark Davis + * @since 1.1 * @see java.text.Format */ diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/RuleBasedCollator.java --- a/jdk/src/java.base/share/classes/java/text/RuleBasedCollator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/RuleBasedCollator.java Wed Jul 05 23:40:06 2017 +0200 @@ -242,6 +242,7 @@ * @see Collator * @see CollationElementIterator * @author Helena Shih, Laura Werner, Richard Gillam + * @since 1.1 */ public class RuleBasedCollator extends Collator{ // IMPLEMENTATION NOTES: The implementation of the collation algorithm is diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/SimpleDateFormat.java --- a/jdk/src/java.base/share/classes/java/text/SimpleDateFormat.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/SimpleDateFormat.java Wed Jul 05 23:40:06 2017 +0200 @@ -434,6 +434,7 @@ * @see DateFormat * @see DateFormatSymbols * @author Mark Davis, Chen-Lieh Huang, Alan Liu + * @since 1.1 */ public class SimpleDateFormat extends DateFormat { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/text/StringCharacterIterator.java --- a/jdk/src/java.base/share/classes/java/text/StringCharacterIterator.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/text/StringCharacterIterator.java Wed Jul 05 23:40:06 2017 +0200 @@ -47,6 +47,7 @@ * entire String. * * @see CharacterIterator + * @since 1.1 */ public final class StringCharacterIterator implements CharacterIterator diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/util/ResourceBundle.java --- a/jdk/src/java.base/share/classes/java/util/ResourceBundle.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/util/ResourceBundle.java Wed Jul 05 23:40:06 2017 +0200 @@ -216,16 +216,17 @@ * the caller module, those resource bundles need to be loaded from service * providers of {@link ResourceBundleProvider}. The caller module must declare * "{@code uses}" and the service interface name is the concatenation of the - * base name of the bundles and the string "{@code Provider}". The + * package name of the base name, string "{@code .spi.}", the simple class + * name of the base name, and the string "{@code Provider}". The * bundle provider modules containing resource bundles must * declare "{@code provides}" with the service interface name and * its implementation class name. For example, if the base name is * "{@code com.example.app.MyResources}", the caller module must declare - * "{@code uses com.example.app.MyResourcesProvider;}" and a module containing resource - * bundles must declare "{@code provides com.example.app.MyResourcesProvider + * "{@code uses com.example.app.spi.MyResourcesProvider;}" and a module containing resource + * bundles must declare "{@code provides com.example.app.spi.MyResourcesProvider * with com.example.app.internal.MyResourcesProviderImpl;}" * where {@code com.example.app.internal.MyResourcesProviderImpl} is an - * implementation class of {@code com.example.app.MyResourcesProvider}. + * implementation class of {@code com.example.app.spi.MyResourcesProvider}. *

  • If you want to use non-standard formats in named modules, such as XML, * {@link ResourceBundleProvider} needs to be used.
  • *
  • The {@code getBundle} method with a {@code ClassLoader} may not be able to @@ -243,9 +244,10 @@ * * The {@code getBundle} factory methods load service providers of * {@link ResourceBundleProvider}, if available, using {@link ServiceLoader}. - * The service type is designated by {@code basename+"Provider"}. For + * The service type is designated by + * {@code + ".spi." + + "Provider"}. For * example, if the base name is "{@code com.example.app.MyResources}", the service - * type is {@code com.example.app.MyResourcesProvider}. + * type is {@code com.example.app.spi.MyResourcesProvider}. *

    * In named modules, the loaded service providers for the given base name are * used to load resource bundles. If no service provider is available, or if @@ -923,7 +925,12 @@ *

    Resource bundles in named modules may be encapsulated. When * the resource bundle is loaded from a provider, the caller module * must have an appropriate uses clause in its module descriptor - * to declare that the module uses implementations of {@code "baseName"Provider}. + * to declare that the module uses implementations of + * {@code + ".spi." + + "Provider"}. + * Otherwise, it will load the resource bundles that are local in the + * given module or that are visible to the class loader of the given module + * (refer to the Resource Bundles in Named Modules + * section for details). * When the resource bundle is loaded from the specified module, it is * subject to the encapsulation rules specified by * {@link Module#getResourceAsStream Module.getResourceAsStream}. @@ -958,20 +965,17 @@ *

    Resource bundles in named modules may be encapsulated. When * the resource bundle is loaded from a provider, the caller module * must have an appropriate uses clause in its module descriptor - * to declare that the module uses implementations of {@code "baseName"Provider}. + * to declare that the module uses implementations of + * {@code + ".spi." + + "Provider"}. + * Otherwise, it will load the resource bundles that are local in the + * given module or that are visible to the class loader of the given module + * (refer to the Resource Bundles in Named Modules + * section for details). * When the resource bundle is loaded from the specified module, it is * subject to the encapsulation rules specified by * {@link Module#getResourceAsStream Module.getResourceAsStream}. * *

    - * If the given {@code module} is a named module, this method will - * load the service providers for {@link java.util.spi.ResourceBundleProvider} - * and also resource bundles that are local in the given module or that - * are visible to the class loader of the given module (refer to the - * Resource Bundles in Named Modules section - * for details). - * - *

    * If the given {@code module} is an unnamed module, then this method is * equivalent to calling {@link #getBundle(String, Locale, ClassLoader) * getBundle(baseName, targetLocale, module.getClassLoader()} to load @@ -1070,8 +1074,10 @@ * Resource bundles in a named module are private to that module. If * the caller is in a named module, this method will find resource bundles * from the service providers of {@link java.util.spi.ResourceBundleProvider} - * and also find resource bundles that are in the caller's module or - * that are visible to the given class loader. + * if any. Otherwise, it will load the resource bundles that are visible to + * the given {@code loader} (refer to the + * Resource Bundles in Named Modules section + * for details). * If the caller is in a named module and the given {@code loader} is * different than the caller's class loader, or if the caller is not in * a named module, this method will not find resource bundles from named @@ -1883,8 +1889,15 @@ private static Class getResourceBundleProviderType(String baseName, ClassLoader loader) { - // Look up + "Provider" - String providerName = baseName + "Provider"; + // Look up + ".spi." + "Provider" + int i = baseName.lastIndexOf('.'); + if (i <= 0) { + return null; + } + + String name = baseName.substring(i+1, baseName.length()) + "Provider"; + String providerName = baseName.substring(0, i) + ".spi." + name; + // Use the class loader of the getBundle caller so that the caller's // visibility of the provider type is checked. return AccessController.doPrivileged( diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/util/concurrent/CompletionService.java --- a/jdk/src/java.base/share/classes/java/util/concurrent/CompletionService.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/util/concurrent/CompletionService.java Wed Jul 05 23:40:06 2017 +0200 @@ -57,6 +57,8 @@ * happen-before * actions taken by that task, which in turn happen-before * actions following a successful return from the corresponding {@code take()}. + * + * @since 1.5 */ public interface CompletionService { /** diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/util/concurrent/ExecutorCompletionService.java --- a/jdk/src/java.base/share/classes/java/util/concurrent/ExecutorCompletionService.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/util/concurrent/ExecutorCompletionService.java Wed Jul 05 23:40:06 2017 +0200 @@ -97,6 +97,8 @@ * if (result != null) * use(result); * }} + * + * @since 1.5 */ public class ExecutorCompletionService implements CompletionService { private final Executor executor; diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/util/concurrent/locks/LockSupport.java --- a/jdk/src/java.base/share/classes/java/util/concurrent/locks/LockSupport.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/util/concurrent/locks/LockSupport.java Wed Jul 05 23:40:06 2017 +0200 @@ -133,6 +133,8 @@ * Class ensureLoaded = LockSupport.class; * } * }} + * + * @since 1.5 */ public class LockSupport { private LockSupport() {} // Cannot be instantiated. diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/util/jar/JarEntry.java --- a/jdk/src/java.base/share/classes/java/util/jar/JarEntry.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/util/jar/JarEntry.java Wed Jul 05 23:40:06 2017 +0200 @@ -32,6 +32,8 @@ /** * This class is used to represent a JAR file entry. + * + * @since 1.2 */ public class JarEntry extends ZipEntry { diff -r ea7475564d07 -r ca0e16b2d5d6 jdk/src/java.base/share/classes/java/util/package-info.java --- a/jdk/src/java.base/share/classes/java/util/package-info.java Thu Jun 15 13:44:42 2017 +0200 +++ b/jdk/src/java.base/share/classes/java/util/package-info.java Wed Jul 05 23:40:06 2017 +0200 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2017, Oracle and/or its affiliates. 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 @@ -29,7 +29,7 @@ * miscellaneous utility classes (a string tokenizer, a random-number * generator, and a bit array). * - *

    {@index "Java Collections Framework"}

    + *

    {@index "Java Collections Framework"}

    *