diff --git a/.hgtags-top-repo b/.hgtags-top-repo index e7cd2f8b813..4a5b7897a36 100644 --- a/.hgtags-top-repo +++ b/.hgtags-top-repo @@ -319,3 +319,4 @@ c706ef5ea5da00078dc5e4334660315f7d99c15b jdk9-b71 57f3134853ecdd4a3ee2d4d26f22ba981d653d79 jdk9-b74 8fd6eeb878606e39c908f12535f34ebbfd225a4a jdk9-b75 d82072b699b880a1f647a5e2d7c0f86cec958941 jdk9-b76 +7972dc8f2a47f0c4cd8f02fa5662af41f028aa14 jdk9-b77 diff --git a/corba/.hgtags b/corba/.hgtags index 5f4956021f3..3f3d3c4089b 100644 --- a/corba/.hgtags +++ b/corba/.hgtags @@ -319,3 +319,4 @@ f9f3706bd24c42c07cb260fe05730a749b8e52f4 jdk9-b72 622fe934e351e89107edf3c667d6b57f543f58f1 jdk9-b74 960b56805abd8460598897481820bd6a75f979e7 jdk9-b75 d8126bc88fa5cd1ae4e44d86a4b1280ca1c9e2aa jdk9-b76 +8bb2441c0fec8b28f7bf11a0ca3ec1642e7ef457 jdk9-b77 diff --git a/hotspot/.hgtags b/hotspot/.hgtags index ec379ef03c1..9662d2a1477 100644 --- a/hotspot/.hgtags +++ b/hotspot/.hgtags @@ -479,3 +479,4 @@ e37d432868be0aa7cb5e0f3d7caff1e825d8ead3 jdk9-b73 fff6b54e9770ac4c12c2fb4cab5aa7672affa4bd jdk9-b74 2f354281e9915275693c4e519a959b8a6f22d3a3 jdk9-b75 0bc8d1656d6f2b1fdfe803c1305a108bb9939f35 jdk9-b76 +e66c3813789debfc06f206afde1bf7a84cb08451 jdk9-b77 diff --git a/hotspot/src/cpu/aarch64/vm/aarch64.ad b/hotspot/src/cpu/aarch64/vm/aarch64.ad index bef849a2050..37d1b09cdda 100644 --- a/hotspot/src/cpu/aarch64/vm/aarch64.ad +++ b/hotspot/src/cpu/aarch64/vm/aarch64.ad @@ -2389,9 +2389,11 @@ int HandlerImpl::emit_exception_handler(CodeBuffer& cbuf) // Note that the code buffer's insts_mark is always relative to insts. // That's why we must use the macroassembler to generate a handler. MacroAssembler _masm(&cbuf); - address base = - __ start_a_stub(size_exception_handler()); - if (base == NULL) return 0; // CodeBuffer::expand failed + address base = __ start_a_stub(size_exception_handler()); + if (base == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return 0; // CodeBuffer::expand failed + } int offset = __ offset(); __ far_jump(RuntimeAddress(OptoRuntime::exception_blob()->entry_point())); assert(__ offset() - offset <= (int) size_exception_handler(), "overflow"); @@ -2405,9 +2407,11 @@ int HandlerImpl::emit_deopt_handler(CodeBuffer& cbuf) // Note that the code buffer's insts_mark is always relative to insts. // That's why we must use the macroassembler to generate a handler. MacroAssembler _masm(&cbuf); - address base = - __ start_a_stub(size_deopt_handler()); - if (base == NULL) return 0; // CodeBuffer::expand failed + address base = __ start_a_stub(size_deopt_handler()); + if (base == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return 0; // CodeBuffer::expand failed + } int offset = __ offset(); __ adr(lr, __ pc()); @@ -3657,24 +3661,37 @@ encode %{ MacroAssembler _masm(&cbuf); address addr = (address)$meth$$method; + address call; if (!_method) { // A call to a runtime wrapper, e.g. new, new_typeArray_Java, uncommon_trap. - __ trampoline_call(Address(addr, relocInfo::runtime_call_type), &cbuf); + call = __ trampoline_call(Address(addr, relocInfo::runtime_call_type), &cbuf); } else if (_optimized_virtual) { - __ trampoline_call(Address(addr, relocInfo::opt_virtual_call_type), &cbuf); + call = __ trampoline_call(Address(addr, relocInfo::opt_virtual_call_type), &cbuf); } else { - __ trampoline_call(Address(addr, relocInfo::static_call_type), &cbuf); + call = __ trampoline_call(Address(addr, relocInfo::static_call_type), &cbuf); + } + if (call == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return; } if (_method) { // Emit stub for static call - CompiledStaticCall::emit_to_interp_stub(cbuf); + address stub = CompiledStaticCall::emit_to_interp_stub(cbuf); + if (stub == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return; + } } %} enc_class aarch64_enc_java_dynamic_call(method meth) %{ MacroAssembler _masm(&cbuf); - __ ic_call((address)$meth$$method); + address call = __ ic_call((address)$meth$$method); + if (call == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return; + } %} enc_class aarch64_enc_call_epilog() %{ @@ -3695,7 +3712,11 @@ encode %{ address entry = (address)$meth$$method; CodeBlob *cb = CodeCache::find_blob(entry); if (cb) { - __ trampoline_call(Address(entry, relocInfo::runtime_call_type)); + address call = __ trampoline_call(Address(entry, relocInfo::runtime_call_type)); + if (call == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return; + } } else { int gpcnt; int fpcnt; diff --git a/hotspot/src/cpu/aarch64/vm/c1_CodeStubs_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/c1_CodeStubs_aarch64.cpp index 5cb78d2055d..bdfc017aa82 100644 --- a/hotspot/src/cpu/aarch64/vm/c1_CodeStubs_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/c1_CodeStubs_aarch64.cpp @@ -327,9 +327,16 @@ void ArrayCopyStub::emit_code(LIR_Assembler* ce) { ce->align_call(lir_static_call); ce->emit_static_call_stub(); + if (ce->compilation()->bailed_out()) { + return; // CodeCache is full + } Address resolve(SharedRuntime::get_resolve_static_call_stub(), relocInfo::static_call_type); - __ trampoline_call(resolve); + address call = __ trampoline_call(resolve); + if (call == NULL) { + ce->bailout("trampoline stub overflow"); + return; + } ce->add_call_info_here(info()); #ifndef PRODUCT diff --git a/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.cpp index 353486c402d..907370d1385 100644 --- a/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.cpp @@ -1996,13 +1996,21 @@ void LIR_Assembler::align_call(LIR_Code code) { } void LIR_Assembler::call(LIR_OpJavaCall* op, relocInfo::relocType rtype) { - __ trampoline_call(Address(op->addr(), rtype)); + address call = __ trampoline_call(Address(op->addr(), rtype)); + if (call == NULL) { + bailout("trampoline stub overflow"); + return; + } add_call_info(code_offset(), op->info()); } void LIR_Assembler::ic_call(LIR_OpJavaCall* op) { - __ ic_call(op->addr()); + address call = __ ic_call(op->addr()); + if (call == NULL) { + bailout("trampoline stub overflow"); + return; + } add_call_info(code_offset(), op->info()); } diff --git a/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.hpp b/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.hpp index d6d323857d3..6d7e27e617b 100644 --- a/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.hpp +++ b/hotspot/src/cpu/aarch64/vm/c1_LIRAssembler_aarch64.hpp @@ -26,6 +26,9 @@ #ifndef CPU_X86_VM_C1_LIRASSEMBLER_X86_HPP #define CPU_X86_VM_C1_LIRASSEMBLER_X86_HPP +// ArrayCopyStub needs access to bailout +friend class ArrayCopyStub; + private: int array_element_size(BasicType type) const; diff --git a/hotspot/src/cpu/aarch64/vm/compiledIC_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/compiledIC_aarch64.cpp index 44e124cf6d9..b30a4a6df10 100644 --- a/hotspot/src/cpu/aarch64/vm/compiledIC_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/compiledIC_aarch64.cpp @@ -51,7 +51,7 @@ bool CompiledIC::is_icholder_call_site(virtual_call_Relocation* call_site) { // ---------------------------------------------------------------------------- #define __ _masm. -void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { +address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { // Stub is fixed up when the corresponding call is converted from // calling compiled code to calling interpreted code. // mov rmethod, 0 @@ -63,10 +63,11 @@ void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { // That's why we must use the macroassembler to generate a stub. MacroAssembler _masm(&cbuf); - address base = __ start_a_stub(to_interp_stub_size()*2); - + address base = __ start_a_stub(to_interp_stub_size()); int offset = __ offset(); - if (base == NULL) return; // CodeBuffer::expand failed + if (base == NULL) { + return NULL; // CodeBuffer::expand failed + } // static stub relocation stores the instruction address of the call __ relocate(static_stub_Relocation::spec(mark)); // static stub relocation also tags the Method* in the code-stream. @@ -76,6 +77,7 @@ void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { assert((__ offset() - offset) <= (int)to_interp_stub_size(), "stub too big"); __ end_a_stub(); + return base; } #undef __ diff --git a/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.cpp b/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.cpp index e8f0612460c..2bd4127cd50 100644 --- a/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.cpp +++ b/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.cpp @@ -664,7 +664,7 @@ void MacroAssembler::call_VM_helper(Register oop_result, address entry_point, in // Maybe emit a call via a trampoline. If the code cache is small // trampolines won't be emitted. -void MacroAssembler::trampoline_call(Address entry, CodeBuffer *cbuf) { +address MacroAssembler::trampoline_call(Address entry, CodeBuffer *cbuf) { assert(entry.rspec().type() == relocInfo::runtime_call_type || entry.rspec().type() == relocInfo::opt_virtual_call_type || entry.rspec().type() == relocInfo::static_call_type @@ -672,7 +672,10 @@ void MacroAssembler::trampoline_call(Address entry, CodeBuffer *cbuf) { unsigned int start_offset = offset(); if (far_branches() && !Compile::current()->in_scratch_emit_size()) { - emit_trampoline_stub(offset(), entry.target()); + address stub = emit_trampoline_stub(start_offset, entry.target()); + if (stub == NULL) { + return NULL; // CodeCache is full + } } if (cbuf) cbuf->set_insts_mark(); @@ -682,6 +685,8 @@ void MacroAssembler::trampoline_call(Address entry, CodeBuffer *cbuf) { } else { bl(pc()); } + // just need to return a non-null address + return pc(); } @@ -696,13 +701,11 @@ void MacroAssembler::trampoline_call(Address entry, CodeBuffer *cbuf) { // load the call target from the constant pool // branch (LR still points to the call site above) -void MacroAssembler::emit_trampoline_stub(int insts_call_instruction_offset, +address MacroAssembler::emit_trampoline_stub(int insts_call_instruction_offset, address dest) { address stub = start_a_stub(Compile::MAX_stubs_size/2); if (stub == NULL) { - start_a_stub(Compile::MAX_stubs_size/2); - Compile::current()->env()->record_out_of_memory_failure(); - return; + return NULL; // CodeBuffer::expand failed } // Create a trampoline stub relocation which relates this trampoline stub @@ -729,15 +732,16 @@ void MacroAssembler::emit_trampoline_stub(int insts_call_instruction_offset, assert(is_NativeCallTrampolineStub_at(stub_start_addr), "doesn't look like a trampoline"); end_a_stub(); + return stub; } -void MacroAssembler::ic_call(address entry) { +address MacroAssembler::ic_call(address entry) { RelocationHolder rh = virtual_call_Relocation::spec(pc()); // address const_ptr = long_constant((jlong)Universe::non_oop_word()); // unsigned long offset; // ldr_constant(rscratch2, const_ptr); movptr(rscratch2, (uintptr_t)Universe::non_oop_word()); - trampoline_call(Address(entry, rh)); + return trampoline_call(Address(entry, rh)); } // Implementation of call_VM versions diff --git a/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.hpp b/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.hpp index 5f903720d97..9711266f52d 100644 --- a/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.hpp +++ b/hotspot/src/cpu/aarch64/vm/macroAssembler_aarch64.hpp @@ -539,7 +539,7 @@ public: static int patch_oop(address insn_addr, address o); - void emit_trampoline_stub(int insts_call_instruction_offset, address target); + address emit_trampoline_stub(int insts_call_instruction_offset, address target); // The following 4 methods return the offset of the appropriate move instruction @@ -942,7 +942,7 @@ public: // Calls - void trampoline_call(Address entry, CodeBuffer *cbuf = NULL); + address trampoline_call(Address entry, CodeBuffer *cbuf = NULL); static bool far_branches() { return ReservedCodeCacheSize > branch_range; @@ -962,7 +962,7 @@ public: } // Emit the CompiledIC call idiom - void ic_call(address entry); + address ic_call(address entry); public: diff --git a/hotspot/src/cpu/ppc/vm/compiledIC_ppc.cpp b/hotspot/src/cpu/ppc/vm/compiledIC_ppc.cpp index 1b54594d09c..762a329e259 100644 --- a/hotspot/src/cpu/ppc/vm/compiledIC_ppc.cpp +++ b/hotspot/src/cpu/ppc/vm/compiledIC_ppc.cpp @@ -94,7 +94,7 @@ bool CompiledIC::is_icholder_call_site(virtual_call_Relocation* call_site) { const int IC_pos_in_java_to_interp_stub = 8; #define __ _masm. -void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { +address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { #ifdef COMPILER2 // Get the mark within main instrs section which is set to the address of the call. address call_addr = cbuf.insts_mark(); @@ -106,8 +106,7 @@ void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { // Start the stub. address stub = __ start_a_stub(CompiledStaticCall::to_interp_stub_size()); if (stub == NULL) { - Compile::current()->env()->record_out_of_memory_failure(); - return; + return NULL; // CodeCache is full } // For java_to_interp stubs we use R11_scratch1 as scratch register @@ -149,6 +148,7 @@ void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { // End the stub. __ end_a_stub(); + return stub; #else ShouldNotReachHere(); #endif diff --git a/hotspot/src/cpu/ppc/vm/interp_masm_ppc_64.cpp b/hotspot/src/cpu/ppc/vm/interp_masm_ppc_64.cpp index 00330ef3461..2c95de9b782 100644 --- a/hotspot/src/cpu/ppc/vm/interp_masm_ppc_64.cpp +++ b/hotspot/src/cpu/ppc/vm/interp_masm_ppc_64.cpp @@ -2187,7 +2187,7 @@ void InterpreterMacroAssembler::get_method_counters(Register method, } void InterpreterMacroAssembler::increment_invocation_counter(Register Rcounters, Register iv_be_count, Register Rtmp_r0) { - assert(UseCompiler, "incrementing must be useful"); + assert(UseCompiler || LogTouchedMethods, "incrementing must be useful"); Register invocation_count = iv_be_count; Register backedge_count = Rtmp_r0; int delta = InvocationCounter::count_increment; diff --git a/hotspot/src/cpu/ppc/vm/ppc.ad b/hotspot/src/cpu/ppc/vm/ppc.ad index a4e5f5a454a..5e0e977e287 100644 --- a/hotspot/src/cpu/ppc/vm/ppc.ad +++ b/hotspot/src/cpu/ppc/vm/ppc.ad @@ -1082,7 +1082,7 @@ void CallStubImpl::emit_trampoline_stub(MacroAssembler &_masm, int destination_t // Start the stub. address stub = __ start_a_stub(Compile::MAX_stubs_size/2); if (stub == NULL) { - Compile::current()->env()->record_out_of_memory_failure(); + ciEnv::current()->record_failure("CodeCache is full"); return; } @@ -1160,7 +1160,7 @@ EmitCallOffsets emit_call_with_trampoline_stub(MacroAssembler &_masm, address en // Emit the trampoline stub which will be related to the branch-and-link below. CallStubImpl::emit_trampoline_stub(_masm, entry_point_toc_offset, offsets.insts_call_instruction_offset); - if (Compile::current()->env()->failing()) { return offsets; } // Code cache may be full. + if (ciEnv::current()->failing()) { return offsets; } // Code cache may be full. __ relocate(rtype); } @@ -3397,7 +3397,7 @@ encode %{ // Emit the trampoline stub which will be related to the branch-and-link below. CallStubImpl::emit_trampoline_stub(_masm, entry_point_toc_offset, start_offset); - if (Compile::current()->env()->failing()) { return; } // Code cache may be full. + if (ciEnv::current()->failing()) { return; } // Code cache may be full. __ relocate(_optimized_virtual ? relocInfo::opt_virtual_call_type : relocInfo::static_call_type); } @@ -3410,7 +3410,11 @@ encode %{ __ bl(__ pc()); // Emits a relocation. // The stub for call to interpreter. - CompiledStaticCall::emit_to_interp_stub(cbuf); + address stub = CompiledStaticCall::emit_to_interp_stub(cbuf); + if (stub == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return; + } } %} @@ -3455,7 +3459,11 @@ encode %{ assert(_method, "execute next statement conditionally"); // The stub for call to interpreter. - CompiledStaticCall::emit_to_interp_stub(cbuf); + address stub = CompiledStaticCall::emit_to_interp_stub(cbuf); + if (stub == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return; + } // Restore original sp. __ ld(R11_scratch1, 0, R1_SP); // Load caller sp. diff --git a/hotspot/src/cpu/sparc/vm/c1_CodeStubs_sparc.cpp b/hotspot/src/cpu/sparc/vm/c1_CodeStubs_sparc.cpp index f998a9c3a12..4f511dce70d 100644 --- a/hotspot/src/cpu/sparc/vm/c1_CodeStubs_sparc.cpp +++ b/hotspot/src/cpu/sparc/vm/c1_CodeStubs_sparc.cpp @@ -432,6 +432,9 @@ void ArrayCopyStub::emit_code(LIR_Assembler* ce) { __ mov(length()->as_register(), O4); ce->emit_static_call_stub(); + if (ce->compilation()->bailed_out()) { + return; // CodeCache is full + } __ call(SharedRuntime::get_resolve_static_call_stub(), relocInfo::static_call_type); __ delayed()->nop(); diff --git a/hotspot/src/cpu/sparc/vm/compiledIC_sparc.cpp b/hotspot/src/cpu/sparc/vm/compiledIC_sparc.cpp index a4b2a094a5b..b6021917710 100644 --- a/hotspot/src/cpu/sparc/vm/compiledIC_sparc.cpp +++ b/hotspot/src/cpu/sparc/vm/compiledIC_sparc.cpp @@ -53,7 +53,7 @@ bool CompiledIC::is_icholder_call_site(virtual_call_Relocation* call_site) { // ---------------------------------------------------------------------------- #define __ _masm. -void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { +address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { #ifdef COMPILER2 // Stub is fixed up when the corresponding call is converted from calling // compiled code to calling interpreted code. @@ -64,9 +64,10 @@ void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { MacroAssembler _masm(&cbuf); - address base = - __ start_a_stub(to_interp_stub_size()*2); - if (base == NULL) return; // CodeBuffer::expand failed. + address base = __ start_a_stub(to_interp_stub_size()); + if (base == NULL) { + return NULL; // CodeBuffer::expand failed. + } // Static stub relocation stores the instruction address of the call. __ relocate(static_stub_Relocation::spec(mark)); @@ -81,6 +82,7 @@ void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { // Update current stubs pointer and restore code_end. __ end_a_stub(); + return base; #else ShouldNotReachHere(); #endif diff --git a/hotspot/src/cpu/sparc/vm/interp_masm_sparc.cpp b/hotspot/src/cpu/sparc/vm/interp_masm_sparc.cpp index 153bfbdda55..44ad8d91dae 100644 --- a/hotspot/src/cpu/sparc/vm/interp_masm_sparc.cpp +++ b/hotspot/src/cpu/sparc/vm/interp_masm_sparc.cpp @@ -2314,7 +2314,7 @@ void InterpreterMacroAssembler::get_method_counters(Register method, } void InterpreterMacroAssembler::increment_invocation_counter( Register Rcounters, Register Rtmp, Register Rtmp2 ) { - assert(UseCompiler, "incrementing must be useful"); + assert(UseCompiler || LogTouchedMethods, "incrementing must be useful"); assert_different_registers(Rcounters, Rtmp, Rtmp2); Address inv_counter(Rcounters, MethodCounters::invocation_counter_offset() + diff --git a/hotspot/src/cpu/sparc/vm/sparc.ad b/hotspot/src/cpu/sparc/vm/sparc.ad index 4a742755f29..04491901ddb 100644 --- a/hotspot/src/cpu/sparc/vm/sparc.ad +++ b/hotspot/src/cpu/sparc/vm/sparc.ad @@ -1773,9 +1773,11 @@ int HandlerImpl::emit_exception_handler(CodeBuffer& cbuf) { AddressLiteral exception_blob(OptoRuntime::exception_blob()->entry_point()); MacroAssembler _masm(&cbuf); - address base = - __ start_a_stub(size_exception_handler()); - if (base == NULL) return 0; // CodeBuffer::expand failed + address base = __ start_a_stub(size_exception_handler()); + if (base == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return 0; // CodeBuffer::expand failed + } int offset = __ offset(); @@ -1796,9 +1798,11 @@ int HandlerImpl::emit_deopt_handler(CodeBuffer& cbuf) { AddressLiteral deopt_blob(SharedRuntime::deopt_blob()->unpack()); MacroAssembler _masm(&cbuf); - address base = - __ start_a_stub(size_deopt_handler()); - if (base == NULL) return 0; // CodeBuffer::expand failed + address base = __ start_a_stub(size_deopt_handler()); + if (base == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return 0; // CodeBuffer::expand failed + } int offset = __ offset(); __ save_frame(0); @@ -2599,7 +2603,12 @@ encode %{ emit_call_reloc(cbuf, $meth$$method, relocInfo::static_call_type); } if (_method) { // Emit stub for static call. - CompiledStaticCall::emit_to_interp_stub(cbuf); + address stub = CompiledStaticCall::emit_to_interp_stub(cbuf); + // Stub does not fit into scratch buffer if TraceJumps is enabled + if (stub == NULL && !(TraceJumps && Compile::current()->in_scratch_emit_size())) { + ciEnv::current()->record_failure("CodeCache is full"); + return; + } } %} diff --git a/hotspot/src/cpu/x86/vm/c1_CodeStubs_x86.cpp b/hotspot/src/cpu/x86/vm/c1_CodeStubs_x86.cpp index 71684561223..a3196fe0b6d 100644 --- a/hotspot/src/cpu/x86/vm/c1_CodeStubs_x86.cpp +++ b/hotspot/src/cpu/x86/vm/c1_CodeStubs_x86.cpp @@ -503,6 +503,9 @@ void ArrayCopyStub::emit_code(LIR_Assembler* ce) { ce->align_call(lir_static_call); ce->emit_static_call_stub(); + if (ce->compilation()->bailed_out()) { + return; // CodeCache is full + } AddressLiteral resolve(SharedRuntime::get_resolve_static_call_stub(), relocInfo::static_call_type); __ call(resolve); diff --git a/hotspot/src/cpu/x86/vm/compiledIC_x86.cpp b/hotspot/src/cpu/x86/vm/compiledIC_x86.cpp index 9537ef971f7..29eba2fb99d 100644 --- a/hotspot/src/cpu/x86/vm/compiledIC_x86.cpp +++ b/hotspot/src/cpu/x86/vm/compiledIC_x86.cpp @@ -50,7 +50,7 @@ bool CompiledIC::is_icholder_call_site(virtual_call_Relocation* call_site) { // ---------------------------------------------------------------------------- #define __ _masm. -void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { +address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { // Stub is fixed up when the corresponding call is converted from // calling compiled code to calling interpreted code. // movq rbx, 0 @@ -62,9 +62,10 @@ void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { // That's why we must use the macroassembler to generate a stub. MacroAssembler _masm(&cbuf); - address base = - __ start_a_stub(to_interp_stub_size()*2); - if (base == NULL) return; // CodeBuffer::expand failed. + address base = __ start_a_stub(to_interp_stub_size()); + if (base == NULL) { + return NULL; // CodeBuffer::expand failed. + } // Static stub relocation stores the instruction address of the call. __ relocate(static_stub_Relocation::spec(mark), Assembler::imm_operand); // Static stub relocation also tags the Method* in the code-stream. @@ -74,6 +75,7 @@ void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { // Update current stubs pointer and restore insts_end. __ end_a_stub(); + return base; } #undef __ diff --git a/hotspot/src/cpu/x86/vm/x86.ad b/hotspot/src/cpu/x86/vm/x86.ad index 53825e4fbb2..c8aa50a106c 100644 --- a/hotspot/src/cpu/x86/vm/x86.ad +++ b/hotspot/src/cpu/x86/vm/x86.ad @@ -1594,7 +1594,10 @@ int HandlerImpl::emit_exception_handler(CodeBuffer& cbuf) { // That's why we must use the macroassembler to generate a handler. MacroAssembler _masm(&cbuf); address base = __ start_a_stub(size_exception_handler()); - if (base == NULL) return 0; // CodeBuffer::expand failed + if (base == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return 0; // CodeBuffer::expand failed + } int offset = __ offset(); __ jump(RuntimeAddress(OptoRuntime::exception_blob()->entry_point())); assert(__ offset() - offset <= (int) size_exception_handler(), "overflow"); @@ -1609,7 +1612,10 @@ int HandlerImpl::emit_deopt_handler(CodeBuffer& cbuf) { // That's why we must use the macroassembler to generate a handler. MacroAssembler _masm(&cbuf); address base = __ start_a_stub(size_deopt_handler()); - if (base == NULL) return 0; // CodeBuffer::expand failed + if (base == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return 0; // CodeBuffer::expand failed + } int offset = __ offset(); #ifdef _LP64 diff --git a/hotspot/src/cpu/x86/vm/x86_32.ad b/hotspot/src/cpu/x86/vm/x86_32.ad index be2f7e65b36..dfe10d5b02a 100644 --- a/hotspot/src/cpu/x86/vm/x86_32.ad +++ b/hotspot/src/cpu/x86/vm/x86_32.ad @@ -1907,7 +1907,11 @@ encode %{ static_call_Relocation::spec(), RELOC_IMM32 ); } if (_method) { // Emit stub for static call. - CompiledStaticCall::emit_to_interp_stub(cbuf); + address stub = CompiledStaticCall::emit_to_interp_stub(cbuf); + if (stub == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return; + } } %} diff --git a/hotspot/src/cpu/x86/vm/x86_64.ad b/hotspot/src/cpu/x86/vm/x86_64.ad index ea8b1c81276..c04661cda7d 100644 --- a/hotspot/src/cpu/x86/vm/x86_64.ad +++ b/hotspot/src/cpu/x86/vm/x86_64.ad @@ -2137,7 +2137,11 @@ encode %{ } if (_method) { // Emit stub for static call. - CompiledStaticCall::emit_to_interp_stub(cbuf); + address stub = CompiledStaticCall::emit_to_interp_stub(cbuf); + if (stub == NULL) { + ciEnv::current()->record_failure("CodeCache is full"); + return; + } } %} diff --git a/hotspot/src/cpu/zero/vm/compiledIC_zero.cpp b/hotspot/src/cpu/zero/vm/compiledIC_zero.cpp index 143dc317380..185a8b169c0 100644 --- a/hotspot/src/cpu/zero/vm/compiledIC_zero.cpp +++ b/hotspot/src/cpu/zero/vm/compiledIC_zero.cpp @@ -60,8 +60,9 @@ bool CompiledIC::is_icholder_call_site(virtual_call_Relocation* call_site) { // ---------------------------------------------------------------------------- -void CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { +address CompiledStaticCall::emit_to_interp_stub(CodeBuffer &cbuf) { ShouldNotReachHere(); // Only needed for COMPILER2. + return NULL; } int CompiledStaticCall::to_interp_stub_size() { diff --git a/hotspot/src/os/aix/vm/os_aix.cpp b/hotspot/src/os/aix/vm/os_aix.cpp index c78577c542f..f2c3933f35f 100644 --- a/hotspot/src/os/aix/vm/os_aix.cpp +++ b/hotspot/src/os/aix/vm/os_aix.cpp @@ -971,34 +971,32 @@ bool os::create_thread(Thread* thread, ThreadType thr_type, size_t stack_size) { guarantee(pthread_attr_setsuspendstate_np(&attr, PTHREAD_CREATE_SUSPENDED_NP) == 0, "???"); // calculate stack size if it's not specified by caller - if (os::Aix::supports_variable_stack_size()) { - if (stack_size == 0) { - stack_size = os::Aix::default_stack_size(thr_type); + if (stack_size == 0) { + stack_size = os::Aix::default_stack_size(thr_type); - switch (thr_type) { - case os::java_thread: - // Java threads use ThreadStackSize whose default value can be changed with the flag -Xss. - assert(JavaThread::stack_size_at_create() > 0, "this should be set"); - stack_size = JavaThread::stack_size_at_create(); + switch (thr_type) { + case os::java_thread: + // Java threads use ThreadStackSize whose default value can be changed with the flag -Xss. + assert(JavaThread::stack_size_at_create() > 0, "this should be set"); + stack_size = JavaThread::stack_size_at_create(); + break; + case os::compiler_thread: + if (CompilerThreadStackSize > 0) { + stack_size = (size_t)(CompilerThreadStackSize * K); break; - case os::compiler_thread: - if (CompilerThreadStackSize > 0) { - stack_size = (size_t)(CompilerThreadStackSize * K); - break; - } // else fall through: - // use VMThreadStackSize if CompilerThreadStackSize is not defined - case os::vm_thread: - case os::pgc_thread: - case os::cgc_thread: - case os::watcher_thread: - if (VMThreadStackSize > 0) stack_size = (size_t)(VMThreadStackSize * K); - break; - } + } // else fall through: + // use VMThreadStackSize if CompilerThreadStackSize is not defined + case os::vm_thread: + case os::pgc_thread: + case os::cgc_thread: + case os::watcher_thread: + if (VMThreadStackSize > 0) stack_size = (size_t)(VMThreadStackSize * K); + break; } + } - stack_size = MAX2(stack_size, os::Aix::min_stack_allowed); - pthread_attr_setstacksize(&attr, stack_size); - } //else let thread_create() pick the default value (96 K on AIX) + stack_size = MAX2(stack_size, os::Aix::min_stack_allowed); + pthread_attr_setstacksize(&attr, stack_size); pthread_t tid; int ret = pthread_create(&tid, &attr, (void* (*)(void*)) java_start, thread); diff --git a/hotspot/src/os/aix/vm/os_aix.hpp b/hotspot/src/os/aix/vm/os_aix.hpp index faba5c2b45e..8e96dd9f6c5 100644 --- a/hotspot/src/os/aix/vm/os_aix.hpp +++ b/hotspot/src/os/aix/vm/os_aix.hpp @@ -131,8 +131,6 @@ class Aix { static void initialize_libo4(); static void initialize_libperfstat(); - static bool supports_variable_stack_size(); - public: static void init_thread_fpu_state(); static pthread_t main_thread(void) { return _main_thread; } diff --git a/hotspot/src/os/bsd/vm/os_bsd.cpp b/hotspot/src/os/bsd/vm/os_bsd.cpp index 8f935d85c05..1c243ae387f 100644 --- a/hotspot/src/os/bsd/vm/os_bsd.cpp +++ b/hotspot/src/os/bsd/vm/os_bsd.cpp @@ -739,40 +739,35 @@ bool os::create_thread(Thread* thread, ThreadType thr_type, size_t stack_size) { pthread_attr_init(&attr); pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED); - // stack size - if (os::Bsd::supports_variable_stack_size()) { - // calculate stack size if it's not specified by caller - if (stack_size == 0) { - stack_size = os::Bsd::default_stack_size(thr_type); + // calculate stack size if it's not specified by caller + if (stack_size == 0) { + stack_size = os::Bsd::default_stack_size(thr_type); - switch (thr_type) { - case os::java_thread: - // Java threads use ThreadStackSize which default value can be - // changed with the flag -Xss - assert(JavaThread::stack_size_at_create() > 0, "this should be set"); - stack_size = JavaThread::stack_size_at_create(); + switch (thr_type) { + case os::java_thread: + // Java threads use ThreadStackSize which default value can be + // changed with the flag -Xss + assert(JavaThread::stack_size_at_create() > 0, "this should be set"); + stack_size = JavaThread::stack_size_at_create(); + break; + case os::compiler_thread: + if (CompilerThreadStackSize > 0) { + stack_size = (size_t)(CompilerThreadStackSize * K); break; - case os::compiler_thread: - if (CompilerThreadStackSize > 0) { - stack_size = (size_t)(CompilerThreadStackSize * K); - break; - } // else fall through: - // use VMThreadStackSize if CompilerThreadStackSize is not defined - case os::vm_thread: - case os::pgc_thread: - case os::cgc_thread: - case os::watcher_thread: - if (VMThreadStackSize > 0) stack_size = (size_t)(VMThreadStackSize * K); - break; - } + } // else fall through: + // use VMThreadStackSize if CompilerThreadStackSize is not defined + case os::vm_thread: + case os::pgc_thread: + case os::cgc_thread: + case os::watcher_thread: + if (VMThreadStackSize > 0) stack_size = (size_t)(VMThreadStackSize * K); + break; } - - stack_size = MAX2(stack_size, os::Bsd::min_stack_allowed); - pthread_attr_setstacksize(&attr, stack_size); - } else { - // let pthread_create() pick the default value. } + stack_size = MAX2(stack_size, os::Bsd::min_stack_allowed); + pthread_attr_setstacksize(&attr, stack_size); + ThreadState state; { diff --git a/hotspot/src/os/bsd/vm/os_bsd.hpp b/hotspot/src/os/bsd/vm/os_bsd.hpp index 8c6dbb78888..8b48cb78cf0 100644 --- a/hotspot/src/os/bsd/vm/os_bsd.hpp +++ b/hotspot/src/os/bsd/vm/os_bsd.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2015, 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 @@ -75,8 +75,6 @@ class Bsd { static julong physical_memory() { return _physical_memory; } static void initialize_system_info(); - static bool supports_variable_stack_size(); - static void rebuild_cpu_to_node_map(); static GrowableArray* cpu_to_node() { return _cpu_to_node; } diff --git a/hotspot/src/os/linux/vm/os_linux.cpp b/hotspot/src/os/linux/vm/os_linux.cpp index 0af27515e89..bd4aa14b32f 100644 --- a/hotspot/src/os/linux/vm/os_linux.cpp +++ b/hotspot/src/os/linux/vm/os_linux.cpp @@ -653,8 +653,7 @@ static void *java_start(Thread *thread) { OSThread* osthread = thread->osthread(); Monitor* sync = osthread->startThread_lock(); - // thread_id is kernel thread id (similar to Solaris LWP id) - osthread->set_thread_id(os::Linux::gettid()); + osthread->set_thread_id(os::current_thread_id()); if (UseNUMA) { int lgrp_id = os::numa_get_group_id(); @@ -712,39 +711,35 @@ bool os::create_thread(Thread* thread, ThreadType thr_type, pthread_attr_setdetachstate(&attr, PTHREAD_CREATE_DETACHED); // stack size - if (os::Linux::supports_variable_stack_size()) { - // calculate stack size if it's not specified by caller - if (stack_size == 0) { - stack_size = os::Linux::default_stack_size(thr_type); + // calculate stack size if it's not specified by caller + if (stack_size == 0) { + stack_size = os::Linux::default_stack_size(thr_type); - switch (thr_type) { - case os::java_thread: - // Java threads use ThreadStackSize which default value can be - // changed with the flag -Xss - assert(JavaThread::stack_size_at_create() > 0, "this should be set"); - stack_size = JavaThread::stack_size_at_create(); + switch (thr_type) { + case os::java_thread: + // Java threads use ThreadStackSize which default value can be + // changed with the flag -Xss + assert(JavaThread::stack_size_at_create() > 0, "this should be set"); + stack_size = JavaThread::stack_size_at_create(); + break; + case os::compiler_thread: + if (CompilerThreadStackSize > 0) { + stack_size = (size_t)(CompilerThreadStackSize * K); break; - case os::compiler_thread: - if (CompilerThreadStackSize > 0) { - stack_size = (size_t)(CompilerThreadStackSize * K); - break; - } // else fall through: - // use VMThreadStackSize if CompilerThreadStackSize is not defined - case os::vm_thread: - case os::pgc_thread: - case os::cgc_thread: - case os::watcher_thread: - if (VMThreadStackSize > 0) stack_size = (size_t)(VMThreadStackSize * K); - break; - } + } // else fall through: + // use VMThreadStackSize if CompilerThreadStackSize is not defined + case os::vm_thread: + case os::pgc_thread: + case os::cgc_thread: + case os::watcher_thread: + if (VMThreadStackSize > 0) stack_size = (size_t)(VMThreadStackSize * K); + break; } - - stack_size = MAX2(stack_size, os::Linux::min_stack_allowed); - pthread_attr_setstacksize(&attr, stack_size); - } else { - // let pthread_create() pick the default value. } + stack_size = MAX2(stack_size, os::Linux::min_stack_allowed); + pthread_attr_setstacksize(&attr, stack_size); + // glibc guard page pthread_attr_setguardsize(&attr, os::Linux::default_guard_size(thr_type)); @@ -1424,7 +1419,8 @@ size_t os::lasterror(char *buf, size_t len) { return n; } -intx os::current_thread_id() { return (intx)pthread_self(); } +// thread_id is kernel thread id (similar to Solaris LWP id) +intx os::current_thread_id() { return os::Linux::gettid(); } int os::current_process_id() { return ::getpid(); } diff --git a/hotspot/src/os/linux/vm/os_linux.hpp b/hotspot/src/os/linux/vm/os_linux.hpp index 9128344ace2..b8104e75ebc 100644 --- a/hotspot/src/os/linux/vm/os_linux.hpp +++ b/hotspot/src/os/linux/vm/os_linux.hpp @@ -83,8 +83,6 @@ class Linux { static void set_glibc_version(const char *s) { _glibc_version = s; } static void set_libpthread_version(const char *s) { _libpthread_version = s; } - static bool supports_variable_stack_size(); - static void rebuild_cpu_to_node_map(); static GrowableArray* cpu_to_node() { return _cpu_to_node; } diff --git a/hotspot/src/os_cpu/aix_ppc/vm/os_aix_ppc.cpp b/hotspot/src/os_cpu/aix_ppc/vm/os_aix_ppc.cpp index 9381b5dcd17..d8829b51c6f 100644 --- a/hotspot/src/os_cpu/aix_ppc/vm/os_aix_ppc.cpp +++ b/hotspot/src/os_cpu/aix_ppc/vm/os_aix_ppc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, Oracle and/or its affiliates. All rights reserved. * Copyright 2012, 2014 SAP AG. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -489,10 +489,6 @@ void os::Aix::init_thread_fpu_state(void) { size_t os::Aix::min_stack_allowed = 128*K; -// Aix is always in floating stack mode. The stack size for a new -// thread can be set via pthread_attr_setstacksize(). -bool os::Aix::supports_variable_stack_size() { return true; } - // return default stack size for thr_type size_t os::Aix::default_stack_size(os::ThreadType thr_type) { // default stack size (compiler thread needs larger stack) diff --git a/hotspot/src/os_cpu/bsd_x86/vm/os_bsd_x86.cpp b/hotspot/src/os_cpu/bsd_x86/vm/os_bsd_x86.cpp index 4b2da94715a..423fea33748 100644 --- a/hotspot/src/os_cpu/bsd_x86/vm/os_bsd_x86.cpp +++ b/hotspot/src/os_cpu/bsd_x86/vm/os_bsd_x86.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2015, 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 @@ -780,9 +780,6 @@ bool os::is_allocatable(size_t bytes) { #ifdef AMD64 size_t os::Bsd::min_stack_allowed = 64 * K; - -// amd64: pthread on amd64 is always in floating stack mode -bool os::Bsd::supports_variable_stack_size() { return true; } #else size_t os::Bsd::min_stack_allowed = (48 DEBUG_ONLY(+4))*K; @@ -790,7 +787,6 @@ size_t os::Bsd::min_stack_allowed = (48 DEBUG_ONLY(+4))*K; #define GET_GS() ({int gs; __asm__ volatile("movw %%gs, %w0":"=q"(gs)); gs&0xffff;}) #endif -bool os::Bsd::supports_variable_stack_size() { return true; } #endif // AMD64 // return default stack size for thr_type diff --git a/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp b/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp index 0ed05eb9a76..9b2db238c0e 100644 --- a/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp +++ b/hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. * Copyright 2007, 2008, 2009, 2010 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -290,10 +290,6 @@ bool os::is_allocatable(size_t bytes) { size_t os::Bsd::min_stack_allowed = 64 * K; -bool os::Bsd::supports_variable_stack_size() { - return true; -} - size_t os::Bsd::default_stack_size(os::ThreadType thr_type) { #ifdef _LP64 size_t s = (thr_type == os::compiler_thread ? 4 * M : 1 * M); diff --git a/hotspot/src/os_cpu/linux_aarch64/vm/os_linux_aarch64.cpp b/hotspot/src/os_cpu/linux_aarch64/vm/os_linux_aarch64.cpp index 2d116ef212c..3a3ffd9fb30 100644 --- a/hotspot/src/os_cpu/linux_aarch64/vm/os_linux_aarch64.cpp +++ b/hotspot/src/os_cpu/linux_aarch64/vm/os_linux_aarch64.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2015, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2014, Red Hat Inc. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -496,9 +496,6 @@ bool os::is_allocatable(size_t bytes) { size_t os::Linux::min_stack_allowed = 64 * K; -// aarch64: pthread on aarch64 is always in floating stack mode -bool os::Linux::supports_variable_stack_size() { return true; } - // return default stack size for thr_type size_t os::Linux::default_stack_size(os::ThreadType thr_type) { // default stack size (compiler thread needs larger stack) diff --git a/hotspot/src/os_cpu/linux_ppc/vm/os_linux_ppc.cpp b/hotspot/src/os_cpu/linux_ppc/vm/os_linux_ppc.cpp index a605d147bd4..ebf67a09f3a 100644 --- a/hotspot/src/os_cpu/linux_ppc/vm/os_linux_ppc.cpp +++ b/hotspot/src/os_cpu/linux_ppc/vm/os_linux_ppc.cpp @@ -467,8 +467,6 @@ void os::Linux::set_fpu_control_word(int fpu_control) { size_t os::Linux::min_stack_allowed = 128*K; -bool os::Linux::supports_variable_stack_size() { return true; } - // return default stack size for thr_type size_t os::Linux::default_stack_size(os::ThreadType thr_type) { // default stack size (compiler thread needs larger stack) diff --git a/hotspot/src/os_cpu/linux_sparc/vm/os_linux_sparc.cpp b/hotspot/src/os_cpu/linux_sparc/vm/os_linux_sparc.cpp index e733cc9e6ab..0c1c6263586 100644 --- a/hotspot/src/os_cpu/linux_sparc/vm/os_linux_sparc.cpp +++ b/hotspot/src/os_cpu/linux_sparc/vm/os_linux_sparc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2015, 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 @@ -733,9 +733,6 @@ bool os::is_allocatable(size_t bytes) { size_t os::Linux::min_stack_allowed = 128 * K; -// pthread on Ubuntu is always in floating stack mode -bool os::Linux::supports_variable_stack_size() { return true; } - // return default stack size for thr_type size_t os::Linux::default_stack_size(os::ThreadType thr_type) { // default stack size (compiler thread needs larger stack) diff --git a/hotspot/src/os_cpu/linux_x86/vm/os_linux_x86.cpp b/hotspot/src/os_cpu/linux_x86/vm/os_linux_x86.cpp index 700c6a762a7..decb51ea74f 100644 --- a/hotspot/src/os_cpu/linux_x86/vm/os_linux_x86.cpp +++ b/hotspot/src/os_cpu/linux_x86/vm/os_linux_x86.cpp @@ -623,11 +623,6 @@ size_t os::Linux::min_stack_allowed = 64 * K; size_t os::Linux::min_stack_allowed = (48 DEBUG_ONLY(+4))*K; #endif // AMD64 -// Test if pthread library can support variable thread stack size. -bool os::Linux::supports_variable_stack_size() { - return true; -} - // return default stack size for thr_type size_t os::Linux::default_stack_size(os::ThreadType thr_type) { // default stack size (compiler thread needs larger stack) diff --git a/hotspot/src/os_cpu/linux_zero/vm/os_linux_zero.cpp b/hotspot/src/os_cpu/linux_zero/vm/os_linux_zero.cpp index 08c46153e5f..5473f8aa44d 100644 --- a/hotspot/src/os_cpu/linux_zero/vm/os_linux_zero.cpp +++ b/hotspot/src/os_cpu/linux_zero/vm/os_linux_zero.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. * Copyright 2007, 2008, 2009, 2010 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -305,10 +305,6 @@ bool os::is_allocatable(size_t bytes) { size_t os::Linux::min_stack_allowed = 64 * K; -bool os::Linux::supports_variable_stack_size() { - return true; -} - size_t os::Linux::default_stack_size(os::ThreadType thr_type) { #ifdef _LP64 size_t s = (thr_type == os::compiler_thread ? 4 * M : 1 * M); diff --git a/hotspot/src/share/vm/c1/c1_Compiler.cpp b/hotspot/src/share/vm/c1/c1_Compiler.cpp index 84a7bd09682..dad6edb35b3 100644 --- a/hotspot/src/share/vm/c1/c1_Compiler.cpp +++ b/hotspot/src/share/vm/c1/c1_Compiler.cpp @@ -239,25 +239,6 @@ bool Compiler::is_intrinsic_supported(methodHandle method) { return true; } -bool Compiler::is_intrinsic_disabled_by_flag(methodHandle method) { - vmIntrinsics::ID id = method->intrinsic_id(); - assert(id != vmIntrinsics::_none, "must be a VM intrinsic"); - - if (vmIntrinsics::is_disabled_by_flags(id)) { - return true; - } - - if (!InlineNatives && id != vmIntrinsics::_Reference_get) { - return true; - } - - if (!InlineClassNatives && id == vmIntrinsics::_getClass) { - return true; - } - - return false; -} - void Compiler::compile_method(ciEnv* env, ciMethod* method, int entry_bci) { BufferBlob* buffer_blob = CompilerThread::current()->get_buffer_blob(); assert(buffer_blob != NULL, "Must exist"); @@ -275,7 +256,3 @@ void Compiler::compile_method(ciEnv* env, ciMethod* method, int entry_bci) { void Compiler::print_timers() { Compilation::print_timers(); } - -bool Compiler::is_intrinsic_available(methodHandle method, methodHandle compilation_context) { - return is_intrinsic_supported(method) && !is_intrinsic_disabled_by_flag(method); -} diff --git a/hotspot/src/share/vm/c1/c1_Compiler.hpp b/hotspot/src/share/vm/c1/c1_Compiler.hpp index 8b8c8d414e3..96a6bad4f5e 100644 --- a/hotspot/src/share/vm/c1/c1_Compiler.hpp +++ b/hotspot/src/share/vm/c1/c1_Compiler.hpp @@ -55,18 +55,9 @@ class Compiler: public AbstractCompiler { // Print compilation timers and statistics virtual void print_timers(); - // Check the availability of an intrinsic for 'method' given a compilation context. - // The compilation context is needed to support per-method usage of the - // DisableIntrinsic flag. However, as C1 ignores the DisableIntrinsic flag, it - // ignores the compilation context. - virtual bool is_intrinsic_available(methodHandle method, methodHandle compilation_context); - // Check if the C1 compiler supports an intrinsic for 'method'. virtual bool is_intrinsic_supported(methodHandle method); - // Processing of command-line flags specific to the C1 compiler. - virtual bool is_intrinsic_disabled_by_flag(methodHandle method); - // Size of the code buffer static int code_buffer_size(); }; diff --git a/hotspot/src/share/vm/c1/c1_GraphBuilder.cpp b/hotspot/src/share/vm/c1/c1_GraphBuilder.cpp index e607b02febc..f3b25e8fa41 100644 --- a/hotspot/src/share/vm/c1/c1_GraphBuilder.cpp +++ b/hotspot/src/share/vm/c1/c1_GraphBuilder.cpp @@ -3491,8 +3491,16 @@ void GraphBuilder::build_graph_for_intrinsic(ciMethod* callee) { bool GraphBuilder::try_inline_intrinsics(ciMethod* callee) { // For calling is_intrinsic_available we need to transition to // the '_thread_in_vm' state because is_intrinsic_available() - // does not accesses critical VM-internal data. - if (!_compilation->compiler()->is_intrinsic_available(callee->get_Method(), NULL)) { + // accesses critical VM-internal data. + bool is_available = false; + { + VM_ENTRY_MARK; + methodHandle mh(THREAD, callee->get_Method()); + methodHandle ct(THREAD, method()->get_Method()); + is_available = _compilation->compiler()->is_intrinsic_available(mh, ct); + } + + if (!is_available) { if (!InlineNatives) { // Return false and also set message that the inlining of // intrinsics has been disabled in general. diff --git a/hotspot/src/share/vm/c1/c1_LIRAssembler.cpp b/hotspot/src/share/vm/c1/c1_LIRAssembler.cpp index f82913e0d18..2f99452a5a9 100644 --- a/hotspot/src/share/vm/c1/c1_LIRAssembler.cpp +++ b/hotspot/src/share/vm/c1/c1_LIRAssembler.cpp @@ -443,6 +443,7 @@ void LIR_Assembler::emit_call(LIR_OpJavaCall* op) { // emit the static call stub stuff out of line emit_static_call_stub(); + CHECK_BAILOUT(); switch (op->code()) { case lir_static_call: diff --git a/hotspot/src/share/vm/classfile/imageDecompressor.cpp b/hotspot/src/share/vm/classfile/imageDecompressor.cpp index 68c5c56f2a4..d6339500234 100644 --- a/hotspot/src/share/vm/classfile/imageDecompressor.cpp +++ b/hotspot/src/share/vm/classfile/imageDecompressor.cpp @@ -22,8 +22,8 @@ * */ -#include "runtime/thread.inline.hpp" #include "precompiled.hpp" +#include "runtime/thread.inline.hpp" #include "classfile/imageDecompressor.hpp" #include "runtime/thread.hpp" #include "utilities/bytes.hpp" diff --git a/hotspot/src/share/vm/classfile/imageDecompressor.hpp b/hotspot/src/share/vm/classfile/imageDecompressor.hpp index c57a8523fdf..6fca341b003 100644 --- a/hotspot/src/share/vm/classfile/imageDecompressor.hpp +++ b/hotspot/src/share/vm/classfile/imageDecompressor.hpp @@ -26,7 +26,6 @@ #define SHARE_VM_CLASSFILE_IMAGEDECOMPRESSOR_HPP #include "runtime/thread.inline.hpp" -#include "precompiled.hpp" #include "classfile/classLoader.hpp" #include "classfile/imageFile.hpp" #include "classfile/symbolTable.hpp" diff --git a/hotspot/src/share/vm/classfile/vmSymbols.cpp b/hotspot/src/share/vm/classfile/vmSymbols.cpp index 1a968acc82c..cbbc4122853 100644 --- a/hotspot/src/share/vm/classfile/vmSymbols.cpp +++ b/hotspot/src/share/vm/classfile/vmSymbols.cpp @@ -417,8 +417,59 @@ int vmIntrinsics::predicates_needed(vmIntrinsics::ID id) { } } -bool vmIntrinsics::is_disabled_by_flags(vmIntrinsics::ID id) { +bool vmIntrinsics::is_disabled_by_flags(methodHandle method, methodHandle compilation_context) { + vmIntrinsics::ID id = method->intrinsic_id(); assert(id != vmIntrinsics::_none, "must be a VM intrinsic"); + + // Check if the intrinsic corresponding to 'method' has been disabled on + // the command line by using the DisableIntrinsic flag (either globally + // or on a per-method level, see src/share/vm/compiler/abstractCompiler.hpp + // for details). + // Usually, the compilation context is the caller of the method 'method'. + // The only case when for a non-recursive method 'method' the compilation context + // is not the caller of the 'method' (but it is the method itself) is + // java.lang.ref.Referene::get. + // For java.lang.ref.Reference::get, the intrinsic version is used + // instead of the compiled version so that the value in the referent + // field can be registered by the G1 pre-barrier code. The intrinsified + // version of Reference::get also adds a memory barrier to prevent + // commoning reads from the referent field across safepoint since GC + // can change the referent field's value. See Compile::Compile() + // in src/share/vm/opto/compile.cpp or + // GraphBuilder::GraphBuilder() in src/share/vm/c1/c1_GraphBuilder.cpp + // for more details. + ccstr disable_intr = NULL; + if ((DisableIntrinsic[0] != '\0' && strstr(DisableIntrinsic, vmIntrinsics::name_at(id)) != NULL) || + (!compilation_context.is_null() && + CompilerOracle::has_option_value(compilation_context, "DisableIntrinsic", disable_intr) && + strstr(disable_intr, vmIntrinsics::name_at(id)) != NULL) + ) { + return true; + } + + // -XX:-InlineNatives disables nearly all intrinsics except the ones listed in + // the following switch statement. + if (!InlineNatives) { + switch (id) { + case vmIntrinsics::_indexOf: + case vmIntrinsics::_compareTo: + case vmIntrinsics::_equals: + case vmIntrinsics::_equalsC: + case vmIntrinsics::_getAndAddInt: + case vmIntrinsics::_getAndAddLong: + case vmIntrinsics::_getAndSetInt: + case vmIntrinsics::_getAndSetLong: + case vmIntrinsics::_getAndSetObject: + case vmIntrinsics::_loadFence: + case vmIntrinsics::_storeFence: + case vmIntrinsics::_fullFence: + case vmIntrinsics::_Reference_get: + break; + default: + return true; + } + } + switch (id) { case vmIntrinsics::_isInstance: case vmIntrinsics::_isAssignableFrom: @@ -430,6 +481,7 @@ bool vmIntrinsics::is_disabled_by_flags(vmIntrinsics::ID id) { case vmIntrinsics::_Class_cast: case vmIntrinsics::_getLength: case vmIntrinsics::_newArray: + case vmIntrinsics::_getClass: if (!InlineClassNatives) return true; break; case vmIntrinsics::_currentThread: @@ -522,6 +574,12 @@ bool vmIntrinsics::is_disabled_by_flags(vmIntrinsics::ID id) { case vmIntrinsics::_getAndSetInt: case vmIntrinsics::_getAndSetLong: case vmIntrinsics::_getAndSetObject: + case vmIntrinsics::_loadFence: + case vmIntrinsics::_storeFence: + case vmIntrinsics::_fullFence: + case vmIntrinsics::_compareAndSwapObject: + case vmIntrinsics::_compareAndSwapLong: + case vmIntrinsics::_compareAndSwapInt: if (!InlineUnsafeOps) return true; break; case vmIntrinsics::_getShortUnaligned: @@ -584,8 +642,8 @@ bool vmIntrinsics::is_disabled_by_flags(vmIntrinsics::ID id) { if (!InlineObjectCopy || !InlineArrayCopy) return true; break; case vmIntrinsics::_compareTo: - if (!SpecialStringCompareTo) return true; - break; + if (!SpecialStringCompareTo) return true; + break; case vmIntrinsics::_indexOf: if (!SpecialStringIndexOf) return true; break; @@ -602,8 +660,8 @@ bool vmIntrinsics::is_disabled_by_flags(vmIntrinsics::ID id) { if (!InlineReflectionGetCallerClass) return true; break; case vmIntrinsics::_multiplyToLen: - if (!UseMultiplyToLenIntrinsic) return true; - break; + if (!UseMultiplyToLenIntrinsic) return true; + break; case vmIntrinsics::_squareToLen: if (!UseSquareToLenIntrinsic) return true; break; diff --git a/hotspot/src/share/vm/classfile/vmSymbols.hpp b/hotspot/src/share/vm/classfile/vmSymbols.hpp index 9e67c5012e0..e012469abde 100644 --- a/hotspot/src/share/vm/classfile/vmSymbols.hpp +++ b/hotspot/src/share/vm/classfile/vmSymbols.hpp @@ -568,6 +568,11 @@ template(java_lang_management_ThreadInfo_constructor_signature, "(Ljava/lang/Thread;ILjava/lang/Object;Ljava/lang/Thread;JJJJ[Ljava/lang/StackTraceElement;)V") \ template(java_lang_management_ThreadInfo_with_locks_constructor_signature, "(Ljava/lang/Thread;ILjava/lang/Object;Ljava/lang/Thread;JJJJ[Ljava/lang/StackTraceElement;[Ljava/lang/Object;[I[Ljava/lang/Object;)V") \ template(long_long_long_long_void_signature, "(JJJJ)V") \ + template(finalizer_histogram_klass, "java/lang/ref/FinalizerHistogram") \ + template(void_finalizer_histogram_entry_array_signature, "()[Ljava/lang/ref/FinalizerHistogram$Entry;") \ + template(get_finalizer_histogram_name, "getFinalizerHistogram") \ + template(finalizer_histogram_entry_name_field, "className") \ + template(finalizer_histogram_entry_count_field, "instanceCount") \ \ template(java_lang_management_MemoryPoolMXBean, "java/lang/management/MemoryPoolMXBean") \ template(java_lang_management_MemoryManagerMXBean, "java/lang/management/MemoryManagerMXBean") \ @@ -1384,10 +1389,9 @@ public: // 'method' requires predicated logic. static int predicates_needed(vmIntrinsics::ID id); - // Returns true if an intrinsic is disabled by command-line flags and - // false otherwise. Implements functionality common to the C1 - // and the C2 compiler. - static bool is_disabled_by_flags(vmIntrinsics::ID id); + // Returns true if a compiler intrinsic is disabled by command-line flags + // and false otherwise. + static bool is_disabled_by_flags(methodHandle method, methodHandle compilation_context); }; #endif // SHARE_VM_CLASSFILE_VMSYMBOLS_HPP diff --git a/hotspot/src/share/vm/code/compiledIC.hpp b/hotspot/src/share/vm/code/compiledIC.hpp index 5d14381c842..56d37c07336 100644 --- a/hotspot/src/share/vm/code/compiledIC.hpp +++ b/hotspot/src/share/vm/code/compiledIC.hpp @@ -306,7 +306,7 @@ class CompiledStaticCall: public NativeCall { friend CompiledStaticCall* compiledStaticCall_at(Relocation* call_site); // Code - static void emit_to_interp_stub(CodeBuffer &cbuf); + static address emit_to_interp_stub(CodeBuffer &cbuf); static int to_interp_stub_size(); static int reloc_to_interp_stub(); diff --git a/hotspot/src/share/vm/compiler/abstractCompiler.hpp b/hotspot/src/share/vm/compiler/abstractCompiler.hpp index e3a727b0886..41c155d09a3 100644 --- a/hotspot/src/share/vm/compiler/abstractCompiler.hpp +++ b/hotspot/src/share/vm/compiler/abstractCompiler.hpp @@ -75,8 +75,8 @@ class AbstractCompiler : public CHeapObj { // // The second parameter, 'compilation_context', is needed to implement functionality // related to the DisableIntrinsic command-line flag. The DisableIntrinsic flag can - // be used to prohibit the C2 compiler (but not the C1 compiler) to use an intrinsic. - // There are three ways to disable an intrinsic using the DisableIntrinsic flag: + // be used to prohibit the compilers to use an intrinsic. There are three ways to + // disable an intrinsic using the DisableIntrinsic flag: // // (1) -XX:DisableIntrinsic=_hashCode,_getClass // Disables intrinsification of _hashCode and _getClass globally @@ -96,7 +96,8 @@ class AbstractCompiler : public CHeapObj { // compilation context is aClass::aMethod and java.lang.ref.Reference::get, // respectively. virtual bool is_intrinsic_available(methodHandle method, methodHandle compilation_context) { - return false; + return is_intrinsic_supported(method) && + !vmIntrinsics::is_disabled_by_flags(method, compilation_context); } // Determines if an intrinsic is supported by the compiler, that is, @@ -111,13 +112,6 @@ class AbstractCompiler : public CHeapObj { return false; } - // Implements compiler-specific processing of command-line flags. - // Processing of command-line flags common to all compilers is implemented - // in vmIntrinsicss::is_disabled_by_flag. - virtual bool is_intrinsic_disabled_by_flag(methodHandle method) { - return false; - } - // Compiler type queries. bool is_c1() { return _type == c1; } bool is_c2() { return _type == c2; } diff --git a/hotspot/src/share/vm/opto/arraycopynode.cpp b/hotspot/src/share/vm/opto/arraycopynode.cpp index b09cecc8760..0672fc8054e 100644 --- a/hotspot/src/share/vm/opto/arraycopynode.cpp +++ b/hotspot/src/share/vm/opto/arraycopynode.cpp @@ -79,10 +79,15 @@ void ArrayCopyNode::connect_outputs(GraphKit* kit) { #ifndef PRODUCT const char* ArrayCopyNode::_kind_names[] = {"arraycopy", "arraycopy, validated arguments", "clone", "oop array clone", "CopyOf", "CopyOfRange"}; + void ArrayCopyNode::dump_spec(outputStream *st) const { CallNode::dump_spec(st); st->print(" (%s%s)", _kind_names[_kind], _alloc_tightly_coupled ? ", tightly coupled allocation" : ""); } + +void ArrayCopyNode::dump_compact_spec(outputStream* st) const { + st->print("%s%s", _kind_names[_kind], _alloc_tightly_coupled ? ",tight" : ""); +} #endif intptr_t ArrayCopyNode::get_length_if_constant(PhaseGVN *phase) const { diff --git a/hotspot/src/share/vm/opto/arraycopynode.hpp b/hotspot/src/share/vm/opto/arraycopynode.hpp index 967ae556d4e..a2237cdd2ef 100644 --- a/hotspot/src/share/vm/opto/arraycopynode.hpp +++ b/hotspot/src/share/vm/opto/arraycopynode.hpp @@ -164,6 +164,7 @@ public: #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void dump_compact_spec(outputStream* st) const; #endif }; #endif // SHARE_VM_OPTO_ARRAYCOPYNODE_HPP diff --git a/hotspot/src/share/vm/opto/c2_globals.hpp b/hotspot/src/share/vm/opto/c2_globals.hpp index dbdfc532776..61abb9c0893 100644 --- a/hotspot/src/share/vm/opto/c2_globals.hpp +++ b/hotspot/src/share/vm/opto/c2_globals.hpp @@ -623,9 +623,6 @@ diagnostic(bool, PrintIntrinsics, false, \ "prints attempted and successful inlining of intrinsics") \ \ - diagnostic(ccstrlist, DisableIntrinsic, "", \ - "do not expand intrinsics whose (internal) names appear here") \ - \ develop(bool, StressReflectiveCode, false, \ "Use inexact types at allocations, etc., to test reflection") \ \ diff --git a/hotspot/src/share/vm/opto/c2compiler.cpp b/hotspot/src/share/vm/opto/c2compiler.cpp index 64ac374d00d..8da6995d80c 100644 --- a/hotspot/src/share/vm/opto/c2compiler.cpp +++ b/hotspot/src/share/vm/opto/c2compiler.cpp @@ -157,14 +157,6 @@ void C2Compiler::print_timers() { Compile::print_timers(); } -bool C2Compiler::is_intrinsic_available(methodHandle method, methodHandle compilation_context) { - // Assume a non-virtual dispatch. A virtual dispatch is - // possible for only a limited set of available intrinsics whereas - // a non-virtual dispatch is possible for all available intrinsics. - return is_intrinsic_supported(method, false) && - !is_intrinsic_disabled_by_flag(method, compilation_context); -} - bool C2Compiler::is_intrinsic_supported(methodHandle method, bool is_virtual) { vmIntrinsics::ID id = method->intrinsic_id(); assert(id != vmIntrinsics::_none, "must be a VM intrinsic"); @@ -436,78 +428,6 @@ bool C2Compiler::is_intrinsic_supported(methodHandle method, bool is_virtual) { return true; } -bool C2Compiler::is_intrinsic_disabled_by_flag(methodHandle method, methodHandle compilation_context) { - vmIntrinsics::ID id = method->intrinsic_id(); - assert(id != vmIntrinsics::_none, "must be a VM intrinsic"); - - if (vmIntrinsics::is_disabled_by_flags(method->intrinsic_id())) { - return true; - } - - // Check if the intrinsic corresponding to 'method' has been disabled on - // the command line by using the DisableIntrinsic flag (either globally - // or on a per-method level, see src/share/vm/compiler/abstractCompiler.hpp - // for details). - // Usually, the compilation context is the caller of the method 'method'. - // The only case when for a non-recursive method 'method' the compilation context - // is not the caller of the 'method' (but it is the method itself) is - // java.lang.ref.Referene::get. - // For java.lang.ref.Reference::get, the intrinsic version is used - // instead of the C2-compiled version so that the value in the referent - // field can be registered by the G1 pre-barrier code. The intrinsified - // version of Reference::get also adds a memory barrier to prevent - // commoning reads from the referent field across safepoint since GC - // can change the referent field's value. See Compile::Compile() - // in src/share/vm/opto/compile.cpp for more details. - ccstr disable_intr = NULL; - if ((DisableIntrinsic[0] != '\0' && strstr(DisableIntrinsic, vmIntrinsics::name_at(id)) != NULL) || - (!compilation_context.is_null() && - CompilerOracle::has_option_value(compilation_context, "DisableIntrinsic", disable_intr) && - strstr(disable_intr, vmIntrinsics::name_at(id)) != NULL) - ) { - return true; - } - - // -XX:-InlineNatives disables nearly all intrinsics except the ones listed in - // the following switch statement. - if (!InlineNatives) { - switch (id) { - case vmIntrinsics::_indexOf: - case vmIntrinsics::_compareTo: - case vmIntrinsics::_equals: - case vmIntrinsics::_equalsC: - case vmIntrinsics::_getAndAddInt: - case vmIntrinsics::_getAndAddLong: - case vmIntrinsics::_getAndSetInt: - case vmIntrinsics::_getAndSetLong: - case vmIntrinsics::_getAndSetObject: - case vmIntrinsics::_loadFence: - case vmIntrinsics::_storeFence: - case vmIntrinsics::_fullFence: - case vmIntrinsics::_Reference_get: - break; - default: - return true; - } - } - - if (!InlineUnsafeOps) { - switch (id) { - case vmIntrinsics::_loadFence: - case vmIntrinsics::_storeFence: - case vmIntrinsics::_fullFence: - case vmIntrinsics::_compareAndSwapObject: - case vmIntrinsics::_compareAndSwapLong: - case vmIntrinsics::_compareAndSwapInt: - return true; - default: - return false; - } - } - - return false; -} - int C2Compiler::initial_code_buffer_size() { assert(SegmentedCodeCache, "Should be only used with a segmented code cache"); return Compile::MAX_inst_size + Compile::MAX_locs_size + initial_const_capacity; diff --git a/hotspot/src/share/vm/opto/c2compiler.hpp b/hotspot/src/share/vm/opto/c2compiler.hpp index d651b1de0e5..f8308190444 100644 --- a/hotspot/src/share/vm/opto/c2compiler.hpp +++ b/hotspot/src/share/vm/opto/c2compiler.hpp @@ -51,11 +51,11 @@ public: // Print compilation timers and statistics void print_timers(); - // Check the availability of an intrinsic for 'method' given a compilation context. - virtual bool is_intrinsic_available(methodHandle method, methodHandle compilation_context); - // Return true if the intrinsification of a method supported by the compiler - // assuming a non-virtual dispatch. Return false otherwise. + // assuming a non-virtual dispatch. (A virtual dispatch is + // possible for only a limited set of available intrinsics whereas + // a non-virtual dispatch is possible for all available intrinsics.) + // Return false otherwise. virtual bool is_intrinsic_supported(methodHandle method) { return is_intrinsic_supported(method, false); } @@ -64,13 +64,6 @@ public: // the dispatch mode specified by the 'is_virtual' parameter. virtual bool is_intrinsic_supported(methodHandle method, bool is_virtual); - // Processing of command-line flags specific to the C2 compiler. - virtual bool is_intrinsic_disabled_by_flag(methodHandle method) { - return is_intrinsic_disabled_by_flag(method, NULL); - } - - virtual bool is_intrinsic_disabled_by_flag(methodHandle method, methodHandle compilation_context); - // Initial size of the code buffer (may be increased at runtime) static int initial_code_buffer_size(); }; diff --git a/hotspot/src/share/vm/opto/callnode.cpp b/hotspot/src/share/vm/opto/callnode.cpp index b0b73830313..3e44fec0a6c 100644 --- a/hotspot/src/share/vm/opto/callnode.cpp +++ b/hotspot/src/share/vm/opto/callnode.cpp @@ -52,6 +52,7 @@ const Type *StartNode::bottom_type() const { return _domain; } const Type *StartNode::Value(PhaseTransform *phase) const { return _domain; } #ifndef PRODUCT void StartNode::dump_spec(outputStream *st) const { st->print(" #"); _domain->dump_on(st);} +void StartNode::dump_compact_spec(outputStream *st) const { /* empty */ } #endif //------------------------------Ideal------------------------------------------ @@ -121,6 +122,23 @@ void ParmNode::dump_spec(outputStream *st) const { if( !Verbose && !WizardMode ) bottom_type()->dump_on(st); } } + +void ParmNode::dump_compact_spec(outputStream *st) const { + if (_con < TypeFunc::Parms) { + st->print("%s", names[_con]); + } else { + st->print("%d:", _con-TypeFunc::Parms); + // unconditionally dump bottom_type + bottom_type()->dump_on(st); + } +} + +// For a ParmNode, all immediate inputs and outputs are considered relevant +// both in compact and standard representation. +void ParmNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + this->collect_nodes(in_rel, 1, false, false); + this->collect_nodes(out_rel, -1, false, false); +} #endif uint ParmNode::ideal_reg() const { @@ -948,6 +966,14 @@ void CallJavaNode::dump_spec(outputStream *st) const { if( _method ) _method->print_short_name(st); CallNode::dump_spec(st); } + +void CallJavaNode::dump_compact_spec(outputStream* st) const { + if (_method) { + _method->print_short_name(st); + } else { + st->print(""); + } +} #endif //============================================================================= @@ -995,6 +1021,16 @@ void CallStaticJavaNode::dump_spec(outputStream *st) const { } CallJavaNode::dump_spec(st); } + +void CallStaticJavaNode::dump_compact_spec(outputStream* st) const { + if (_method) { + _method->print_short_name(st); + } else if (_name) { + st->print("%s", _name); + } else { + st->print(""); + } +} #endif //============================================================================= @@ -1130,6 +1166,19 @@ void SafePointNode::dump_spec(outputStream *st) const { st->print(" SafePoint "); _replaced_nodes.dump(st); } + +// The related nodes of a SafepointNode are all data inputs, excluding the +// control boundary, as well as all outputs till level 2 (to include projection +// nodes and targets). In compact mode, just include inputs till level 1 and +// outputs as before. +void SafePointNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + if (compact) { + this->collect_nodes(in_rel, 1, false, false); + } else { + this->collect_nodes_in_all_data(in_rel, false); + } + this->collect_nodes(out_rel, -2, false, false); +} #endif const RegMask &SafePointNode::in_RegMask(uint idx) const { @@ -1676,6 +1725,27 @@ void AbstractLockNode::set_eliminated_lock_counter() { _counter->set_tag(NamedCounter::EliminatedLockCounter); } } + +const char* AbstractLockNode::_kind_names[] = {"Regular", "NonEscObj", "Coarsened", "Nested"}; + +void AbstractLockNode::dump_spec(outputStream* st) const { + st->print("%s ", _kind_names[_kind]); + CallNode::dump_spec(st); +} + +void AbstractLockNode::dump_compact_spec(outputStream* st) const { + st->print("%s", _kind_names[_kind]); +} + +// The related set of lock nodes includes the control boundary. +void AbstractLockNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + if (compact) { + this->collect_nodes(in_rel, 1, false, false); + } else { + this->collect_nodes_in_all_data(in_rel, true); + } + this->collect_nodes(out_rel, -2, false, false); +} #endif //============================================================================= diff --git a/hotspot/src/share/vm/opto/callnode.hpp b/hotspot/src/share/vm/opto/callnode.hpp index 990962188e5..2c788e52a11 100644 --- a/hotspot/src/share/vm/opto/callnode.hpp +++ b/hotspot/src/share/vm/opto/callnode.hpp @@ -84,6 +84,7 @@ public: virtual uint ideal_reg() const { return 0; } #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void dump_compact_spec(outputStream *st) const; #endif }; @@ -110,6 +111,8 @@ public: virtual uint ideal_reg() const; #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void dump_compact_spec(outputStream *st) const; + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; #endif }; @@ -476,6 +479,7 @@ public: #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; #endif }; @@ -675,6 +679,7 @@ public: #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void dump_compact_spec(outputStream *st) const; #endif }; @@ -730,6 +735,7 @@ public: virtual int Opcode() const; #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void dump_compact_spec(outputStream *st) const; #endif }; @@ -951,6 +957,7 @@ private: } _kind; #ifndef PRODUCT NamedCounter* _counter; + static const char* _kind_names[Nested+1]; #endif protected: @@ -1005,6 +1012,9 @@ public: #ifndef PRODUCT void create_lock_counter(JVMState* s); NamedCounter* counter() const { return _counter; } + virtual void dump_spec(outputStream* st) const; + virtual void dump_compact_spec(outputStream* st) const; + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; #endif }; diff --git a/hotspot/src/share/vm/opto/cfgnode.cpp b/hotspot/src/share/vm/opto/cfgnode.cpp index fcb3fcd2c20..9014eb6df4a 100644 --- a/hotspot/src/share/vm/opto/cfgnode.cpp +++ b/hotspot/src/share/vm/opto/cfgnode.cpp @@ -2023,6 +2023,14 @@ const RegMask &PhiNode::out_RegMask() const { } #ifndef PRODUCT +void PhiNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + // For a PhiNode, the set of related nodes includes all inputs till level 2, + // and all outputs till level 1. In compact mode, inputs till level 1 are + // collected. + this->collect_nodes(in_rel, compact ? 1 : 2, false, false); + this->collect_nodes(out_rel, -1, false, false); +} + void PhiNode::dump_spec(outputStream *st) const { TypeNode::dump_spec(st); if (is_tripcount()) { @@ -2047,11 +2055,33 @@ const RegMask &GotoNode::out_RegMask() const { return RegMask::Empty; } +#ifndef PRODUCT +//-----------------------------related----------------------------------------- +// The related nodes of a GotoNode are all inputs at level 1, as well as the +// outputs at level 1. This is regardless of compact mode. +void GotoNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + this->collect_nodes(in_rel, 1, false, false); + this->collect_nodes(out_rel, -1, false, false); +} +#endif + + //============================================================================= const RegMask &JumpNode::out_RegMask() const { return RegMask::Empty; } +#ifndef PRODUCT +//-----------------------------related----------------------------------------- +// The related nodes of a JumpNode are all inputs at level 1, as well as the +// outputs at level 2 (to include actual jump targets beyond projection nodes). +// This is regardless of compact mode. +void JumpNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + this->collect_nodes(in_rel, 1, false, false); + this->collect_nodes(out_rel, -2, false, false); +} +#endif + //============================================================================= const RegMask &JProjNode::out_RegMask() const { return RegMask::Empty; @@ -2105,7 +2135,18 @@ uint JumpProjNode::cmp( const Node &n ) const { #ifndef PRODUCT void JumpProjNode::dump_spec(outputStream *st) const { ProjNode::dump_spec(st); - st->print("@bci %d ",_dest_bci); + st->print("@bci %d ",_dest_bci); +} + +void JumpProjNode::dump_compact_spec(outputStream *st) const { + ProjNode::dump_compact_spec(st); + st->print("(%d)%d@%d", _switch_val, _proj_no, _dest_bci); +} + +void JumpProjNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + // The related nodes of a JumpProjNode are its inputs and outputs at level 1. + this->collect_nodes(in_rel, 1, false, false); + this->collect_nodes(out_rel, -1, false, false); } #endif diff --git a/hotspot/src/share/vm/opto/cfgnode.hpp b/hotspot/src/share/vm/opto/cfgnode.hpp index 7d851b564e0..33a378e5be5 100644 --- a/hotspot/src/share/vm/opto/cfgnode.hpp +++ b/hotspot/src/share/vm/opto/cfgnode.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, 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 @@ -204,6 +204,7 @@ public: virtual const RegMask &out_RegMask() const; virtual const RegMask &in_RegMask(uint) const; #ifndef PRODUCT + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; virtual void dump_spec(outputStream *st) const; #endif #ifdef ASSERT @@ -229,6 +230,10 @@ public: virtual const Type *Value( PhaseTransform *phase ) const; virtual Node *Identity( PhaseTransform *phase ); virtual const RegMask &out_RegMask() const; + +#ifndef PRODUCT + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; +#endif }; //------------------------------CProjNode-------------------------------------- @@ -382,6 +387,7 @@ public: #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; #endif }; @@ -393,6 +399,11 @@ public: protected: // Type of If input when this branch is always taken virtual bool always_taken(const TypeTuple* t) const = 0; + +#ifndef PRODUCT +public: + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; +#endif }; class IfTrueNode : public IfProjNode { @@ -455,6 +466,9 @@ public: virtual int Opcode() const; virtual const RegMask& out_RegMask() const; virtual const Node* is_block_proj() const { return this; } +#ifndef PRODUCT + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; +#endif }; class JumpProjNode : public JProjNode { @@ -479,6 +493,8 @@ class JumpProjNode : public JProjNode { uint proj_no() const { return _proj_no; } #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void dump_compact_spec(outputStream *st) const; + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; #endif }; diff --git a/hotspot/src/share/vm/opto/compile.cpp b/hotspot/src/share/vm/opto/compile.cpp index 5025d8360a6..3cf18d16ceb 100644 --- a/hotspot/src/share/vm/opto/compile.cpp +++ b/hotspot/src/share/vm/opto/compile.cpp @@ -594,6 +594,10 @@ uint Compile::scratch_emit_size(const Node* n) { n->as_MachBranch()->label_set(&fakeL, 0); } n->emit(buf, this->regalloc()); + + // Emitting into the scratch buffer should not fail + assert (!failing(), err_msg_res("Must not have pending failure. Reason is: %s", failure_reason())); + if (is_branch) // Restore label. n->as_MachBranch()->label_set(saveL, save_bnum); diff --git a/hotspot/src/share/vm/opto/ifnode.cpp b/hotspot/src/share/vm/opto/ifnode.cpp index bc107f4b7d5..cd60f19cd67 100644 --- a/hotspot/src/share/vm/opto/ifnode.cpp +++ b/hotspot/src/share/vm/opto/ifnode.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2000, 2015, 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 @@ -1601,11 +1601,41 @@ Node *IfProjNode::Identity(PhaseTransform *phase) { return this; } -//------------------------------dump_spec-------------------------------------- #ifndef PRODUCT +//-------------------------------related--------------------------------------- +// An IfProjNode's related node set consists of its input (an IfNode) including +// the IfNode's condition, plus all of its outputs at level 1. In compact mode, +// the restrictions for IfNode apply (see IfNode::rel). +void IfProjNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + Node* ifNode = this->in(0); + in_rel->append(ifNode); + if (compact) { + ifNode->collect_nodes(in_rel, 3, false, true); + } else { + ifNode->collect_nodes_in_all_data(in_rel, false); + } + this->collect_nodes(out_rel, -1, false, false); +} + +//------------------------------dump_spec-------------------------------------- void IfNode::dump_spec(outputStream *st) const { st->print("P=%f, C=%f",_prob,_fcnt); } + +//-------------------------------related--------------------------------------- +// For an IfNode, the set of related output nodes is just the output nodes till +// depth 2, i.e, the IfTrue/IfFalse projection nodes plus the nodes they refer. +// The related input nodes contain no control nodes, but all data nodes +// pertaining to the condition. In compact mode, the input nodes are collected +// up to a depth of 3. +void IfNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + if (compact) { + this->collect_nodes(in_rel, 3, false, true); + } else { + this->collect_nodes_in_all_data(in_rel, false); + } + this->collect_nodes(out_rel, -2, false, false); +} #endif //------------------------------idealize_test---------------------------------- diff --git a/hotspot/src/share/vm/opto/library_call.cpp b/hotspot/src/share/vm/opto/library_call.cpp index 23b993edcbd..417135b7c54 100644 --- a/hotspot/src/share/vm/opto/library_call.cpp +++ b/hotspot/src/share/vm/opto/library_call.cpp @@ -327,7 +327,7 @@ CallGenerator* Compile::make_vm_intrinsic(ciMethod* m, bool is_virtual) { methodHandle mh(THREAD, m->get_Method()); methodHandle ct(THREAD, method()->get_Method()); is_available = compiler->is_intrinsic_supported(mh, is_virtual) && - !compiler->is_intrinsic_disabled_by_flag(mh, ct); + !vmIntrinsics::is_disabled_by_flags(mh, ct); } if (is_available) { diff --git a/hotspot/src/share/vm/opto/movenode.cpp b/hotspot/src/share/vm/opto/movenode.cpp index 234cdebf031..8fe9b0233be 100644 --- a/hotspot/src/share/vm/opto/movenode.cpp +++ b/hotspot/src/share/vm/opto/movenode.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -396,3 +396,17 @@ const Type *MoveD2LNode::Value( PhaseTransform *phase ) const { return TypeLong::make( v.get_jlong() ); } +#ifndef PRODUCT +//----------------------------BinaryNode--------------------------------------- +// The set of related nodes for a BinaryNode is all data inputs and all outputs +// till level 2 (i.e., one beyond the associated CMoveNode). In compact mode, +// it's the inputs till level 1 and the outputs till level 2. +void BinaryNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + if (compact) { + this->collect_nodes(in_rel, 1, false, true); + } else { + this->collect_nodes_in_all_data(in_rel, false); + } + this->collect_nodes(out_rel, -2, false, false); +} +#endif diff --git a/hotspot/src/share/vm/opto/movenode.hpp b/hotspot/src/share/vm/opto/movenode.hpp index bb99f7ba083..4cd94185063 100644 --- a/hotspot/src/share/vm/opto/movenode.hpp +++ b/hotspot/src/share/vm/opto/movenode.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -145,6 +145,10 @@ class BinaryNode : public Node { BinaryNode( Node *n1, Node *n2 ) : Node(0,n1,n2) { } virtual int Opcode() const; virtual uint ideal_reg() const { return 0; } + +#ifndef PRODUCT + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; +#endif }; diff --git a/hotspot/src/share/vm/opto/multnode.cpp b/hotspot/src/share/vm/opto/multnode.cpp index 00ff009660c..3648fef790e 100644 --- a/hotspot/src/share/vm/opto/multnode.cpp +++ b/hotspot/src/share/vm/opto/multnode.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, 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 @@ -118,6 +118,20 @@ const TypePtr *ProjNode::adr_type() const { bool ProjNode::pinned() const { return in(0)->pinned(); } #ifndef PRODUCT void ProjNode::dump_spec(outputStream *st) const { st->print("#%d",_con); if(_is_io_use) st->print(" (i_o_use)");} + +void ProjNode::dump_compact_spec(outputStream *st) const { + for (DUIterator i = this->outs(); this->has_out(i); i++) { + Node* o = this->out(i); + if (NotANode(o)) { + st->print("[?]"); + } else if (o == NULL) { + st->print("[_]"); + } else { + st->print("[%d]", o->_idx); + } + } + st->print("#%d", _con); +} #endif //----------------------------check_con---------------------------------------- diff --git a/hotspot/src/share/vm/opto/multnode.hpp b/hotspot/src/share/vm/opto/multnode.hpp index 02558db1679..25f8c503436 100644 --- a/hotspot/src/share/vm/opto/multnode.hpp +++ b/hotspot/src/share/vm/opto/multnode.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, 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 @@ -87,6 +87,7 @@ public: #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void dump_compact_spec(outputStream *st) const; #endif // Return uncommon trap call node if proj is for "proj->[region->..]call_uct" diff --git a/hotspot/src/share/vm/opto/node.cpp b/hotspot/src/share/vm/opto/node.cpp index 5b2aa145d81..a331ac637cf 100644 --- a/hotspot/src/share/vm/opto/node.cpp +++ b/hotspot/src/share/vm/opto/node.cpp @@ -1489,16 +1489,6 @@ jfloat Node::getf() const { #ifndef PRODUCT -//----------------------------NotANode---------------------------------------- -// Used in debugging code to avoid walking across dead or uninitialized edges. -static inline bool NotANode(const Node* n) { - if (n == NULL) return true; - if (((intptr_t)n & 1) != 0) return true; // uninitialized, etc. - if (*(address*)n == badAddress) return true; // kill by Node::destruct - return false; -} - - //------------------------------find------------------------------------------ // Find a neighbor of this Node with the given _idx // If idx is negative, find its absolute value, following both _in and _out. @@ -1636,11 +1626,11 @@ void Node::set_debug_orig(Node* orig) { //------------------------------dump------------------------------------------ // Dump a Node -void Node::dump(const char* suffix, outputStream *st) const { +void Node::dump(const char* suffix, bool mark, outputStream *st) const { Compile* C = Compile::current(); bool is_new = C->node_arena()->contains(this); C->_in_dump_cnt++; - st->print("%c%d\t%s\t=== ", is_new ? ' ' : 'o', _idx, Name()); + st->print("%c%d%s\t%s\t=== ", is_new ? ' ' : 'o', _idx, mark ? " >" : "", Name()); // Dump the required and precedence inputs dump_req(st); @@ -1760,42 +1750,60 @@ void Node::dump_out(outputStream *st) const { st->print("]] "); } -//------------------------------dump_nodes------------------------------------- -static void dump_nodes(const Node* start, int d, bool only_ctrl) { - Node* s = (Node*)start; // remove const - if (NotANode(s)) return; - - uint depth = (uint)ABS(d); - int direction = d; - Compile* C = Compile::current(); - GrowableArray nstack(C->unique()); - - nstack.append(s); +//----------------------------collect_nodes_i---------------------------------- +// Collects nodes from an Ideal graph, starting from a given start node and +// moving in a given direction until a certain depth (distance from the start +// node) is reached. Duplicates are ignored. +// Arguments: +// nstack: the nodes are collected into this array. +// start: the node at which to start collecting. +// direction: if this is a positive number, collect input nodes; if it is +// a negative number, collect output nodes. +// depth: collect nodes up to this distance from the start node. +// include_start: whether to include the start node in the result collection. +// only_ctrl: whether to regard control edges only during traversal. +// only_data: whether to regard data edges only during traversal. +static void collect_nodes_i(GrowableArray *nstack, const Node* start, int direction, uint depth, bool include_start, bool only_ctrl, bool only_data) { + Node* s = (Node*) start; // remove const + nstack->append(s); int begin = 0; int end = 0; for(uint i = 0; i < depth; i++) { - end = nstack.length(); + end = nstack->length(); for(int j = begin; j < end; j++) { - Node* tp = nstack.at(j); + Node* tp = nstack->at(j); uint limit = direction > 0 ? tp->len() : tp->outcnt(); for(uint k = 0; k < limit; k++) { Node* n = direction > 0 ? tp->in(k) : tp->raw_out(k); if (NotANode(n)) continue; // do not recurse through top or the root (would reach unrelated stuff) - if (n->is_Root() || n->is_top()) continue; + if (n->is_Root() || n->is_top()) continue; if (only_ctrl && !n->is_CFG()) continue; + if (only_data && n->is_CFG()) continue; - bool on_stack = nstack.contains(n); + bool on_stack = nstack->contains(n); if (!on_stack) { - nstack.append(n); + nstack->append(n); } } } begin = end; } - end = nstack.length(); - if (direction > 0) { + if (!include_start) { + nstack->remove(s); + } +} + +//------------------------------dump_nodes------------------------------------- +static void dump_nodes(const Node* start, int d, bool only_ctrl) { + if (NotANode(start)) return; + + GrowableArray nstack(Compile::current()->unique()); + collect_nodes_i(&nstack, start, d, (uint) ABS(d), true, only_ctrl, false); + + int end = nstack.length(); + if (d > 0) { for(int j = end-1; j >= 0; j--) { nstack.at(j)->dump(); } @@ -1817,6 +1825,221 @@ void Node::dump_ctrl(int d) const { dump_nodes(this, d, true); } +//-----------------------------dump_compact------------------------------------ +void Node::dump_comp() const { + this->dump_comp("\n"); +} + +//-----------------------------dump_compact------------------------------------ +// Dump a Node in compact representation, i.e., just print its name and index. +// Nodes can specify additional specifics to print in compact representation by +// implementing dump_compact_spec. +void Node::dump_comp(const char* suffix, outputStream *st) const { + Compile* C = Compile::current(); + C->_in_dump_cnt++; + st->print("%s(%d)", Name(), _idx); + this->dump_compact_spec(st); + if (suffix) { + st->print("%s", suffix); + } + C->_in_dump_cnt--; +} + +//----------------------------dump_related------------------------------------- +// Dump a Node's related nodes - the notion of "related" depends on the Node at +// hand and is determined by the implementation of the virtual method rel. +void Node::dump_related() const { + Compile* C = Compile::current(); + GrowableArray in_rel(C->unique()); + GrowableArray out_rel(C->unique()); + this->related(&in_rel, &out_rel, false); + for (int i = in_rel.length() - 1; i >= 0; i--) { + in_rel.at(i)->dump(); + } + this->dump("\n", true); + for (int i = 0; i < out_rel.length(); i++) { + out_rel.at(i)->dump(); + } +} + +//----------------------------dump_related------------------------------------- +// Dump a Node's related nodes up to a given depth (distance from the start +// node). +// Arguments: +// d_in: depth for input nodes. +// d_out: depth for output nodes (note: this also is a positive number). +void Node::dump_related(uint d_in, uint d_out) const { + Compile* C = Compile::current(); + GrowableArray in_rel(C->unique()); + GrowableArray out_rel(C->unique()); + + // call collect_nodes_i directly + collect_nodes_i(&in_rel, this, 1, d_in, false, false, false); + collect_nodes_i(&out_rel, this, -1, d_out, false, false, false); + + for (int i = in_rel.length() - 1; i >= 0; i--) { + in_rel.at(i)->dump(); + } + this->dump("\n", true); + for (int i = 0; i < out_rel.length(); i++) { + out_rel.at(i)->dump(); + } +} + +//------------------------dump_related_compact--------------------------------- +// Dump a Node's related nodes in compact representation. The notion of +// "related" depends on the Node at hand and is determined by the implementation +// of the virtual method rel. +void Node::dump_related_compact() const { + Compile* C = Compile::current(); + GrowableArray in_rel(C->unique()); + GrowableArray out_rel(C->unique()); + this->related(&in_rel, &out_rel, true); + int n_in = in_rel.length(); + int n_out = out_rel.length(); + + this->dump_comp(n_in == 0 ? "\n" : " "); + for (int i = 0; i < n_in; i++) { + in_rel.at(i)->dump_comp(i == n_in - 1 ? "\n" : " "); + } + for (int i = 0; i < n_out; i++) { + out_rel.at(i)->dump_comp(i == n_out - 1 ? "\n" : " "); + } +} + +//------------------------------related---------------------------------------- +// Collect a Node's related nodes. The default behaviour just collects the +// inputs and outputs at depth 1, including both control and data flow edges, +// regardless of whether the presentation is compact or not. For data nodes, +// the default is to collect all data inputs (till level 1 if compact), and +// outputs till level 1. +void Node::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + if (this->is_CFG()) { + collect_nodes_i(in_rel, this, 1, 1, false, false, false); + collect_nodes_i(out_rel, this, -1, 1, false, false, false); + } else { + if (compact) { + this->collect_nodes(in_rel, 1, false, true); + } else { + this->collect_nodes_in_all_data(in_rel, false); + } + this->collect_nodes(out_rel, -1, false, false); + } +} + +//---------------------------collect_nodes------------------------------------- +// An entry point to the low-level node collection facility, to start from a +// given node in the graph. The start node is by default not included in the +// result. +// Arguments: +// ns: collect the nodes into this data structure. +// d: the depth (distance from start node) to which nodes should be +// collected. A value >0 indicates input nodes, a value <0, output +// nodes. +// ctrl: include only control nodes. +// data: include only data nodes. +void Node::collect_nodes(GrowableArray *ns, int d, bool ctrl, bool data) const { + if (ctrl && data) { + // ignore nonsensical combination + return; + } + collect_nodes_i(ns, this, d, (uint) ABS(d), false, ctrl, data); +} + +//--------------------------collect_nodes_in----------------------------------- +static void collect_nodes_in(Node* start, GrowableArray *ns, bool primary_is_data, bool collect_secondary) { + // The maximum depth is determined using a BFS that visits all primary (data + // or control) inputs and increments the depth at each level. + uint d_in = 0; + GrowableArray nodes(Compile::current()->unique()); + nodes.push(start); + int nodes_at_current_level = 1; + int n_idx = 0; + while (nodes_at_current_level > 0) { + // Add all primary inputs reachable from the current level to the list, and + // increase the depth if there were any. + int nodes_at_next_level = 0; + bool nodes_added = false; + while (nodes_at_current_level > 0) { + nodes_at_current_level--; + Node* current = nodes.at(n_idx++); + for (uint i = 0; i < current->len(); i++) { + Node* n = current->in(i); + if (NotANode(n)) { + continue; + } + if ((primary_is_data && n->is_CFG()) || (!primary_is_data && !n->is_CFG())) { + continue; + } + if (!nodes.contains(n)) { + nodes.push(n); + nodes_added = true; + nodes_at_next_level++; + } + } + } + if (nodes_added) { + d_in++; + } + nodes_at_current_level = nodes_at_next_level; + } + start->collect_nodes(ns, d_in, !primary_is_data, primary_is_data); + if (collect_secondary) { + // Now, iterate over the secondary nodes in ns and add the respective + // boundary reachable from them. + GrowableArray sns(Compile::current()->unique()); + for (GrowableArrayIterator it = ns->begin(); it != ns->end(); ++it) { + Node* n = *it; + n->collect_nodes(&sns, 1, primary_is_data, !primary_is_data); + for (GrowableArrayIterator d = sns.begin(); d != sns.end(); ++d) { + ns->append_if_missing(*d); + } + sns.clear(); + } + } +} + +//---------------------collect_nodes_in_all_data------------------------------- +// Collect the entire data input graph. Include the control boundary if +// requested. +// Arguments: +// ns: collect the nodes into this data structure. +// ctrl: if true, include the control boundary. +void Node::collect_nodes_in_all_data(GrowableArray *ns, bool ctrl) const { + collect_nodes_in((Node*) this, ns, true, ctrl); +} + +//--------------------------collect_nodes_in_all_ctrl-------------------------- +// Collect the entire control input graph. Include the data boundary if +// requested. +// ns: collect the nodes into this data structure. +// data: if true, include the control boundary. +void Node::collect_nodes_in_all_ctrl(GrowableArray *ns, bool data) const { + collect_nodes_in((Node*) this, ns, false, data); +} + +//------------------collect_nodes_out_all_ctrl_boundary------------------------ +// Collect the entire output graph until hitting control node boundaries, and +// include those. +void Node::collect_nodes_out_all_ctrl_boundary(GrowableArray *ns) const { + // Perform a BFS and stop at control nodes. + GrowableArray nodes(Compile::current()->unique()); + nodes.push((Node*) this); + while (nodes.length() > 0) { + Node* current = nodes.pop(); + if (NotANode(current)) { + continue; + } + ns->append_if_missing(current); + if (!current->is_CFG()) { + for (DUIterator i = current->outs(); current->has_out(i); i++) { + nodes.push(current->out(i)); + } + } + } + ns->remove((Node*) this); +} + // VERIFICATION CODE // For each input edge to a node (ie - for each Use-Def edge), verify that // there is a corresponding Def-Use edge. @@ -2173,6 +2396,11 @@ void TypeNode::dump_spec(outputStream *st) const { st->print(" #"); _type->dump_on(st); } } + +void TypeNode::dump_compact_spec(outputStream *st) const { + st->print("#"); + _type->dump_on(st); +} #endif uint TypeNode::hash() const { return Node::hash() + _type->hash(); diff --git a/hotspot/src/share/vm/opto/node.hpp b/hotspot/src/share/vm/opto/node.hpp index 2dfedbc085a..97c844891d0 100644 --- a/hotspot/src/share/vm/opto/node.hpp +++ b/hotspot/src/share/vm/opto/node.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, 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 @@ -1038,13 +1038,35 @@ public: Node* find(int idx) const; // Search the graph for the given idx. Node* find_ctrl(int idx) const; // Search control ancestors for the given idx. void dump() const { dump("\n"); } // Print this node. - void dump(const char* suffix, outputStream *st = tty) const;// Print this node. + void dump(const char* suffix, bool mark = false, outputStream *st = tty) const; // Print this node. void dump(int depth) const; // Print this node, recursively to depth d void dump_ctrl(int depth) const; // Print control nodes, to depth d - virtual void dump_req(outputStream *st = tty) const; // Print required-edge info - virtual void dump_prec(outputStream *st = tty) const; // Print precedence-edge info - virtual void dump_out(outputStream *st = tty) const; // Print the output edge info - virtual void dump_spec(outputStream *st) const {}; // Print per-node info + void dump_comp() const; // Print this node in compact representation. + // Print this node in compact representation. + void dump_comp(const char* suffix, outputStream *st = tty) const; + virtual void dump_req(outputStream *st = tty) const; // Print required-edge info + virtual void dump_prec(outputStream *st = tty) const; // Print precedence-edge info + virtual void dump_out(outputStream *st = tty) const; // Print the output edge info + virtual void dump_spec(outputStream *st) const {}; // Print per-node info + // Print compact per-node info + virtual void dump_compact_spec(outputStream *st) const { dump_spec(st); } + void dump_related() const; // Print related nodes (depends on node at hand). + // Print related nodes up to given depths for input and output nodes. + void dump_related(uint d_in, uint d_out) const; + void dump_related_compact() const; // Print related nodes in compact representation. + // Collect related nodes. + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; + // Collect nodes starting from this node, explicitly including/excluding control and data links. + void collect_nodes(GrowableArray *ns, int d, bool ctrl, bool data) const; + + // Node collectors, to be used in implementations of Node::rel(). + // Collect the entire data input graph. Include control inputs if requested. + void collect_nodes_in_all_data(GrowableArray *ns, bool ctrl) const; + // Collect the entire control input graph. Include data inputs if requested. + void collect_nodes_in_all_ctrl(GrowableArray *ns, bool data) const; + // Collect the entire output graph until hitting and including control nodes. + void collect_nodes_out_all_ctrl_boundary(GrowableArray *ns) const; + void verify_edges(Unique_Node_List &visited); // Verify bi-directional edges void verify() const; // Check Def-Use info for my subgraph static void verify_recur(const Node *n, int verify_depth, VectorSet &old_space, VectorSet &new_space); @@ -1091,6 +1113,20 @@ public: #endif }; + +#ifndef PRODUCT + +// Used in debugging code to avoid walking across dead or uninitialized edges. +inline bool NotANode(const Node* n) { + if (n == NULL) return true; + if (((intptr_t)n & 1) != 0) return true; // uninitialized, etc. + if (*(address*)n == badAddress) return true; // kill by Node::destruct + return false; +} + +#endif + + //----------------------------------------------------------------------------- // Iterators over DU info, and associated Node functions. @@ -1618,6 +1654,7 @@ public: virtual uint ideal_reg() const; #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void dump_compact_spec(outputStream *st) const; #endif }; diff --git a/hotspot/src/share/vm/opto/output.cpp b/hotspot/src/share/vm/opto/output.cpp index 4c9ccaa43a1..7423155de04 100644 --- a/hotspot/src/share/vm/opto/output.cpp +++ b/hotspot/src/share/vm/opto/output.cpp @@ -1504,6 +1504,13 @@ void Compile::fill_buffer(CodeBuffer* cb, uint* blk_starts) { n->emit(*cb, _regalloc); current_offset = cb->insts_size(); + // Above we only verified that there is enough space in the instruction section. + // However, the instruction may emit stubs that cause code buffer expansion. + // Bail out here if expansion failed due to a lack of code cache space. + if (failing()) { + return; + } + #ifdef ASSERT if (n->size(_regalloc) < (current_offset-instr_offset)) { n->dump(); @@ -1632,11 +1639,14 @@ void Compile::fill_buffer(CodeBuffer* cb, uint* blk_starts) { if (_method) { // Emit the exception handler code. _code_offsets.set_value(CodeOffsets::Exceptions, HandlerImpl::emit_exception_handler(*cb)); + if (failing()) { + return; // CodeBuffer::expand failed + } // Emit the deopt handler code. _code_offsets.set_value(CodeOffsets::Deopt, HandlerImpl::emit_deopt_handler(*cb)); // Emit the MethodHandle deopt handler code (if required). - if (has_method_handle_invokes()) { + if (has_method_handle_invokes() && !failing()) { // We can use the same code as for the normal deopt handler, we // just need a different entry point address. _code_offsets.set_value(CodeOffsets::DeoptMH, HandlerImpl::emit_deopt_handler(*cb)); diff --git a/hotspot/src/share/vm/opto/rootnode.cpp b/hotspot/src/share/vm/opto/rootnode.cpp index 4cf51528df5..e5542f6ff74 100644 --- a/hotspot/src/share/vm/opto/rootnode.cpp +++ b/hotspot/src/share/vm/opto/rootnode.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, 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 @@ -88,3 +88,18 @@ const Type *HaltNode::Value( PhaseTransform *phase ) const { const RegMask &HaltNode::out_RegMask() const { return RegMask::Empty; } + +#ifndef PRODUCT +//-----------------------------related----------------------------------------- +// Include all control inputs in the related set, and also the input data +// boundary. In compact mode, include all inputs till level 2. Also include +// all outputs at level 1. +void HaltNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + if (compact) { + this->collect_nodes(in_rel, 2, false, false); + } else { + this->collect_nodes_in_all_ctrl(in_rel, true); + } + this->collect_nodes(out_rel, -1, false, false); +} +#endif diff --git a/hotspot/src/share/vm/opto/rootnode.hpp b/hotspot/src/share/vm/opto/rootnode.hpp index cef207d649e..3be5dfa7673 100644 --- a/hotspot/src/share/vm/opto/rootnode.hpp +++ b/hotspot/src/share/vm/opto/rootnode.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, 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 @@ -64,6 +64,10 @@ public: virtual const RegMask &out_RegMask() const; virtual uint ideal_reg() const { return NotAMachineReg; } virtual uint match_edge(uint idx) const { return 0; } + +#ifndef PRODUCT + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; +#endif }; #endif // SHARE_VM_OPTO_ROOTNODE_HPP diff --git a/hotspot/src/share/vm/opto/subnode.cpp b/hotspot/src/share/vm/opto/subnode.cpp index 27cf544da11..a41538d75d5 100644 --- a/hotspot/src/share/vm/opto/subnode.cpp +++ b/hotspot/src/share/vm/opto/subnode.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, 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 @@ -498,6 +498,37 @@ Node *CmpNode::Identity( PhaseTransform *phase ) { return this; } +#ifndef PRODUCT +//----------------------------related------------------------------------------ +// Related nodes of comparison nodes include all data inputs (until hitting a +// control boundary) as well as all outputs until and including control nodes +// as well as their projections. In compact mode, data inputs till depth 1 and +// all outputs till depth 1 are considered. +void CmpNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + if (compact) { + this->collect_nodes(in_rel, 1, false, true); + this->collect_nodes(out_rel, -1, false, false); + } else { + this->collect_nodes_in_all_data(in_rel, false); + this->collect_nodes_out_all_ctrl_boundary(out_rel); + // Now, find all control nodes in out_rel, and include their projections + // and projection targets (if any) in the result. + GrowableArray proj(Compile::current()->unique()); + for (GrowableArrayIterator it = out_rel->begin(); it != out_rel->end(); ++it) { + Node* n = *it; + if (n->is_CFG() && !n->is_Proj()) { + // Assume projections and projection targets are found at levels 1 and 2. + n->collect_nodes(&proj, -2, false, false); + for (GrowableArrayIterator p = proj.begin(); p != proj.end(); ++p) { + out_rel->append_if_missing(*p); + } + proj.clear(); + } + } + } +} +#endif + //============================================================================= //------------------------------cmp-------------------------------------------- // Simplify a CmpI (compare 2 integers) node, based on local information. @@ -1396,17 +1427,31 @@ const Type *BoolNode::Value( PhaseTransform *phase ) const { return _test.cc2logical( phase->type( in(1) ) ); } +#ifndef PRODUCT //------------------------------dump_spec-------------------------------------- // Dump special per-node info -#ifndef PRODUCT void BoolNode::dump_spec(outputStream *st) const { st->print("["); _test.dump_on(st); st->print("]"); } + +//-------------------------------related--------------------------------------- +// A BoolNode's related nodes are all of its data inputs, and all of its +// outputs until control nodes are hit, which are included. In compact +// representation, inputs till level 3 and immediate outputs are included. +void BoolNode::related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const { + if (compact) { + this->collect_nodes(in_rel, 3, false, true); + this->collect_nodes(out_rel, -1, false, false); + } else { + this->collect_nodes_in_all_data(in_rel, false); + this->collect_nodes_out_all_ctrl_boundary(out_rel); + } +} #endif -//------------------------------is_counted_loop_exit_test-------------------------------------- +//----------------------is_counted_loop_exit_test------------------------------ // Returns true if node is used by a counted loop node. bool BoolNode::is_counted_loop_exit_test() { for( DUIterator_Fast imax, i = fast_outs(imax); i < imax; i++ ) { diff --git a/hotspot/src/share/vm/opto/subnode.hpp b/hotspot/src/share/vm/opto/subnode.hpp index 485cd17717b..a287ffaf026 100644 --- a/hotspot/src/share/vm/opto/subnode.hpp +++ b/hotspot/src/share/vm/opto/subnode.hpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2015, 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,7 +60,6 @@ public: // Supplied function to return the additive identity type. // This is returned whenever the subtracts inputs are the same. virtual const Type *add_id() const = 0; - }; @@ -140,6 +139,13 @@ public: const Type *add_id() const { return TypeInt::ZERO; } const Type *bottom_type() const { return TypeInt::CC; } virtual uint ideal_reg() const { return Op_RegFlags; } + +#ifndef PRODUCT + // CmpNode and subclasses include all data inputs (until hitting a control + // boundary) in their related node set, as well as all outputs until and + // including eventual control nodes and their projections. + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; +#endif }; //------------------------------CmpINode--------------------------------------- @@ -311,6 +317,7 @@ public: bool is_counted_loop_exit_test(); #ifndef PRODUCT virtual void dump_spec(outputStream *st) const; + virtual void related(GrowableArray *in_rel, GrowableArray *out_rel, bool compact) const; #endif }; diff --git a/hotspot/src/share/vm/runtime/commandLineFlagConstraintsCompiler.cpp b/hotspot/src/share/vm/runtime/commandLineFlagConstraintsCompiler.cpp index 83e371c446f..f0e43a44fdb 100644 --- a/hotspot/src/share/vm/runtime/commandLineFlagConstraintsCompiler.cpp +++ b/hotspot/src/share/vm/runtime/commandLineFlagConstraintsCompiler.cpp @@ -70,7 +70,10 @@ Flag::Error CICompilerCountConstraintFunc(bool verbose, intx* value) { #endif // The default CICompilerCount's value is CI_COMPILER_COUNT. - assert(min_number_of_compiler_threads <= CI_COMPILER_COUNT, "minimum should be less or equal default number"); + // With a client VM, -XX:+TieredCompilation causes TieredCompilation + // to be true here (the option is validated later) and + // min_number_of_compiler_threads to exceed CI_COMPILER_COUNT. + min_number_of_compiler_threads = MIN2(min_number_of_compiler_threads, CI_COMPILER_COUNT); if (*value < (intx)min_number_of_compiler_threads) { if (verbose == true) { diff --git a/hotspot/src/share/vm/runtime/globals.hpp b/hotspot/src/share/vm/runtime/globals.hpp index d2982e0d422..20098056d42 100644 --- a/hotspot/src/share/vm/runtime/globals.hpp +++ b/hotspot/src/share/vm/runtime/globals.hpp @@ -848,6 +848,9 @@ public: product(bool, UseCRC32CIntrinsics, false, \ "use intrinsics for java.util.zip.CRC32C") \ \ + diagnostic(ccstrlist, DisableIntrinsic, "", \ + "do not expand intrinsics whose (internal) names appear here") \ + \ develop(bool, TraceCallFixup, false, \ "Trace all call fixups") \ \ @@ -3913,7 +3916,7 @@ public: product(bool, PerfDisableSharedMem, false, \ "Store performance data in standard memory") \ \ - product(intx, PerfDataMemorySize, 32*K, \ + product(intx, PerfDataMemorySize, 64*K, \ "Size of performance data memory region. Will be rounded " \ "up to a multiple of the native os page size.") \ \ diff --git a/hotspot/src/share/vm/services/diagnosticCommand.cpp b/hotspot/src/share/vm/services/diagnosticCommand.cpp index e0fa2193c11..8c326cf73f5 100644 --- a/hotspot/src/share/vm/services/diagnosticCommand.cpp +++ b/hotspot/src/share/vm/services/diagnosticCommand.cpp @@ -37,6 +37,7 @@ #include "services/management.hpp" #include "services/writeableFlags.hpp" #include "utilities/macros.hpp" +#include "oops/objArrayOop.inline.hpp" PRAGMA_FORMAT_MUTE_WARNINGS_FOR_GCC @@ -57,6 +58,8 @@ void DCmdRegistrant::register_dcmds(){ DCmdFactory::register_DCmdFactory(new DCmdFactoryImpl(full_export, true, false)); DCmdFactory::register_DCmdFactory(new DCmdFactoryImpl(full_export, true, false)); DCmdFactory::register_DCmdFactory(new DCmdFactoryImpl(full_export, true, false)); + DCmdFactory::register_DCmdFactory(new DCmdFactoryImpl(full_export, true, false)); + DCmdFactory::register_DCmdFactory(new DCmdFactoryImpl(full_export, true, false)); #if INCLUDE_SERVICES // Heap dumping/inspection supported DCmdFactory::register_DCmdFactory(new DCmdFactoryImpl(DCmd_Source_Internal | DCmd_Source_AttachAPI, true, false)); DCmdFactory::register_DCmdFactory(new DCmdFactoryImpl(full_export, true, false)); @@ -333,6 +336,60 @@ void RunFinalizationDCmd::execute(DCmdSource source, TRAPS) { vmSymbols::void_method_signature(), CHECK); } +void HeapInfoDCmd::execute(DCmdSource source, TRAPS) { + Universe::heap()->print_on(output()); +} + +void FinalizerInfoDCmd::execute(DCmdSource source, TRAPS) { + ResourceMark rm; + + + Klass* k = SystemDictionary::resolve_or_null( + vmSymbols::finalizer_histogram_klass(), THREAD); + assert(k != NULL, "FinalizerHistogram class is not accessible"); + + instanceKlassHandle klass(THREAD, k); + JavaValue result(T_ARRAY); + + // We are calling lang.ref.FinalizerHistogram.getFinalizerHistogram() method + // and expect it to return array of FinalizerHistogramEntry as Object[] + + JavaCalls::call_static(&result, klass, + vmSymbols::get_finalizer_histogram_name(), + vmSymbols::void_finalizer_histogram_entry_array_signature(), CHECK); + + objArrayOop result_oop = (objArrayOop) result.get_jobject(); + if (result_oop->length() == 0) { + output()->print_cr("No instances waiting for finalization found"); + return; + } + + oop foop = result_oop->obj_at(0); + InstanceKlass* ik = InstanceKlass::cast(foop->klass()); + + fieldDescriptor count_fd, name_fd; + + Klass* count_res = ik->find_field( + vmSymbols::finalizer_histogram_entry_count_field(), vmSymbols::int_signature(), &count_fd); + + Klass* name_res = ik->find_field( + vmSymbols::finalizer_histogram_entry_name_field(), vmSymbols::string_signature(), &name_fd); + + assert(count_res != NULL && name_res != NULL, "Unexpected layout of FinalizerHistogramEntry"); + + output()->print_cr("Unreachable instances waiting for finalization"); + output()->print_cr("#instances class name"); + output()->print_cr("-----------------------"); + + for (int i = 0; i < result_oop->length(); ++i) { + oop element_oop = result_oop->obj_at(i); + oop str_oop = element_oop->obj_field(name_fd.offset()); + char *name = java_lang_String::as_utf8_string(str_oop); + int count = element_oop->int_field(count_fd.offset()); + output()->print_cr("%10d %s", count, name); + } +} + #if INCLUDE_SERVICES // Heap dumping/inspection supported HeapDumpDCmd::HeapDumpDCmd(outputStream* output, bool heap) : DCmdWithParser(output, heap), diff --git a/hotspot/src/share/vm/services/diagnosticCommand.hpp b/hotspot/src/share/vm/services/diagnosticCommand.hpp index 9362687128a..3106c0c9079 100644 --- a/hotspot/src/share/vm/services/diagnosticCommand.hpp +++ b/hotspot/src/share/vm/services/diagnosticCommand.hpp @@ -241,6 +241,46 @@ public: virtual void execute(DCmdSource source, TRAPS); }; +class HeapInfoDCmd : public DCmd { +public: + HeapInfoDCmd(outputStream* output, bool heap) : DCmd(output, heap) { } + static const char* name() { return "GC.heap_info"; } + static const char* description() { + return "Provide generic Java heap information."; + } + static const char* impact() { + return "Medium"; + } + static int num_arguments() { return 0; } + static const JavaPermission permission() { + JavaPermission p = {"java.lang.management.ManagementPermission", + "monitor", NULL}; + return p; + } + + virtual void execute(DCmdSource source, TRAPS); +}; + +class FinalizerInfoDCmd : public DCmd { +public: + FinalizerInfoDCmd(outputStream* output, bool heap) : DCmd(output, heap) { } + static const char* name() { return "GC.finalizer_info"; } + static const char* description() { + return "Provide information about Java finalization queue."; + } + static const char* impact() { + return "Medium"; + } + static int num_arguments() { return 0; } + static const JavaPermission permission() { + JavaPermission p = {"java.lang.management.ManagementPermission", + "monitor", NULL}; + return p; + } + + virtual void execute(DCmdSource source, TRAPS); +}; + #if INCLUDE_SERVICES // Heap dumping supported // See also: dump_heap in attachListener.cpp class HeapDumpDCmd : public DCmdWithParser { diff --git a/hotspot/test/compiler/arguments/CheckCICompilerCount.java b/hotspot/test/compiler/arguments/CheckCICompilerCount.java index 4f50e3b3162..ed32ade9bde 100644 --- a/hotspot/test/compiler/arguments/CheckCICompilerCount.java +++ b/hotspot/test/compiler/arguments/CheckCICompilerCount.java @@ -26,6 +26,7 @@ import jdk.test.lib.*; /* * @test CheckCheckCICompilerCount * @bug 8130858 + * @bug 8132525 * @summary Check that correct range of values for CICompilerCount are allowed depending on whether tiered is enabled or not * @library /testlibrary * @modules java.base/sun.misc @@ -36,12 +37,28 @@ import jdk.test.lib.*; public class CheckCICompilerCount { private static final String[][] NON_TIERED_ARGUMENTS = { { + "-server", "-XX:-TieredCompilation", "-XX:+PrintFlagsFinal", "-XX:CICompilerCount=0", "-version" }, { + "-server", + "-XX:-TieredCompilation", + "-XX:+PrintFlagsFinal", + "-XX:CICompilerCount=1", + "-version" + }, + { + "-client", + "-XX:-TieredCompilation", + "-XX:+PrintFlagsFinal", + "-XX:CICompilerCount=0", + "-version" + }, + { + "-client", "-XX:-TieredCompilation", "-XX:+PrintFlagsFinal", "-XX:CICompilerCount=1", @@ -50,6 +67,13 @@ public class CheckCICompilerCount { }; private static final String[][] NON_TIERED_EXPECTED_OUTPUTS = { + { + "CICompilerCount=0 must be at least 1", + "Improperly specified VM option 'CICompilerCount=0'" + }, + { + "intx CICompilerCount := 1 {product}" + }, { "CICompilerCount=0 must be at least 1", "Improperly specified VM option 'CICompilerCount=0'" @@ -60,18 +84,36 @@ public class CheckCICompilerCount { }; private static final int[] NON_TIERED_EXIT = { + 1, + 0, 1, 0 }; private static final String[][] TIERED_ARGUMENTS = { { + "-server", "-XX:+TieredCompilation", "-XX:+PrintFlagsFinal", "-XX:CICompilerCount=1", "-version" }, { + "-server", + "-XX:+TieredCompilation", + "-XX:+PrintFlagsFinal", + "-XX:CICompilerCount=2", + "-version" + }, + { + "-client", + "-XX:+TieredCompilation", + "-XX:+PrintFlagsFinal", + "-XX:CICompilerCount=1", + "-version" + }, + { + "-client", "-XX:+TieredCompilation", "-XX:+PrintFlagsFinal", "-XX:CICompilerCount=2", @@ -80,6 +122,13 @@ public class CheckCICompilerCount { }; private static final String[][] TIERED_EXPECTED_OUTPUTS = { + { + "CICompilerCount=1 must be at least 2", + "Improperly specified VM option 'CICompilerCount=1'" + }, + { + "intx CICompilerCount := 2 {product}" + }, { "CICompilerCount=1 must be at least 2", "Improperly specified VM option 'CICompilerCount=1'" @@ -90,6 +139,8 @@ public class CheckCICompilerCount { }; private static final int[] TIERED_EXIT = { + 1, + 0, 1, 0 }; diff --git a/hotspot/test/runtime/CommandLine/PrintTouchedMethods.java b/hotspot/test/runtime/CommandLine/PrintTouchedMethods.java index 0eb1852552a..7bae35ee714 100644 --- a/hotspot/test/runtime/CommandLine/PrintTouchedMethods.java +++ b/hotspot/test/runtime/CommandLine/PrintTouchedMethods.java @@ -87,6 +87,24 @@ public class PrintTouchedMethods { output.shouldNotContain("TestLogTouchedMethods.methodB:()V"); output.shouldHaveExitValue(0); + String[] javaArgs4 = {"-XX:+UnlockDiagnosticVMOptions", "-Xint", "-XX:+LogTouchedMethods", "-XX:+PrintTouchedMethodsAtExit", "-XX:-TieredCompilation", "TestLogTouchedMethods"}; + pb = ProcessTools.createJavaProcessBuilder(javaArgs4); + output = new OutputAnalyzer(pb.start()); + lines = output.asLines(); + + if (lines.size() < 1) { + throw new Exception("Empty output"); + } + + first = lines.get(0); + if (!first.equals("# Method::print_touched_methods version 1")) { + throw new Exception("First line mismatch"); + } + + output.shouldContain("TestLogTouchedMethods.methodA:()V"); + output.shouldNotContain("TestLogTouchedMethods.methodB:()V"); + output.shouldHaveExitValue(0); + // Test jcmd PrintTouchedMethods VM.print_touched_methods String pid = Integer.toString(ProcessTools.getProcessId()); pb = new ProcessBuilder(); diff --git a/hotspot/test/serviceability/dcmd/gc/FinalizerInfoTest.java b/hotspot/test/serviceability/dcmd/gc/FinalizerInfoTest.java new file mode 100644 index 00000000000..1e53a234b5a --- /dev/null +++ b/hotspot/test/serviceability/dcmd/gc/FinalizerInfoTest.java @@ -0,0 +1,87 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import org.testng.annotations.Test; +import org.testng.Assert; + +import java.util.concurrent.TimeUnit; +import java.util.concurrent.locks.Condition; +import java.util.concurrent.locks.ReentrantLock; + +import jdk.test.lib.OutputAnalyzer; +import jdk.test.lib.dcmd.CommandExecutor; +import jdk.test.lib.dcmd.PidJcmdExecutor; + +/* + * @test + * @summary + * @library /testlibrary + * @build jdk.test.lib.* + * @build jdk.test.lib.dcmd.* + * @run testng FinalizerInfoTest + */ +public class FinalizerInfoTest { + static ReentrantLock lock = new ReentrantLock(); + static volatile int wasInitialized = 0; + static volatile int wasTrapped = 0; + static final String cmd = "GC.finalizer_info"; + static final int objectsCount = 1000; + + class MyObject { + public MyObject() { + // Make sure object allocation/deallocation is not optimized out + wasInitialized += 1; + } + + protected void finalize() { + // Trap the object in a finalization queue + wasTrapped += 1; + lock.lock(); + } + } + + public void run(CommandExecutor executor) { + try { + lock.lock(); + for(int i = 0; i < objectsCount; ++i) { + new MyObject(); + } + System.out.println("Objects initialized: " + objectsCount); + System.gc(); + + while(wasTrapped < 1) { + // Waiting for gc thread. + } + + OutputAnalyzer output = executor.execute(cmd); + output.shouldContain("MyObject"); + } finally { + lock.unlock(); + } + } + + @Test + public void pid() { + run(new PidJcmdExecutor()); + } +} diff --git a/hotspot/test/serviceability/dcmd/gc/HeapInfoTest.java b/hotspot/test/serviceability/dcmd/gc/HeapInfoTest.java new file mode 100644 index 00000000000..daedf1252ef --- /dev/null +++ b/hotspot/test/serviceability/dcmd/gc/HeapInfoTest.java @@ -0,0 +1,54 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import org.testng.annotations.Test; +import org.testng.Assert; + +import java.io.IOException; + +import jdk.test.lib.dcmd.CommandExecutor; +import jdk.test.lib.dcmd.PidJcmdExecutor; +import jdk.test.lib.OutputAnalyzer; + + +/* + * @test + * @summary Test of diagnostic command GC.heap_info + * @library /testlibrary + * @build jdk.test.lib.* + * @build jdk.test.lib.dcmd.* + * @run testng HeapInfoTest + */ +public class HeapInfoTest { + public void run(CommandExecutor executor) { + String cmd = "GC.heap_info"; + OutputAnalyzer output = executor.execute(cmd); + output.shouldContain("Metaspace"); + } + + @Test + public void pid() { + run(new PidJcmdExecutor()); + } +} + diff --git a/hotspot/test/serviceability/dcmd/gc/RunFinalizationTest.java b/hotspot/test/serviceability/dcmd/gc/RunFinalizationTest.java index 21606a83b7c..bc34351974c 100644 --- a/hotspot/test/serviceability/dcmd/gc/RunFinalizationTest.java +++ b/hotspot/test/serviceability/dcmd/gc/RunFinalizationTest.java @@ -21,15 +21,13 @@ * questions. */ -import org.testng.annotations.Test; -import org.testng.Assert; - +import java.util.concurrent.Phaser; import java.util.concurrent.TimeUnit; -import java.util.concurrent.locks.Condition; -import java.util.concurrent.locks.ReentrantLock; +import java.util.concurrent.TimeoutException; import jdk.test.lib.dcmd.CommandExecutor; import jdk.test.lib.dcmd.JMXExecutor; +import jdk.test.lib.Utils; /* * @test @@ -41,62 +39,71 @@ import jdk.test.lib.dcmd.JMXExecutor; * jdk.jvmstat/sun.jvmstat.monitor * @build jdk.test.lib.* * @build jdk.test.lib.dcmd.* - * @run testng RunFinalizationTest + * @run main/othervm RunFinalizationTest */ public class RunFinalizationTest { - static ReentrantLock lock = new ReentrantLock(); - static Condition cond = lock.newCondition(); + private static final long TIMEOUT = Utils.adjustTimeout(15000); // 15s + private static final Phaser ph = new Phaser(3); static volatile boolean wasFinalized = false; static volatile boolean wasInitialized = false; - class MyObject { + static class MyObject { public MyObject() { /* Make sure object allocation/deallocation is not optimized out */ wasInitialized = true; } protected void finalize() { - lock.lock(); - wasFinalized = true; - cond.signalAll(); - lock.unlock(); + if (!Thread.currentThread().getName().equals("Finalizer")) { + wasFinalized = true; + ph.arrive(); + } else { + ph.arriveAndAwaitAdvance(); + } } } public static MyObject o; - public void run(CommandExecutor executor) { - lock.lock(); + private static void run(CommandExecutor executor) { o = new MyObject(); o = null; System.gc(); executor.execute("GC.run_finalization"); - int waited = 0; - int waitTime = 15; + System.out.println("Waiting for signal from finalizer"); - try { - System.out.println("Waiting for signal from finalizer"); - - while (!cond.await(waitTime, TimeUnit.SECONDS)) { - waited += waitTime; - System.out.println(String.format("Waited %d seconds", waited)); + long targetTime = System.currentTimeMillis() + TIMEOUT; + while (System.currentTimeMillis() < targetTime) { + try { + ph.awaitAdvanceInterruptibly(ph.arrive(), 200, TimeUnit.MILLISECONDS); + System.out.println("Received signal"); + break; + } catch (InterruptedException e) { + fail("Test error: Interrupted while waiting for signal from finalizer", e); + } catch (TimeoutException e) { + System.out.println("Haven't received signal in 200ms. Retrying ..."); } - - System.out.println("Received signal"); - } catch (InterruptedException e) { - Assert.fail("Test error: Interrupted while waiting for signal from finalizer", e); - } finally { - lock.unlock(); } if (!wasFinalized) { - Assert.fail("Test failure: Object was not finalized"); + fail("Test failure: Object was not finalized"); } } - @Test - public void jmx() { - run(new JMXExecutor()); + public static void main(String ... args) { + MyObject o = new MyObject(); + o = null; + Runtime.getRuntime().addShutdownHook(new Thread(()->{ + run(new JMXExecutor()); + })); + } + + private static void fail(String msg, Exception e) { + throw new Error(msg, e); + } + + private static void fail(String msg) { + throw new Error(msg); } } diff --git a/hotspot/test/testlibrary/jdk/test/lib/Utils.java b/hotspot/test/testlibrary/jdk/test/lib/Utils.java index 73027cbaab3..eb9ae00017c 100644 --- a/hotspot/test/testlibrary/jdk/test/lib/Utils.java +++ b/hotspot/test/testlibrary/jdk/test/lib/Utils.java @@ -314,9 +314,8 @@ public final class Utils { */ public static String fileAsString(String filename) throws IOException { Path filePath = Paths.get(filename); - return Files.exists(filePath) - ? Files.lines(filePath).collect(Collectors.joining(NEW_LINE)) - : null; + if (!Files.exists(filePath)) return null; + return new String(Files.readAllBytes(filePath)); } /** diff --git a/jaxp/.hgtags b/jaxp/.hgtags index 6165f2117df..e3b3c6177a6 100644 --- a/jaxp/.hgtags +++ b/jaxp/.hgtags @@ -319,3 +319,4 @@ be5efc34a43bdd982d1cbe11cb2f6d6a060dde60 jdk9-b73 eadcb2b55cd1daf77625813aad0f6f3967b1528a jdk9-b74 16b5e696f948cd8aa9b3afdb686ddffd48bd17a8 jdk9-b75 36801a89a04201b59874ec776ffe85d6253c9ab5 jdk9-b76 +be357705874c4ba1a69c38fb211e5e31e35bf9cb jdk9-b77 diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6350682.java b/jaxp/test/javax/xml/jaxp/unittest/common/Bug6350682.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6350682.java rename to jaxp/test/javax/xml/jaxp/unittest/common/Bug6350682.java index 04d4f2502b7..e955df49676 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6350682.java +++ b/jaxp/test/javax/xml/jaxp/unittest/common/Bug6350682.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.common; +package common; import javax.xml.parsers.SAXParserFactory; import javax.xml.transform.TransformerFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6723276Test.java b/jaxp/test/javax/xml/jaxp/unittest/common/Bug6723276Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6723276Test.java rename to jaxp/test/javax/xml/jaxp/unittest/common/Bug6723276Test.java index 7e1ecd89a6f..63ac73d4973 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6723276Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/common/Bug6723276Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.common; +package common; import org.testng.annotations.Test; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6941169.xml b/jaxp/test/javax/xml/jaxp/unittest/common/Bug6941169.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6941169.xml rename to jaxp/test/javax/xml/jaxp/unittest/common/Bug6941169.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6941169.xsd b/jaxp/test/javax/xml/jaxp/unittest/common/Bug6941169.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6941169.xsd rename to jaxp/test/javax/xml/jaxp/unittest/common/Bug6941169.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6941169Test.java b/jaxp/test/javax/xml/jaxp/unittest/common/Bug6941169Test.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6941169Test.java rename to jaxp/test/javax/xml/jaxp/unittest/common/Bug6941169Test.java index fa35c3aa2cb..8f03995bc10 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug6941169Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/common/Bug6941169Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.common; +package common; import java.io.InputStream; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug7143711Test.java b/jaxp/test/javax/xml/jaxp/unittest/common/Bug7143711Test.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug7143711Test.java rename to jaxp/test/javax/xml/jaxp/unittest/common/Bug7143711Test.java index 7b38db0c0c2..5074da2150b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/common/Bug7143711Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/common/Bug7143711Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.common; +package common; import java.security.AllPermission; import java.security.Permission; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6320118.java b/jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6320118.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6320118.java rename to jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6320118.java index 959a978f6f0..87d3829e658 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6320118.java +++ b/jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6320118.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.datatype; +package datatype; import javax.xml.datatype.DatatypeConfigurationException; import javax.xml.datatype.DatatypeFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6937951Test.java b/jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6937951Test.java similarity index 88% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6937951Test.java rename to jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6937951Test.java index a7335644c61..161f127b9b2 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6937951Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6937951Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,11 @@ * questions. */ -package javax.xml.datatype; +package datatype; + +import javax.xml.datatype.DatatypeConfigurationException; +import javax.xml.datatype.DatatypeFactory; +import javax.xml.datatype.XMLGregorianCalendar; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6937964Test.java b/jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6937964Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6937964Test.java rename to jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6937964Test.java index 31aff0538f9..73ea2930cf2 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug6937964Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/datatype/Bug6937964Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,15 @@ * questions. */ -package javax.xml.datatype; +package datatype; import java.math.BigDecimal; import java.math.BigInteger; +import javax.xml.datatype.DatatypeConfigurationException; +import javax.xml.datatype.DatatypeConstants; +import javax.xml.datatype.DatatypeFactory; +import javax.xml.datatype.Duration; import javax.xml.namespace.QName; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug7042647Test.java b/jaxp/test/javax/xml/jaxp/unittest/datatype/Bug7042647Test.java similarity index 89% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug7042647Test.java rename to jaxp/test/javax/xml/jaxp/unittest/datatype/Bug7042647Test.java index 36438265010..3bf98f65bed 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/Bug7042647Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/datatype/Bug7042647Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,15 @@ * questions. */ -package javax.xml.datatype; +package datatype; import java.util.Calendar; import java.util.GregorianCalendar; +import javax.xml.datatype.DatatypeConfigurationException; +import javax.xml.datatype.DatatypeFactory; +import javax.xml.datatype.XMLGregorianCalendar; + import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/DatatypeFactoryTest.java b/jaxp/test/javax/xml/jaxp/unittest/datatype/DatatypeFactoryTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/DatatypeFactoryTest.java rename to jaxp/test/javax/xml/jaxp/unittest/datatype/DatatypeFactoryTest.java index 67e458ee719..c6977e98967 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/DatatypeFactoryTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/datatype/DatatypeFactoryTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,16 @@ * questions. */ -package javax.xml.datatype; +package datatype; import java.math.BigDecimal; import java.math.BigInteger; +import javax.xml.datatype.DatatypeConfigurationException; +import javax.xml.datatype.DatatypeConstants; +import javax.xml.datatype.DatatypeFactory; +import javax.xml.datatype.Duration; +import javax.xml.datatype.XMLGregorianCalendar; import javax.xml.namespace.QName; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/DurationTest.java b/jaxp/test/javax/xml/jaxp/unittest/datatype/DurationTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/DurationTest.java rename to jaxp/test/javax/xml/jaxp/unittest/datatype/DurationTest.java index f97536c8765..ece77adc8fa 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/DurationTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/datatype/DurationTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.datatype; +package datatype; import java.math.BigDecimal; import java.math.BigInteger; @@ -30,6 +30,10 @@ import java.util.Date; import java.util.GregorianCalendar; import java.util.TimeZone; +import javax.xml.datatype.DatatypeConfigurationException; +import javax.xml.datatype.DatatypeConstants; +import javax.xml.datatype.DatatypeFactory; +import javax.xml.datatype.Duration; import javax.xml.namespace.QName; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/FactoryFindTest.java b/jaxp/test/javax/xml/jaxp/unittest/datatype/FactoryFindTest.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/FactoryFindTest.java rename to jaxp/test/javax/xml/jaxp/unittest/datatype/FactoryFindTest.java index e9e84bd61a3..87e46373e8b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/FactoryFindTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/datatype/FactoryFindTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,13 @@ * questions. */ -package javax.xml.datatype; +package datatype; import java.net.URL; import java.net.URLClassLoader; +import javax.xml.datatype.DatatypeFactory; + import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/XMLGregorianCalendarTest.java b/jaxp/test/javax/xml/jaxp/unittest/datatype/XMLGregorianCalendarTest.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/XMLGregorianCalendarTest.java rename to jaxp/test/javax/xml/jaxp/unittest/datatype/XMLGregorianCalendarTest.java index b842fd5a177..4c3deb901ac 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/datatype/XMLGregorianCalendarTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/datatype/XMLGregorianCalendarTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,12 @@ * questions. */ -package javax.xml.datatype; +package datatype; + +import javax.xml.datatype.DatatypeConfigurationException; +import javax.xml.datatype.DatatypeConstants; +import javax.xml.datatype.DatatypeFactory; +import javax.xml.datatype.XMLGregorianCalendar; import org.testng.Assert; import org.testng.annotations.BeforeMethod; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4915524.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4915524.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4915524.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4915524.java index f496447619d..3540089c9ef 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4915524.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4915524.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4915748.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4915748.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4915748.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4915748.java index 9e04b082254..8c8f71714de 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4915748.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4915748.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966082.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966082.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966082.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966082.java index 3bc3c357443..b18f8094710 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966082.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966082.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966082.xml b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966082.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966082.xml rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966082.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966138.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966138.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966138.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966138.java index ddd0bf5ff89..5244112fe3f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966138.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966138.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import javax.xml.XMLConstants; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966142.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966142.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966142.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966142.java index dd55013d571..890ada5f019 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966142.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966142.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import javax.xml.XMLConstants; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966142.xml b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966142.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966142.xml rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966142.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966142.xsd b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966142.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966142.xsd rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966142.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966143.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966143.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966143.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966143.java index 7133089d296..9cf87b200af 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966143.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966143.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import javax.xml.XMLConstants; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966143.xml b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966143.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966143.xml rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966143.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966143.xsd b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966143.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug4966143.xsd rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug4966143.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6339023.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6339023.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6339023.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6339023.java index 273708cc209..7b611bd9993 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6339023.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6339023.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6355326.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6355326.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6355326.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6355326.java index 911baf4a07f..cea41cc9a87 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6355326.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6355326.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.ByteArrayInputStream; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6367542.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6367542.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6367542.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6367542.java index fa77a70df16..c0a3e164834 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6367542.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6367542.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6520131.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6520131.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6520131.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6520131.java index c30f43070da..982d481014e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6520131.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6520131.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6521260.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6521260.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6521260.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6521260.java index bcfa894ed53..3c9a97644eb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6521260.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6521260.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.ByteArrayInputStream; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6582545.xml b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6582545.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6582545.xml rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6582545.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6582545Test.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6582545Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6582545Test.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6582545Test.java index 2966d0accc6..fec67cdfe20 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6582545Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6582545Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.File; import java.io.IOException; @@ -32,6 +32,9 @@ import javax.xml.parsers.ParserConfigurationException; import org.testng.Assert; import org.testng.annotations.Test; +import org.w3c.dom.Document; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.NodeList; import org.xml.sax.SAXException; /* diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6879614.xml b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6879614.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6879614.xml rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6879614.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6879614Test.java b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6879614Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6879614Test.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/Bug6879614Test.java index 7c669698814..b19a28ba29a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/Bug6879614Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/Bug6879614Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.File; import java.io.IOException; @@ -31,6 +31,7 @@ import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; import org.testng.annotations.Test; +import org.w3c.dom.Document; import org.xml.sax.SAXException; /* diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6333993Test.java b/jaxp/test/javax/xml/jaxp/unittest/dom/CR6333993Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6333993Test.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/CR6333993Test.java index b54e9c61de0..84c06b829b4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6333993Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/CR6333993Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.ByteArrayInputStream; @@ -34,6 +34,8 @@ import javax.xml.xpath.XPathFactory; import org.testng.Assert; import org.testng.annotations.Test; +import org.w3c.dom.Document; +import org.w3c.dom.NodeList; /* * @bug 6333993 diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6517707Test.java b/jaxp/test/javax/xml/jaxp/unittest/dom/CR6517707Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6517707Test.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/CR6517707Test.java index 67241c85d05..9bc2c6c3a0f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6517707Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/CR6517707Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.ByteArrayInputStream; import java.io.IOException; @@ -33,6 +33,9 @@ import javax.xml.parsers.ParserConfigurationException; import org.testng.Assert; import org.testng.annotations.Test; +import org.w3c.dom.DOMException; +import org.w3c.dom.Document; +import org.w3c.dom.Entity; import org.xml.sax.InputSource; import org.xml.sax.SAXException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6517717Test.java b/jaxp/test/javax/xml/jaxp/unittest/dom/CR6517717Test.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6517717Test.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/CR6517717Test.java index 02e1972b11a..44bab9c37f7 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6517717Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/CR6517717Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.IOException; import java.io.StringReader; @@ -32,6 +32,9 @@ import javax.xml.parsers.ParserConfigurationException; import org.testng.Assert; import org.testng.annotations.Test; +import org.w3c.dom.DOMException; +import org.w3c.dom.Document; +import org.w3c.dom.Entity; import org.xml.sax.InputSource; import org.xml.sax.SAXException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6909336Test.java b/jaxp/test/javax/xml/jaxp/unittest/dom/CR6909336Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6909336Test.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/CR6909336Test.java index 85e90cd294b..15dc9636af6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/CR6909336Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/CR6909336Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import javax.xml.stream.XMLOutputFactory; import javax.xml.stream.XMLStreamException; @@ -30,6 +30,7 @@ import javax.xml.transform.dom.DOMResult; import org.testng.Assert; import org.testng.annotations.Test; +import org.w3c.dom.Document; import org.w3c.dom.bootstrap.DOMImplementationRegistry; /* diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/DOMConfigurationTest.java b/jaxp/test/javax/xml/jaxp/unittest/dom/DOMConfigurationTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/DOMConfigurationTest.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/DOMConfigurationTest.java index 6a4fba6245c..0bc4669c4e6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/DOMConfigurationTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/DOMConfigurationTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -20,7 +20,7 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package org.w3c.dom; +package dom; import java.io.IOException; import java.io.StringReader; @@ -34,6 +34,21 @@ import javax.xml.parsers.ParserConfigurationException; import org.testng.Assert; import org.testng.annotations.Test; +import org.w3c.dom.Attr; +import org.w3c.dom.CDATASection; +import org.w3c.dom.Comment; +import org.w3c.dom.DOMConfiguration; +import org.w3c.dom.DOMError; +import org.w3c.dom.DOMErrorHandler; +import org.w3c.dom.DOMException; +import org.w3c.dom.DOMImplementation; +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.w3c.dom.Entity; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.Node; +import org.w3c.dom.ProcessingInstruction; +import org.w3c.dom.Text; import org.w3c.dom.ls.DOMImplementationLS; import org.w3c.dom.ls.LSInput; import org.w3c.dom.ls.LSParser; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/DOMConfigurationTest.xsd b/jaxp/test/javax/xml/jaxp/unittest/dom/DOMConfigurationTest.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/DOMConfigurationTest.xsd rename to jaxp/test/javax/xml/jaxp/unittest/dom/DOMConfigurationTest.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/DOMXPathTest.java b/jaxp/test/javax/xml/jaxp/unittest/dom/DOMXPathTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/DOMXPathTest.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/DOMXPathTest.java index fa92dc7175b..ebd97facd4b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/DOMXPathTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/DOMXPathTest.java @@ -20,12 +20,14 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package org.w3c.dom; +package dom; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; + import org.testng.Assert; import org.testng.annotations.Test; +import org.w3c.dom.DOMImplementation; /* * @bug 8042244 diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/JdkXmlDomTest.java b/jaxp/test/javax/xml/jaxp/unittest/dom/JdkXmlDomTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/JdkXmlDomTest.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/JdkXmlDomTest.java index b65b4fd6bff..4c1269cf79c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/JdkXmlDomTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/JdkXmlDomTest.java @@ -20,7 +20,7 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package org.w3c.dom; +package dom; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/TCKEncodingTest.java b/jaxp/test/javax/xml/jaxp/unittest/dom/TCKEncodingTest.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/TCKEncodingTest.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/TCKEncodingTest.java index a5148fb563b..4f4ece1766a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/TCKEncodingTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/TCKEncodingTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom; +package dom; import java.io.IOException; import java.io.StringReader; @@ -32,6 +32,7 @@ import javax.xml.parsers.ParserConfigurationException; import org.testng.Assert; import org.testng.annotations.Test; +import org.w3c.dom.Document; import org.xml.sax.InputSource; import org.xml.sax.SAXException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug4973153.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug4973153.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug4973153.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug4973153.java index 6b9b44ccaac..b16d06c6172 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug4973153.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug4973153.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom.ls; +package dom.ls; import java.io.ByteArrayOutputStream; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6290947.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6290947.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6290947.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6290947.java index 065dfcbe491..9ef91451fbe 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6290947.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6290947.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom.ls; +package dom.ls; import java.io.StringBufferInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6354955.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6354955.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6354955.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6354955.java index d184cf8e6f2..cdaa0cf4d03 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6354955.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6354955.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom.ls; +package dom.ls; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6376823.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6376823.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6376823.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6376823.java index f3ba84e2e0e..d4fcc32aeb9 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6376823.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6376823.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom.ls; +package dom.ls; import java.io.StringBufferInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6710741Test.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6710741Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6710741Test.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6710741Test.java index 3f70fb7b6bb..d0b95b99073 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/Bug6710741Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/Bug6710741Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom.ls; +package dom.ls; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; @@ -30,6 +30,8 @@ import org.testng.Assert; import org.testng.annotations.Test; import org.w3c.dom.Document; import org.w3c.dom.Element; +import org.w3c.dom.ls.DOMImplementationLS; +import org.w3c.dom.ls.LSException; /* * @bug 6710741 diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSParserTCKTest.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSParserTCKTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSParserTCKTest.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSParserTCKTest.java index 69e27e1bb96..8c609fc594d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSParserTCKTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSParserTCKTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom.ls; +package dom.ls; import java.io.IOException; import java.io.StringBufferInputStream; @@ -39,6 +39,10 @@ import org.w3c.dom.Element; import org.w3c.dom.NamedNodeMap; import org.w3c.dom.Node; import org.w3c.dom.NodeList; +import org.w3c.dom.ls.DOMImplementationLS; +import org.w3c.dom.ls.LSInput; +import org.w3c.dom.ls.LSParser; +import org.w3c.dom.ls.LSParserFilter; import org.w3c.dom.traversal.NodeFilter; import org.xml.sax.SAXException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSParserTest.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSParserTest.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSParserTest.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSParserTest.java index 3d0c199ea3f..bf24b878037 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSParserTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSParserTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom.ls; +package dom.ls; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; @@ -33,6 +33,10 @@ import org.w3c.dom.DOMError; import org.w3c.dom.DOMErrorHandler; import org.w3c.dom.DOMException; import org.w3c.dom.DOMImplementation; +import org.w3c.dom.ls.DOMImplementationLS; +import org.w3c.dom.ls.LSInput; +import org.w3c.dom.ls.LSParser; +import org.w3c.dom.ls.LSResourceResolver; /* * @summary Test LSParser's DOMConfiguration for supported properties. diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSSerializerTest.java b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSSerializerTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSSerializerTest.java rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSSerializerTest.java index 9df924a3c43..172d3299d5b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/LSSerializerTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/LSSerializerTest.java @@ -21,7 +21,7 @@ * questions. */ -package org.w3c.dom.ls; +package dom.ls; import java.io.IOException; import java.io.OutputStream; @@ -39,6 +39,10 @@ import org.w3c.dom.DOMError; import org.w3c.dom.DOMErrorHandler; import org.w3c.dom.DOMImplementation; import org.w3c.dom.Document; +import org.w3c.dom.ls.DOMImplementationLS; +import org.w3c.dom.ls.LSException; +import org.w3c.dom.ls.LSOutput; +import org.w3c.dom.ls.LSSerializer; import org.xml.sax.InputSource; import org.xml.sax.SAXException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/note_in_dtd.xml b/jaxp/test/javax/xml/jaxp/unittest/dom/ls/note_in_dtd.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/ls/note_in_dtd.xml rename to jaxp/test/javax/xml/jaxp/unittest/dom/ls/note_in_dtd.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/test.xml b/jaxp/test/javax/xml/jaxp/unittest/dom/test.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/test.xml rename to jaxp/test/javax/xml/jaxp/unittest/dom/test.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/test.xsd b/jaxp/test/javax/xml/jaxp/unittest/dom/test.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/w3c/dom/test.xsd rename to jaxp/test/javax/xml/jaxp/unittest/dom/test.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.dtd.bak b/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.dtd.bak deleted file mode 100644 index 6fbfdfeb67b..00000000000 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.dtd.bak +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - - - diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.xml.bak b/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.xml.bak deleted file mode 100644 index c4fab83ca91..00000000000 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.xml.bak +++ /dev/null @@ -1,19 +0,0 @@ - - -]> - - - The Publishers - - Alfred Publishing - 15535 Morrison - South Oaks CA 91403 - &max; - - eXtensible Markup Language - - - - diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4674384_MAX_OCCURS_Test.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4674384_MAX_OCCURS_Test.java similarity index 92% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4674384_MAX_OCCURS_Test.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4674384_MAX_OCCURS_Test.java index 7978e5c7c15..5c8248a065b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4674384_MAX_OCCURS_Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4674384_MAX_OCCURS_Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,13 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.File; +import javax.xml.parsers.SAXParser; +import javax.xml.parsers.SAXParserFactory; + import org.testng.Assert; import org.testng.annotations.Test; import org.xml.sax.helpers.DefaultHandler; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4674384_MAX_OCCURS_Test.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4674384_MAX_OCCURS_Test.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4674384_MAX_OCCURS_Test.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4674384_MAX_OCCURS_Test.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4674384_MAX_OCCURS_Test.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4674384_MAX_OCCURS_Test.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4674384_MAX_OCCURS_Test.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4674384_MAX_OCCURS_Test.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4934208.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4934208.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4934208.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4934208.java index 8e77af0ef87..50f5514f3af 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4934208.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4934208.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import javax.xml.parsers.SAXParser; import javax.xml.parsers.SAXParserFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4967002.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4967002.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4967002.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4967002.java index 3fd09a7b6e4..084323445a9 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4967002.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4967002.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4985486.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4985486.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4985486.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4985486.java index b8ab86e6858..c87f47187c7 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4985486.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4985486.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import javax.xml.parsers.SAXParserFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4985486.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4985486.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4985486.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4985486.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991020.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991020.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991020.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991020.java index 38036a725e0..6a50919122f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991020.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991020.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import javax.xml.parsers.SAXParser; import javax.xml.parsers.SAXParserFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991020.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991020.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991020.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991020.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991020.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991020.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991020.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991020.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991946.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991946.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991946.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991946.java index 39091809059..f48e0bdc783 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991946.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991946.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import javax.xml.parsers.SAXParser; import javax.xml.parsers.SAXParserFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991946.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991946.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991946.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991946.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991946.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991946.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug4991946.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug4991946.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug5010072.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug5010072.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug5010072.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug5010072.java index 292a3042e71..68d9a170435 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug5010072.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug5010072.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug5010072.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug5010072.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug5010072.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug5010072.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug5025825.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug5025825.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug5025825.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug5025825.java index a2912089f9e..9a87104746b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug5025825.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug5025825.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6309988.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6309988.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6309988.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6309988.java index 499dc2a5861..fc38d41c3e4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6309988.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6309988.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.File; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6341770.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6341770.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6341770.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6341770.java index e5b1f74a793..94873dfaab3 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6341770.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6341770.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.File; import java.io.FileWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6361283.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6361283.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6361283.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6361283.java index 8a0f3c9f322..f3bfb88fce1 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6361283.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6361283.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import javax.xml.parsers.SAXParser; import javax.xml.parsers.SAXParserFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6506304Test.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6506304Test.java similarity index 92% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6506304Test.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6506304Test.java index b93e7333977..a7e82d51eab 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6506304Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6506304Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,10 @@ * questions. */ -package javax.xml.parsers; +package parsers; + +import javax.xml.parsers.SAXParser; +import javax.xml.parsers.SAXParserFactory; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6518733.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6518733.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6518733.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6518733.java index c1d141eef53..c6a03542a43 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6518733.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6518733.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.FileReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6518733.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6518733.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6518733.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6518733.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6564400.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6564400.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6564400.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6564400.java index c76304d8bad..e7aa719dd81 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6564400.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6564400.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.File; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6564400.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6564400.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6564400.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6564400.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6564400.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6564400.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6564400.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6564400.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6573786.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6573786.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6573786.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6573786.java index 49488360b0d..ff3d19388e6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6573786.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6573786.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.InputStream; import java.io.StringBufferInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6573786ErrorHandler.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6573786ErrorHandler.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6573786ErrorHandler.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6573786ErrorHandler.java index 5d55cea1029..b938eb6eb6f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6573786ErrorHandler.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6573786ErrorHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import org.xml.sax.SAXException; import org.xml.sax.SAXParseException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6594813.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6594813.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6594813.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6594813.java index d660f958bcc..a89d834642f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6594813.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6594813.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.StringReader; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841.dtd b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841.dtd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841.java index d68837793fe..db724d83e86 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.File; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841_xhtml11-flat.dtd b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841_xhtml11-flat.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6608841_xhtml11-flat.dtd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6608841_xhtml11-flat.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6690015.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6690015.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6690015.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6690015.java index 50838e82196..25f536f73bb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6690015.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6690015.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.FileInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6760982.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6760982.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6760982.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6760982.java index 1a2bc04f9de..cfd2fe26a74 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6760982.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6760982.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.File; import java.io.FileReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6849942Test.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6849942Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6849942Test.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6849942Test.java index 3a28a094243..c65bd1bc285 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug6849942Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug6849942Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,13 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.ByteArrayInputStream; +import javax.xml.parsers.DocumentBuilder; +import javax.xml.parsers.DocumentBuilderFactory; + import org.testng.Assert; import org.testng.annotations.Test; import org.w3c.dom.Document; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608.dtd b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608.dtd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608Test.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608Test.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608Test.java index c4a7f7a42e6..bd1e303dc17 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,14 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.File; import java.io.IOException; +import javax.xml.parsers.DocumentBuilder; +import javax.xml.parsers.DocumentBuilderFactory; + import org.testng.Assert; import org.testng.annotations.BeforeMethod; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608_1.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608_1.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7157608_1.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7157608_1.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7166896Test.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7166896Test.java similarity index 91% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7166896Test.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7166896Test.java index e886bca59c9..7230f9c1488 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug7166896Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug7166896Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,14 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.IOException; +import javax.xml.parsers.DocumentBuilder; +import javax.xml.parsers.DocumentBuilderFactory; +import javax.xml.parsers.ParserConfigurationException; + import org.testng.Assert; import org.testng.annotations.Test; import org.w3c.dom.Document; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug8073385.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug8073385.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug8073385.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/Bug8073385.java index 1d3aa66ce08..5a034c378b9 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/Bug8073385.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/Bug8073385.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.StringReader; import java.util.Locale; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/DosTest.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/DosTest.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/DosTest.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/DosTest.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/DosTest3.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/DosTest3.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/DosTest3.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/DosTest3.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/FactoryFindTest.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/FactoryFindTest.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/FactoryFindTest.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/FactoryFindTest.java index 6f769714125..031b0fea2a2 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/FactoryFindTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/FactoryFindTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,13 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.net.URL; import java.net.URLClassLoader; +import javax.xml.parsers.SAXParserFactory; + import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/MyDefaultHandler.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/MyDefaultHandler.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/MyDefaultHandler.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/MyDefaultHandler.java index a63bcd4cf26..c690163eb86 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/MyDefaultHandler.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/MyDefaultHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import org.xml.sax.Attributes; import org.xml.sax.Locator; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/MyErrorHandler.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/MyErrorHandler.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/MyErrorHandler.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/MyErrorHandler.java index 3dc24dcdfcb..695c932f603 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/MyErrorHandler.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/MyErrorHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers; +package parsers; import org.xml.sax.SAXException; import org.xml.sax.SAXParseException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/ParseEmptyStream.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/ParseEmptyStream.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/ParseEmptyStream.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/ParseEmptyStream.java index cc9ba34faa7..a6dafccba4c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/ParseEmptyStream.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/ParseEmptyStream.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,13 @@ * questions. */ -package javax.xml.parsers; +package parsers; import java.io.StringReader; +import javax.xml.parsers.SAXParser; +import javax.xml.parsers.SAXParserFactory; + import org.testng.Assert; import org.testng.annotations.Test; import org.xml.sax.InputSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/bug6690015.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/bug6690015.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/bug6690015.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/bug6690015.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/bug6760982.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/bug6760982.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/bug6760982.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/bug6760982.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/catalog.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/catalog.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/catalog.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/catalog.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/catalog.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/catalog.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/catalog.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/catalog.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/entity.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/entity.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/entity.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/entity.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/entity64K.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/entity64K.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/entity64K.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/entity64K.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/test.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/test.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/test.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/test.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/test1.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/test1.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/test1.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/test1.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/test2.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/test2.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/test2.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/test2.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/toys.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/toys.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/toys.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/toys.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/toys.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/toys.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/toys.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/toys.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/toys3002.xsd b/jaxp/test/javax/xml/jaxp/unittest/parsers/toys3002.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/toys3002.xsd rename to jaxp/test/javax/xml/jaxp/unittest/parsers/toys3002.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/xinclude/Bug6794483Test.java b/jaxp/test/javax/xml/jaxp/unittest/parsers/xinclude/Bug6794483Test.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/xinclude/Bug6794483Test.java rename to jaxp/test/javax/xml/jaxp/unittest/parsers/xinclude/Bug6794483Test.java index ee5e2587d6c..841191704eb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/xinclude/Bug6794483Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/parsers/xinclude/Bug6794483Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.parsers.xinclude; +package parsers.xinclude; import static java.lang.System.lineSeparator; import static org.testng.Assert.assertEquals; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/xinclude/test1.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/xinclude/test1.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/xinclude/test1.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/xinclude/test1.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/xinclude/test2.xml b/jaxp/test/javax/xml/jaxp/unittest/parsers/xinclude/test2.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/parsers/xinclude/test2.xml rename to jaxp/test/javax/xml/jaxp/unittest/parsers/xinclude/test2.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Attributes2ImplTest.java b/jaxp/test/javax/xml/jaxp/unittest/sax/Attributes2ImplTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Attributes2ImplTest.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/Attributes2ImplTest.java index 362440fcf55..e8a1bba6864 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Attributes2ImplTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/Attributes2ImplTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6889654Test.java b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug6889654Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6889654Test.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/Bug6889654Test.java index ece2b16f09c..e5043aa0f48 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6889654Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug6889654Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import java.io.IOException; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6925410Test.java b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug6925410Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6925410Test.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/Bug6925410Test.java index 280d2c8d6e1..5679ed6b262 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6925410Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug6925410Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import javax.xml.datatype.DatatypeConfigurationException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6949607Test.java b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug6949607Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6949607Test.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/Bug6949607Test.java index 800788a8581..d8fd89cd29a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6949607Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug6949607Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import java.io.ByteArrayInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6992561Test.java b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug6992561Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6992561Test.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/Bug6992561Test.java index f4761bf9440..d82fe101f47 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug6992561Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug6992561Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import java.io.ByteArrayInputStream; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug7057778.xml b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug7057778.xml rename to jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug7057778Test.java b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug7057778Test.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778Test.java index 39039ddc223..77809766d5e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/Bug7057778Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/Bug7057778Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import java.io.File; import java.io.FileInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/DefaultHandler2Test.java b/jaxp/test/javax/xml/jaxp/unittest/sax/DefaultHandler2Test.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/DefaultHandler2Test.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/DefaultHandler2Test.java index ecce29090ce..15205d745cb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/DefaultHandler2Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/DefaultHandler2Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/IssueTracker56Test.java b/jaxp/test/javax/xml/jaxp/unittest/sax/IssueTracker56Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/IssueTracker56Test.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/IssueTracker56Test.java index 9b26c5d04e0..b5a46472f34 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/IssueTracker56Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/IssueTracker56Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import java.io.IOException; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/MyDefaultHandler2.java b/jaxp/test/javax/xml/jaxp/unittest/sax/MyDefaultHandler2.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/MyDefaultHandler2.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/MyDefaultHandler2.java index 548d662256e..44ac9fde73d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/MyDefaultHandler2.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/MyDefaultHandler2.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/NSSupportTest.java b/jaxp/test/javax/xml/jaxp/unittest/sax/NSSupportTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/NSSupportTest.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/NSSupportTest.java index b2c5221f259..c04ecc7ab54 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/NSSupportTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/NSSupportTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import java.util.Enumeration; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/SAXExceptionExt.java b/jaxp/test/javax/xml/jaxp/unittest/sax/SAXExceptionExt.java similarity index 92% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/SAXExceptionExt.java rename to jaxp/test/javax/xml/jaxp/unittest/sax/SAXExceptionExt.java index 3e5421c5573..9b9800d27fa 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/SAXExceptionExt.java +++ b/jaxp/test/javax/xml/jaxp/unittest/sax/SAXExceptionExt.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package org.xml.sax; +package sax; import org.xml.sax.SAXException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/externalDTD.dtd b/jaxp/test/javax/xml/jaxp/unittest/sax/externalDTD.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/externalDTD.dtd rename to jaxp/test/javax/xml/jaxp/unittest/sax/externalDTD.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/toys.xml b/jaxp/test/javax/xml/jaxp/unittest/sax/toys.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/toys.xml rename to jaxp/test/javax/xml/jaxp/unittest/sax/toys.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/toys_error.xml b/jaxp/test/javax/xml/jaxp/unittest/sax/toys_error.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/org/xml/sax/toys_error.xml rename to jaxp/test/javax/xml/jaxp/unittest/sax/toys_error.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/AttributeLocalNameTest/AttributeLocalNameTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/AttributeLocalNameTest/AttributeLocalNameTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/AttributeLocalNameTest/AttributeLocalNameTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/AttributeLocalNameTest/AttributeLocalNameTest.java index dd2570c8daa..01d54e05785 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/AttributeLocalNameTest/AttributeLocalNameTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/AttributeLocalNameTest/AttributeLocalNameTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.AttributeLocalNameTest; +package stream.AttributeLocalNameTest; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6370703.java b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6370703.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6370703.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/Bug6370703.java index 0366b2ef831..f386e5d5a30 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6370703.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6370703.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream; +package stream; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6378422.java b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6378422.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6378422.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/Bug6378422.java index be4e230a51f..f273d1f002e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6378422.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6378422.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream; +package stream; import javax.xml.stream.XMLInputFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6380870.java b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6380870.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6380870.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/Bug6380870.java index 8f8cfa45f98..8eb6a7ffad9 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6380870.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6380870.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream; +package stream; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6489502.java b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6489502.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6489502.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/Bug6489502.java index 1c0793995fa..9cc264a4fd6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6489502.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6489502.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream; +package stream; import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLInputFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6509774.java b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6509774.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6509774.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/Bug6509774.java index 711775fba81..b92f4bf0757 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6509774.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6509774.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream; +package stream; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamConstants; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6688002Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6688002Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6688002Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/Bug6688002Test.java index 594546296b4..57bb97ed144 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6688002Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6688002Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,13 +21,18 @@ * questions. */ -package javax.xml.stream; +package stream; import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.InputStream; import java.io.OutputStream; +import javax.xml.stream.XMLInputFactory; +import javax.xml.stream.XMLOutputFactory; +import javax.xml.stream.XMLStreamReader; +import javax.xml.stream.XMLStreamWriter; + import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6976938.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6976938.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6976938.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/Bug6976938.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6976938Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6976938Test.java similarity index 92% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6976938Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/Bug6976938Test.java index 08be1fe5c51..ac317469cd7 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Bug6976938Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/Bug6976938Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,9 +21,13 @@ * questions. */ -package javax.xml.stream; +package stream; import javax.xml.namespace.QName; +import javax.xml.stream.EventFilter; +import javax.xml.stream.XMLEventReader; +import javax.xml.stream.XMLInputFactory; +import javax.xml.stream.XMLStreamException; import javax.xml.stream.events.XMLEvent; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/CoalesceTest/CoalesceTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/CoalesceTest/CoalesceTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/CoalesceTest/CoalesceTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/CoalesceTest/CoalesceTest.java index 899e2705892..70f286cefbe 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/CoalesceTest/CoalesceTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/CoalesceTest/CoalesceTest.java @@ -20,7 +20,7 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package javax.xml.stream.CoalesceTest; +package stream.CoalesceTest; import java.io.File; import java.io.FileInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/CoalesceTest/coalesce.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/CoalesceTest/coalesce.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/CoalesceTest/coalesce.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/CoalesceTest/coalesce.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EntitiesTest/EntityTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/EntitiesTest/EntityTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EntitiesTest/EntityTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/EntitiesTest/EntityTest.java index 0da8153adce..aa72e3fb139 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EntitiesTest/EntityTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/EntitiesTest/EntityTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.EntitiesTest; +package stream.EntitiesTest; import java.io.IOException; import java.io.InputStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EntitiesTest/testCharRef.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/EntitiesTest/testCharRef.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EntitiesTest/testCharRef.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/EntitiesTest/testCharRef.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EntitiesTest/testCharRef.xml.output b/jaxp/test/javax/xml/jaxp/unittest/stream/EntitiesTest/testCharRef.xml.output similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EntitiesTest/testCharRef.xml.output rename to jaxp/test/javax/xml/jaxp/unittest/stream/EntitiesTest/testCharRef.xml.output diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EventReaderDelegateTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/EventReaderDelegateTest.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EventReaderDelegateTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/EventReaderDelegateTest.java index 77186aea6e1..b314ff7a022 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/EventReaderDelegateTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/EventReaderDelegateTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,14 +21,20 @@ * questions. */ -package javax.xml.stream; +package stream; import org.testng.annotations.Test; import org.testng.Assert; + import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; +import javax.xml.stream.FactoryConfigurationError; +import javax.xml.stream.XMLEventReader; +import javax.xml.stream.XMLInputFactory; +import javax.xml.stream.XMLStreamConstants; +import javax.xml.stream.XMLStreamException; import javax.xml.stream.events.XMLEvent; import javax.xml.stream.util.EventReaderDelegate; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue41Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue41Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue41Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue41Test.java index 87d3ad41587..738f4e3329a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue41Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue41Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.Events; +package stream.EventsTest; import java.io.StringReader; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue48Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue48Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue48Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue48Test.java index b10b6cd92c0..b5673029449 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue48Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue48Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.Events; +package stream.EventsTest; import java.io.StringReader; import java.util.Iterator; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue53Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue53Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue53Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue53Test.java index c9c1deeac13..7193d27e48f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue53Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue53Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.Events; +package stream.EventsTest; import javax.xml.stream.XMLEventFactory; import javax.xml.stream.events.StartDocument; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue58Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue58Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue58Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue58Test.java index 30ce60028dd..3c467411b70 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/Events/Issue58Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/EventsTest/Issue58Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.Events; +package stream.EventsTest; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/FactoryFindTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/FactoryFindTest.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/FactoryFindTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/FactoryFindTest.java index 555c8a8a565..f016df38df4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/FactoryFindTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/FactoryFindTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream; +package stream; import java.io.File; import java.io.FileInputStream; @@ -32,6 +32,9 @@ import java.net.URL; import java.net.URLClassLoader; import java.util.Properties; +import javax.xml.stream.XMLInputFactory; +import javax.xml.stream.XMLOutputFactory; + import org.testng.Assert; import org.testng.annotations.BeforeClass; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/FactoryFindTest.policy b/jaxp/test/javax/xml/jaxp/unittest/stream/FactoryFindTest.policy similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/FactoryFindTest.policy rename to jaxp/test/javax/xml/jaxp/unittest/stream/FactoryFindTest.policy diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/IgnoreExternalDTDTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/IgnoreExternalDTDTest.java similarity index 90% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/IgnoreExternalDTDTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/IgnoreExternalDTDTest.java index 79b6c89603c..5475cba5d6e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/IgnoreExternalDTDTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/IgnoreExternalDTDTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,15 @@ * questions. */ -package javax.xml.stream; +package stream; import java.io.StringReader; +import javax.xml.stream.XMLInputFactory; +import javax.xml.stream.XMLStreamConstants; +import javax.xml.stream.XMLStreamException; +import javax.xml.stream.XMLStreamReader; + import org.testng.annotations.Test; /* diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/ProcessingInstruction/ProcessingInstructionTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/ProcessingInstructionTest/ProcessingInstructionTest.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/ProcessingInstruction/ProcessingInstructionTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/ProcessingInstructionTest/ProcessingInstructionTest.java index 9dc297f9761..1234a37a803 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/ProcessingInstruction/ProcessingInstructionTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/ProcessingInstructionTest/ProcessingInstructionTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.ProcessingInstruction; +package stream.ProcessingInstructionTest; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/StreamReaderDelegateTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/StreamReaderDelegateTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/StreamReaderDelegateTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/StreamReaderDelegateTest.java index b1f76f9672b..d7f9f485fc2 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/StreamReaderDelegateTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/StreamReaderDelegateTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream; +package stream; import java.io.File; import java.io.FileInputStream; @@ -30,6 +30,11 @@ import java.io.InputStream; import java.util.Iterator; import javax.xml.namespace.NamespaceContext; +import javax.xml.stream.FactoryConfigurationError; +import javax.xml.stream.XMLInputFactory; +import javax.xml.stream.XMLStreamConstants; +import javax.xml.stream.XMLStreamException; +import javax.xml.stream.XMLStreamReader; import javax.xml.stream.util.StreamReaderDelegate; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventLocationTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventLocationTest.java similarity index 92% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventLocationTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventLocationTest.java index eccc7ff7d0c..6c760382c58 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventLocationTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventLocationTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,8 +21,10 @@ * questions. */ -package javax.xml.stream; +package stream; +import javax.xml.stream.Location; +import javax.xml.stream.XMLEventFactory; import javax.xml.stream.events.XMLEvent; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6489890.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6489890.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6489890.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6489890.java index 84a49f956c4..0d554808f79 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6489890.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6489890.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLEventReaderTest; +package stream.XMLEventReaderTest; import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLInputFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6555001.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6555001.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6555001.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6555001.java index dfd95e3aca2..566186c4c33 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6555001.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6555001.java @@ -20,7 +20,7 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package javax.xml.stream.XMLEventReaderTest; +package stream.XMLEventReaderTest; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6586466Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6586466Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6586466Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6586466Test.java index c3484426bad..319c50ad7fa 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6586466Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6586466Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLEventReaderTest; +package stream.XMLEventReaderTest; import org.testng.annotations.Test; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6613059Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6613059Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6613059Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6613059Test.java index 73fe8c4c61e..88d0be0c17d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6613059Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6613059Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLEventReaderTest; +package stream.XMLEventReaderTest; import org.testng.annotations.Test; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6668115Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6668115Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6668115Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6668115Test.java index a66ec748058..c56e7569c3c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6668115Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6668115Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLEventReaderTest; +package stream.XMLEventReaderTest; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6846133Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6846133Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6846133Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6846133Test.java index 0470a6bf441..16bf959dc45 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Bug6846133Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Bug6846133Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLEventReaderTest; +package stream.XMLEventReaderTest; import javax.xml.stream.XMLStreamException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Issue40Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Issue40Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Issue40Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Issue40Test.java index 48ecebcae90..161b6e6dcdb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/Issue40Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/Issue40Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLEventReaderTest; +package stream.XMLEventReaderTest; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/bug6613059.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/bug6613059.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/bug6613059.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/bug6613059.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/play.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/play.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/play.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/play.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/play2.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/play2.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/play2.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/play2.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/sgml.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/sgml.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventReaderTest/sgml.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventReaderTest/sgml.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/ReaderToWriterTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/ReaderToWriterTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.java index 9c2df037342..1805e9922f0 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/ReaderToWriterTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLEventWriterTest; +package stream.XMLEventWriterTest; import java.io.ByteArrayOutputStream; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/ReaderToWriterTest.wsdl b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.wsdl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/ReaderToWriterTest.wsdl rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.wsdl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/ReaderToWriterTest.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/ReaderToWriterTest.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/ReaderToWriterTest.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/W2JDLR4002TestService.wsdl.data b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/W2JDLR4002TestService.wsdl.data similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/W2JDLR4002TestService.wsdl.data rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/W2JDLR4002TestService.wsdl.data diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/XMLEventWriterTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/XMLEventWriterTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/XMLEventWriterTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/XMLEventWriterTest.java index d12ca93b4a9..ab076f27d6e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/XMLEventWriterTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/XMLEventWriterTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLEventWriterTest; +package stream.XMLEventWriterTest; import java.io.File; import java.io.FileInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/XMLEventWriterTest.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/XMLEventWriterTest.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/XMLEventWriterTest.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/XMLEventWriterTest.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/merge-1.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/merge-1.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/merge-1.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/merge-1.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/merge-2.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/merge-2.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/merge-2.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/merge-2.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/replace1.txt b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/replace1.txt similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLEventWriterTest/replace1.txt rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLEventWriterTest/replace1.txt diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/Bug6756677Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/Bug6756677Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/Bug6756677Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/Bug6756677Test.java index 569d6c5f5f9..17604ac6d09 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/Bug6756677Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/Bug6756677Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLInputFactoryTest; +package stream.XMLInputFactoryTest; import javax.xml.stream.XMLInputFactory; @@ -36,7 +36,7 @@ public class Bug6756677Test { @Test public void testNewInstance() { - String myFactory = "javax.xml.stream.XMLInputFactoryTest.MyInputFactory"; + String myFactory = "stream.XMLInputFactoryTest.MyInputFactory"; try { System.setProperty("MyInputFactory", myFactory); XMLInputFactory xif = XMLInputFactory.newInstance("MyInputFactory", null); @@ -52,7 +52,7 @@ public class Bug6756677Test { // newFactory was added in StAX 1.2 @Test public void testNewFactory() { - String myFactory = "javax.xml.stream.XMLInputFactoryTest.MyInputFactory"; + String myFactory = "stream.XMLInputFactoryTest.MyInputFactory"; ClassLoader cl = null; try { System.setProperty("MyInputFactory", myFactory); diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/Bug6909759Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/Bug6909759Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/Bug6909759Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/Bug6909759Test.java index 1c699c83323..36cc136dadd 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/Bug6909759Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/Bug6909759Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLInputFactoryTest; +package stream.XMLInputFactoryTest; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/IssueTracker38.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/IssueTracker38.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/IssueTracker38.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/IssueTracker38.java index f468d7a0f41..448a854d45f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/IssueTracker38.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/IssueTracker38.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLInputFactoryTest; +package stream.XMLInputFactoryTest; import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLInputFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/MyInputFactory.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/MyInputFactory.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/MyInputFactory.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/MyInputFactory.java index 581c122585c..551d3f0f8d2 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/MyInputFactory.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/MyInputFactory.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLInputFactoryTest; +package stream.XMLInputFactoryTest; import java.io.InputStream; import java.io.Reader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/play.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/play.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLInputFactoryTest/play.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLInputFactoryTest/play.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/Bug6846132Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/Bug6846132Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/Bug6846132Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/Bug6846132Test.java index 9e5093d35e6..15afdafd751 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/Bug6846132Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/Bug6846132Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLOutputFactoryTest; +package stream.XMLOutputFactoryTest; import javax.xml.stream.XMLEventWriter; import javax.xml.stream.XMLOutputFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/DuplicateNSDeclarationTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/DuplicateNSDeclarationTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/DuplicateNSDeclarationTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/DuplicateNSDeclarationTest.java index 64517c363ed..884c9235d24 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/DuplicateNSDeclarationTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/DuplicateNSDeclarationTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLOutputFactoryTest; +package stream.XMLOutputFactoryTest; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/StreamResultTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/StreamResultTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/StreamResultTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/StreamResultTest.java index 368c80c1b0d..96d928c6572 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLOutputFactoryTest/StreamResultTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLOutputFactoryTest/StreamResultTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLOutputFactoryTest; +package stream.XMLOutputFactoryTest; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/XMLResolverTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/XMLResolverTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/XMLResolverTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/XMLResolverTest.java index 9d4ca307fff..1a0780398d6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/XMLResolverTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/XMLResolverTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLResolverTest; +package stream.XMLResolverTest; import java.io.File; import java.io.FileInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/XMLResolverTest.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/XMLResolverTest.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/XMLResolverTest.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/XMLResolverTest.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/replace1.txt b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/replace1.txt similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/replace1.txt rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/replace1.txt diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/replace2.txt b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/replace2.txt similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLResolverTest/replace2.txt rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLResolverTest/replace2.txt diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamExceptionTest/ExceptionTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamExceptionTest/ExceptionTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamExceptionTest/ExceptionTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamExceptionTest/ExceptionTest.java index a64d93f1dd8..3e0dda7d042 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamExceptionTest/ExceptionTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamExceptionTest/ExceptionTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamExceptionTest; +package stream.XMLStreamExceptionTest; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/Bug6481615.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/Bug6481615.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/Bug6481615.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/Bug6481615.java index 25bc88d22d6..1aa221969d3 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/Bug6481615.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/Bug6481615.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamFilterTest; +package stream.XMLStreamFilterTest; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/Bug6481678.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/Bug6481678.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/Bug6481678.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/Bug6481678.java index 1f697b775a5..9b3273ac09e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/Bug6481678.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/Bug6481678.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamFilterTest; +package stream.XMLStreamFilterTest; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/HasNextTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/HasNextTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/HasNextTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/HasNextTest.java index 5625f78177f..3df73ae0472 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/HasNextTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/HasNextTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamFilterTest; +package stream.XMLStreamFilterTest; import javax.xml.stream.StreamFilter; import javax.xml.stream.XMLInputFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/HasNextTest.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/HasNextTest.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/HasNextTest.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/HasNextTest.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/HasNextTypeFilter.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/HasNextTypeFilter.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/HasNextTypeFilter.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/HasNextTypeFilter.java index 95b3f505a27..1fd6e20fe08 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamFilterTest/HasNextTypeFilter.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamFilterTest/HasNextTypeFilter.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamFilterTest; +package stream.XMLStreamFilterTest; import javax.xml.stream.EventFilter; import javax.xml.stream.StreamFilter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/BOMTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/BOMTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/BOMTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/BOMTest.java index eb7c3b44770..b253e95b1b0 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/BOMTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/BOMTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6388460.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6388460.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6388460.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6388460.java index 4d6b58ad41a..c73348c744c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6388460.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6388460.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6472982Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6472982Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6472982Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6472982Test.java index 830718fe175..c22dde736de 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6472982Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6472982Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6767322.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6767322.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6767322.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6767322.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6767322Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6767322Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6767322Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6767322Test.java index fe0da552cc8..b9ffde7fefd 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6767322Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6767322Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.ByteArrayInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6847819Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6847819Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6847819Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6847819Test.java index c9211c06781..2480b727d90 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Bug6847819Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Bug6847819Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import org.testng.annotations.Test; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/BugTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/BugTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/BugTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/BugTest.java index 2499a07db4a..15e01a21896 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/BugTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/BugTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/DefaultAttributeTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/DefaultAttributeTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/DefaultAttributeTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/DefaultAttributeTest.java index 33e8c5b9353..6ce3bd4568d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/DefaultAttributeTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/DefaultAttributeTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.util.Iterator; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/DoubleXmlnsTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/DoubleXmlnsTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/DoubleXmlnsTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/DoubleXmlnsTest.java index da73bd6cc91..df1ced6bb61 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/DoubleXmlnsTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/DoubleXmlnsTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.dtd b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/ExternalDTD.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.dtd rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/ExternalDTD.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/ExternalDTD.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/ExternalDTD.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/ExternalDTD.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Hello.wsdl.data b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Hello.wsdl.data similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Hello.wsdl.data rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Hello.wsdl.data diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IsValidatingTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IsValidatingTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IsValidatingTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IsValidatingTest.java index dcd2d39b2bb..06dc2665a7f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IsValidatingTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IsValidatingTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IsValidatingTest.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IsValidatingTest.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IsValidatingTest.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IsValidatingTest.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IsValidatingTestInternalSubset.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IsValidatingTestInternalSubset.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IsValidatingTestInternalSubset.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IsValidatingTestInternalSubset.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Issue44Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Issue44Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Issue44Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Issue44Test.java index 47ed0bc9ff9..082aa87d0c4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Issue44Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Issue44Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Issue47Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Issue47Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Issue47Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Issue47Test.java index 736971d1f5a..7d868423677 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Issue47Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Issue47Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker24.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker24.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker24.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker24.java index 0d2f723fcd1..dd0fb1a0bf9 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker24.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker24.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker35.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker35.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker35.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker35.java index 2f93c9810b6..1aa8d6b4c7c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker35.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker35.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker70.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker70.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker70.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker70.java index ed9dc284943..c616a3aa669 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker70.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker70.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.File; import java.io.FileInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker70.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker70.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/IssueTracker70.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/IssueTracker70.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req5.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req5.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req5.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req5.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req5Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req5Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req5Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req5Test.java index c58fd03908d..50dfed8a487 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req5Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req5Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamConstants; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req8.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req8.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req8.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req8.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req8Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req8Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req8Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req8Test.java index c39106f24bc..d1c007402ff 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/Jsr173MR1Req8Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/Jsr173MR1Req8Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamConstants; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/NamespaceTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/NamespaceTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/NamespaceTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/NamespaceTest.java index 75d32705daf..5c9440d0998 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/NamespaceTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/NamespaceTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/StreamReaderTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/StreamReaderTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/StreamReaderTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/StreamReaderTest.java index 8b7475db66a..cbaa37863cf 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/StreamReaderTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/StreamReaderTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamConstants; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/SupportDTDTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/SupportDTDTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/SupportDTDTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/SupportDTDTest.java index 7b8e28e8a01..1a2e325fdd2 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/SupportDTDTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/SupportDTDTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import java.io.File; import java.io.FileInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/UTF16-BE.wsdl.data b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/UTF16-BE.wsdl.data similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/UTF16-BE.wsdl.data rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/UTF16-BE.wsdl.data diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/UTF8-BOM.xml.data b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/UTF8-BOM.xml.data similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/UTF8-BOM.xml.data rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/UTF8-BOM.xml.data diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/VoiceXMLDTDTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/VoiceXMLDTDTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/VoiceXMLDTDTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/VoiceXMLDTDTest.java index 5e193f667fa..5befcb70609 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/VoiceXMLDTDTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/VoiceXMLDTDTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import javax.xml.stream.XMLInputFactory; import javax.xml.stream.XMLStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/XML11Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/XML11Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/XML11Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/XML11Test.java index 2293aaca37a..ac98279175d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/XML11Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/XML11Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamReaderTest; +package stream.XMLStreamReaderTest; import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLInputFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/XMLSchema.dtd b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/XMLSchema.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/XMLSchema.dtd rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/XMLSchema.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/XMLSchema.xsd b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/XMLSchema.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/XMLSchema.xsd rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/XMLSchema.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/datatypes.dtd b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/datatypes.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/datatypes.dtd rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/datatypes.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/report.dtd b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/report.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/report.dtd rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/report.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/sgml.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/sgml.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/sgml.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/sgml.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/voicexml.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/voicexml.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/voicexml.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/voicexml.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/vxml.dtd b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/vxml.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/vxml.dtd rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/vxml.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/xml11.xml.data b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/xml11.xml.data similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamReaderTest/xml11.xml.data rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamReaderTest/xml11.xml.data diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/AttributeEscapeTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/AttributeEscapeTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/AttributeEscapeTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/AttributeEscapeTest.java index 0cd9466dbf3..7a426c93f8d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/AttributeEscapeTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/AttributeEscapeTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.IOException; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6452107.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6452107.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6452107.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6452107.java index 2d45aa2f603..b3148c60502 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6452107.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6452107.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.ByteArrayOutputStream; import java.io.OutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6600882Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6600882Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6600882Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6600882Test.java index 3b22705100a..f34b559f86c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6600882Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6600882Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6675332Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6675332Test.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6675332Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6675332Test.java index a22580670a0..e52fb4acbd4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug6675332Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug6675332Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug7037352Test.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug7037352Test.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug7037352Test.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug7037352Test.java index a15b7a6142f..7c1e50264d5 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/Bug7037352Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/Bug7037352Test.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import javax.xml.XMLConstants; import javax.xml.namespace.NamespaceContext; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/DOMUtil.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/DOMUtil.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/DOMUtil.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/DOMUtil.java index 674e00dc193..f59ef011018 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/DOMUtil.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/DOMUtil.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.IOException; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/DomUtilTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/DomUtilTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/DomUtilTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/DomUtilTest.java index 76d5c981bd3..d2c2491e36e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/DomUtilTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/DomUtilTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.ByteArrayOutputStream; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/EmptyElementTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/EmptyElementTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/EmptyElementTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/EmptyElementTest.java index 475c3edb323..b813ef5607c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/EmptyElementTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/EmptyElementTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/EncodingTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/EncodingTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/EncodingTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/EncodingTest.java index d79a2331374..50973152487 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/EncodingTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/EncodingTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/NamespaceTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/NamespaceTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/NamespaceTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/NamespaceTest.java index 7f036defb2f..24d89a08ba6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/NamespaceTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/NamespaceTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/NullUriDetectionTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/NullUriDetectionTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/NullUriDetectionTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/NullUriDetectionTest.java index 9dbb40cec11..3eb0222cbaf 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/NullUriDetectionTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/NullUriDetectionTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/SqeLinuxTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/SqeLinuxTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/SqeLinuxTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/SqeLinuxTest.java index fa53214f633..90ca0f313a2 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/SqeLinuxTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/SqeLinuxTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/UnprefixedNameTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/UnprefixedNameTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/UnprefixedNameTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/UnprefixedNameTest.java index c4174cf10fa..5e05fd82394 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/UnprefixedNameTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/UnprefixedNameTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import javax.xml.stream.XMLOutputFactory; import javax.xml.stream.XMLStreamException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/WriterTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/WriterTest.java similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/WriterTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/WriterTest.java index 05f777d9327..adb43d95e0a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/WriterTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/WriterTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.FileInputStream; import java.io.FileOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/XMLStreamWriterTest.java b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/XMLStreamWriterTest.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/XMLStreamWriterTest.java rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/XMLStreamWriterTest.java index 4fa782130f9..2bc71a315ce 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/XMLStreamWriterTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/XMLStreamWriterTest.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.stream.XMLStreamWriterTest; +package stream.XMLStreamWriterTest; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/message_12.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/message_12.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/message_12.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/message_12.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testEight.xml.org b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testEight.xml.org similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testEight.xml.org rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testEight.xml.org diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testFive.xml.org b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testFive.xml.org similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testFive.xml.org rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testFive.xml.org diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testFour.xml.org b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testFour.xml.org similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testFour.xml.org rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testFour.xml.org diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testOne.xml.org b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testOne.xml.org similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testOne.xml.org rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testOne.xml.org diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testSeven.xml.org b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testSeven.xml.org similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testSeven.xml.org rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testSeven.xml.org diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testSix.xml.org b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testSix.xml.org similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testSix.xml.org rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testSix.xml.org diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testThree.xml.org b/jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testThree.xml.org similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/XMLStreamWriterTest/testThree.xml.org rename to jaxp/test/javax/xml/jaxp/unittest/stream/XMLStreamWriterTest/testThree.xml.org diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/basic-form.vxml b/jaxp/test/javax/xml/jaxp/unittest/stream/basic-form.vxml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/basic-form.vxml rename to jaxp/test/javax/xml/jaxp/unittest/stream/basic-form.vxml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/report.dtd b/jaxp/test/javax/xml/jaxp/unittest/stream/report.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/report.dtd rename to jaxp/test/javax/xml/jaxp/unittest/stream/report.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/sgml-bad-systemId.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/sgml-bad-systemId.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/sgml-bad-systemId.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/sgml-bad-systemId.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/sgml.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/sgml.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/sgml.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/sgml.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/sgml_Bug6509774.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/sgml_Bug6509774.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/sgml_Bug6509774.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/sgml_Bug6509774.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/testfile1.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/testfile1.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/testfile1.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/testfile1.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/testfile2.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/testfile2.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/testfile2.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/testfile2.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/testfile3.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/testfile3.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/testfile3.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/testfile3.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/testfile4.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/testfile4.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/testfile4.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/testfile4.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/toys.xml b/jaxp/test/javax/xml/jaxp/unittest/stream/toys.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/toys.xml rename to jaxp/test/javax/xml/jaxp/unittest/stream/toys.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/vxml.dtd b/jaxp/test/javax/xml/jaxp/unittest/stream/vxml.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/stream/vxml.dtd rename to jaxp/test/javax/xml/jaxp/unittest/stream/vxml.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/5368141.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/5368141.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/5368141.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/5368141.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341.dtd b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341.dtd rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341.out b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341.out similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341.out rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341.out diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341Test.java index 605baf81ef5..f0dc71feb5a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; import java.io.FileInputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341_golden.dtd b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341_golden.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341_golden.dtd rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341_golden.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341_golden.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341_golden.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4693341_golden.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug4693341_golden.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4892774.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4892774.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4892774.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug4892774.java index c4b54f80cd0..e65bdaf6058 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug4892774.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug4892774.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; @@ -32,16 +32,17 @@ import javax.xml.transform.dom.DOMResult; import javax.xml.transform.sax.SAXResult; import javax.xml.transform.stax.StAXResult; import javax.xml.transform.stream.StreamResult; -import javax.xml.transform.util.DOMUtil; -import javax.xml.transform.util.SAXUtil; -import javax.xml.transform.util.StAXUtil; -import javax.xml.transform.util.StreamUtil; import org.testng.Assert; import org.testng.annotations.AfterMethod; import org.testng.annotations.BeforeMethod; import org.testng.annotations.Test; +import transform.util.DOMUtil; +import transform.util.SAXUtil; +import transform.util.StAXUtil; +import transform.util.StreamUtil; + /* * @bug 4892774 * @summary Test identity transformer with all possible types of Source and Result combinations for doucment version and encoding information. diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug5073477.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug5073477.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug5073477.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug5073477.java index 7d061c2c2c0..4d406747c8a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug5073477.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug5073477.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug5073477.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug5073477.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug5073477.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug5073477.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6175602.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6175602.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6175602.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6175602.java index ae568341344..bb3c7d61a29 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6175602.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6175602.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491.java index 9b508796ac9..eaaa3f77908 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491_2.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491_2.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6206491_2.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6206491_2.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6216226Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6216226Test.java similarity index 91% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6216226Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6216226Test.java index ec856b7116f..275fd8c5af1 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6216226Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6216226Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,13 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; import java.io.StringReader; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6311448.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6311448.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6311448.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6311448.java index 5b395170918..db6925d00e4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6311448.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6311448.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6384805.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6384805.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6384805.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6384805.java index c59b9555f0a..680398bf037 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6384805.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6384805.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.util.Iterator; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6465722.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6465722.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6465722.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6465722.java index 3a261092f0e..80d5139e7c3 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6465722.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6465722.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringReader; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6467808.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6467808.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6467808.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6467808.java index e32947c1814..7a7fb1aa074 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6467808.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6467808.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6490380.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6490380.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6490380.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6490380.java index 5ec65e81110..4385fb245bf 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6490380.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6490380.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringWriter; import java.net.URL; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6490921.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6490921.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6490921.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6490921.java index b8ec881fdc6..38f72d5a89f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6490921.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6490921.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.IOException; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6505031.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6505031.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6505031.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6505031.java index 931bf6dc34b..d3fa4fd30f4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6505031.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6505031.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringWriter; import java.util.HashMap; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6513892.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6513892.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6513892.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6513892.java index ac9fab16438..da26d64e2ec 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6513892.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6513892.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6537167.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6537167.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6537167.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6537167.java index f64c67213b5..c75ff71b584 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6537167.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6537167.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6540545.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6540545.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6540545.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6540545.java index e9ddaee53a7..2c76ad694fa 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6540545.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6540545.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6559595.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6559595.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6559595.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6559595.java index 1c568b1b86c..162c92a2e8a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6559595.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6559595.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringReader; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6565260.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6565260.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6565260.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6565260.java index d6a548bff68..3b0f6361b1d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6565260.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6565260.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6940416.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6940416.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6940416.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Bug6940416.java index 5c881e10089..41f7279506a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Bug6940416.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Bug6940416.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.FileInputStream; import java.io.FileNotFoundException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/BugDB12665704.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/BugDB12665704.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/BugDB12665704.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/BugDB12665704.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/BugDB12665704.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/BugDB12665704.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/BugDB12665704.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/BugDB12665704.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/BugDB12665704Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/BugDB12665704Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/BugDB12665704Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/BugDB12665704Test.java index 6099296b73f..5f5fa0e8fdd 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/BugDB12665704Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/BugDB12665704Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.BufferedReader; import java.io.ByteArrayInputStream; @@ -33,6 +33,12 @@ import java.io.InputStream; import java.io.StringReader; import java.io.StringWriter; +import javax.xml.transform.Result; +import javax.xml.transform.Source; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerConfigurationException; +import javax.xml.transform.TransformerException; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6401137.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6401137.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6401137.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6401137.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6401137.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6401137.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6401137.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6401137.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6401137Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6401137Test.java similarity index 92% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6401137Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6401137Test.java index c74fb355e89..7a2c5427633 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6401137Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6401137Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; @@ -29,6 +29,10 @@ import java.io.File; import java.io.FileReader; import java.io.InputStream; +import javax.xml.transform.Result; +import javax.xml.transform.Source; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6551600.policy b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6551600.policy similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6551600.policy rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6551600.policy diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6551600Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6551600Test.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6551600Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6551600Test.java index 4211bdf5d8d..f364f5d2332 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6551600Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6551600Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,12 +21,14 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.stream.StreamResult; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6577667.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6577667.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6577667.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6577667.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6577667Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6577667Test.java similarity index 90% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6577667Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6577667Test.java index b6039c120e1..70767a47d3b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6577667Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6577667Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,12 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.InputStream; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamSource; import org.testng.Assert; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6652519Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6652519Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6652519Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6652519Test.java index afec16489fd..9be065fb038 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6652519Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6652519Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,12 +21,14 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6689809Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6689809Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6689809Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6689809Test.java index dec6b4eb799..91da2f6d4fd 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6689809Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6689809Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,11 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.CharArrayWriter; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829Inc.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829Inc.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829Inc.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829Inc.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829Test.java similarity index 91% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829Test.java index 9a77ed1a1bf..60de73f31e0 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6905829Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6905829Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,13 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; import java.io.StringWriter; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6935697.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6935697.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6935697.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6935697.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6935697Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697Test.java similarity index 89% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6935697Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697Test.java index 646043feaa6..6742d3fe47e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6935697Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6935697Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,15 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.FileOutputStream; +import javax.xml.transform.Result; +import javax.xml.transform.Source; +import javax.xml.transform.Templates; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6941869.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6941869.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6941869.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6941869.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6941869.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6941869.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6941869.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6941869.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6941869Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6941869Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6941869Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6941869Test.java index d2e6eba9b41..07a18b6ad14 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6941869Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6941869Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,13 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.File; import java.io.StringWriter; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6957215.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6957215.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6957215.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6957215.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6957215.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6957215.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6957215.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6957215.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6957215Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6957215Test.java similarity index 88% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6957215Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR6957215Test.java index 2a8460a10a7..3d9a74012b1 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR6957215Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR6957215Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,12 +21,20 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.StringWriter; +import javax.xml.transform.Result; +import javax.xml.transform.Source; +import javax.xml.transform.SourceLocator; +import javax.xml.transform.Templates; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerConfigurationException; +import javax.xml.transform.TransformerException; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR7098746.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/CR7098746.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR7098746.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR7098746.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR7098746.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/CR7098746.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR7098746.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR7098746.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR7098746Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/CR7098746Test.java similarity index 90% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR7098746Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/CR7098746Test.java index 5b3e71c18a2..d67a58ad847 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/CR7098746Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/CR7098746Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,15 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringWriter; +import javax.xml.transform.Result; +import javax.xml.transform.Source; +import javax.xml.transform.Templates; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/DOMResultTest.java b/jaxp/test/javax/xml/jaxp/unittest/transform/DOMResultTest.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/DOMResultTest.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/DOMResultTest.java index b08d532bd09..b21fadd8724 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/DOMResultTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/DOMResultTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,11 @@ * questions. */ -package javax.xml.transform; +package transform; import org.testng.annotations.Test; import org.testng.Assert; + import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException; @@ -33,6 +34,10 @@ import java.io.IOException; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; +import javax.xml.transform.Transformer; +import javax.xml.transform.TransformerConfigurationException; +import javax.xml.transform.TransformerException; +import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMResult; import javax.xml.transform.dom.DOMSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/DocumentExtFunc.java b/jaxp/test/javax/xml/jaxp/unittest/transform/DocumentExtFunc.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/DocumentExtFunc.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/DocumentExtFunc.java index 44976edcc1a..81227c7d691 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/DocumentExtFunc.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/DocumentExtFunc.java @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import org.w3c.dom.Node; import org.w3c.dom.NodeList; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/FactoryFindTest.java b/jaxp/test/javax/xml/jaxp/unittest/transform/FactoryFindTest.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/FactoryFindTest.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/FactoryFindTest.java index 370f0fff2ac..c0f17b8d5c0 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/FactoryFindTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/FactoryFindTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,13 @@ * questions. */ -package javax.xml.transform; +package transform; import java.net.URL; import java.net.URLClassLoader; +import javax.xml.transform.TransformerFactory; + import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2204.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/Issue2204.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2204.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/Issue2204.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2204.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/Issue2204.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2204.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/Issue2204.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2204Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Issue2204Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2204Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Issue2204Test.java index 35bcab3dc23..b0912eb8479 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2204Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Issue2204Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2290.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/Issue2290.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2290.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/Issue2290.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2290Test.java b/jaxp/test/javax/xml/jaxp/unittest/transform/Issue2290Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2290Test.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/Issue2290Test.java index 1c63d974bb0..b2be968bea6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/Issue2290Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/Issue2290Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform; +package transform; import java.io.StringReader; import java.io.StringWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/MsWordXMLImport.xsl.data b/jaxp/test/javax/xml/jaxp/unittest/transform/MsWordXMLImport.xsl.data similarity index 99% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/MsWordXMLImport.xsl.data rename to jaxp/test/javax/xml/jaxp/unittest/transform/MsWordXMLImport.xsl.data index 9ba08025521..07e954144c8 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/MsWordXMLImport.xsl.data +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/MsWordXMLImport.xsl.data @@ -1,7 +1,7 @@ " - + "" + + "" + "" - + "" + + "" + ""; static final String documentTesteExpectedResult = "" diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/attribset27.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/attribset27.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/attribset27.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/attribset27.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/attribset27.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/attribset27.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/attribset27.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/attribset27.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/catalog.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/catalog.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/catalog.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/catalog.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/catalog.xsd b/jaxp/test/javax/xml/jaxp/unittest/transform/catalog.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/catalog.xsd rename to jaxp/test/javax/xml/jaxp/unittest/transform/catalog.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/catalog_10.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/catalog_10.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/catalog_10.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/catalog_10.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/config.dtd b/jaxp/test/javax/xml/jaxp/unittest/transform/config.dtd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/config.dtd rename to jaxp/test/javax/xml/jaxp/unittest/transform/config.dtd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/config.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/config.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/config.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/config.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/default-layout.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/default-layout.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/default-layout.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/default-layout.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/global-variables.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/global-variables.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/global-variables.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/global-variables.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/global.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/global.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/global.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/global.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/home.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/home.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/home.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/home.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/in.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/in.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/in.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/in.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/inner.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/inner.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/inner.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/inner.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/logon.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/logon.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/logon.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/logon.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/maps.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/maps.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/maps.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/maps.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/msgAttach.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/msgAttach.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/msgAttach.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/msgAttach.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/numbering63.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/numbering63.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/numbering63.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/numbering63.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/numbering63.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/numbering63.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/numbering63.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/numbering63.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/outer.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/outer.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/outer.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/outer.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/redirect.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/redirect.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/redirect.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/redirect.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/redirect.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/redirect.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/redirect.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/redirect.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/sax/Bug6451633.java b/jaxp/test/javax/xml/jaxp/unittest/transform/sax/Bug6451633.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/sax/Bug6451633.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/sax/Bug6451633.java index 855fa6ee1e6..a299656033e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/sax/Bug6451633.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/sax/Bug6451633.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform.sax; +package transform.sax; import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMResult; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/src.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/src.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/src.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/src.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/template.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/template.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/template.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/template.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/tigertest-in.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/tigertest-in.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/tigertest-in.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/tigertest-in.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/tigertest.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/tigertest.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/tigertest.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/tigertest.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/tmp.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/tmp.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/tmp.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/tmp.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/toys.xml b/jaxp/test/javax/xml/jaxp/unittest/transform/toys.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/toys.xml rename to jaxp/test/javax/xml/jaxp/unittest/transform/toys.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/transform.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/transform.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/transform.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/transform.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/upload-media-form.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/upload-media-form.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/upload-media-form.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/upload-media-form.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/upload-media.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/upload-media.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/upload-media.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/upload-media.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util.xsl b/jaxp/test/javax/xml/jaxp/unittest/transform/util.xsl similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util.xsl rename to jaxp/test/javax/xml/jaxp/unittest/transform/util.xsl diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/DOMUtil.java b/jaxp/test/javax/xml/jaxp/unittest/transform/util/DOMUtil.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/DOMUtil.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/util/DOMUtil.java index 1881299a7c6..988da74f834 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/DOMUtil.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/util/DOMUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform.util; +package transform.util; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/SAXUtil.java b/jaxp/test/javax/xml/jaxp/unittest/transform/util/SAXUtil.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/SAXUtil.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/util/SAXUtil.java index fd7421c23ff..9e257ebf9a6 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/SAXUtil.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/util/SAXUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,19 +21,20 @@ * questions. */ -package javax.xml.transform.util; +package transform.util; import java.io.InputStream; import javax.xml.transform.Result; import javax.xml.transform.Source; -import javax.xml.transform.VersionDefaultHandler; import javax.xml.transform.sax.SAXResult; import javax.xml.transform.sax.SAXSource; import org.testng.Assert; import org.xml.sax.InputSource; +import transform.VersionDefaultHandler; + public class SAXUtil extends TransformerUtil { private static SAXUtil instance = null; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/StAXUtil.java b/jaxp/test/javax/xml/jaxp/unittest/transform/util/StAXUtil.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/StAXUtil.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/util/StAXUtil.java index 6c17ffa7829..26374d76ab0 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/StAXUtil.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/util/StAXUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform.util; +package transform.util; import java.io.FileInputStream; import java.io.FileOutputStream; @@ -34,13 +34,14 @@ import javax.xml.stream.XMLStreamReader; import javax.xml.stream.XMLStreamWriter; import javax.xml.transform.Result; import javax.xml.transform.Source; -import javax.xml.transform.TransformerUtilFactory; -import javax.xml.transform.VersionEventWriter; import javax.xml.transform.stax.StAXResult; import javax.xml.transform.stax.StAXSource; import org.testng.Assert; +import transform.TransformerUtilFactory; +import transform.VersionEventWriter; + public class StAXUtil extends TransformerUtil { private static StAXUtil instance = null; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/StreamUtil.java b/jaxp/test/javax/xml/jaxp/unittest/transform/util/StreamUtil.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/StreamUtil.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/util/StreamUtil.java index 7bbf93f4359..019c2f16b1e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/StreamUtil.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/util/StreamUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform.util; +package transform.util; import java.io.File; import java.io.FileInputStream; @@ -33,13 +33,14 @@ import javax.xml.parsers.SAXParser; import javax.xml.parsers.SAXParserFactory; import javax.xml.transform.Result; import javax.xml.transform.Source; -import javax.xml.transform.VersionDefaultHandler; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; import org.testng.Assert; import org.w3c.dom.Document; +import transform.VersionDefaultHandler; + public class StreamUtil extends TransformerUtil { DocumentBuilder docBuilder = null; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/TransformerUtil.java b/jaxp/test/javax/xml/jaxp/unittest/transform/util/TransformerUtil.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/TransformerUtil.java rename to jaxp/test/javax/xml/jaxp/unittest/transform/util/TransformerUtil.java index 5a92fe77069..61d7bfe09db 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/transform/util/TransformerUtil.java +++ b/jaxp/test/javax/xml/jaxp/unittest/transform/util/TransformerUtil.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.transform.util; +package transform.util; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/6773084.policy b/jaxp/test/javax/xml/jaxp/unittest/validation/6773084.policy similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/6773084.policy rename to jaxp/test/javax/xml/jaxp/unittest/validation/6773084.policy diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/AnyElementTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/AnyElementTest.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/AnyElementTest.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/AnyElementTest.java index f37f0bfab28..a1218b1616e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/AnyElementTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/AnyElementTest.java @@ -20,7 +20,7 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package javax.xml.validation; +package validation; /* * @bug 8080907 @@ -31,6 +31,8 @@ import static javax.xml.XMLConstants.W3C_XML_SCHEMA_NS_URI; import java.net.URISyntaxException; import javax.xml.transform.stream.StreamSource; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.annotations.BeforeClass; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966232.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966232.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966232.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966232.java index 925bf2c9123..1e9d473fb5c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966232.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966232.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.transform.dom.DOMSource; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966254.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966254.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966254.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966254.java index 6d1f0ad2374..e081f37f072 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966254.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966254.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.transform.stream.StreamSource; import javax.xml.validation.Schema; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966254.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966254.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966254.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966254.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966254.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966254.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4966254.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4966254.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969042.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969042.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969042.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969042.java index 71ad30d61c9..d04395e6615 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969042.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969042.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969089.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969089.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969089.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969089.java index 32477a246b5..4b7f0b53078 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969089.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969089.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969110.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969110.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969110.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969110.java index f9fb0f4adb9..ace534e2c53 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969110.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969110.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; import javax.xml.validation.ValidatorHandler; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969689.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969689.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969689.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969689.java index 6790321bdbf..85cc249fefb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969689.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969689.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969692.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969692.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969692.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969692.java index e19372242a3..2e146123869 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969692.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969692.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; import javax.xml.validation.Validator; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969693.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969693.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969693.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969693.java index 026da4a3ebf..18512dde195 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969693.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969693.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; import javax.xml.validation.Validator; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969695.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969695.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969695.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969695.java index 39ea1b7be03..db6941673d5 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969695.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969695.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969732.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969732.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969732.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969732.java index 5f298af454d..3fe2dcfb9bf 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4969732.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4969732.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970380.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970380.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970380.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970380.java index b9a0656b002..b9d055547e5 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970380.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970380.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; import javax.xml.validation.ValidatorHandler; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970383.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970383.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970383.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970383.java index 3ac15277ec4..f53615333c4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970383.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970383.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; import javax.xml.validation.ValidatorHandler; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970400.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970400.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970400.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970400.java index d0c57b20765..c4575679ca5 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970400.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970400.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; import javax.xml.validation.ValidatorHandler; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970402.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970402.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970402.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970402.java index 55f3d1d9d3d..e66e01062ed 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970402.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970402.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970951.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970951.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970951.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970951.java index 4f986a8920a..e033d499078 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4970951.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4970951.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4971605.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4971605.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4971605.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4971605.java index 09cd588489a..566f17c0c1a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4971605.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4971605.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4971607.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4971607.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4971607.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4971607.java index e33b040a778..870e7a7bc38 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4971607.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4971607.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; import javax.xml.validation.ValidatorHandler; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4972882.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4972882.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4972882.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4972882.java index 8e84e840626..8b3ce663eca 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4972882.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4972882.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.XMLConstants; import javax.xml.parsers.DocumentBuilder; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4986844.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4986844.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4986844.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4986844.java index 73049545f24..f98f6d5b768 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4986844.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4986844.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4986844.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4986844.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4986844.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4986844.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4987574.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4987574.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4987574.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4987574.java index a56806a61c8..d479455524a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4987574.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4987574.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import java.io.FileWriter; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988267.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988267.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988267.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988267.java index 4c372f5ad7a..ef57585545d 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988267.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988267.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988267.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988267.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988267.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988267.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988268.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988268.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988268.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988268.java index d99960674b0..0005f17e51c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988268.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988268.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988268.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988268.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988268.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988268.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988387.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988387.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988387.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988387.java index 9ca25216ec6..b7b889b90fb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988387.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988387.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988387.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988387.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4988387.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4988387.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4996446.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4996446.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4996446.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4996446.java index e381e65f59c..4ea0afe938e 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4996446.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4996446.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.net.URL; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4996446.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4996446.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4996446.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4996446.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4997818.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4997818.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4997818.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug4997818.java index 7330d49358b..b46bf36eea7 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug4997818.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug4997818.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5011500.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug5011500.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5011500.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug5011500.java index bc65b4de23b..6d79fb2cc7b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5011500.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug5011500.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.ByteArrayInputStream; import java.io.InputStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5072946.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug5072946.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5072946.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug5072946.java index 327a387e51a..9769d1dc8f3 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5072946.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug5072946.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.XMLConstants; import javax.xml.parsers.DocumentBuilder; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5072946.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug5072946.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5072946.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug5072946.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5072946.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug5072946.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug5072946.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug5072946.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6378043.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6378043.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6378043.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6378043.java index 6078724f89c..c561bb12ecf 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6378043.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6378043.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.validation.Schema; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6449797.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6449797.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6449797.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6449797.java index ca24b94281f..3b797edc0b3 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6449797.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6449797.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -20,7 +20,7 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ -package javax.xml.validation; +package validation; import javax.xml.XMLConstants; import javax.xml.validation.SchemaFactory; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6449797.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6449797.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6449797.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6449797.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6457662.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6457662.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6457662.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6457662.java index 84bfa2681f3..3518a0e7267 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6457662.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6457662.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import java.io.FileOutputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6467424.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6467424.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6467424.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6467424.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6467424.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6467424.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6467424.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6467424.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6467424Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6467424Test.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6467424Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6467424Test.java index 76cf2a30699..4ebce561e3f 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6467424Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6467424Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import java.io.IOException; @@ -38,6 +38,9 @@ import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMResult; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.stream.StreamResult; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6483188.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6483188.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6483188.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6483188.java index 848a545bec8..f5947130ee7 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6483188.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6483188.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.net.URL; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6493687.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6493687.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6493687.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6493687.java index 5034d3d29f6..2da6c45a1fb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6493687.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6493687.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import org.testng.annotations.Test; import org.w3c.dom.Document; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6493687.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6493687.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6493687.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6493687.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6493687.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6493687.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6493687.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6493687.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6509668.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6509668.java similarity index 98% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6509668.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6509668.java index 094c8a6eac9..2c9906c9711 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6509668.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6509668.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.ByteArrayInputStream; import java.io.IOException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6526547.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6526547.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6526547.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6526547.java index dfbf550e560..e737d7514fc 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6526547.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6526547.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import javax.xml.XMLConstants; import javax.xml.parsers.DocumentBuilder; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6526547.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6526547.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6526547.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6526547.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6526547.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6526547.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6526547.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6526547.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6531160.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6531160.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6531160.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6531160.java index 7c682dbd4fb..53cea01f5d8 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6531160.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6531160.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.StringReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6695843.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6695843.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6695843.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6695843.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6695843.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6695843.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6695843.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6695843.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6695843Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6695843Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6695843Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6695843Test.java index fde9fb2e420..e70dbff8a11 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6695843Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6695843Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; @@ -30,6 +30,9 @@ import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; import javax.xml.transform.dom.DOMSource; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_1.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_1.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_1.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_1.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_10.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_10.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_10.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_10.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_11.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_11.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_11.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_11.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_12.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_12.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_12.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_12.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_13.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_13.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_13.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_13.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_14.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_14.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_14.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_14.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_15.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_15.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_15.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_15.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_16.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_16.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_16.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_16.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_17.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_17.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_17.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_17.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_18.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_18.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_18.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_18.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_19.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_19.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_19.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_19.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_2.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_2.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_2.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_2.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_20.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_20.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_20.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_20.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_21.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_21.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_21.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_21.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_22.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_22.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_22.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_22.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_23.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_23.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_23.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_23.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_24.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_24.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_24.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_24.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_25.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_25.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_25.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_25.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_3.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_3.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_3.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_3.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_4.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_4.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_4.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_4.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_5.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_5.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_5.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_5.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_6.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_6.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_6.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_6.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_7.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_7.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_7.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_7.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_8.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_8.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_8.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_8.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_9.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_9.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084In/Bug6773084_9.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084In/Bug6773084_9.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084Test.java index 41103d20b13..98737edebaf 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6773084Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6773084Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import java.io.FileFilter; @@ -38,6 +38,9 @@ import javax.xml.parsers.ParserConfigurationException; import javax.xml.transform.Source; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.stream.StreamSource; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.BeforeClass; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6859210.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6859210.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6859210.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6859210.java index 322a7dc4fa2..1bb0d046499 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6859210.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6859210.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6925531Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6925531Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6925531Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6925531Test.java index 03b2efd3a53..b3fad32adb0 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6925531Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6925531Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.ByteArrayInputStream; import java.io.IOException; @@ -35,6 +35,9 @@ import java.security.PrivilegedAction; import javax.xml.XMLConstants; import javax.xml.transform.sax.SAXSource; import javax.xml.transform.stream.StreamSource; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6946312.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6946312.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6946312.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6946312.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6946312Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6946312Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6946312Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6946312Test.java index b93c1ac8f62..5f0b19d50dc 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6946312Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6946312Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; import java.io.InputStream; @@ -31,6 +31,8 @@ import javax.xml.parsers.ParserConfigurationException; import javax.xml.parsers.SAXParser; import javax.xml.parsers.SAXParserFactory; import javax.xml.transform.stream.StreamSource; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6954738.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6954738.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6954738.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6954738.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6954738.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6954738.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6954738.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6954738.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6954738_Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6954738_Test.java similarity index 92% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6954738_Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Bug6954738_Test.java index da5bb1a4cab..5118754af73 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Bug6954738_Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Bug6954738_Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,12 +21,15 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; import javax.xml.XMLConstants; import javax.xml.transform.stream.StreamSource; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.annotations.Test; import org.xml.sax.ErrorHandler; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6708840Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/CR6708840Test.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6708840Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/CR6708840Test.java index 932c8fb43b8..7c9b0bd83e1 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6708840Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/CR6708840Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import java.io.FileWriter; @@ -33,6 +33,9 @@ import javax.xml.stream.XMLStreamReader; import javax.xml.transform.Result; import javax.xml.transform.Source; import javax.xml.transform.stax.StAXSource; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6740048.java b/jaxp/test/javax/xml/jaxp/unittest/validation/CR6740048.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6740048.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/CR6740048.java index 7ef779eb0a9..26a239b2854 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6740048.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/CR6740048.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6740048.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/CR6740048.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6740048.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/CR6740048.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6740048.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/CR6740048.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CR6740048.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/CR6740048.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CREMAS01.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/CREMAS01.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CREMAS01.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/CREMAS01.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CREMAS01.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/CREMAS01.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/CREMAS01.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/CREMAS01.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ErrorHandlerImpl.java b/jaxp/test/javax/xml/jaxp/unittest/validation/ErrorHandlerImpl.java similarity index 94% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ErrorHandlerImpl.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/ErrorHandlerImpl.java index 6fbd8570d88..95806ed3f21 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ErrorHandlerImpl.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/ErrorHandlerImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import org.xml.sax.ErrorHandler; import org.xml.sax.SAXException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Issue682.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/Issue682.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Issue682.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/Issue682.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Issue682.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/Issue682.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Issue682.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/Issue682.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Issue682Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/Issue682Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Issue682Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/Issue682Test.java index 9301f3bd6b8..e1753f06817 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/Issue682Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/Issue682Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import java.io.InputStream; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30.java b/jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30.java index afde0f092a4..765fa1329c5 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-error.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-error.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-error.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-error.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-ok.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-ok.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-ok.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-ok.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-optimize-error.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-optimize-error.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-optimize-error.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-optimize-error.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-optimize-ok.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-optimize-ok.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-optimize-ok.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-optimize-ok.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-optimize.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-optimize.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs-optimize.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs-optimize.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/IssueTracker30_occurs.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/IssueTracker30_occurs.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/JaxpIssue43Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/JaxpIssue43Test.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/JaxpIssue43Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/JaxpIssue43Test.java index 5a451ca7a6e..e590b221330 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/JaxpIssue43Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/JaxpIssue43Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.FileInputStream; import java.util.ArrayList; @@ -34,6 +34,9 @@ import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMResult; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.stream.StreamSource; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.annotations.Test; import org.w3c.dom.Document; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/JaxpIssue49.java b/jaxp/test/javax/xml/jaxp/unittest/validation/JaxpIssue49.java similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/JaxpIssue49.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/JaxpIssue49.java index 85522e9503d..aec363119a1 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/JaxpIssue49.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/JaxpIssue49.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.FileInputStream; @@ -33,6 +33,9 @@ import javax.xml.transform.dom.DOMResult; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.stream.StreamResult; import javax.xml.transform.stream.StreamSource; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/JaxpIssue49.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/JaxpIssue49.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/JaxpIssue49.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/JaxpIssue49.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/LargeMaxOccursTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/LargeMaxOccursTest.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/LargeMaxOccursTest.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/LargeMaxOccursTest.java index 4a4e06235d2..d78322723c7 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/LargeMaxOccursTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/LargeMaxOccursTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,14 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import javax.xml.XMLConstants; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/MultiOccursTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/MultiOccursTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/MultiOccursTest.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/MultiOccursTest.java index 7f0dbddebee..014e8af7dad 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/MultiOccursTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/MultiOccursTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/MultiOccursUnboundedTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/MultiOccursUnboundedTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/MultiOccursUnboundedTest.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/MultiOccursUnboundedTest.java index 8d7d5163756..b6069c26a3b 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/MultiOccursUnboundedTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/MultiOccursUnboundedTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/OccursTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursTest.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/OccursTest.java index be3ed12bf0f..0cb9177760c 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/OccursTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursUnboundedTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/OccursUnboundedTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursUnboundedTest.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/OccursUnboundedTest.java index 47d1ba9af91..df0e07829dd 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursUnboundedTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/OccursUnboundedTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursWildcardTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/OccursWildcardTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursWildcardTest.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/OccursWildcardTest.java index 36b21cdf8bd..36b97cf9361 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursWildcardTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/OccursWildcardTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursWildcardUnbounded.java b/jaxp/test/javax/xml/jaxp/unittest/validation/OccursWildcardUnbounded.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursWildcardUnbounded.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/OccursWildcardUnbounded.java index e11fa92fd47..b454db97b22 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/OccursWildcardUnbounded.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/OccursWildcardUnbounded.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesId005Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesId005Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesId005Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesId005Test.java index 429ea2d9d83..74169f4af09 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesId005Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesId005Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesIg004Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesIg004Test.java similarity index 88% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesIg004Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesIg004Test.java index c1618505e34..2fe1a305e2a 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesIg004Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesIg004Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,11 +21,14 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import javax.xml.XMLConstants; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesQ013Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesQ013Test.java similarity index 96% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesQ013Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesQ013Test.java index ef589d13847..33e73d5ce80 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ParticlesQ013Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/ParticlesQ013Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ProcessContents-lax-error.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/ProcessContents-lax-error.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ProcessContents-lax-error.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/ProcessContents-lax-error.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ProcessContents-ok.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/ProcessContents-ok.xml similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ProcessContents-ok.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/ProcessContents-ok.xml diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ProcessContents.xsd b/jaxp/test/javax/xml/jaxp/unittest/validation/ProcessContents.xsd similarity index 100% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ProcessContents.xsd rename to jaxp/test/javax/xml/jaxp/unittest/validation/ProcessContents.xsd diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/TCKGroupA008Test.java b/jaxp/test/javax/xml/jaxp/unittest/validation/TCKGroupA008Test.java similarity index 89% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/TCKGroupA008Test.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/TCKGroupA008Test.java index e097422fbdf..c88c09b85f5 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/TCKGroupA008Test.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/TCKGroupA008Test.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,10 +21,14 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; + import org.testng.Assert; import org.testng.annotations.Test; import org.xml.sax.SAXException; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ValidatorTest.java b/jaxp/test/javax/xml/jaxp/unittest/validation/ValidatorTest.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ValidatorTest.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/ValidatorTest.java index 5a84c5211a7..9dd421a4a26 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/ValidatorTest.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/ValidatorTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.File; import java.io.FileInputStream; @@ -34,6 +34,9 @@ import javax.xml.stream.XMLOutputFactory; import javax.xml.transform.Result; import javax.xml.transform.Source; import javax.xml.transform.stax.StAXResult; +import javax.xml.validation.Schema; +import javax.xml.validation.SchemaFactory; +import javax.xml.validation.Validator; import org.testng.Assert; import org.testng.annotations.Test; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/XMLDocBuilder.java b/jaxp/test/javax/xml/jaxp/unittest/validation/XMLDocBuilder.java similarity index 97% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/XMLDocBuilder.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/XMLDocBuilder.java index f0513bb3683..de9b0d935e4 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/XMLDocBuilder.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/XMLDocBuilder.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; import java.io.InputStreamReader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/XMLSchemaValidator.java b/jaxp/test/javax/xml/jaxp/unittest/validation/XMLSchemaValidator.java similarity index 95% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/XMLSchemaValidator.java rename to jaxp/test/javax/xml/jaxp/unittest/validation/XMLSchemaValidator.java index c1722a190e5..beb05e56afb 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/XMLSchemaValidator.java +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/XMLSchemaValidator.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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 @@ -21,7 +21,7 @@ * questions. */ -package javax.xml.validation; +package validation; import java.io.IOException; import java.io.Reader; diff --git a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/gMonths-invalid.xml b/jaxp/test/javax/xml/jaxp/unittest/validation/gMonths-invalid.xml similarity index 93% rename from jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/gMonths-invalid.xml rename to jaxp/test/javax/xml/jaxp/unittest/validation/gMonths-invalid.xml index a3071b50bab..ce13a8848a3 100644 --- a/jaxp/test/javax/xml/jaxp/unittest/javax/xml/validation/gMonths-invalid.xml +++ b/jaxp/test/javax/xml/jaxp/unittest/validation/gMonths-invalid.xml @@ -1,7 +1,7 @@ * *   * Special constructs (named-capturing and non-capturing) * - * (?<name>X) + * (?<name>X{@code )} * X, as a named-capturing group - * (?:X) + * {@code (?:}X{@code )} * X, as a non-capturing group - * (?idmsuxU-idmsuxU)  + * (?idmsuxU-idmsuxU)  * Nothing, but turns match flags i * d m s * u x U * on - off - * (?idmsux-idmsux:X)   + * (?idmsux-idmsux:X{@code )}   * X, as a non-capturing group with the * given flags i d * m s u * x on - off - * (?=X) + * {@code (?=}X{@code )} * X, via zero-width positive lookahead - * (?!X) + * {@code (?!}X{@code )} * X, via zero-width negative lookahead - * (?<=X) + * {@code (?<=}X{@code )} * X, via zero-width positive lookbehind - * (?<!X) + * {@code (?X{@code )} * X, via zero-width negative lookbehind - * (?>X) + * {@code (?>}X{@code )} * X, as an independent, non-capturing group * * @@ -377,10 +377,10 @@ import java.util.stream.StreamSupport; * *

Backslashes, escapes, and quoting

* - *

The backslash character ('\') serves to introduce escaped + *

The backslash character ({@code '\'}) serves to introduce escaped * constructs, as defined in the table above, as well as to quote characters * that otherwise would be interpreted as unescaped constructs. Thus the - * expression \\ matches a single backslash and \{ matches a + * expression {@code \\} matches a single backslash and \{ matches a * left brace. * *

It is an error to use a backslash prior to any alphabetic character that @@ -396,18 +396,18 @@ import java.util.stream.StreamSupport; * It is therefore necessary to double backslashes in string * literals that represent regular expressions to protect them from * interpretation by the Java bytecode compiler. The string literal - * "\b", for example, matches a single backspace character when - * interpreted as a regular expression, while "\\b" matches a - * word boundary. The string literal "\(hello\)" is illegal + * "\b", for example, matches a single backspace character when + * interpreted as a regular expression, while {@code "\\b"} matches a + * word boundary. The string literal {@code "\(hello\)"} is illegal * and leads to a compile-time error; in order to match the string - * (hello) the string literal "\\(hello\\)" + * {@code (hello)} the string literal {@code "\\(hello\\)"} * must be used. * *

Character Classes

* *

Character classes may appear within other character classes, and * may be composed by the union operator (implicit) and the intersection - * operator (&&). + * operator ({@code &&}). * The union operator denotes a class that contains every character that is * in at least one of its operand classes. The intersection operator * denotes a class that contains every character that is in both of its @@ -420,16 +420,16 @@ import java.util.stream.StreamSupport; * summary="Precedence of character class operators."> * 1     * Literal escape     - * \x + * {@code \x} * 2     * Grouping - * [...] + * {@code [...]} * 3     * Range - * a-z + * {@code a-z} * 4     * Union - * [a-e][i-u] + * {@code [a-e][i-u]} * 5     * Intersection * {@code [a-z&&[aeiou]]} @@ -437,8 +437,8 @@ import java.util.stream.StreamSupport; * *

Note that a different set of metacharacters are in effect inside * a character class than outside a character class. For instance, the - * regular expression . loses its special meaning inside a - * character class, while the expression - becomes a range + * regular expression {@code .} loses its special meaning inside a + * character class, while the expression {@code -} becomes a range * forming metacharacter. * *

Line terminators

@@ -449,49 +449,49 @@ import java.util.stream.StreamSupport; * *
    * - *
  • A newline (line feed) character ('\n'), + *
  • A newline (line feed) character ({@code '\n'}), * *
  • A carriage-return character followed immediately by a newline - * character ("\r\n"), + * character ({@code "\r\n"}), * - *
  • A standalone carriage-return character ('\r'), + *
  • A standalone carriage-return character ({@code '\r'}), * - *
  • A next-line character ('\u0085'), + *
  • A next-line character ('\u0085'), * - *
  • A line-separator character ('\u2028'), or + *
  • A line-separator character ('\u2028'), or * - *
  • A paragraph-separator character ('\u2029). + *
  • A paragraph-separator character ('\u2029). * *
*

If {@link #UNIX_LINES} mode is activated, then the only line terminators * recognized are newline characters. * - *

The regular expression . matches any character except a line + *

The regular expression {@code .} matches any character except a line * terminator unless the {@link #DOTALL} flag is specified. * - *

By default, the regular expressions ^ and $ ignore + *

By default, the regular expressions {@code ^} and {@code $} ignore * line terminators and only match at the beginning and the end, respectively, * of the entire input sequence. If {@link #MULTILINE} mode is activated then - * ^ matches at the beginning of input and after any line terminator - * except at the end of input. When in {@link #MULTILINE} mode $ + * {@code ^} matches at the beginning of input and after any line terminator + * except at the end of input. When in {@link #MULTILINE} mode {@code $} * matches just before a line terminator or the end of the input sequence. * *

Groups and capturing

* *

Group number

*

Capturing groups are numbered by counting their opening parentheses from - * left to right. In the expression ((A)(B(C))), for example, there + * left to right. In the expression {@code ((A)(B(C)))}, for example, there * are four such groups:

* *
* - * + * * - * + * * - * + * * - * + * *
1    ((A)(B(C)))
{@code ((A)(B(C)))}
2    (A)
{@code (A)}
3    (B(C))
{@code (B(C))}
4    (C)
{@code (C)}
* *

Group zero always stands for the entire expression. @@ -502,31 +502,31 @@ import java.util.stream.StreamSupport; * may also be retrieved from the matcher once the match operation is complete. * *

Group name

- *

A capturing group can also be assigned a "name", a named-capturing group, + *

A capturing group can also be assigned a "name", a {@code named-capturing group}, * and then be back-referenced later by the "name". Group names are composed of - * the following characters. The first character must be a letter. + * the following characters. The first character must be a {@code letter}. * *

    - *
  • The uppercase letters 'A' through 'Z' - * ('\u0041' through '\u005a'), - *
  • The lowercase letters 'a' through 'z' - * ('\u0061' through '\u007a'), - *
  • The digits '0' through '9' - * ('\u0030' through '\u0039'), + *
  • The uppercase letters {@code 'A'} through {@code 'Z'} + * ('\u0041' through '\u005a'), + *
  • The lowercase letters {@code 'a'} through {@code 'z'} + * ('\u0061' through '\u007a'), + *
  • The digits {@code '0'} through {@code '9'} + * ('\u0030' through '\u0039'), *
* - *

A named-capturing group is still numbered as described in + *

A {@code named-capturing group} is still numbered as described in * Group number. * *

The captured input associated with a group is always the subsequence * that the group most recently matched. If a group is evaluated a second time * because of quantification then its previously-captured value, if any, will * be retained if the second evaluation fails. Matching the string - * "aba" against the expression (a(b)?)+, for example, leaves - * group two set to "b". All captured input is discarded at the + * {@code "aba"} against the expression {@code (a(b)?)+}, for example, leaves + * group two set to {@code "b"}. All captured input is discarded at the * beginning of each match. * - *

Groups beginning with (? are either pure, non-capturing groups + *

Groups beginning with {@code (?} are either pure, non-capturing groups * that do not capture text and do not count towards the group total, or * named-capturing group. * @@ -537,26 +537,26 @@ import java.util.stream.StreamSupport; * Standard #18: Unicode Regular Expression, plus RL2.1 * Canonical Equivalents. *

- * Unicode escape sequences such as \u2014 in Java source code + * Unicode escape sequences such as \u2014 in Java source code * are processed as described in section 3.3 of * The Java™ Language Specification. * Such escape sequences are also implemented directly by the regular-expression * parser so that Unicode escapes can be used in expressions that are read from - * files or from the keyboard. Thus the strings "\u2014" and - * "\\u2014", while not equal, compile into the same pattern, which - * matches the character with hexadecimal value 0x2014. + * files or from the keyboard. Thus the strings "\u2014" and + * {@code "\\u2014"}, while not equal, compile into the same pattern, which + * matches the character with hexadecimal value {@code 0x2014}. *

* A Unicode character can also be represented in a regular-expression by * using its Hex notation(hexadecimal code point value) directly as described in construct - * \x{...}, for example a supplementary character U+2011F - * can be specified as \x{2011F}, instead of two consecutive + * \x{...}, for example a supplementary character U+2011F + * can be specified as \x{2011F}, instead of two consecutive * Unicode escape sequences of the surrogate pair - * \uD840\uDD1F. + * \uD840\uDD1F. *

* Unicode scripts, blocks, categories and binary properties are written with - * the \p and \P constructs as in Perl. - * \p{prop} matches if - * the input has the property prop, while \P{prop} + * the {@code \p} and {@code \P} constructs as in Perl. + * \p{prop} matches if + * the input has the property prop, while \P{prop} * does not match if the input has that property. *

* Scripts, blocks, categories and binary properties can be used both inside @@ -567,7 +567,7 @@ import java.util.stream.StreamSupport; * {@code IsHiragana}, or by using the {@code script} keyword (or its short * form {@code sc}) as in {@code script=Hiragana} or {@code sc=Hiragana}. *

- * The script names supported by Pattern are the valid script names + * The script names supported by {@code Pattern} are the valid script names * accepted and defined by * {@link java.lang.Character.UnicodeScript#forName(String) UnicodeScript.forName}. * @@ -576,7 +576,7 @@ import java.util.stream.StreamSupport; * {@code InMongolian}, or by using the keyword {@code block} (or its short * form {@code blk}) as in {@code block=Mongolian} or {@code blk=Mongolian}. *

- * The block names supported by Pattern are the valid block names + * The block names supported by {@code Pattern} are the valid block names * accepted and defined by * {@link java.lang.Character.UnicodeBlock#forName(String) UnicodeBlock.forName}. *

@@ -595,7 +595,7 @@ import java.util.stream.StreamSupport; *

* * Binary properties are specified with the prefix {@code Is}, as in - * {@code IsAlphabetic}. The supported binary properties by Pattern + * {@code IsAlphabetic}. The supported binary properties by {@code Pattern} * are *

    *
  • Alphabetic @@ -625,88 +625,88 @@ import java.util.stream.StreamSupport; * Classes * Matches * - * \p{Lower} - * A lowercase character:\p{IsLowercase} - * \p{Upper} - * An uppercase character:\p{IsUppercase} - * \p{ASCII} - * All ASCII:[\x00-\x7F] - * \p{Alpha} - * An alphabetic character:\p{IsAlphabetic} - * \p{Digit} - * A decimal digit character:p{IsDigit} - * \p{Alnum} - * An alphanumeric character:[\p{IsAlphabetic}\p{IsDigit}] - * \p{Punct} - * A punctuation character:p{IsPunctuation} - * \p{Graph} - * A visible character: [^\p{IsWhite_Space}\p{gc=Cc}\p{gc=Cs}\p{gc=Cn}] - * \p{Print} + * {@code \p{Lower}} + * A lowercase character:{@code \p{IsLowercase}} + * {@code \p{Upper}} + * An uppercase character:{@code \p{IsUppercase}} + * {@code \p{ASCII}} + * All ASCII:{@code [\x00-\x7F]} + * {@code \p{Alpha}} + * An alphabetic character:{@code \p{IsAlphabetic}} + * {@code \p{Digit}} + * A decimal digit character:{@code p{IsDigit}} + * {@code \p{Alnum}} + * An alphanumeric character:{@code [\p{IsAlphabetic}\p{IsDigit}]} + * {@code \p{Punct}} + * A punctuation character:{@code p{IsPunctuation}} + * {@code \p{Graph}} + * A visible character: {@code [^\p{IsWhite_Space}\p{gc=Cc}\p{gc=Cs}\p{gc=Cn}]} + * {@code \p{Print}} * A printable character: {@code [\p{Graph}\p{Blank}&&[^\p{Cntrl}]]} - * \p{Blank} + * {@code \p{Blank}} * A space or a tab: {@code [\p{IsWhite_Space}&&[^\p{gc=Zl}\p{gc=Zp}\x0a\x0b\x0c\x0d\x85]]} - * \p{Cntrl} - * A control character: \p{gc=Cc} - * \p{XDigit} - * A hexadecimal digit: [\p{gc=Nd}\p{IsHex_Digit}] - * \p{Space} - * A whitespace character:\p{IsWhite_Space} - * \d - * A digit: \p{IsDigit} - * \D - * A non-digit: [^\d] - * \s - * A whitespace character: \p{IsWhite_Space} - * \S - * A non-whitespace character: [^\s] - * \w - * A word character: [\p{Alpha}\p{gc=Mn}\p{gc=Me}\p{gc=Mc}\p{Digit}\p{gc=Pc}\p{IsJoin_Control}] - * \W - * A non-word character: [^\w] + * {@code \p{Cntrl}} + * A control character: {@code \p{gc=Cc}} + * {@code \p{XDigit}} + * A hexadecimal digit: {@code [\p{gc=Nd}\p{IsHex_Digit}]} + * {@code \p{Space}} + * A whitespace character:{@code \p{IsWhite_Space}} + * {@code \d} + * A digit: {@code \p{IsDigit}} + * {@code \D} + * A non-digit: {@code [^\d]} + * {@code \s} + * A whitespace character: {@code \p{IsWhite_Space}} + * {@code \S} + * A non-whitespace character: {@code [^\s]} + * {@code \w} + * A word character: {@code [\p{Alpha}\p{gc=Mn}\p{gc=Me}\p{gc=Mc}\p{Digit}\p{gc=Pc}\p{IsJoin_Control}]} + * {@code \W} + * A non-word character: {@code [^\w]} * *

    * * Categories that behave like the java.lang.Character * boolean ismethodname methods (except for the deprecated ones) are - * available through the same \p{prop} syntax where - * the specified property has the name javamethodname. + * available through the same \p{prop} syntax where + * the specified property has the name javamethodname. * *

    Comparison to Perl 5

    * - *

    The Pattern engine performs traditional NFA-based matching + *

    The {@code Pattern} engine performs traditional NFA-based matching * with ordered alternation as occurs in Perl 5. * *

    Perl constructs not supported by this class:

    * *
      *
    • Predefined character classes (Unicode character) - *

      \X    Match Unicode + *

      \X    Match Unicode * * extended grapheme cluster *

    • * - *
    • The backreference constructs, \g{n} for + *

    • The backreference constructs, \g{n} for * the nthcapturing group and - * \g{name} for + * \g{name} for * named-capturing group. *

    • * - *
    • The named character construct, \N{name} + *

    • The named character construct, \N{name} * for a Unicode character by its name. *

    • * *
    • The conditional constructs - * (?(condition)X) and - * (?(condition)X|Y), + * {@code (?(}condition{@code )}X{@code )} and + * {@code (?(}condition{@code )}X{@code |}Y{@code )}, *

    • * - *
    • The embedded code constructs (?{code}) - * and (??{code}),

    • + *
    • The embedded code constructs (?{code}) + * and (??{code}),

    • * - *
    • The embedded comment syntax (?#comment), and

    • + *
    • The embedded comment syntax {@code (?#comment)}, and

    • * - *
    • The preprocessing operations \l \u, - * \L, and \U.

    • + *
    • The preprocessing operations {@code \l} \u, + * {@code \L}, and {@code \U}.

    • * *
    * @@ -723,19 +723,19 @@ import java.util.stream.StreamSupport; * *
      * - *
    • In Perl, \1 through \9 are always interpreted - * as back references; a backslash-escaped number greater than 9 is + *

    • In Perl, {@code \1} through {@code \9} are always interpreted + * as back references; a backslash-escaped number greater than {@code 9} is * treated as a back reference if at least that many subexpressions exist, * otherwise it is interpreted, if possible, as an octal escape. In this * class octal escapes must always begin with a zero. In this class, - * \1 through \9 are always interpreted as back + * {@code \1} through {@code \9} are always interpreted as back * references, and a larger number is accepted as a back reference if at * least that many subexpressions exist at that point in the regular * expression, otherwise the parser will drop digits until the number is * smaller or equal to the existing number of groups or it is one digit. *

    • * - *
    • Perl uses the g flag to request a match that resumes + *

    • Perl uses the {@code g} flag to request a match that resumes * where the last match left off. This functionality is provided implicitly * by the {@link Matcher} class: Repeated invocations of the {@link * Matcher#find find} method will resume where the last match left off, @@ -786,11 +786,11 @@ public final class Pattern /** * Enables Unix lines mode. * - *

      In this mode, only the '\n' line terminator is recognized - * in the behavior of ., ^, and $. + *

      In this mode, only the {@code '\n'} line terminator is recognized + * in the behavior of {@code .}, {@code ^}, and {@code $}. * *

      Unix lines mode can also be enabled via the embedded flag - * expression (?d). + * expression {@code (?d)}. */ public static final int UNIX_LINES = 0x01; @@ -803,7 +803,7 @@ public final class Pattern * #UNICODE_CASE} flag in conjunction with this flag. * *

      Case-insensitive matching can also be enabled via the embedded flag - * expression (?i). + * expression {@code (?i)}. * *

      Specifying this flag may impose a slight performance penalty.

      */ @@ -813,23 +813,23 @@ public final class Pattern * Permits whitespace and comments in pattern. * *

      In this mode, whitespace is ignored, and embedded comments starting - * with # are ignored until the end of a line. + * with {@code #} are ignored until the end of a line. * *

      Comments mode can also be enabled via the embedded flag - * expression (?x). + * expression {@code (?x)}. */ public static final int COMMENTS = 0x04; /** * Enables multiline mode. * - *

      In multiline mode the expressions ^ and $ match + *

      In multiline mode the expressions {@code ^} and {@code $} match * just after or just before, respectively, a line terminator or the end of * the input sequence. By default these expressions only match at the * beginning and the end of the entire input sequence. * *

      Multiline mode can also be enabled via the embedded flag - * expression (?m).

      + * expression {@code (?m)}.

      */ public static final int MULTILINE = 0x08; @@ -853,12 +853,12 @@ public final class Pattern /** * Enables dotall mode. * - *

      In dotall mode, the expression . matches any character, + *

      In dotall mode, the expression {@code .} matches any character, * including a line terminator. By default this expression does not match * line terminators. * *

      Dotall mode can also be enabled via the embedded flag - * expression (?s). (The s is a mnemonic for + * expression {@code (?s)}. (The {@code s} is a mnemonic for * "single-line" mode, which is what this is called in Perl.)

      */ public static final int DOTALL = 0x20; @@ -873,7 +873,7 @@ public final class Pattern * matched. * *

      Unicode-aware case folding can also be enabled via the embedded flag - * expression (?u). + * expression {@code (?u)}. * *

      Specifying this flag may impose a performance penalty.

      */ @@ -884,8 +884,8 @@ public final class Pattern * *

      When this flag is specified then two characters will be considered * to match if, and only if, their full canonical decompositions match. - * The expression "a\u030A", for example, will match the - * string "\u00E5" when this flag is specified. By default, + * The expression "a\u030A", for example, will match the + * string "\u00E5" when this flag is specified. By default, * matching does not take canonical equivalence into account. * *

      There is no embedded flag character for enabling canonical @@ -907,7 +907,7 @@ public final class Pattern * Annex C: Compatibility Properties. *

      * The UNICODE_CHARACTER_CLASS mode can also be enabled via the embedded - * flag expression (?U). + * flag expression {@code (?U)}. *

      * The flag implies UNICODE_CASE, that is, it enables Unicode-aware case * folding. @@ -1052,7 +1052,7 @@ public final class Pattern * @return the given regular expression compiled into a pattern with the given flags * @throws IllegalArgumentException * If bit values other than those corresponding to the defined - * match flags are set in flags + * match flags are set in {@code flags} * * @throws PatternSyntaxException * If the expression's syntax is invalid @@ -1158,7 +1158,7 @@ public final class Pattern * of the resulting array. A zero-width match at the beginning however * never produces such empty leading substring. * - *

      The limit parameter controls the number of times the + *

      The {@code limit} parameter controls the number of times the * pattern is applied and therefore affects the length of the resulting * array. If the limit n is greater than zero then the pattern * will be applied at most n - 1 times, the array's @@ -1169,7 +1169,7 @@ public final class Pattern * the pattern will be applied as many times as possible, the array can * have any length, and trailing empty strings will be discarded. * - *

      The input "boo:and:foo", for example, yields the following + *

      The input {@code "boo:and:foo"}, for example, yields the following * results with these parameters: * *

      Result     * * - * + * * * - * + * * * - * + * * * - * + * * * - * + * * * - * + * *
      :2{ "boo", "and:foo" }
      {@code { "boo", "and:foo" }}
      :5{ "boo", "and", "foo" }
      {@code { "boo", "and", "foo" }}
      :-2{ "boo", "and", "foo" }
      {@code { "boo", "and", "foo" }}
      o5{ "b", "", ":and:f", "", "" }
      {@code { "b", "", ":and:f", "", "" }}
      o-2{ "b", "", ":and:f", "", "" }
      {@code { "b", "", ":and:f", "", "" }}
      o0{ "b", "", ":and:f" }
      {@code { "b", "", ":and:f" }}
      * * @param input @@ -1256,7 +1256,7 @@ public final class Pattern * sequence and a limit argument of zero. Trailing empty strings are * therefore not included in the resulting array.

      * - *

      The input "boo:and:foo", for example, yields the following + *

      The input {@code "boo:and:foo"}, for example, yields the following * results with these expressions: * *

      * * - * + * * - * + * *
      Regex    Result
      :{ "boo", "and", "foo" }
      {@code { "boo", "and", "foo" }}
      o{ "b", "", ":and:f" }
      {@code { "b", "", ":and:f" }}
      * * @@ -1281,12 +1281,12 @@ public final class Pattern } /** - * Returns a literal pattern String for the specified - * String. + * Returns a literal pattern {@code String} for the specified + * {@code String}. * - *

      This method produces a String that can be used to - * create a Pattern that would match the string - * s as if it were a literal pattern.

      Metacharacters + *

      This method produces a {@code String} that can be used to + * create a {@code Pattern} that would match the string + * {@code s} as if it were a literal pattern.

      Metacharacters * or escape sequences in the input sequence will be given no special * meaning. * diff --git a/jdk/src/java.base/share/classes/java/util/regex/PatternSyntaxException.java b/jdk/src/java.base/share/classes/java/util/regex/PatternSyntaxException.java index f7b767a75ba..94d7abc78a5 100644 --- a/jdk/src/java.base/share/classes/java/util/regex/PatternSyntaxException.java +++ b/jdk/src/java.base/share/classes/java/util/regex/PatternSyntaxException.java @@ -57,7 +57,7 @@ public class PatternSyntaxException * * @param index * The approximate index in the pattern of the error, - * or -1 if the index is not known + * or {@code -1} if the index is not known */ public PatternSyntaxException(String desc, String regex, int index) { this.desc = desc; @@ -69,7 +69,7 @@ public class PatternSyntaxException * Retrieves the error index. * * @return The approximate index in the pattern of the error, - * or -1 if the index is not known + * or {@code -1} if the index is not known */ public int getIndex() { return index; diff --git a/jdk/src/java.base/share/classes/java/util/regex/package-info.java b/jdk/src/java.base/share/classes/java/util/regex/package-info.java index 2907f10c003..86136637c56 100644 --- a/jdk/src/java.base/share/classes/java/util/regex/package-info.java +++ b/jdk/src/java.base/share/classes/java/util/regex/package-info.java @@ -37,7 +37,7 @@ * interface in order to support matching against characters from a * wide variety of input sources.

      * - *

      Unless otherwise noted, passing a null argument to a + *

      Unless otherwise noted, passing a null argument to a * method in any class or interface in this package will cause a * {@link java.lang.NullPointerException NullPointerException} to be * thrown. diff --git a/jdk/src/java.base/share/classes/javax/security/auth/AuthPermission.java b/jdk/src/java.base/share/classes/javax/security/auth/AuthPermission.java index 49f51481d17..889d14af979 100644 --- a/jdk/src/java.base/share/classes/javax/security/auth/AuthPermission.java +++ b/jdk/src/java.base/share/classes/javax/security/auth/AuthPermission.java @@ -26,18 +26,17 @@ package javax.security.auth; /** - * This class is for authentication permissions. - * An AuthPermission contains a name - * (also referred to as a "target name") - * but no actions list; you either have the named permission - * or you don't. + * This class is for authentication permissions. An {@code AuthPermission} + * contains a name (also referred to as a "target name") but no actions + * list; you either have the named permission or you don't. * *

      The target name is the name of a security configuration parameter - * (see below). Currently the AuthPermission object is used to - * guard access to the Policy, Subject, LoginContext, - * and Configuration objects. + * (see below). Currently the {@code AuthPermission} object is used to + * guard access to the {@link Policy}, {@link Subject}, + * {@link javax.security.auth.login.LoginContext}, and + * {@link javax.security.auth.login.Configuration} objects. * - *

      The possible target names for an Authentication Permission are: + *

      The standard target names for an Authentication Permission are: * *

        *      doAs -                  allow the caller to invoke the
      @@ -125,6 +124,9 @@ package javax.security.auth;
        *                              Subject-based access control policy.
        * 
      * + * @implNote + * Implementations may define additional target names, but should use naming + * conventions such as reverse domain name notation to avoid name clashes. */ public final class AuthPermission extends java.security.BasicPermission { diff --git a/jdk/src/java.base/share/classes/sun/nio/ByteBuffered.java b/jdk/src/java.base/share/classes/sun/nio/ByteBuffered.java index a09621bbff4..6a016419ee4 100644 --- a/jdk/src/java.base/share/classes/sun/nio/ByteBuffered.java +++ b/jdk/src/java.base/share/classes/sun/nio/ByteBuffered.java @@ -29,11 +29,11 @@ import java.nio.ByteBuffer; import java.io.IOException; /** This is an interface to adapt existing APIs to use {@link java.nio.ByteBuffer - * ByteBuffers} as the underlying + * ByteBuffers} as the underlying * data format. Only the initial producer and final consumer have to be changed.

      * - * For example, the Zip/Jar code supports {@link java.io.InputStream InputStreams}. - * To make the Zip code use {@link java.nio.MappedByteBuffer MappedByteBuffers} as + * For example, the Zip/Jar code supports {@link java.io.InputStream InputStreams}. + * To make the Zip code use {@link java.nio.MappedByteBuffer MappedByteBuffers} as * the underlying data structure, it can create a class of InputStream that wraps the ByteBuffer, * and implements the ByteBuffered interface. A co-operating class several layers * away can ask the InputStream if it is an instance of ByteBuffered, then @@ -42,12 +42,12 @@ import java.io.IOException; public interface ByteBuffered { /** - * Returns the ByteBuffer behind this object, if this particular - * instance has one. An implementation of getByteBuffer() is allowed - * to return null for any reason. + * Returns the {@code ByteBuffer} behind this object, if this particular + * instance has one. An implementation of {@code getByteBuffer()} is allowed + * to return {@code null} for any reason. * - * @return The ByteBuffer, if this particular instance has one, - * or null otherwise. + * @return The {@code ByteBuffer}, if this particular instance has one, + * or {@code null} otherwise. * * @throws IOException * If the ByteBuffer is no longer valid. diff --git a/jdk/src/java.base/share/classes/sun/nio/ch/AllocatedNativeObject.java b/jdk/src/java.base/share/classes/sun/nio/ch/AllocatedNativeObject.java index 2406cb8f1e4..6709ce115cf 100644 --- a/jdk/src/java.base/share/classes/sun/nio/ch/AllocatedNativeObject.java +++ b/jdk/src/java.base/share/classes/sun/nio/ch/AllocatedNativeObject.java @@ -36,14 +36,14 @@ class AllocatedNativeObject // package-private { /** - * Allocates a memory area of at least size bytes outside of the + * Allocates a memory area of at least {@code size} bytes outside of the * Java heap and creates a native object for that area. * * @param size * Number of bytes to allocate * * @param pageAligned - * If true then the area will be aligned on a hardware + * If {@code true} then the area will be aligned on a hardware * page boundary * * @throws OutOfMemoryError diff --git a/jdk/src/java.base/share/conf/security/java.policy b/jdk/src/java.base/share/conf/security/java.policy index aef0017be48..968cc4ff52e 100644 --- a/jdk/src/java.base/share/conf/security/java.policy +++ b/jdk/src/java.base/share/conf/security/java.policy @@ -23,6 +23,14 @@ grant codeBase "jrt:/jdk.scripting.nashorn" { permission java.security.AllPermission; }; +grant codeBase "jrt:/jdk.scripting.nashorn.shell" { + permission java.security.AllPermission; +}; + +grant codeBase "jrt:/jdk.internal.le" { + permission java.security.AllPermission; +}; + grant codeBase "jrt:/jdk.crypto.ucrypto" { permission java.lang.RuntimePermission "accessClassInPackage.sun.security.*"; permission java.lang.RuntimePermission "accessClassInPackage.sun.nio.ch"; diff --git a/jdk/src/java.base/share/native/libnio/nio_util.c b/jdk/src/java.base/share/native/libnio/nio_util.c new file mode 100644 index 00000000000..f61c65268e8 --- /dev/null +++ b/jdk/src/java.base/share/native/libnio/nio_util.c @@ -0,0 +1,40 @@ +/* + * Copyright (c) 2015, 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 + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +#include "jni.h" +#include "jvm.h" +#include "jni_util.h" + +JNIEXPORT jint JNICALL +JNI_OnLoad(JavaVM *vm, void *reserved) +{ + JNIEnv *env; + + if ((*vm)->GetEnv(vm, (void**) &env, JNI_VERSION_1_2) != JNI_OK) { + return JNI_EVERSION; /* JNI version not supported */ + } + + return JNI_VERSION_1_2; +} diff --git a/jdk/src/java.base/unix/classes/sun/nio/fs/GnomeFileTypeDetector.java b/jdk/src/java.base/unix/classes/sun/nio/fs/GnomeFileTypeDetector.java index 7d120e45e45..88c6839e492 100644 --- a/jdk/src/java.base/unix/classes/sun/nio/fs/GnomeFileTypeDetector.java +++ b/jdk/src/java.base/unix/classes/sun/nio/fs/GnomeFileTypeDetector.java @@ -67,7 +67,7 @@ public class GnomeFileTypeDetector // GIO private static native boolean initializeGio(); - private static native byte[] probeGio(long pathAddress); + private static synchronized native byte[] probeGio(long pathAddress); static { AccessController.doPrivileged(new PrivilegedAction<>() { diff --git a/jdk/src/java.base/unix/classes/sun/nio/fs/MimeTypesFileTypeDetector.java b/jdk/src/java.base/unix/classes/sun/nio/fs/MimeTypesFileTypeDetector.java index 20e077cbdc3..9eb683b2bd7 100644 --- a/jdk/src/java.base/unix/classes/sun/nio/fs/MimeTypesFileTypeDetector.java +++ b/jdk/src/java.base/unix/classes/sun/nio/fs/MimeTypesFileTypeDetector.java @@ -159,7 +159,7 @@ class MimeTypesFileTypeDetector extends AbstractFileTypeDetector { final String EXTEQUAL = "exts="; String extRegex = "\\b" + EXTEQUAL + - "(\"[\\p{Graph}|\\p{Blank}]+?\"|\\p{Graph}+\\b)"; + "(\"[\\p{Graph}\\p{Blank}]+?\"|\\p{Graph}+\\b)"; Pattern extPattern = Pattern.compile(extRegex); Matcher extMatcher = extPattern.matcher(entry); @@ -169,7 +169,7 @@ class MimeTypesFileTypeDetector extends AbstractFileTypeDetector { if (exts.charAt(0) == '"') { exts = exts.substring(1, exts.length() - 1); } - String[] extList = exts.split("[\\p{Blank}|\\p{Punct}]+"); + String[] extList = exts.split("[\\p{Blank}\\p{Punct}]+"); for (String ext : extList) { putIfAbsent(ext, type); } diff --git a/jdk/src/java.base/windows/native/libjava/WinNTFileSystem_md.c b/jdk/src/java.base/windows/native/libjava/WinNTFileSystem_md.c index 3c280c0c9b4..1e29fd23965 100644 --- a/jdk/src/java.base/windows/native/libjava/WinNTFileSystem_md.c +++ b/jdk/src/java.base/windows/native/libjava/WinNTFileSystem_md.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2001, 2015, 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 @@ -233,10 +233,13 @@ DWORD getFinalAttributes(WCHAR *path) if (GetFileAttributesExW(path, GetFileExInfoStandard, &wfad)) { attr = getFinalAttributesIfReparsePoint(path, wfad.dwFileAttributes); - } else if (GetLastError() == ERROR_SHARING_VIOLATION && - (h = FindFirstFileW(path, &wfd)) != INVALID_HANDLE_VALUE) { - attr = getFinalAttributesIfReparsePoint(path, wfd.dwFileAttributes); - FindClose(h); + } else { + DWORD lerr = GetLastError(); + if ((lerr == ERROR_SHARING_VIOLATION || lerr == ERROR_ACCESS_DENIED) && + (h = FindFirstFileW(path, &wfd)) != INVALID_HANDLE_VALUE) { + attr = getFinalAttributesIfReparsePoint(path, wfd.dwFileAttributes); + FindClose(h); + } } return attr; } diff --git a/jdk/src/java.desktop/macosx/native/libawt_lwawt/awt/CFRetainedResource.m b/jdk/src/java.desktop/macosx/native/libawt_lwawt/awt/CFRetainedResource.m index 1371189b83f..b5650cdd63c 100644 --- a/jdk/src/java.desktop/macosx/native/libawt_lwawt/awt/CFRetainedResource.m +++ b/jdk/src/java.desktop/macosx/native/libawt_lwawt/awt/CFRetainedResource.m @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2011, 2015, 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 @@ -40,10 +40,17 @@ JNIEXPORT void JNICALL Java_sun_lwawt_macosx_CFRetainedResource_nativeCFRelease if (releaseOnAppKitThread) { // Releasing resources on the main AppKit message loop only // Releasing resources on the nested loops may cause dangling - // pointers after the nested loop is exited - [NSApp postRunnableEvent:^(){ - CFRelease(jlong_to_ptr(ptr)); - }]; + // pointers after the nested loop is exited + if ([NSApp respondsToSelector:@selector(postRunnableEvent:)]) { + [NSApp postRunnableEvent:^() { + CFRelease(jlong_to_ptr(ptr)); + }]; + } else { + // could happen if we are embedded inside SWT/FX application, + [JNFRunLoop performOnMainThreadWaiting:NO withBlock:^() { + CFRelease(jlong_to_ptr(ptr)); + }]; + } } else { JNF_COCOA_ENTER(env); diff --git a/jdk/src/java.desktop/share/classes/com/sun/beans/introspect/PropertyInfo.java b/jdk/src/java.desktop/share/classes/com/sun/beans/introspect/PropertyInfo.java index 44d6a1f7919..3bda169a89a 100644 --- a/jdk/src/java.desktop/share/classes/com/sun/beans/introspect/PropertyInfo.java +++ b/jdk/src/java.desktop/share/classes/com/sun/beans/introspect/PropertyInfo.java @@ -40,7 +40,7 @@ import java.util.TreeMap; import static com.sun.beans.finder.ClassFinder.findClass; public final class PropertyInfo { - public enum Name {bound, expert, hidden, preferred, visualUpdate, description, enumerationValues} + public enum Name {bound, expert, hidden, preferred, required, visualUpdate, description, enumerationValues} private static final String VETO_EXCEPTION_NAME = "java.beans.PropertyVetoException"; private static final Class VETO_EXCEPTION; @@ -120,6 +120,7 @@ public final class PropertyInfo { put(Name.bound, Boolean.FALSE); } put(Name.expert, annotation.expert()); + put(Name.required, annotation.required()); put(Name.hidden, annotation.hidden()); put(Name.preferred, annotation.preferred()); put(Name.visualUpdate, annotation.visualUpdate()); diff --git a/jdk/src/java.desktop/share/classes/com/sun/media/sound/AiffFileReader.java b/jdk/src/java.desktop/share/classes/com/sun/media/sound/AiffFileReader.java index 6d91be4bf61..8c9dc3c78be 100644 --- a/jdk/src/java.desktop/share/classes/com/sun/media/sound/AiffFileReader.java +++ b/jdk/src/java.desktop/share/classes/com/sun/media/sound/AiffFileReader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2015, 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 @@ -27,19 +27,14 @@ package com.sun.media.sound; import java.io.DataInputStream; import java.io.DataOutputStream; -import java.io.File; -import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; -import java.net.URL; import javax.sound.sampled.AudioFileFormat; import javax.sound.sampled.AudioFormat; -import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.AudioSystem; import javax.sound.sampled.UnsupportedAudioFileException; - /** * AIFF file reader and writer. * @@ -49,177 +44,10 @@ import javax.sound.sampled.UnsupportedAudioFileException; */ public final class AiffFileReader extends SunFileReader { - private static final int MAX_READ_LENGTH = 8; - - // METHODS TO IMPLEMENT AudioFileReader - - /** - * Obtains the audio file format of the input stream provided. The stream must - * point to valid audio file data. In general, audio file providers may - * need to read some data from the stream before determining whether they - * support it. These parsers must - * be able to mark the stream, read enough data to determine whether they - * support the stream, and, if not, reset the stream's read pointer to its original - * position. If the input stream does not support this, this method may fail - * with an IOException. - * @param stream the input stream from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the stream does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - * @see InputStream#markSupported - * @see InputStream#mark - */ - public AudioFileFormat getAudioFileFormat(InputStream stream) throws UnsupportedAudioFileException, IOException { - // fix for 4489272: AudioSystem.getAudioFileFormat() fails for InputStream, but works for URL - AudioFileFormat aff = getCOMM(stream, true); - // the following is not strictly necessary - but was implemented like that in 1.3.0 - 1.4.1 - // so I leave it as it was. May remove this for 1.5.0 - stream.reset(); - return aff; - } - - - /** - * Obtains the audio file format of the URL provided. The URL must - * point to valid audio file data. - * @param url the URL from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the URL does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioFileFormat getAudioFileFormat(URL url) throws UnsupportedAudioFileException, IOException { - AudioFileFormat fileFormat = null; - InputStream urlStream = url.openStream(); // throws IOException - try { - fileFormat = getCOMM(urlStream, false); - } finally { - urlStream.close(); - } - return fileFormat; - } - - - /** - * Obtains the audio file format of the File provided. The File must - * point to valid audio file data. - * @param file the File from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the File does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioFileFormat getAudioFileFormat(File file) throws UnsupportedAudioFileException, IOException { - AudioFileFormat fileFormat = null; - FileInputStream fis = new FileInputStream(file); // throws IOException - // part of fix for 4325421 - try { - fileFormat = getCOMM(fis, false); - } finally { - fis.close(); - } - - return fileFormat; - } - - - - - /** - * Obtains an audio stream from the input stream provided. The stream must - * point to valid audio file data. In general, audio file providers may - * need to read some data from the stream before determining whether they - * support it. These parsers must - * be able to mark the stream, read enough data to determine whether they - * support the stream, and, if not, reset the stream's read pointer to its original - * position. If the input stream does not support this, this method may fail - * with an IOException. - * @param stream the input stream from which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data contained - * in the input stream. - * @throws UnsupportedAudioFileException if the stream does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - * @see InputStream#markSupported - * @see InputStream#mark - */ - public AudioInputStream getAudioInputStream(InputStream stream) throws UnsupportedAudioFileException, IOException { - // getCOMM leaves the input stream at the beginning of the audio data - AudioFileFormat fileFormat = getCOMM(stream, true); // throws UnsupportedAudioFileException, IOException - - // we've got everything, and the stream is at the - // beginning of the audio data, so return an AudioInputStream. - return new AudioInputStream(stream, fileFormat.getFormat(), fileFormat.getFrameLength()); - } - - - /** - * Obtains an audio stream from the URL provided. The URL must - * point to valid audio file data. - * @param url the URL for which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data pointed - * to by the URL - * @throws UnsupportedAudioFileException if the URL does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioInputStream getAudioInputStream(URL url) throws UnsupportedAudioFileException, IOException { - InputStream urlStream = url.openStream(); // throws IOException - AudioFileFormat fileFormat = null; - try { - fileFormat = getCOMM(urlStream, false); - } finally { - if (fileFormat == null) { - urlStream.close(); - } - } - return new AudioInputStream(urlStream, fileFormat.getFormat(), fileFormat.getFrameLength()); - } - - - /** - * Obtains an audio stream from the File provided. The File must - * point to valid audio file data. - * @param file the File for which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data pointed - * to by the File - * @throws UnsupportedAudioFileException if the File does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioInputStream getAudioInputStream(File file) - throws UnsupportedAudioFileException, IOException { - - FileInputStream fis = new FileInputStream(file); // throws IOException - AudioFileFormat fileFormat = null; - // part of fix for 4325421 - try { - fileFormat = getCOMM(fis, false); - } finally { - if (fileFormat == null) { - fis.close(); - } - } - return new AudioInputStream(fis, fileFormat.getFormat(), fileFormat.getFrameLength()); - } - - //-------------------------------------------------------------------- - - private AudioFileFormat getCOMM(InputStream is, boolean doReset) - throws UnsupportedAudioFileException, IOException { - - DataInputStream dis = new DataInputStream(is); - - if (doReset) { - dis.mark(MAX_READ_LENGTH); - } + @Override + AudioFileFormat getAudioFileFormatImpl(final InputStream stream) + throws UnsupportedAudioFileException, IOException { + DataInputStream dis = new DataInputStream(stream); // assumes a stream at the beginning of the file which has already // passed the magic number test... @@ -234,9 +62,6 @@ public final class AiffFileReader extends SunFileReader { // $$fb: fix for 4369044: javax.sound.sampled.AudioSystem.getAudioInputStream() works wrong with Cp037 if (magic != AiffFileFormat.AIFF_MAGIC) { // not AIFF, throw exception - if (doReset) { - dis.reset(); - } throw new UnsupportedAudioFileException("not an AIFF file"); } diff --git a/jdk/src/java.desktop/share/classes/com/sun/media/sound/AuFileReader.java b/jdk/src/java.desktop/share/classes/com/sun/media/sound/AuFileReader.java index a12e461c95d..7e83180dffa 100644 --- a/jdk/src/java.desktop/share/classes/com/sun/media/sound/AuFileReader.java +++ b/jdk/src/java.desktop/share/classes/com/sun/media/sound/AuFileReader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2015, 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 @@ -25,21 +25,15 @@ package com.sun.media.sound; -import java.io.BufferedInputStream; import java.io.DataInputStream; -import java.io.File; -import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; -import java.net.URL; import javax.sound.sampled.AudioFileFormat; import javax.sound.sampled.AudioFormat; -import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.AudioSystem; import javax.sound.sampled.UnsupportedAudioFileException; - /** * AU file reader. * @@ -49,33 +43,10 @@ import javax.sound.sampled.UnsupportedAudioFileException; */ public final class AuFileReader extends SunFileReader { - // METHODS TO IMPLEMENT AudioFileReader - - /** - * Obtains the audio file format of the input stream provided. The stream must - * point to valid audio file data. In general, audio file providers may - * need to read some data from the stream before determining whether they - * support it. These parsers must - * be able to mark the stream, read enough data to determine whether they - * support the stream, and, if not, reset the stream's read pointer to its original - * position. If the input stream does not support this, this method may fail - * with an IOException. - * @param stream the input stream from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the stream does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - * @see InputStream#markSupported - * @see InputStream#mark - */ - public AudioFileFormat getAudioFileFormat(InputStream stream) throws UnsupportedAudioFileException, IOException { - - AudioFormat format = null; - AuFileFormat fileFormat = null; - int maxReadLength = 28; + @Override + public AudioFileFormat getAudioFileFormatImpl(final InputStream stream) + throws UnsupportedAudioFileException, IOException { boolean bigendian = false; - int magic = -1; int headerSize = -1; int dataSize = -1; int encoding_local = -1; @@ -90,15 +61,12 @@ public final class AuFileReader extends SunFileReader { DataInputStream dis = new DataInputStream( stream ); - dis.mark(maxReadLength); - - magic = dis.readInt(); + final int magic = dis.readInt(); nread += 4; if (! (magic == AuFileFormat.AU_SUN_MAGIC) || (magic == AuFileFormat.AU_DEC_MAGIC) || (magic == AuFileFormat.AU_SUN_INV_MAGIC) || (magic == AuFileFormat.AU_DEC_INV_MAGIC) ) { - // not AU, reset the stream, place into exception, throw exception - dis.reset(); + // not AU, throw exception throw new UnsupportedAudioFileException("not an AU file"); } @@ -112,7 +80,6 @@ public final class AuFileReader extends SunFileReader { sampleRate = (bigendian==true ? dis.readInt() : rllong(dis) ); nread += 4; channels = (bigendian==true ? dis.readInt() : rllong(dis) ); nread += 4; if (channels <= 0) { - dis.reset(); throw new UnsupportedAudioFileException("Invalid number of channels"); } @@ -172,7 +139,6 @@ public final class AuFileReader extends SunFileReader { */ default: // unsupported filetype, throw exception - dis.reset(); throw new UnsupportedAudioFileException("not a valid AU file"); } @@ -184,189 +150,13 @@ public final class AuFileReader extends SunFileReader { //$$fb 2003-10-20: fix for 4940459: AudioInputStream.getFrameLength() returns 0 instead of NOT_SPECIFIED length = dataSize / frameSize; } - - format = new AudioFormat( encoding, (float)sampleRate, sampleSizeInBits, - channels, frameSize, (float)frameRate, bigendian); - - fileFormat = new AuFileFormat( AudioFileFormat.Type.AU, dataSize+headerSize, - format, length); - - dis.reset(); // Throws IOException - return fileFormat; - - } - - - /** - * Obtains the audio file format of the URL provided. The URL must - * point to valid audio file data. - * @param url the URL from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the URL does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioFileFormat getAudioFileFormat(URL url) throws UnsupportedAudioFileException, IOException { - - InputStream urlStream = null; - BufferedInputStream bis = null; - AudioFileFormat fileFormat = null; - AudioFormat format = null; - - urlStream = url.openStream(); // throws IOException - - try { - bis = new BufferedInputStream( urlStream, bisBufferSize ); - - fileFormat = getAudioFileFormat( bis ); // throws UnsupportedAudioFileException - } finally { - urlStream.close(); - } - - return fileFormat; - } - - - /** - * Obtains the audio file format of the File provided. The File must - * point to valid audio file data. - * @param file the File from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the File does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioFileFormat getAudioFileFormat(File file) throws UnsupportedAudioFileException, IOException { - - FileInputStream fis = null; - BufferedInputStream bis = null; - AudioFileFormat fileFormat = null; - AudioFormat format = null; - - fis = new FileInputStream( file ); // throws IOException - // part of fix for 4325421 - try { - bis = new BufferedInputStream( fis, bisBufferSize ); - fileFormat = getAudioFileFormat( bis ); // throws UnsupportedAudioFileException - } finally { - fis.close(); - } - - return fileFormat; - } - - - /** - * Obtains an audio stream from the input stream provided. The stream must - * point to valid audio file data. In general, audio file providers may - * need to read some data from the stream before determining whether they - * support it. These parsers must - * be able to mark the stream, read enough data to determine whether they - * support the stream, and, if not, reset the stream's read pointer to its original - * position. If the input stream does not support this, this method may fail - * with an IOException. - * @param stream the input stream from which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data contained - * in the input stream. - * @throws UnsupportedAudioFileException if the stream does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - * @see InputStream#markSupported - * @see InputStream#mark - */ - public AudioInputStream getAudioInputStream(InputStream stream) throws UnsupportedAudioFileException, IOException { - - DataInputStream dis = null; - int headerSize; - AudioFileFormat fileFormat = null; - AudioFormat format = null; - - - fileFormat = getAudioFileFormat( stream ); // throws UnsupportedAudioFileException, IOException - - // if we passed this call, we have an AU file. - - format = fileFormat.getFormat(); - - dis = new DataInputStream(stream); - // now seek past the header - - dis.readInt(); // magic - headerSize = (format.isBigEndian()==true ? dis.readInt() : rllong(dis) ); - dis.skipBytes( headerSize - 8 ); - - - // we've got everything, and the stream should be at the - // beginning of the data chunk, so return an AudioInputStream. - - return new AudioInputStream(dis, format, fileFormat.getFrameLength()); - } - - - /** - * Obtains an audio stream from the URL provided. The URL must - * point to valid audio file data. - * @param url the URL for which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data pointed - * to by the URL - * @throws UnsupportedAudioFileException if the URL does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioInputStream getAudioInputStream(URL url) throws UnsupportedAudioFileException, IOException { - - InputStream urlStream = null; - BufferedInputStream bis = null; - AudioFileFormat fileFormat = null; - - urlStream = url.openStream(); // throws IOException - AudioInputStream result = null; - try { - bis = new BufferedInputStream( urlStream, bisBufferSize ); - result = getAudioInputStream( (InputStream)bis ); - } finally { - if (result == null) { - urlStream.close(); - } - } - return result; - } - - - /** - * Obtains an audio stream from the File provided. The File must - * point to valid audio file data. - * @param file the File for which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data pointed - * to by the File - * @throws UnsupportedAudioFileException if the File does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioInputStream getAudioInputStream(File file) throws UnsupportedAudioFileException, IOException { - - FileInputStream fis = null; - BufferedInputStream bis = null; - AudioFileFormat fileFormat = null; - - fis = new FileInputStream( file ); // throws IOException - AudioInputStream result = null; - // part of fix for 4325421 - try { - bis = new BufferedInputStream( fis, bisBufferSize ); - result = getAudioInputStream( (InputStream)bis ); - } finally { - if (result == null) { - fis.close(); - } - } - - return result; + dis.skipBytes(headerSize - nread); + AudioFormat format = new AudioFormat(encoding, sampleRate, + sampleSizeInBits, channels, + frameSize, (float) frameRate, + bigendian); + return new AuFileFormat(AudioFileFormat.Type.AU, dataSize + headerSize, + format, length); } } diff --git a/jdk/src/java.desktop/share/classes/com/sun/media/sound/SunFileReader.java b/jdk/src/java.desktop/share/classes/com/sun/media/sound/SunFileReader.java index 7e59125946b..06b9ff0e456 100644 --- a/jdk/src/java.desktop/share/classes/com/sun/media/sound/SunFileReader.java +++ b/jdk/src/java.desktop/share/classes/com/sun/media/sound/SunFileReader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2015, 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 @@ -25,10 +25,12 @@ package com.sun.media.sound; -import java.io.File; -import java.io.InputStream; -import java.io.IOException; +import java.io.BufferedInputStream; import java.io.DataInputStream; +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.io.InputStream; import java.net.URL; import javax.sound.sampled.AudioFileFormat; @@ -36,8 +38,6 @@ import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.UnsupportedAudioFileException; import javax.sound.sampled.spi.AudioFileReader; - - /** * Abstract File Reader class. * @@ -45,118 +45,109 @@ import javax.sound.sampled.spi.AudioFileReader; */ abstract class SunFileReader extends AudioFileReader { - // buffer size for temporary input streams - protected static final int bisBufferSize = 4096; - - /** - * Constructs a new SunFileReader object. - */ - SunFileReader() { + @Override + public final AudioFileFormat getAudioFileFormat(final InputStream stream) + throws UnsupportedAudioFileException, IOException { + stream.mark(200); // The biggest value which was historically used + try { + return getAudioFileFormatImpl(stream); + } finally { + // According to specification the following is not strictly + // necessary, if we got correct format. But it was implemented like + // that in 1.3.0 - 1.8. So I leave it as it was, but it seems + // specification should be updated. + stream.reset(); + } } + @Override + public final AudioFileFormat getAudioFileFormat(final URL url) + throws UnsupportedAudioFileException, IOException { + try (InputStream is = url.openStream()) { + return getAudioFileFormatImpl(new BufferedInputStream(is)); + } + } - // METHODS TO IMPLEMENT AudioFileReader + @Override + public final AudioFileFormat getAudioFileFormat(final File file) + throws UnsupportedAudioFileException, IOException { + try (InputStream is = new FileInputStream(file)) { + return getAudioFileFormatImpl(new BufferedInputStream(is)); + } + } + + @Override + public AudioInputStream getAudioInputStream(final InputStream stream) + throws UnsupportedAudioFileException, IOException { + stream.mark(200); // The biggest value which was historically used + try { + final AudioFileFormat fileFormat = getAudioFileFormatImpl(stream); + // we've got everything, the stream is supported and it is at the + // beginning of the audio data, so return an AudioInputStream + return new AudioInputStream(stream, fileFormat.getFormat(), + fileFormat.getFrameLength()); + } catch (final UnsupportedAudioFileException e) { + stream.reset(); + throw e; + } + } + + @Override + public final AudioInputStream getAudioInputStream(final URL url) + throws UnsupportedAudioFileException, IOException { + final InputStream urlStream = url.openStream(); + try { + return getAudioInputStream(new BufferedInputStream(urlStream)); + } catch (final Throwable e) { + closeSilently(urlStream); + throw e; + } + } + + @Override + public final AudioInputStream getAudioInputStream(final File file) + throws UnsupportedAudioFileException, IOException { + final InputStream fileStream = new FileInputStream(file); + try { + return getAudioInputStream(new BufferedInputStream(fileStream)); + } catch (final Throwable e) { + closeSilently(fileStream); + throw e; + } + } /** - * Obtains the audio file format of the input stream provided. The stream must - * point to valid audio file data. In general, audio file providers may - * need to read some data from the stream before determining whether they - * support it. These parsers must - * be able to mark the stream, read enough data to determine whether they - * support the stream, and, if not, reset the stream's read pointer to its original - * position. If the input stream does not support this, this method may fail - * with an IOException. - * @param stream the input stream from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the stream does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - * @see InputStream#markSupported - * @see InputStream#mark - */ - abstract public AudioFileFormat getAudioFileFormat(InputStream stream) throws UnsupportedAudioFileException, IOException; - - - /** - * Obtains the audio file format of the URL provided. The URL must - * point to valid audio file data. - * @param url the URL from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the URL does not point to valid audio - * file data recognized by the system + * Obtains the audio file format of the input stream provided. The stream + * must point to valid audio file data. Note that default implementation of + * {@link #getAudioInputStream(InputStream)} assume that this method leaves + * the input stream at the beginning of the audio data. + * + * @param stream the input stream from which file format information should + * be extracted + * @return an {@code AudioFileFormat} object describing the audio file + * format + * @throws UnsupportedAudioFileException if the stream does not point to + * valid audio file data recognized by the system * @throws IOException if an I/O exception occurs */ - abstract public AudioFileFormat getAudioFileFormat(URL url) throws UnsupportedAudioFileException, IOException; - - - /** - * Obtains the audio file format of the File provided. The File must - * point to valid audio file data. - * @param file the File from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the File does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - abstract public AudioFileFormat getAudioFileFormat(File file) throws UnsupportedAudioFileException, IOException; - - - /** - * Obtains an audio stream from the input stream provided. The stream must - * point to valid audio file data. In general, audio file providers may - * need to read some data from the stream before determining whether they - * support it. These parsers must - * be able to mark the stream, read enough data to determine whether they - * support the stream, and, if not, reset the stream's read pointer to its original - * position. If the input stream does not support this, this method may fail - * with an IOException. - * @param stream the input stream from which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data contained - * in the input stream. - * @throws UnsupportedAudioFileException if the stream does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - * @see InputStream#markSupported - * @see InputStream#mark - */ - abstract public AudioInputStream getAudioInputStream(InputStream stream) throws UnsupportedAudioFileException, IOException; - - - /** - * Obtains an audio stream from the URL provided. The URL must - * point to valid audio file data. - * @param url the URL for which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data pointed - * to by the URL - * @throws UnsupportedAudioFileException if the URL does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - abstract public AudioInputStream getAudioInputStream(URL url) throws UnsupportedAudioFileException, IOException; - - - /** - * Obtains an audio stream from the File provided. The File must - * point to valid audio file data. - * @param file the File for which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data pointed - * to by the File - * @throws UnsupportedAudioFileException if the File does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - abstract public AudioInputStream getAudioInputStream(File file) throws UnsupportedAudioFileException, IOException; - + abstract AudioFileFormat getAudioFileFormatImpl(InputStream stream) + throws UnsupportedAudioFileException, IOException; // HELPER METHODS - + /** + * Closes the InputStream when we have read all necessary data from it, and + * ignores an IOException. + * + * @param is the InputStream which should be closed + */ + private static void closeSilently(final InputStream is) { + try { + is.close(); + } catch (final IOException ignored) { + // IOException is ignored + } + } /** * rllong diff --git a/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveExtensibleFileReader.java b/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveExtensibleFileReader.java index 2dbcab81c7c..b238e9da66e 100644 --- a/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveExtensibleFileReader.java +++ b/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveExtensibleFileReader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2015, 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 @@ -22,55 +22,40 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + package com.sun.media.sound; -import java.io.BufferedInputStream; -import java.io.File; -import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; -import java.net.URL; import java.util.HashMap; import java.util.Map; import javax.sound.sampled.AudioFileFormat; import javax.sound.sampled.AudioFormat; +import javax.sound.sampled.AudioFormat.Encoding; import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.AudioSystem; import javax.sound.sampled.UnsupportedAudioFileException; -import javax.sound.sampled.AudioFormat.Encoding; -import javax.sound.sampled.spi.AudioFileReader; /** * WAVE file reader for files using format WAVE_FORMAT_EXTENSIBLE (0xFFFE). * * @author Karl Helgason */ -public final class WaveExtensibleFileReader extends AudioFileReader { - - static private class GUID { - long i1; - - int s1; - - int s2; - - int x1; - - int x2; - - int x3; - - int x4; - - int x5; - - int x6; - - int x7; - - int x8; +public final class WaveExtensibleFileReader extends SunFileReader { + private static class GUID { + private long i1; + private int s1; + private int s2; + private int x1; + private int x2; + private int x3; + private int x4; + private int x5; + private int x6; + private int x7; + private int x8; private GUID() { } @@ -105,10 +90,12 @@ public final class WaveExtensibleFileReader extends AudioFileReader { return d; } + @Override public int hashCode() { return (int) i1; } + @Override public boolean equals(Object obj) { if (!(obj instanceof GUID)) return false; @@ -161,7 +148,7 @@ public final class WaveExtensibleFileReader extends AudioFileReader { private static final GUID SUBTYPE_IEEE_FLOAT = new GUID(0x00000003, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71); - private String decodeChannelMask(long channelmask) { + private static String decodeChannelMask(long channelmask) { StringBuilder sb = new StringBuilder(); long m = 1; for (int i = 0; i < allchannelnames.length; i++) { @@ -180,20 +167,8 @@ public final class WaveExtensibleFileReader extends AudioFileReader { } - public AudioFileFormat getAudioFileFormat(InputStream stream) - throws UnsupportedAudioFileException, IOException { - - stream.mark(200); - AudioFileFormat format; - try { - format = internal_getAudioFileFormat(stream); - } finally { - stream.reset(); - } - return format; - } - - private AudioFileFormat internal_getAudioFileFormat(InputStream stream) + @Override + AudioFileFormat getAudioFileFormatImpl(final InputStream stream) throws UnsupportedAudioFileException, IOException { RIFFReader riffiterator = new RIFFReader(stream); @@ -244,12 +219,9 @@ public final class WaveExtensibleFileReader extends AudioFileReader { break; } } - - if (!fmt_found) + if (!fmt_found || !data_found) { throw new UnsupportedAudioFileException(); - if (!data_found) - throw new UnsupportedAudioFileException(); - + } Map p = new HashMap(); String s_channelmask = decodeChannelMask(channelMask); if (s_channelmask != null) @@ -273,24 +245,22 @@ public final class WaveExtensibleFileReader extends AudioFileReader { } else if (subFormat.equals(SUBTYPE_IEEE_FLOAT)) { audioformat = new AudioFormat(Encoding.PCM_FLOAT, samplerate, bits, channels, framesize, samplerate, false, p); - } else + } else { throw new UnsupportedAudioFileException(); - - AudioFileFormat fileformat = new AudioFileFormat( - AudioFileFormat.Type.WAVE, audioformat, - AudioSystem.NOT_SPECIFIED); - return fileformat; + } + return new AudioFileFormat(AudioFileFormat.Type.WAVE, audioformat, + AudioSystem.NOT_SPECIFIED); } - public AudioInputStream getAudioInputStream(InputStream stream) + @Override + public AudioInputStream getAudioInputStream(final InputStream stream) throws UnsupportedAudioFileException, IOException { AudioFileFormat format = getAudioFileFormat(stream); + // we've got everything, the stream is supported and it is at the + // beginning of the header, so find the data chunk again and return an + // AudioInputStream RIFFReader riffiterator = new RIFFReader(stream); - if (!riffiterator.getFormat().equals("RIFF")) - throw new UnsupportedAudioFileException(); - if (!riffiterator.getType().equals("WAVE")) - throw new UnsupportedAudioFileException(); while (riffiterator.hasNextChunk()) { RIFFReader chunk = riffiterator.nextChunk(); if (chunk.getFormat().equals("data")) { @@ -300,40 +270,4 @@ public final class WaveExtensibleFileReader extends AudioFileReader { } throw new UnsupportedAudioFileException(); } - - public AudioFileFormat getAudioFileFormat(URL url) - throws UnsupportedAudioFileException, IOException { - InputStream stream = url.openStream(); - AudioFileFormat format; - try { - format = getAudioFileFormat(new BufferedInputStream(stream)); - } finally { - stream.close(); - } - return format; - } - - public AudioFileFormat getAudioFileFormat(File file) - throws UnsupportedAudioFileException, IOException { - InputStream stream = new FileInputStream(file); - AudioFileFormat format; - try { - format = getAudioFileFormat(new BufferedInputStream(stream)); - } finally { - stream.close(); - } - return format; - } - - public AudioInputStream getAudioInputStream(URL url) - throws UnsupportedAudioFileException, IOException { - return getAudioInputStream(new BufferedInputStream(url.openStream())); - } - - public AudioInputStream getAudioInputStream(File file) - throws UnsupportedAudioFileException, IOException { - return getAudioInputStream(new BufferedInputStream(new FileInputStream( - file))); - } - } diff --git a/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveFileReader.java b/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveFileReader.java index 3599fdfab52..96a4bd7cd1f 100644 --- a/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveFileReader.java +++ b/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveFileReader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1999, 2015, 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 @@ -27,20 +27,14 @@ package com.sun.media.sound; import java.io.DataInputStream; import java.io.EOFException; -import java.io.File; -import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; -import java.net.URL; import javax.sound.sampled.AudioFileFormat; import javax.sound.sampled.AudioFormat; -import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.AudioSystem; import javax.sound.sampled.UnsupportedAudioFileException; - - /** * WAVE file reader. * @@ -50,170 +44,12 @@ import javax.sound.sampled.UnsupportedAudioFileException; */ public final class WaveFileReader extends SunFileReader { - private static final int MAX_READ_LENGTH = 12; - - /** - * Obtains the audio file format of the input stream provided. The stream must - * point to valid audio file data. In general, audio file providers may - * need to read some data from the stream before determining whether they - * support it. These parsers must - * be able to mark the stream, read enough data to determine whether they - * support the stream, and, if not, reset the stream's read pointer to its original - * position. If the input stream does not support this, this method may fail - * with an IOException. - * @param stream the input stream from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the stream does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - * @see InputStream#markSupported - * @see InputStream#mark - */ - public AudioFileFormat getAudioFileFormat(InputStream stream) throws UnsupportedAudioFileException, IOException { - // fix for 4489272: AudioSystem.getAudioFileFormat() fails for InputStream, but works for URL - AudioFileFormat aff = getFMT(stream, true); - // the following is not strictly necessary - but was implemented like that in 1.3.0 - 1.4.1 - // so I leave it as it was. May remove this for 1.5.0 - stream.reset(); - return aff; - } - - - /** - * Obtains the audio file format of the URL provided. The URL must - * point to valid audio file data. - * @param url the URL from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the URL does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioFileFormat getAudioFileFormat(URL url) throws UnsupportedAudioFileException, IOException { - InputStream urlStream = url.openStream(); // throws IOException - AudioFileFormat fileFormat = null; - try { - fileFormat = getFMT(urlStream, false); - } finally { - urlStream.close(); - } - return fileFormat; - } - - - /** - * Obtains the audio file format of the File provided. The File must - * point to valid audio file data. - * @param file the File from which file format information should be - * extracted - * @return an AudioFileFormat object describing the audio file format - * @throws UnsupportedAudioFileException if the File does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioFileFormat getAudioFileFormat(File file) throws UnsupportedAudioFileException, IOException { - AudioFileFormat fileFormat = null; - FileInputStream fis = new FileInputStream(file); // throws IOException - // part of fix for 4325421 - try { - fileFormat = getFMT(fis, false); - } finally { - fis.close(); - } - - return fileFormat; - } - - - /** - * Obtains an audio stream from the input stream provided. The stream must - * point to valid audio file data. In general, audio file providers may - * need to read some data from the stream before determining whether they - * support it. These parsers must - * be able to mark the stream, read enough data to determine whether they - * support the stream, and, if not, reset the stream's read pointer to its original - * position. If the input stream does not support this, this method may fail - * with an IOException. - * @param stream the input stream from which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data contained - * in the input stream. - * @throws UnsupportedAudioFileException if the stream does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - * @see InputStream#markSupported - * @see InputStream#mark - */ - public AudioInputStream getAudioInputStream(InputStream stream) throws UnsupportedAudioFileException, IOException { - // getFMT leaves the input stream at the beginning of the audio data - AudioFileFormat fileFormat = getFMT(stream, true); // throws UnsupportedAudioFileException, IOException - - // we've got everything, and the stream is at the - // beginning of the audio data, so return an AudioInputStream. - return new AudioInputStream(stream, fileFormat.getFormat(), fileFormat.getFrameLength()); - } - - - /** - * Obtains an audio stream from the URL provided. The URL must - * point to valid audio file data. - * @param url the URL for which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data pointed - * to by the URL - * @throws UnsupportedAudioFileException if the URL does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioInputStream getAudioInputStream(URL url) throws UnsupportedAudioFileException, IOException { - InputStream urlStream = url.openStream(); // throws IOException - AudioFileFormat fileFormat = null; - try { - fileFormat = getFMT(urlStream, false); - } finally { - if (fileFormat == null) { - urlStream.close(); - } - } - return new AudioInputStream(urlStream, fileFormat.getFormat(), fileFormat.getFrameLength()); - } - - - /** - * Obtains an audio stream from the File provided. The File must - * point to valid audio file data. - * @param file the File for which the AudioInputStream should be - * constructed - * @return an AudioInputStream object based on the audio file data pointed - * to by the File - * @throws UnsupportedAudioFileException if the File does not point to valid audio - * file data recognized by the system - * @throws IOException if an I/O exception occurs - */ - public AudioInputStream getAudioInputStream(File file) throws UnsupportedAudioFileException, IOException { - FileInputStream fis = new FileInputStream(file); // throws IOException - AudioFileFormat fileFormat = null; - // part of fix for 4325421 - try { - fileFormat = getFMT(fis, false); - } finally { - if (fileFormat == null) { - fis.close(); - } - } - return new AudioInputStream(fis, fileFormat.getFormat(), fileFormat.getFrameLength()); - } - - - //-------------------------------------------------------------------- - - - private AudioFileFormat getFMT(InputStream stream, boolean doReset) throws UnsupportedAudioFileException, IOException { + @Override + AudioFileFormat getAudioFileFormatImpl(final InputStream stream) + throws UnsupportedAudioFileException, IOException { // assumes sream is rewound - int bytesRead; int nread = 0; int fmt; int length = 0; @@ -227,10 +63,6 @@ public final class WaveFileReader extends SunFileReader { DataInputStream dis = new DataInputStream( stream ); - if (doReset) { - dis.mark(MAX_READ_LENGTH); - } - int magic = dis.readInt(); int fileLength = rllong(dis); int waveMagic = dis.readInt(); @@ -244,9 +76,6 @@ public final class WaveFileReader extends SunFileReader { if ((magic != WaveFileFormat.RIFF_MAGIC) || (waveMagic != WaveFileFormat.WAVE_MAGIC)) { // not WAVE, throw UnsupportedAudioFileException - if (doReset) { - dis.reset(); - } throw new UnsupportedAudioFileException("not a WAVE file"); } diff --git a/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveFloatFileReader.java b/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveFloatFileReader.java index 280196ef188..3fe278fc70c 100644 --- a/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveFloatFileReader.java +++ b/jdk/src/java.desktop/share/classes/com/sun/media/sound/WaveFloatFileReader.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2015, 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 @@ -22,14 +22,11 @@ * or visit www.oracle.com if you need additional information or have any * questions. */ + package com.sun.media.sound; -import java.io.BufferedInputStream; -import java.io.File; -import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; -import java.net.URL; import javax.sound.sampled.AudioFileFormat; import javax.sound.sampled.AudioFormat; @@ -37,29 +34,16 @@ import javax.sound.sampled.AudioFormat.Encoding; import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.AudioSystem; import javax.sound.sampled.UnsupportedAudioFileException; -import javax.sound.sampled.spi.AudioFileReader; /** * Floating-point encoded (format 3) WAVE file loader. * * @author Karl Helgason */ -public final class WaveFloatFileReader extends AudioFileReader { +public final class WaveFloatFileReader extends SunFileReader { - public AudioFileFormat getAudioFileFormat(InputStream stream) - throws UnsupportedAudioFileException, IOException { - - stream.mark(200); - AudioFileFormat format; - try { - format = internal_getAudioFileFormat(stream); - } finally { - stream.reset(); - } - return format; - } - - private AudioFileFormat internal_getAudioFileFormat(InputStream stream) + @Override + AudioFileFormat getAudioFileFormatImpl(final InputStream stream) throws UnsupportedAudioFileException, IOException { RIFFReader riffiterator = new RIFFReader(stream); @@ -96,30 +80,25 @@ public final class WaveFloatFileReader extends AudioFileReader { break; } } - - if (!fmt_found) + if (!fmt_found || !data_found) { throw new UnsupportedAudioFileException(); - if (!data_found) - throw new UnsupportedAudioFileException(); - + } AudioFormat audioformat = new AudioFormat( Encoding.PCM_FLOAT, samplerate, bits, channels, framesize, samplerate, false); - AudioFileFormat fileformat = new AudioFileFormat( - AudioFileFormat.Type.WAVE, audioformat, - AudioSystem.NOT_SPECIFIED); - return fileformat; + return new AudioFileFormat(AudioFileFormat.Type.WAVE, audioformat, + AudioSystem.NOT_SPECIFIED); } - public AudioInputStream getAudioInputStream(InputStream stream) + @Override + public AudioInputStream getAudioInputStream(final InputStream stream) throws UnsupportedAudioFileException, IOException { AudioFileFormat format = getAudioFileFormat(stream); + // we've got everything, the stream is supported and it is at the + // beginning of the header, so find the data chunk again and return an + // AudioInputStream RIFFReader riffiterator = new RIFFReader(stream); - if (!riffiterator.getFormat().equals("RIFF")) - throw new UnsupportedAudioFileException(); - if (!riffiterator.getType().equals("WAVE")) - throw new UnsupportedAudioFileException(); while (riffiterator.hasNextChunk()) { RIFFReader chunk = riffiterator.nextChunk(); if (chunk.getFormat().equals("data")) { @@ -129,39 +108,4 @@ public final class WaveFloatFileReader extends AudioFileReader { } throw new UnsupportedAudioFileException(); } - - public AudioFileFormat getAudioFileFormat(URL url) - throws UnsupportedAudioFileException, IOException { - InputStream stream = url.openStream(); - AudioFileFormat format; - try { - format = getAudioFileFormat(new BufferedInputStream(stream)); - } finally { - stream.close(); - } - return format; - } - - public AudioFileFormat getAudioFileFormat(File file) - throws UnsupportedAudioFileException, IOException { - InputStream stream = new FileInputStream(file); - AudioFileFormat format; - try { - format = getAudioFileFormat(new BufferedInputStream(stream)); - } finally { - stream.close(); - } - return format; - } - - public AudioInputStream getAudioInputStream(URL url) - throws UnsupportedAudioFileException, IOException { - return getAudioInputStream(new BufferedInputStream(url.openStream())); - } - - public AudioInputStream getAudioInputStream(File file) - throws UnsupportedAudioFileException, IOException { - return getAudioInputStream(new BufferedInputStream(new FileInputStream( - file))); - } } diff --git a/jdk/src/java.desktop/share/classes/java/awt/MenuBar.java b/jdk/src/java.desktop/share/classes/java/awt/MenuBar.java index 5ba87f646b9..b8bb64d8efb 100644 --- a/jdk/src/java.desktop/share/classes/java/awt/MenuBar.java +++ b/jdk/src/java.desktop/share/classes/java/awt/MenuBar.java @@ -229,9 +229,11 @@ public class MenuBar extends MenuComponent implements MenuContainer, Accessible if (m.peer == null) { m.addNotify(); } + menus.addElement(m); peer.addMenu(m); + } else { + menus.addElement(m); } - menus.addElement(m); return m; } } diff --git a/jdk/src/java.desktop/share/classes/java/awt/Toolkit.java b/jdk/src/java.desktop/share/classes/java/awt/Toolkit.java index e48d28eacf8..b8769a1fad1 100644 --- a/jdk/src/java.desktop/share/classes/java/awt/Toolkit.java +++ b/jdk/src/java.desktop/share/classes/java/awt/Toolkit.java @@ -519,13 +519,7 @@ public abstract class Toolkit { *

      * If a system property named {@code "java.awt.headless"} is set * to {@code true} then the headless implementation - * of {@code Toolkit} is used. - *

      - * If there is no {@code "java.awt.headless"} or it is set to - * {@code false} and there is a system property named - * {@code "awt.toolkit"}, - * that property is treated as the name of a class that is a subclass - * of {@code Toolkit}; + * of {@code Toolkit} is used, * otherwise the default platform-specific implementation of * {@code Toolkit} is used. *

      diff --git a/jdk/src/java.desktop/share/classes/java/beans/PropertyDescriptor.java b/jdk/src/java.desktop/share/classes/java/beans/PropertyDescriptor.java index 96c29e46126..bf465a1bbd3 100644 --- a/jdk/src/java.desktop/share/classes/java/beans/PropertyDescriptor.java +++ b/jdk/src/java.desktop/share/classes/java/beans/PropertyDescriptor.java @@ -160,21 +160,23 @@ public class PropertyDescriptor extends FeatureDescriptor { setPropertyType(info.getPropertyType()); setConstrained(info.isConstrained()); setBound(bound && info.is(PropertyInfo.Name.bound)); - if (info.is(PropertyInfo.Name.expert)) { - setValue(PropertyInfo.Name.expert.name(), Boolean.TRUE); // compatibility - setExpert(true); - } - if (info.is(PropertyInfo.Name.hidden)) { - setValue(PropertyInfo.Name.hidden.name(), Boolean.TRUE); // compatibility - setHidden(true); - } - if (info.is(PropertyInfo.Name.preferred)) { - setPreferred(true); - } - Object visual = info.get(PropertyInfo.Name.visualUpdate); - if (visual != null) { - setValue(PropertyInfo.Name.visualUpdate.name(), visual); - } + + boolean isExpert = info.is(PropertyInfo.Name.expert); + setValue(PropertyInfo.Name.expert.name(), isExpert); // compatibility + setExpert(isExpert); + + boolean isHidden = info.is(PropertyInfo.Name.hidden); + setValue(PropertyInfo.Name.hidden.name(), isHidden); // compatibility + setHidden(isHidden); + + setPreferred(info.is(PropertyInfo.Name.preferred)); + + boolean isRequired = info.is(PropertyInfo.Name.required); + setValue(PropertyInfo.Name.required.name(), isRequired); + + boolean visual = info.is(PropertyInfo.Name.visualUpdate); + setValue(PropertyInfo.Name.visualUpdate.name(), visual); + Object description = info.get(PropertyInfo.Name.description); if (description != null) { setShortDescription(description.toString()); diff --git a/jdk/src/java.desktop/share/classes/javax/swing/JInternalFrame.java b/jdk/src/java.desktop/share/classes/javax/swing/JInternalFrame.java index 8549e1328f7..06aff62f849 100644 --- a/jdk/src/java.desktop/share/classes/javax/swing/JInternalFrame.java +++ b/jdk/src/java.desktop/share/classes/javax/swing/JInternalFrame.java @@ -1247,6 +1247,7 @@ public class JInternalFrame extends JComponent implements * * @param layer an Integer object specifying this * frame's desktop layer + * @throws NullPointerException if {@code layer} is {@code null} * @see JLayeredPane * @beaninfo * expert: true diff --git a/jdk/src/java.desktop/share/classes/javax/swing/TimerQueue.java b/jdk/src/java.desktop/share/classes/javax/swing/TimerQueue.java index d221929b849..e2ac94080f7 100644 --- a/jdk/src/java.desktop/share/classes/javax/swing/TimerQueue.java +++ b/jdk/src/java.desktop/share/classes/javax/swing/TimerQueue.java @@ -94,6 +94,9 @@ class TimerQueue implements Runnable void startIfNeeded() { if (! running) { runningLock.lock(); + if (running) { + return; + } try { final ThreadGroup threadGroup = AppContext.getAppContext().getThreadGroup(); AccessController.doPrivileged((PrivilegedAction) () -> { @@ -166,15 +169,17 @@ class TimerQueue implements Runnable try { while (running) { try { - Timer timer = queue.take().getTimer(); + DelayedTimer runningTimer = queue.take(); + Timer timer = runningTimer.getTimer(); timer.getLock().lock(); try { DelayedTimer delayedTimer = timer.delayedTimer; - if (delayedTimer != null) { + if (delayedTimer == runningTimer) { /* - * Timer is not removed after we get it from - * the queue and before the lock on the timer is - * acquired + * Timer is not removed (delayedTimer != null) + * or not removed and added (runningTimer == delayedTimer) + * after we get it from the queue and before the + * lock on the timer is acquired */ timer.post(); // have timer post an event timer.delayedTimer = null; diff --git a/jdk/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextFieldUI.java b/jdk/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextFieldUI.java index 5a5f119c48a..1db0d09a875 100644 --- a/jdk/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextFieldUI.java +++ b/jdk/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextFieldUI.java @@ -97,12 +97,7 @@ public class BasicTextFieldUI extends BasicTextUI { String kind = elem.getName(); if (kind != null) { if (kind.equals(AbstractDocument.ContentElementName)) { - return new GlyphView(elem) { - @Override - public int getResizeWeight(int axis) { - return 0; - } - }; + return new GlyphView(elem); } else if (kind.equals(AbstractDocument.ParagraphElementName)) { return new I18nFieldView(elem); } diff --git a/jdk/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextUI.java b/jdk/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextUI.java index 4058c912563..2941cc9e85b 100644 --- a/jdk/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextUI.java +++ b/jdk/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextUI.java @@ -940,7 +940,7 @@ public abstract class BasicTextUI extends TextUI implements ViewFactory { rootView.setSize(d.width - i.left - i.right - caretMargin, d.height - i.top - i.bottom); } - else if (d.width == 0 || d.height == 0) { + else if (d.width <= 0 || d.height <= 0) { // Probably haven't been layed out yet, force some sort of // initial sizing. rootView.setSize(Integer.MAX_VALUE, Integer.MAX_VALUE); diff --git a/jdk/src/java.desktop/share/classes/javax/swing/text/GlyphView.java b/jdk/src/java.desktop/share/classes/javax/swing/text/GlyphView.java index ccd88f1fc82..31eb62d5d6b 100644 --- a/jdk/src/java.desktop/share/classes/javax/swing/text/GlyphView.java +++ b/jdk/src/java.desktop/share/classes/javax/swing/text/GlyphView.java @@ -537,17 +537,6 @@ public class GlyphView extends View implements TabableView, Cloneable { } } - /** - * {@inheritDoc} - */ - @Override - public int getResizeWeight(int axis) { - if (axis == View.X_AXIS) { - return 1; - } - return 0; - } - /** * Determines the minimum span for this view along an axis. * @@ -561,11 +550,13 @@ public class GlyphView extends View implements TabableView, Cloneable { */ @Override public float getMinimumSpan(int axis) { + int w = getResizeWeight(axis); + if (w == 0) { + // can't resize + return getPreferredSpan(axis); + } switch (axis) { case View.X_AXIS: - if (getResizeWeight(X_AXIS) == 0) { - return getPreferredSpan(X_AXIS); - } if (minimumSpan < 0) { minimumSpan = 0; int p0 = getStartOffset(); diff --git a/jdk/src/java.desktop/share/classes/sun/applet/AppletPanel.java b/jdk/src/java.desktop/share/classes/sun/applet/AppletPanel.java index a262864b4cc..14023fcfa67 100644 --- a/jdk/src/java.desktop/share/classes/sun/applet/AppletPanel.java +++ b/jdk/src/java.desktop/share/classes/sun/applet/AppletPanel.java @@ -687,12 +687,7 @@ abstract class AppletPanel extends Panel implements AppletStub, Runnable { if (toFocus != null) { if (parent instanceof EmbeddedFrame) { - // JDK-8056915: Try to request focus to the embedder first and - // activate the embedded frame through it - if (!((EmbeddedFrame) parent).requestFocusToEmbedder()) { - // Otherwise activate the embedded frame directly - ((EmbeddedFrame) parent).synthesizeWindowActivation(true); - } + ((EmbeddedFrame) parent).synthesizeWindowActivation(true); } // EmbeddedFrame might have focus before the applet was added. // Thus after its activation the most recent focus owner will be diff --git a/jdk/src/java.desktop/share/classes/sun/awt/EmbeddedFrame.java b/jdk/src/java.desktop/share/classes/sun/awt/EmbeddedFrame.java index d90132e35e9..affe2bcb8e7 100644 --- a/jdk/src/java.desktop/share/classes/sun/awt/EmbeddedFrame.java +++ b/jdk/src/java.desktop/share/classes/sun/awt/EmbeddedFrame.java @@ -356,15 +356,6 @@ public abstract class EmbeddedFrame extends Frame */ public void synthesizeWindowActivation(boolean doActivate) {} - /** - * Requests the focus to the embedder. - * - * @return {@code true} if focus request was successful, and {@code false} otherwise. - */ - public boolean requestFocusToEmbedder() { - return false; - } - /** * Moves this embedded frame to a new location. The top-left corner of * the new location is specified by the x and y diff --git a/jdk/src/java.desktop/share/classes/sun/awt/image/MultiResolutionCachedImage.java b/jdk/src/java.desktop/share/classes/sun/awt/image/MultiResolutionCachedImage.java index b1c6dae2c4b..84d3db8d601 100644 --- a/jdk/src/java.desktop/share/classes/sun/awt/image/MultiResolutionCachedImage.java +++ b/jdk/src/java.desktop/share/classes/sun/awt/image/MultiResolutionCachedImage.java @@ -86,19 +86,24 @@ public class MultiResolutionCachedImage extends AbstractMultiResolutionImage { @Override public int getWidth(ImageObserver observer) { updateInfo(observer, ImageObserver.WIDTH); - return super.getWidth(observer); + return baseImageWidth; } @Override public int getHeight(ImageObserver observer) { updateInfo(observer, ImageObserver.HEIGHT); - return super.getHeight(observer); + return baseImageHeight; } @Override public Object getProperty(String name, ImageObserver observer) { updateInfo(observer, ImageObserver.PROPERTIES); - return super.getProperty(name, observer); + return Image.UndefinedProperty; + } + + @Override + public Image getScaledInstance(int width, int height, int hints) { + return getResolutionVariant(width, height); } @Override diff --git a/jdk/src/java.desktop/share/native/libjsound/PortMixer.c b/jdk/src/java.desktop/share/native/libjsound/PortMixer.c index 8213598c0af..c7f35b37b69 100644 --- a/jdk/src/java.desktop/share/native/libjsound/PortMixer.c +++ b/jdk/src/java.desktop/share/native/libjsound/PortMixer.c @@ -272,7 +272,7 @@ void* PORT_NewCompoundControl(void* creatorV, char* type, void** controls, int c } void* PORT_NewFloatControl(void* creatorV, void* controlID, char* type, - float min, float max, float precision, char* units) { + float min, float max, float precision, const char* units) { ControlCreatorJNI* creator = (ControlCreatorJNI*) creatorV; jobject ctrl = NULL; jstring unitsString; diff --git a/jdk/src/java.desktop/share/native/libjsound/Ports.h b/jdk/src/java.desktop/share/native/libjsound/Ports.h index f58ea003b50..5de8930cd0e 100644 --- a/jdk/src/java.desktop/share/native/libjsound/Ports.h +++ b/jdk/src/java.desktop/share/native/libjsound/Ports.h @@ -93,7 +93,7 @@ typedef void* (*PORT_NewCompoundControlPtr)(void* creator, char* type, void** co * returns an opaque pointer to the created control */ typedef void* (*PORT_NewFloatControlPtr)(void* creator, void* controlID, char* type, - float min, float max, float precision, char* units); + float min, float max, float precision, const char* units); /* control: The control to add to current port * creator: pointer to the creator struct provided by PORT_GetControls diff --git a/jdk/src/java.desktop/unix/classes/sun/awt/X11/GtkFileDialogPeer.java b/jdk/src/java.desktop/unix/classes/sun/awt/X11/GtkFileDialogPeer.java index db2f2dcfa5b..d6ef132fede 100644 --- a/jdk/src/java.desktop/unix/classes/sun/awt/X11/GtkFileDialogPeer.java +++ b/jdk/src/java.desktop/unix/classes/sun/awt/X11/GtkFileDialogPeer.java @@ -42,6 +42,8 @@ final class GtkFileDialogPeer extends XDialogPeer implements FileDialogPeer { // A pointer to the native GTK FileChooser widget private volatile long widget = 0L; + private long standaloneWindow; + private volatile boolean quit; GtkFileDialogPeer(FileDialog fd) { super(fd); @@ -111,9 +113,11 @@ final class GtkFileDialogPeer extends XDialogPeer implements FileDialogPeer { public void setVisible(boolean b) { XToolkit.awtLock(); try { + quit = !b; if (b) { Runnable task = () -> { showNativeDialog(); + standaloneWindow = 0; fd.setVisible(false); }; new ManagedLocalsThread(task).start(); @@ -128,7 +132,14 @@ final class GtkFileDialogPeer extends XDialogPeer implements FileDialogPeer { @Override public void dispose() { - quit(); + XToolkit.awtLock(); + try { + quit = true; + quit(); + } + finally { + XToolkit.awtUnlock(); + } super.dispose(); } @@ -144,6 +155,17 @@ final class GtkFileDialogPeer extends XDialogPeer implements FileDialogPeer { // have delegated to FileDialog#setFile } + protected void requestXFocus(long time, boolean timeProvided) { + if(standaloneWindow == 0) { + super.requestXFocus(time, timeProvided); + return; + } + XNETProtocol net_protocol = XWM.getWM().getNETProtocol(); + if (net_protocol != null) { + net_protocol.setActiveWindow(standaloneWindow); + } + } + @Override public void setFilenameFilter(FilenameFilter filter) { // We do not implement this method because we @@ -170,7 +192,21 @@ final class GtkFileDialogPeer extends XDialogPeer implements FileDialogPeer { dirname = file.getParent(); } } - run(fd.getTitle(), fd.getMode(), dirname, filename, - fd.getFilenameFilter(), fd.isMultipleMode(), fd.getX(), fd.getY()); + if (!quit) { + run(fd.getTitle(), fd.getMode(), dirname, filename, + fd.getFilenameFilter(), fd.isMultipleMode(), fd.getX(), fd.getY()); + } + } + + /** + * Called by native code when GTK dialog is created. + */ + boolean setWindow(long xid) { + if (!quit && widget != 0) { + standaloneWindow = xid; + requestXFocus(); + return true; + } + return false; } } diff --git a/jdk/src/java.desktop/unix/classes/sun/awt/X11/XFramePeer.java b/jdk/src/java.desktop/unix/classes/sun/awt/X11/XFramePeer.java index ea60094bb2d..aa1bc2dc83c 100644 --- a/jdk/src/java.desktop/unix/classes/sun/awt/X11/XFramePeer.java +++ b/jdk/src/java.desktop/unix/classes/sun/awt/X11/XFramePeer.java @@ -289,7 +289,7 @@ class XFramePeer extends XDecoratedPeer implements FramePeer { XNETProtocol net_protocol = XWM.getWM().getNETProtocol(); if (net_protocol != null) { - net_protocol.setActiveWindow(this); + net_protocol.setActiveWindow(getWindow()); } xSetVisible(true); } diff --git a/jdk/src/java.desktop/unix/classes/sun/awt/X11/XNETProtocol.java b/jdk/src/java.desktop/unix/classes/sun/awt/X11/XNETProtocol.java index a9122c8e906..5ba80bbef0f 100644 --- a/jdk/src/java.desktop/unix/classes/sun/awt/X11/XNETProtocol.java +++ b/jdk/src/java.desktop/unix/classes/sun/awt/X11/XNETProtocol.java @@ -326,7 +326,7 @@ final class XNETProtocol extends XProtocol implements XStateProtocol, XLayerProt return res; } - public void setActiveWindow(XWindow window) { + public void setActiveWindow(long window) { if (!active() || !checkProtocol(XA_NET_SUPPORTED, XA_NET_ACTIVE_WINDOW)) { return; } @@ -336,7 +336,7 @@ final class XNETProtocol extends XProtocol implements XStateProtocol, XLayerProt msg.set_type(XConstants.ClientMessage); msg.set_message_type(XA_NET_ACTIVE_WINDOW.getAtom()); msg.set_display(XToolkit.getDisplay()); - msg.set_window(window.getWindow()); + msg.set_window(window); msg.set_format(32); msg.set_data(0, 1); msg.set_data(1, XToolkit.getCurrentServerTime()); diff --git a/jdk/src/java.desktop/unix/classes/sun/awt/X11GraphicsDevice.java b/jdk/src/java.desktop/unix/classes/sun/awt/X11GraphicsDevice.java index f24df1fd216..56b4252f761 100644 --- a/jdk/src/java.desktop/unix/classes/sun/awt/X11GraphicsDevice.java +++ b/jdk/src/java.desktop/unix/classes/sun/awt/X11GraphicsDevice.java @@ -316,6 +316,7 @@ public final class X11GraphicsDevice extends GraphicsDevice @Override public boolean isDisplayChangeSupported() { return (isFullScreenSupported() + && (getFullScreenWindow() != null) && !((X11GraphicsEnvironment) GraphicsEnvironment .getLocalGraphicsEnvironment()).runningXinerama()); } diff --git a/jdk/src/java.desktop/unix/classes/sun/java2d/xr/XRDrawImage.java b/jdk/src/java.desktop/unix/classes/sun/java2d/xr/XRDrawImage.java index ea8edbb391a..69502f2ee2a 100644 --- a/jdk/src/java.desktop/unix/classes/sun/java2d/xr/XRDrawImage.java +++ b/jdk/src/java.desktop/unix/classes/sun/java2d/xr/XRDrawImage.java @@ -46,24 +46,28 @@ public class XRDrawImage extends DrawImage { SurfaceData dstData = sg.surfaceData; SurfaceData srcData = dstData.getSourceSurfaceData(img, SunGraphics2D.TRANSFORM_GENERIC, sg.imageComp, bgColor); - int compRule = ((AlphaComposite) sg.composite).getRule(); - float extraAlpha = ((AlphaComposite) sg.composite).getAlpha(); - if (srcData != null && !isBgOperation(srcData, bgColor) + if (sg.composite instanceof AlphaComposite) { + int compRule = ((AlphaComposite) sg.composite).getRule(); + float extraAlpha = ((AlphaComposite) sg.composite).getAlpha(); + + if (srcData != null && !isBgOperation(srcData, bgColor) && interpType <= AffineTransformOp.TYPE_BILINEAR && (XRUtils.isMaskEvaluated(XRUtils.j2dAlphaCompToXR(compRule)) - || (XRUtils.isTransformQuadrantRotated(tx)) && extraAlpha == 1.0f)) - { - SurfaceType srcType = srcData.getSurfaceType(); - SurfaceType dstType = dstData.getSurfaceType(); + || (XRUtils.isTransformQuadrantRotated(tx)) + && extraAlpha == 1.0f)) + { + SurfaceType srcType = srcData.getSurfaceType(); + SurfaceType dstType = dstData.getSurfaceType(); - TransformBlit blit = TransformBlit.getFromCache(srcType, - sg.imageComp, dstType); - if (blit != null) { - blit.Transform(srcData, dstData, sg.composite, - sg.getCompClip(), tx, interpType, sx1, sy1, 0, 0, sx2 + TransformBlit blit = TransformBlit.getFromCache(srcType, + sg.imageComp, dstType); + if (blit != null) { + blit.Transform(srcData, dstData, sg.composite, + sg.getCompClip(), tx, interpType, sx1, sy1, 0, 0, sx2 - sx1, sy2 - sy1); return; + } } } diff --git a/jdk/src/java.desktop/unix/native/common/awt/awt.h b/jdk/src/java.desktop/unix/native/common/awt/awt.h index df5f60300b6..0dacab98a40 100644 --- a/jdk/src/java.desktop/unix/native/common/awt/awt.h +++ b/jdk/src/java.desktop/unix/native/common/awt/awt.h @@ -82,7 +82,12 @@ extern void awt_output_flush(); } while (0) #define AWT_LOCK_IMPL() \ - (*env)->CallStaticVoidMethod(env, tkClass, awtLockMID) + do { \ + (*env)->CallStaticVoidMethod(env, tkClass, awtLockMID); \ + if ((*env)->ExceptionCheck(env)) { \ + (*env)->ExceptionClear(env); \ + } \ + } while(0) #define AWT_NOFLUSH_UNLOCK_IMPL() \ do { \ @@ -91,11 +96,10 @@ extern void awt_output_flush(); (*env)->ExceptionClear(env); \ } \ (*env)->CallStaticVoidMethod(env, tkClass, awtUnlockMID); \ + if ((*env)->ExceptionCheck(env)) { \ + (*env)->ExceptionClear(env); \ + } \ if (pendingException) { \ - if ((*env)->ExceptionCheck(env)) { \ - (*env)->ExceptionDescribe(env); \ - (*env)->ExceptionClear(env); \ - } \ (*env)->Throw(env, pendingException); \ } \ } while (0) diff --git a/jdk/src/java.desktop/unix/native/libawt/awt/awt_LoadLibrary.c b/jdk/src/java.desktop/unix/native/libawt/awt/awt_LoadLibrary.c index 59483027131..3f79aa36c79 100644 --- a/jdk/src/java.desktop/unix/native/libawt/awt/awt_LoadLibrary.c +++ b/jdk/src/java.desktop/unix/native/libawt/awt/awt_LoadLibrary.c @@ -71,6 +71,10 @@ JNIEXPORT jboolean JNICALL AWTIsHeadless() { } isHeadless = (*env)->CallStaticBooleanMethod(env, graphicsEnvClass, headlessFn); + if ((*env)->ExceptionCheck(env)) { + (*env)->ExceptionClear(env); + return JNI_TRUE; + } } return isHeadless; } diff --git a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/HPkeysym.h b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/HPkeysym.h index 2f0447b28f2..f736e752149 100644 --- a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/HPkeysym.h +++ b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/HPkeysym.h @@ -58,7 +58,7 @@ performance, or use of this material. #ifndef _HPKEYSYM_H -#define _HPKEYSYM +#define _HPKEYSYM_H #define hpXK_ClearLine 0x1000FF6F #define hpXK_InsertLine 0x1000FF70 diff --git a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_Event.h b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_Event.h index 21e1db92fdb..06659ef9347 100644 --- a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_Event.h +++ b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_Event.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 1998, 2001, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1998, 2015, 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,7 +28,7 @@ *** ***/ #ifndef _AWT_EVENT_H_ -#define _AWT_EVENT_H +#define _AWT_EVENT_H_ #include "jni_util.h" diff --git a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_GraphicsEnv.c b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_GraphicsEnv.c index 1a20b404ad0..a1c9fc27c44 100644 --- a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_GraphicsEnv.c +++ b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_GraphicsEnv.c @@ -1564,6 +1564,9 @@ Java_sun_awt_X11GraphicsDevice_getDoubleBufferVisuals(JNIEnv *env, for (i = 0; i < visScreenInfo->count; i++) { XdbeVisualInfo* visInfo = visScreenInfo->visinfo; (*env)->CallVoidMethod(env, this, midAddVisual, (visInfo[i]).visual); + if ((*env)->ExceptionCheck(env)) { + break; + } } #endif /* !HEADLESS */ } diff --git a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_util.c b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_util.c index 13ba377966f..261986f9ac0 100644 --- a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_util.c +++ b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/awt_util.c @@ -98,5 +98,8 @@ awtJNI_ThreadYield(JNIEnv *env) { (*env)->CallStaticVoidMethod(env, threadClass, yieldMethodID); DASSERT(!((*env)->ExceptionOccurred(env))); + if ((*env)->ExceptionCheck(env)) { + return JNI_FALSE; + } return JNI_TRUE; } /* awtJNI_ThreadYield() */ diff --git a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.c b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.c index e5711df06c3..84e2df3bdf4 100644 --- a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.c +++ b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.c @@ -576,6 +576,7 @@ void gtk2_file_chooser_load() fp_gtk_file_chooser_get_filenames = dl_symbol( "gtk_file_chooser_get_filenames"); fp_gtk_g_slist_length = dl_symbol("g_slist_length"); + fp_gdk_x11_drawable_get_xid = dl_symbol("gdk_x11_drawable_get_xid"); } gboolean gtk2_load(JNIEnv *env) @@ -904,6 +905,10 @@ gboolean gtk2_load(JNIEnv *env) // Init the thread system to use GLib in a thread-safe mode (*env)->CallStaticVoidMethod(env, clazz, mid_lock); + if ((*env)->ExceptionCheck(env)) { + AWT_UNLOCK(); + return FALSE; + } // Calling g_thread_init() multiple times leads to crash on GLib < 2.24 // We can use g_thread_get_initialized () but it is available only for @@ -922,7 +927,22 @@ gboolean gtk2_load(JNIEnv *env) //called before gtk_init() or gtk_init_check() fp_gdk_threads_init(); } + jthrowable pendExcpn = NULL; + // Exception raised during mid_getAndSetInitializationNeededFlag + // call is saved and error handling is done + // after unlock method is called + if ((pendExcpn = (*env)->ExceptionOccurred(env)) != NULL) { + (*env)->ExceptionClear(env); + } (*env)->CallStaticVoidMethod(env, clazz, mid_unlock); + if (pendExcpn != NULL) { + (*env)->Throw(env, pendExcpn); + } + // check if any exception occured during mid_unlock call + if ((*env)->ExceptionCheck(env)) { + AWT_UNLOCK(); + return FALSE; + } } result = (*fp_gtk_init_check)(NULL, NULL); diff --git a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.h b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.h index 5891a66d5ff..0150f9347bb 100644 --- a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.h +++ b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.h @@ -27,6 +27,7 @@ #include #include +#include #define _G_TYPE_CIC(ip, gt, ct) ((ct*) ip) #define G_TYPE_CHECK_INSTANCE_CAST(instance, g_type, c_type) (_G_TYPE_CIC ((instance), (g_type), c_type)) @@ -820,6 +821,7 @@ void (*fp_gtk_widget_show)(GtkWidget *widget); void (*fp_gtk_main)(void); guint (*fp_gtk_main_level)(void); gchar* (*fp_g_path_get_dirname) (const gchar *file_name); +XID (*fp_gdk_x11_drawable_get_xid) (GdkWindow *drawable); /** * This function is available for GLIB > 2.20, so it MUST be diff --git a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/sun_awt_X11_GtkFileDialogPeer.c b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/sun_awt_X11_GtkFileDialogPeer.c index 68019269031..97fbcc60da0 100644 --- a/jdk/src/java.desktop/unix/native/libawt_xawt/awt/sun_awt_X11_GtkFileDialogPeer.c +++ b/jdk/src/java.desktop/unix/native/libawt_xawt/awt/sun_awt_X11_GtkFileDialogPeer.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2015, 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 @@ -27,6 +27,7 @@ #include #include #include +#include #include "gtk2_interface.h" #include "sun_awt_X11_GtkFileDialogPeer.h" #include "java_awt_FileDialog.h" @@ -38,6 +39,7 @@ static JavaVM *jvm; static jmethodID filenameFilterCallbackMethodID = NULL; static jmethodID setFileInternalMethodID = NULL; static jfieldID widgetFieldID = NULL; +static jmethodID setWindowMethodID = NULL; JNIEXPORT void JNICALL Java_sun_awt_X11_GtkFileDialogPeer_initIDs (JNIEnv *env, jclass cx) @@ -54,6 +56,10 @@ JNIEXPORT void JNICALL Java_sun_awt_X11_GtkFileDialogPeer_initIDs widgetFieldID = (*env)->GetFieldID(env, cx, "widget", "J"); DASSERT(widgetFieldID != NULL); + CHECK_NULL(widgetFieldID); + + setWindowMethodID = (*env)->GetMethodID(env, cx, "setWindow", "(J)Z"); + DASSERT(setWindowMethodID != NULL); } static gboolean filenameFilterCallback(const GtkFileFilterInfo * filter_info, gpointer obj) @@ -401,7 +407,11 @@ Java_sun_awt_X11_GtkFileDialogPeer_run(JNIEnv * env, jobject jpeer, fp_gtk_widget_show(dialog); - fp_gtk_main(); + XID xid = fp_gdk_x11_drawable_get_xid(dialog->window); + if( (*env)->CallBooleanMethod(env, jpeer, setWindowMethodID, xid) ) { + fp_gtk_main(); + } + fp_gdk_threads_leave(); } diff --git a/jdk/src/java.desktop/unix/native/libjsound/PLATFORM_API_LinuxOS_ALSA_Ports.c b/jdk/src/java.desktop/unix/native/libjsound/PLATFORM_API_LinuxOS_ALSA_Ports.c index 1542ad08566..47f3c3f6d89 100644 --- a/jdk/src/java.desktop/unix/native/libjsound/PLATFORM_API_LinuxOS_ALSA_Ports.c +++ b/jdk/src/java.desktop/unix/native/libjsound/PLATFORM_API_LinuxOS_ALSA_Ports.c @@ -431,8 +431,8 @@ void PORT_GetControls(void* id, INT32 portIndex, PortControlCreator* creator) { } } else { // more than two channels, each channels has its own control. for (channel = SND_MIXER_SCHN_FRONT_LEFT; channel <= SND_MIXER_SCHN_LAST; channel++) { - if (isPlayback && snd_mixer_selem_has_playback_channel(elem, channel) || - !isPlayback && snd_mixer_selem_has_capture_channel(elem, channel)) { + if ((isPlayback && snd_mixer_selem_has_playback_channel(elem, channel)) || + (!isPlayback && snd_mixer_selem_has_capture_channel(elem, channel))) { if (getControlSlot(portMixer, &portControl)) { portControl->elem = elem; portControl->portType = portMixer->types[portIndex]; diff --git a/jdk/src/java.desktop/windows/classes/sun/awt/windows/WEmbeddedFrame.java b/jdk/src/java.desktop/windows/classes/sun/awt/windows/WEmbeddedFrame.java index 05769303cc9..a2cac44e4bb 100644 --- a/jdk/src/java.desktop/windows/classes/sun/awt/windows/WEmbeddedFrame.java +++ b/jdk/src/java.desktop/windows/classes/sun/awt/windows/WEmbeddedFrame.java @@ -251,15 +251,6 @@ public class WEmbeddedFrame extends EmbeddedFrame { } } - public boolean requestFocusToEmbedder() { - if (isEmbeddedInIE) { - final WEmbeddedFramePeer peer = AWTAccessor.getComponentAccessor() - .getPeer(this); - return peer.requestFocusToEmbedder(); - } - return false; - } - public void registerAccelerator(AWTKeyStroke stroke) {} public void unregisterAccelerator(AWTKeyStroke stroke) {} diff --git a/jdk/src/java.desktop/windows/classes/sun/awt/windows/WEmbeddedFramePeer.java b/jdk/src/java.desktop/windows/classes/sun/awt/windows/WEmbeddedFramePeer.java index 4cc3a4d716b..c0ef8a78dde 100644 --- a/jdk/src/java.desktop/windows/classes/sun/awt/windows/WEmbeddedFramePeer.java +++ b/jdk/src/java.desktop/windows/classes/sun/awt/windows/WEmbeddedFramePeer.java @@ -79,10 +79,4 @@ public class WEmbeddedFramePeer extends WFramePeer { return !Win32GraphicsEnvironment.isDWMCompositionEnabled(); } - /** - * Sets the focus to plugin control window, the parent of embedded frame. - * Eventually, it will synthesizeWindowActivation to activate the embedded frame, - * if plugin control window gets the focus. - */ - public native boolean requestFocusToEmbedder(); } diff --git a/jdk/src/java.desktop/windows/classes/sun/awt/windows/WListPeer.java b/jdk/src/java.desktop/windows/classes/sun/awt/windows/WListPeer.java index e89aaaea658..9429a9f8949 100644 --- a/jdk/src/java.desktop/windows/classes/sun/awt/windows/WListPeer.java +++ b/jdk/src/java.desktop/windows/classes/sun/awt/windows/WListPeer.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 1996, 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1996, 2015, 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,9 @@ final class WListPeer extends WComponentPeer implements ListPeer { // ListPeer implementation @Override - @SuppressWarnings("deprecation") public int[] getSelectedIndexes() { List l = (List)target; - int len = l.countItems(); + int len = l.getItemCount(); int sel[] = new int[len]; int nsel = 0; for (int i = 0 ; i < len ; i++) { @@ -93,10 +92,9 @@ final class WListPeer extends WComponentPeer implements ListPeer { @Override public native void delItems(int start, int end); - @SuppressWarnings("deprecation") public void clear() { List l = (List)target; - delItems(0, l.countItems()); + delItems(0, l.getItemCount()); } @Override public native void select(int index); @@ -131,7 +129,6 @@ final class WListPeer extends WComponentPeer implements ListPeer { native void create(WComponentPeer parent); @Override - @SuppressWarnings("deprecation") void initialize() { List li = (List)target; @@ -144,7 +141,7 @@ final class WListPeer extends WComponentPeer implements ListPeer { } // add any items that were already inserted in the target. - int nitems = li.countItems(); + int nitems = li.getItemCount(); if (nitems > 0) { String[] items = new String[nitems]; int maxWidth = 0; @@ -160,7 +157,7 @@ final class WListPeer extends WComponentPeer implements ListPeer { } // set whether this list should allow multiple selections. - setMultipleSelections(li.allowsMultipleSelections()); + setMultipleSelections(li.isMultipleMode()); // select the item if necessary. int sel[] = li.getSelectedIndexes(); diff --git a/jdk/src/java.desktop/windows/native/libawt/windows/awt_Frame.cpp b/jdk/src/java.desktop/windows/native/libawt/windows/awt_Frame.cpp index 2c25e975d39..53f6a50149e 100644 --- a/jdk/src/java.desktop/windows/native/libawt/windows/awt_Frame.cpp +++ b/jdk/src/java.desktop/windows/native/libawt/windows/awt_Frame.cpp @@ -1961,29 +1961,6 @@ Java_sun_awt_windows_WFramePeer_synthesizeWmActivate(JNIEnv *env, jobject self, CATCH_BAD_ALLOC; } -JNIEXPORT jboolean JNICALL -Java_sun_awt_windows_WEmbeddedFramePeer_requestFocusToEmbedder(JNIEnv *env, jobject self) -{ - jboolean result = JNI_FALSE; - - TRY; - - AwtFrame *frame = NULL; - - PDATA pData; - JNI_CHECK_PEER_GOTO(self, ret); - frame = (AwtFrame *)pData; - - // JDK-8056915: During initial applet activation, set focus to plugin control window - HWND hwndParent = ::GetParent(frame->GetHWnd()); - - result = SetFocusToPluginControl(hwndParent); - - CATCH_BAD_ALLOC_RET(JNI_FALSE); -ret: - return result; -} - } /* extern "C" */ static bool SetFocusToPluginControl(HWND hwndPlugin) diff --git a/jdk/src/java.management/share/classes/com/sun/jmx/mbeanserver/Introspector.java b/jdk/src/java.management/share/classes/com/sun/jmx/mbeanserver/Introspector.java index e3c273328fc..92dc59c0b64 100644 --- a/jdk/src/java.management/share/classes/com/sun/jmx/mbeanserver/Introspector.java +++ b/jdk/src/java.management/share/classes/com/sun/jmx/mbeanserver/Introspector.java @@ -552,8 +552,10 @@ public class Introspector { // Java Beans introspection // Class clazz = complex.getClass(); - Method readMethod = JavaBeansAccessor.getReadMethod(clazz, element); - if (readMethod == null) { + Method readMethod; + if (JavaBeansAccessor.isAvailable()) { + readMethod = JavaBeansAccessor.getReadMethod(clazz, element); + } else { // Java Beans not available so use simple introspection // to locate method readMethod = SimpleIntrospector.getReadMethod(clazz, element); @@ -676,7 +678,12 @@ public class Introspector { * {@code null} if no method is found. */ static Method getReadMethod(Class clazz, String property) { - // first character in uppercase (compatibility with JavaBeans) + if (Character.isUpperCase(property.charAt(0))) { + // the property name must start with a lower-case letter + return null; + } + // first character after 'get/is' prefix must be in uppercase + // (compatibility with JavaBeans) property = property.substring(0, 1).toUpperCase(Locale.ENGLISH) + property.substring(1); String getMethod = GET_METHOD_PREFIX + property; diff --git a/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/AccessBridgeATInstance.cpp b/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/AccessBridgeATInstance.cpp index 092c4a0b352..e62eb1c983c 100644 --- a/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/AccessBridgeATInstance.cpp +++ b/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/AccessBridgeATInstance.cpp @@ -87,7 +87,7 @@ LRESULT AccessBridgeATInstance::initiateIPC() { DWORD errorCode; - PrintDebugString("\r\nin AccessBridgeATInstance::initiateIPC()"); + PrintDebugString("\r\nIn AccessBridgeATInstance::initiateIPC()"); // open Windows-initiated IPC filemap & map it to a ptr diff --git a/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/AccessBridgeJavaEntryPoints.cpp b/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/AccessBridgeJavaEntryPoints.cpp index 952df4f8c55..9131f363136 100644 --- a/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/AccessBridgeJavaEntryPoints.cpp +++ b/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/AccessBridgeJavaEntryPoints.cpp @@ -40,7 +40,7 @@ AccessBridgeJavaEntryPoints::AccessBridgeJavaEntryPoints(JNIEnv *jniEnvironment, jobject bridgeObject) { jniEnv = jniEnvironment; accessBridgeObject = (jobject)bridgeObject; - PrintDebugString("AccessBridgeJavaEntryPoints(%X, %X) called", jniEnv, accessBridgeObject); + PrintDebugString("AccessBridgeJavaEntryPoints(%p, %p) called", jniEnv, accessBridgeObject); } diff --git a/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/JavaAccessBridge.cpp b/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/JavaAccessBridge.cpp index 52316876bca..40aba7c3a88 100644 --- a/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/JavaAccessBridge.cpp +++ b/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/JavaAccessBridge.cpp @@ -89,53 +89,31 @@ extern "C" { theJavaAccessBridge->javaRun(env, obj); } -#if 0 // SetDlgItemText has caused problems with JAWS - /** - * Append debug info to dialog - * - */ - void AppendToCallInfo(char *s) { - char buffer[4096]; - - PrintDebugString(s); - - GetDlgItemText(theDialogWindow, cCallInfo, buffer, sizeof(buffer)); - if (strlen(buffer) < (sizeof(buffer) - strlen(s))) { - strncat(buffer, s, sizeof(buffer)); - SetDlgItemText(theDialogWindow, cCallInfo, buffer); - } else { - SetDlgItemText(theDialogWindow, cCallInfo, s); - } - } -#endif - - /** * Our window proc * */ - BOOL APIENTRY AccessBridgeDialogProc (HWND hDlg, UINT message, UINT wParam, LONG lParam) { + BOOL APIENTRY AccessBridgeDialogProc (HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam) { int command; COPYDATASTRUCT *sentToUs; char *package; - //DEBUG_CODE(char buffer[256]); switch (message) { case WM_INITDIALOG: - //DEBUG_CODE(SetDlgItemText(theDialogWindow, cStatusText, "Initializing")); + PrintDebugString("In AccessBridgeDialog - Initializing"); break; case WM_COMMAND: command = LOWORD (wParam); + PrintDebugString("In AccessBridgeDialog - Got WM_COMMAND, command: %X", command); break; // call from Java with data for us to deliver case WM_COPYDATA: if (theDialogWindow == (HWND) wParam) { - //DEBUG_CODE(SetDlgItemText(theDialogWindow, cStatusText, "Got WM_COPYDATA from ourselves")); + PrintDebugString("In AccessBridgeDialog - Got WM_COPYDATA from ourselves"); } else { - //DEBUG_CODE(sprintf(buffer, "Got WM_COPYDATA from HWND %p", wParam)); - //DEBUG_CODE(SetDlgItemText(theDialogWindow, cStatusText, buffer)); + PrintDebugString("In AccessBridgeDialog - Got WM_COPYDATA from HWND %p", wParam); sentToUs = (COPYDATASTRUCT *) lParam; package = (char *) sentToUs->lpData; theJavaAccessBridge->processPackage(package, sentToUs->cbData); @@ -147,18 +125,16 @@ extern "C" { // wParam == sourceHwnd // lParam == buffer size in shared memory if (theDialogWindow == (HWND) wParam) { - //DEBUG_CODE(SetDlgItemText(theDialogWindow, cStatusText, "Got AB_MESSAGE_WAITING from ourselves")); + PrintDebugString("In AccessBridgeDialog - Got AB_MESSAGE_WAITING from ourselves"); } else { - //DEBUG_CODE(sprintf(buffer, "Got AB_MESSAGE_WAITING from HWND %p", wParam)); - //DEBUG_CODE(SetDlgItemText(theDialogWindow, cStatusText, buffer)); - LRESULT returnVal = theJavaAccessBridge->receiveMemoryPackage((HWND) wParam, lParam); + PrintDebugString("In AccessBridgeDialog - Got AB_MESSAGE_WAITING from HWND %p", wParam); + LRESULT returnVal = theJavaAccessBridge->receiveMemoryPackage((HWND) wParam, (long) lParam); } break; // a JavaAccessBridge DLL is going away case AB_DLL_GOING_AWAY: - // wParam == sourceHwnd - //DEBUG_CODE(SetDlgItemText(theDialogWindow, cStatusText, "Got AB_DLL_GOING_AWAY message")); + PrintDebugString("In AccessBridgeDialog - Got AB_DLL_GOING_AWAY message"); theJavaAccessBridge->WindowsATDestroyed((HWND) wParam); break; @@ -169,6 +145,7 @@ extern "C" { // A new Windows AT just said "hi"; // say "hi" back so it can mate up with us // otherwise don't do anything (e.g. don't set up data structures yet) + PrintDebugString("In AccessBridgeDialog - Got theFromWindowsHelloMsgID message"); theJavaAccessBridge->postHelloToWindowsDLLMsg((HWND) wParam); } } @@ -324,9 +301,9 @@ JavaAccessBridge::initWindow() { */ void JavaAccessBridge::postHelloToWindowsDLLMsg(HWND destHwnd) { - PrintDebugString("\r\nin JavaAccessBridge::postHelloToWindowsDLLMsg"); + PrintDebugString("\r\nIn JavaAccessBridge::postHelloToWindowsDLLMsg"); PrintDebugString(" calling PostMessage(%p, %X, %p, %p)", - destHwnd, theFromJavaHelloMsgID, dialogWindow, javaVM); + destHwnd, theFromJavaHelloMsgID, dialogWindow, dialogWindow); PostMessage(destHwnd, theFromJavaHelloMsgID, (WPARAM) dialogWindow, (LPARAM) dialogWindow); } @@ -2493,7 +2470,7 @@ JavaAccessBridge::firePropertyTableModelChange(JNIEnv *env, jobject callingObj, jobject eventObj, jobject source) { \ \ PrintDebugString("\r\nFiring event id = %d(%p, %p, %p, %p); vmID = %X", \ - eventConstant, env, callingObj, eventObj, source, javaVM); \ + eventConstant, env, callingObj, eventObj, source, dialogWindow); \ \ /* sanity check */ \ if (ATs == (AccessBridgeATInstance *) 0) { \ @@ -2531,7 +2508,7 @@ JavaAccessBridge::firePropertyTableModelChange(JNIEnv *env, jobject callingObj, void JavaAccessBridge::javaShutdown(JNIEnv *env, jobject callingObj) { PrintDebugString("\r\nFiring event id = %d(%p, %p); vmID = %X", - cJavaShutdownEvent, env, callingObj, javaVM); + cJavaShutdownEvent, env, callingObj, dialogWindow); /* sanity check */ if (ATs == (AccessBridgeATInstance *) 0) { diff --git a/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/JavaAccessBridge.h b/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/JavaAccessBridge.h index d03960f7f00..9340f819c88 100644 --- a/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/JavaAccessBridge.h +++ b/jdk/src/jdk.accessibility/windows/native/libjavaaccessbridge/JavaAccessBridge.h @@ -44,7 +44,7 @@ extern "C" { LPVOID lpvReserved); void AppendToCallOutput(char *s); BOOL APIENTRY AccessBridgeDialogProc(HWND hDlg, UINT message, - UINT wParam, LONG lParam); + WPARAM wParam, LPARAM lParam); } /** diff --git a/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/AccessBridgeJavaVMInstance.cpp b/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/AccessBridgeJavaVMInstance.cpp index 7294a3e5c6b..129cf144fb4 100644 --- a/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/AccessBridgeJavaVMInstance.cpp +++ b/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/AccessBridgeJavaVMInstance.cpp @@ -188,7 +188,7 @@ AccessBridgeJavaVMInstance::initiateIPC() { * with the Java AccessBridge DLL * * NOTE: WM_COPYDATA is only for one-way IPC; there - * is now way to return parameters (especially big ones) + * is no way to return parameters (especially big ones) * Use sendMemoryPackage() to do that! */ LRESULT diff --git a/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/AccessBridgeWindowsEntryPoints.cpp b/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/AccessBridgeWindowsEntryPoints.cpp index afd5677550f..22004433b07 100644 --- a/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/AccessBridgeWindowsEntryPoints.cpp +++ b/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/AccessBridgeWindowsEntryPoints.cpp @@ -51,7 +51,6 @@ extern "C" { // open our window if (theWindowsAccessBridge != (WinAccessBridge *) 0) { theWindowsAccessBridge->initWindow(); - DEBUG_CODE(SetDlgItemText(theDialogWindow, cInvokedByText, "Windows")); } } diff --git a/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/WinAccessBridge.cpp b/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/WinAccessBridge.cpp index a24e8fa45a3..17412f9befd 100644 --- a/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/WinAccessBridge.cpp +++ b/jdk/src/jdk.accessibility/windows/native/libwindowsaccessbridge/WinAccessBridge.cpp @@ -366,7 +366,7 @@ LRESULT WinAccessBridge::rendezvousWithNewJavaDLL(HWND JavaBridgeDLLwindow, long vmID) { LRESULT returnVal; - PrintDebugString("in JavaAccessBridge::rendezvousWithNewJavaDLL(%p, %X)", + PrintDebugString("in WinAccessBridge::rendezvousWithNewJavaDLL(%p, %X)", JavaBridgeDLLwindow, vmID); isVMInstanceChainInUse = true; @@ -880,7 +880,7 @@ WinAccessBridge::isJavaWindow(HWND window) { return FALSE; } - PrintDebugString(" in WinAccessBridge::isJavaWindow"); + PrintDebugString("In WinAccessBridge::isJavaWindow"); diff --git a/jdk/src/jdk.crypto.pkcs11/share/native/libj2pkcs11/p11_convert.c b/jdk/src/jdk.crypto.pkcs11/share/native/libj2pkcs11/p11_convert.c index 89842582b82..78e52a20404 100644 --- a/jdk/src/jdk.crypto.pkcs11/share/native/libj2pkcs11/p11_convert.c +++ b/jdk/src/jdk.crypto.pkcs11/share/native/libj2pkcs11/p11_convert.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved. */ /* Copyright (c) 2002 Graz University of Technology. All rights reserved. @@ -474,6 +474,7 @@ CK_SSL3_MASTER_KEY_DERIVE_PARAMS jSsl3MasterKeyDeriveParamToCKSsl3MasterKeyDeriv jfieldID fieldID; jclass jSsl3RandomDataClass; jobject jRandomInfo, jRIClientRandom, jRIServerRandom, jVersion; + memset(&ckParam, 0, sizeof(CK_SSL3_MASTER_KEY_DERIVE_PARAMS)); /* get RandomInfo */ jSsl3MasterKeyDeriveParamsClass = (*env)->FindClass(env, CLASS_SSL3_MASTER_KEY_DERIVE_PARAMS); @@ -527,6 +528,7 @@ CK_TLS_PRF_PARAMS jTlsPrfParamsToCKTlsPrfParam(JNIEnv *env, jobject jParam) CK_TLS_PRF_PARAMS ckParam; jfieldID fieldID; jobject jSeed, jLabel, jOutput; + memset(&ckParam, 0, sizeof(CK_TLS_PRF_PARAMS)); // TBD: what if jParam == NULL?! @@ -592,6 +594,7 @@ CK_SSL3_KEY_MAT_PARAMS jSsl3KeyMatParamToCKSsl3KeyMatParam(JNIEnv *env, jobject jobject jRandomInfo, jRIClientRandom, jRIServerRandom; jobject jReturnedKeyMaterial, jRMIvClient, jRMIvServer; CK_ULONG ckTemp; + memset(&ckParam, 0, sizeof(CK_SSL3_KEY_MAT_PARAMS)); /* get ulMacSizeInBits */ jSsl3KeyMatParamsClass = (*env)->FindClass(env, CLASS_SSL3_KEY_MAT_PARAMS); @@ -1355,6 +1358,7 @@ CK_RSA_PKCS_OAEP_PARAMS jRsaPkcsOaepParamToCKRsaPkcsOaepParam(JNIEnv *env, jobje jlong jHashAlg, jMgf, jSource; jobject jSourceData; CK_BYTE_PTR ckpByte; + memset(&ckParam, 0, sizeof(CK_RSA_PKCS_OAEP_PARAMS)); /* get hashAlg */ jRsaPkcsOaepParamsClass = (*env)->FindClass(env, CLASS_RSA_PKCS_OAEP_PARAMS); @@ -1404,6 +1408,7 @@ CK_PBE_PARAMS jPbeParamToCKPbeParam(JNIEnv *env, jobject jParam) jlong jIteration; jobject jInitVector, jPassword, jSalt; CK_ULONG ckTemp; + memset(&ckParam, 0, sizeof(CK_PBE_PARAMS)); /* get pInitVector */ jPbeParamsClass = (*env)->FindClass(env, CLASS_PBE_PARAMS); @@ -1522,6 +1527,7 @@ CK_PKCS5_PBKD2_PARAMS jPkcs5Pbkd2ParamToCKPkcs5Pbkd2Param(JNIEnv *env, jobject j jfieldID fieldID; jlong jSaltSource, jIteration, jPrf; jobject jSaltSourceData, jPrfData; + memset(&ckParam, 0, sizeof(CK_PKCS5_PBKD2_PARAMS)); /* get saltSource */ jPkcs5Pbkd2ParamsClass = (*env)->FindClass(env, CLASS_PKCS5_PBKD2_PARAMS); @@ -1734,6 +1740,7 @@ CK_X9_42_DH1_DERIVE_PARAMS jX942Dh1DeriveParamToCKX942Dh1DeriveParam(JNIEnv *env jfieldID fieldID; jlong jKdf; jobject jOtherInfo, jPublicData; + memset(&ckParam, 0, sizeof(CK_X9_42_DH1_DERIVE_PARAMS)); /* get kdf */ jX942Dh1DeriveParamsClass = (*env)->FindClass(env, CLASS_X9_42_DH1_DERIVE_PARAMS); @@ -1779,6 +1786,7 @@ CK_X9_42_DH2_DERIVE_PARAMS jX942Dh2DeriveParamToCKX942Dh2DeriveParam(JNIEnv *env jfieldID fieldID; jlong jKdf, jPrivateDataLen, jPrivateData; jobject jOtherInfo, jPublicData, jPublicData2; + memset(&ckParam, 0, sizeof(CK_X9_42_DH2_DERIVE_PARAMS)); /* get kdf */ jX942Dh2DeriveParamsClass = (*env)->FindClass(env, CLASS_X9_42_DH2_DERIVE_PARAMS); diff --git a/jdk/src/jdk.sctp/share/classes/com/sun/nio/sctp/SctpChannel.java b/jdk/src/jdk.sctp/share/classes/com/sun/nio/sctp/SctpChannel.java index 445b75530cb..065b13036e5 100644 --- a/jdk/src/jdk.sctp/share/classes/com/sun/nio/sctp/SctpChannel.java +++ b/jdk/src/jdk.sctp/share/classes/com/sun/nio/sctp/SctpChannel.java @@ -538,11 +538,11 @@ public abstract class SctpChannel * {@link java.io.IOException} to be thrown. * *

      If this channel is already connected then this method will not block - * and will immediately return true. If this channel is in - * non-blocking mode then this method will return false if the + * and will immediately return {@code true}. If this channel is in + * non-blocking mode then this method will return {@code false} if the * connection process is not yet complete. If this channel is in blocking * mode then this method will block until the connection either completes - * or fails, and will always either return true or throw a checked + * or fails, and will always either return {@code true} or throw a checked * exception describing the failure. * *

      This method may be invoked at any time. If a {@link #send send} or {@link #receive receive} @@ -711,9 +711,9 @@ public abstract class SctpChannel * Returns an operation set identifying this channel's supported operations. * *

      SCTP channels support connecting, reading, and writing, so this - * method returns ({@link SelectionKey#OP_CONNECT} - * | {@link SelectionKey#OP_READ} | {@link - * SelectionKey#OP_WRITE}).

      + * method returns {@code (}{@link SelectionKey#OP_CONNECT} + * {@code |} {@link SelectionKey#OP_READ} {@code |} {@link + * SelectionKey#OP_WRITE}{@code )}. * * @return The valid-operation set */ diff --git a/jdk/test/ProblemList.txt b/jdk/test/ProblemList.txt index 10be3c68111..67724532e40 100644 --- a/jdk/test/ProblemList.txt +++ b/jdk/test/ProblemList.txt @@ -353,6 +353,10 @@ com/sun/jdi/GetLocalVariables4Test.sh windows-all # 8062512 java/util/spi/ResourceBundleControlProvider/UserDefaultControlTest.java generic-all +# 8029453 +java/util/concurrent/locks/ReentrantLock/TimeoutLockLoops.java linux-all + + ############################################################################ # jdk_instrument diff --git a/jdk/test/com/sun/jmx/mbeanserver/introspector/BeanClass.java b/jdk/test/com/sun/jmx/mbeanserver/introspector/BeanClass.java new file mode 100644 index 00000000000..06746f64923 --- /dev/null +++ b/jdk/test/com/sun/jmx/mbeanserver/introspector/BeanClass.java @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2015, 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 + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +public class BeanClass { + public int getNumber() {return 1;} + public boolean isAvailable() {return false;} +} diff --git a/jdk/test/com/sun/jmx/mbeanserver/introspector/SimpleIntrospectorTest.java b/jdk/test/com/sun/jmx/mbeanserver/introspector/SimpleIntrospectorTest.java new file mode 100644 index 00000000000..1b463f585a2 --- /dev/null +++ b/jdk/test/com/sun/jmx/mbeanserver/introspector/SimpleIntrospectorTest.java @@ -0,0 +1,104 @@ + +/* + * Copyright (c) 2015, 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 + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ +import java.lang.reflect.Method; + +/* + * @test + * @bug 8129215 + * @summary The test checks whether the SimpleIntrospector is honoring the + * the JavaBeans property naming convention of always starting + * with a lower-case letter + * + * @author Jaroslav Bachorik + * @modules java.management + * @run clean SimpleIntrospectorTest + * @run build SimpleIntrospectorTest BeanClass + * @run main SimpleIntrospectorTest + */ +public class SimpleIntrospectorTest { + private static Method INTROSPECT_GETTER; + + public static void main(String ... args) throws Exception { + Class clz = Class.forName( + "com.sun.jmx.mbeanserver.Introspector$SimpleIntrospector" + ); + INTROSPECT_GETTER = clz.getDeclaredMethod( + "getReadMethod", + Class.class, + String.class + ); + INTROSPECT_GETTER.setAccessible(true); + boolean result = true; + result &= checkNumberValid(); + result &= checkNumberInvalid(); + result &= checkAvailableValid(); + result &= checkAvailableInvalid(); + + if (!result) { + throw new Error(); + } + } + + private static boolean checkNumberValid() throws Exception { + return checkGetter(false, "number"); + } + + private static boolean checkNumberInvalid() throws Exception { + return checkGetter(true, "Number"); + } + + private static boolean checkAvailableValid() throws Exception { + return checkGetter(false, "available"); + } + + private static boolean checkAvailableInvalid() throws Exception { + return checkGetter(true, "Available"); + } + + private static boolean checkGetter(boolean nullExpected, String name) + throws Exception { + Method m = getReadMethod(BeanClass.class, name); + boolean result = (m != null); + if (nullExpected) result = !result; + + if (result) { + return true; + } + if (nullExpected) { + System.err.println("SimpleIntrospector resolved an unknown getter " + + "for attribute '"+ name +"'"); + } else { + System.err.println("SimpleIntrospector fails to resolve getter " + + "for attribute '"+ name +"'"); + } + return false; + } + + private static Method getReadMethod(Class clz, String attr) + throws Exception { + return (Method)INTROSPECT_GETTER.invoke(null, clz, attr); + } +} diff --git a/jdk/test/java/awt/FileDialog/ModalFocus/FileDialogModalFocusTest.java b/jdk/test/java/awt/FileDialog/ModalFocus/FileDialogModalFocusTest.java new file mode 100644 index 00000000000..aa8b2292f74 --- /dev/null +++ b/jdk/test/java/awt/FileDialog/ModalFocus/FileDialogModalFocusTest.java @@ -0,0 +1,137 @@ +/* + * Copyright (c) 2015, 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 + * 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 8025815 + @summary Child FileDialog of modal dialog does not get focus on Gnome + @author Semyon Sadetsky + */ + +import javax.swing.*; +import java.awt.*; +import java.awt.event.*; +import java.awt.image.BufferedImage; +import java.lang.reflect.InvocationTargetException; +import java.util.concurrent.TimeUnit; +import java.util.concurrent.locks.Condition; +import java.util.concurrent.locks.ReentrantLock; + +public class FileDialogModalFocusTest { + public static void main(String[] args) throws Exception { + Frame frame = new Frame(); + FileDialog fileDialog = new FileDialog((Frame) null); + test(frame, fileDialog); + frame = new Frame(); + fileDialog = new FileDialog(frame); + test(frame, fileDialog); + System.out.println("ok"); + } + + private static void test(final Frame frame, final FileDialog fileDialog) + throws InterruptedException, InvocationTargetException, + AWTException { + Button button = new Button(); + button.setBackground(Color.RED); + button.addActionListener(new ActionListener() { + @Override + public void actionPerformed(ActionEvent e) { + fileDialog.setVisible(true); + } + }); + frame.add(button); + frame.setSize(200, 200); + EventQueue.invokeAndWait(new Runnable() { + @Override + public void run() { + frame.setVisible(true); + } + }); + Robot robot = new Robot(); + robot.setAutoDelay(200); + robot.waitForIdle(); + Point point = button.getLocationOnScreen(); + point.translate(100, 100); + robot.mouseMove(point.x, point.y); + robot.mousePress(InputEvent.BUTTON1_MASK); + robot.mouseRelease(InputEvent.BUTTON1_MASK); + int delay = 0; + while (frame.isFocused() && delay < 2000) { + robot.delay(50); + delay += 50; + } + ReentrantLock lock = new ReentrantLock(); + Condition condition = lock.newCondition(); + button.addComponentListener(new ComponentAdapter() { + @Override + public void componentResized(ComponentEvent e) { + lock.lock(); + condition.signal(); + lock.unlock(); + } + }); + lock.lock(); + EventQueue.invokeLater(new Runnable() { + @Override + public void run() { + frame.setExtendedState(JFrame.MAXIMIZED_BOTH); + } + }); + condition.await(5, TimeUnit.SECONDS); + lock.unlock(); + robot.delay(200); + robot.waitForIdle(); + EventQueue.invokeAndWait(new Runnable() { + @Override + public void run() { + button.requestFocus(); + Point p = new Point(button.getWidth() - 10, button.getHeight() - 10); + SwingUtilities.convertPointToScreen(p, button); + robot.mouseMove(p.x, p.y); + robot.mousePress(InputEvent.BUTTON1_MASK); + robot.mouseRelease(InputEvent.BUTTON1_MASK); + } + }); + robot.waitForIdle(); + Point p = new Point(100, 100); + SwingUtilities.convertPointToScreen(p, button); + BufferedImage image = robot.createScreenCapture( + new Rectangle(p, + new Dimension(button.getWidth() - 200, + button.getHeight() - 200))); + boolean found = false; + for (int x = 0; x < image.getWidth(); x+=50) { + for (int y = 0; y < image.getHeight(); y+=50) { + if( (image.getRGB(x, y) & 0x00FFFF) != 0 ) { + found = true; + break; + }; + } + } + frame.dispose(); + robot.waitForIdle(); + fileDialog.dispose(); + if(!found) { + throw new RuntimeException("file chooser is underneath"); + } + } +} \ No newline at end of file diff --git a/jdk/test/java/awt/event/KeyEvent/KeyTyped/CtrlASCII.java b/jdk/test/java/awt/event/KeyEvent/KeyTyped/CtrlASCII.java index cf3f1e3d941..1c63ea856b6 100644 --- a/jdk/test/java/awt/event/KeyEvent/KeyTyped/CtrlASCII.java +++ b/jdk/test/java/awt/event/KeyEvent/KeyTyped/CtrlASCII.java @@ -257,8 +257,12 @@ public class CtrlASCII extends Applet implements KeyListener }// start() public void punchCtrlKey( Robot ro, int keyCode ) { ro.keyPress(KeyEvent.VK_CONTROL); - ro.keyPress(keyCode); - ro.keyRelease(keyCode); + try { + ro.keyPress(keyCode); + ro.keyRelease(keyCode); + }catch(IllegalArgumentException iae) { + System.err.println("skip probably invalid keyCode "+keyCode); + } ro.keyRelease(KeyEvent.VK_CONTROL); ro.delay(200); } diff --git a/jdk/test/java/awt/image/DrawImage/IncorrectClipXorModeSurface2Surface.java b/jdk/test/java/awt/image/DrawImage/IncorrectClipXorModeSurface2Surface.java index 8a9b1bd1ae7..c23a1cf0968 100644 --- a/jdk/test/java/awt/image/DrawImage/IncorrectClipXorModeSurface2Surface.java +++ b/jdk/test/java/awt/image/DrawImage/IncorrectClipXorModeSurface2Surface.java @@ -40,7 +40,7 @@ import static java.awt.geom.Rectangle2D.Double; /** * @test - * @bug 8061831 + * @bug 8061831 8130400 * @summary Tests drawing volatile image to volatile image using different * clips + xor mode. Results of the blit compatibleImage to * compatibleImage is used for comparison. diff --git a/jdk/test/java/awt/image/multiresolution/MultiResolutionCachedImageTest.java b/jdk/test/java/awt/image/multiresolution/MultiResolutionCachedImageTest.java new file mode 100644 index 00000000000..9b4a52ed739 --- /dev/null +++ b/jdk/test/java/awt/image/multiresolution/MultiResolutionCachedImageTest.java @@ -0,0 +1,113 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import java.awt.Color; +import java.awt.Dimension; +import java.awt.Graphics; +import java.awt.Image; +import java.awt.geom.Dimension2D; +import java.awt.image.BufferedImage; +import sun.awt.image.MultiResolutionCachedImage; + +/** + * @test + * @bug 8132123 + * @author Alexander Scherbatiy + * @summary MultiResolutionCachedImage unnecessarily creates base image to get + * its size + * @modules java.desktop/sun.awt.image + * @run main MultiResolutionCachedImageTest + */ +public class MultiResolutionCachedImageTest { + + private static final Color TEST_COLOR = Color.BLUE; + + public static void main(String[] args) { + + Image image = new TestMultiResolutionCachedImage(100); + + image.getWidth(null); + image.getHeight(null); + image.getProperty("comment", null); + + int scaledSize = 50; + Image scaledImage = image.getScaledInstance(scaledSize, scaledSize, + Image.SCALE_SMOOTH); + + if (!(scaledImage instanceof BufferedImage)) { + throw new RuntimeException("Wrong scaled image!"); + } + + BufferedImage buffScaledImage = (BufferedImage) scaledImage; + + if (buffScaledImage.getWidth() != scaledSize + || buffScaledImage.getHeight() != scaledSize) { + throw new RuntimeException("Wrong scaled image!"); + } + + if (buffScaledImage.getRGB(scaledSize / 2, scaledSize / 2) != TEST_COLOR.getRGB()) { + throw new RuntimeException("Wrong scaled image!"); + } + } + + private static Dimension2D getDimension(int size) { + return new Dimension(size, size); + } + + private static Dimension2D[] getSizes(int size) { + return new Dimension2D[]{getDimension(size), getDimension(2 * size)}; + } + + private static Image createImage(int width, int height) { + BufferedImage buffImage = new BufferedImage(width, height, + BufferedImage.TYPE_INT_RGB); + Graphics g = buffImage.createGraphics(); + g.setColor(TEST_COLOR); + g.fillRect(0, 0, width, height); + return buffImage; + } + + private static class TestMultiResolutionCachedImage + extends MultiResolutionCachedImage { + + private final int size; + + public TestMultiResolutionCachedImage(int size) { + super(size, size, getSizes(size), (w, h) -> createImage(w, h)); + this.size = size; + } + + @Override + public Image getResolutionVariant(int width, int height) { + if (width == size || height == size) { + throw new RuntimeException("Base image is requested!"); + } + return super.getResolutionVariant(width, height); + } + + @Override + protected Image getBaseImage() { + throw new RuntimeException("Base image is used"); + } + } +} diff --git a/jdk/test/java/beans/Introspector/4058433/TestBeanInfoPriority.java b/jdk/test/java/beans/Introspector/4058433/TestBeanInfoPriority.java new file mode 100644 index 00000000000..589e9c06696 --- /dev/null +++ b/jdk/test/java/beans/Introspector/4058433/TestBeanInfoPriority.java @@ -0,0 +1,294 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + + +import java.awt.event.ActionListener; +import java.awt.event.MouseListener; +import java.beans.BeanDescriptor; +import java.beans.BeanInfo; +import java.beans.BeanProperty; +import java.beans.EventSetDescriptor; +import java.beans.IntrospectionException; +import java.beans.Introspector; +import java.beans.JavaBean; +import java.beans.MethodDescriptor; +import java.beans.PropertyDescriptor; +import java.beans.SimpleBeanInfo; +import javax.swing.SwingContainer; +import java.util.Arrays; + +/** + * @test + * @bug 4058433 8131055 + * @summary Check if the user-defined bean info + * is not overridden with the annotated one. + * @author a.stepanov + */ + + +public class TestBeanInfoPriority { + + // ========== test bean (annotations must be ignored!) ========== + + @JavaBean( + description = "annotation-description", + defaultProperty = "other", + defaultEventSet = "mouse") + @SwingContainer(value = false) + public static class TestClass { + + private int value; + private double other; + + @BeanProperty( + bound = false, + expert = false, + hidden = false, + preferred = false, + required = false, + visualUpdate = false, + description = "annotation-value", + enumerationValues = { + "javax.swing.SwingConstants.NORTH"} + ) + public void setValue(int v) { value = v; } + public int getValue() { return value; } + + + @BeanProperty( + bound = true, + expert = true, + hidden = true, + preferred = true, + required = true, + visualUpdate = true, + description = "annotation-other", + enumerationValues = { + "javax.swing.SwingConstants.LEFT", + "javax.swing.SwingConstants.RIGHT", + "javax.swing.SwingConstants.CENTER"} + ) + public void setOther(double o) { other = o; } + public double getOther() { return other; } + + public void addActionListener(ActionListener l) {} + public void removeActionListener(ActionListener l) {} + + public void addMouseListener(MouseListener l) {} + public void removeMouseListener(MouseListener l) {} + } + + // ========== user-defined bean info ========== + + public static class TestClassBeanInfo extends SimpleBeanInfo { + + private static final int iOther = 0; + private static final int iValue = 1; + + private static final int iAction = 0; + private static final int iMouse = 1; + + + @Override + public BeanDescriptor getBeanDescriptor() { + + BeanDescriptor bd = new BeanDescriptor(TestClass.class, null); + bd.setShortDescription("user-defined-description"); + bd.setValue("isContainer", true); + bd.setValue("containerDelegate", "user-defined-delegate"); + + return bd; + } + + @Override + public PropertyDescriptor[] getPropertyDescriptors() { + + PropertyDescriptor[] p = new PropertyDescriptor[2]; + + try { + + // value + PropertyDescriptor pdValue = new PropertyDescriptor( + "value", TestClass.class, "getValue", "setValue"); + pdValue.setBound(true); + pdValue.setConstrained(true); + pdValue.setExpert(true); + pdValue.setHidden(true); + pdValue.setPreferred(true); + pdValue.setValue("required", true); + pdValue.setValue("visualUpdate", true); + pdValue.setShortDescription("user-defined-value"); + pdValue.setValue("enumerationValues", new Object[]{ + "EAST", 3, "javax.swing.SwingConstants.EAST", + "WEST", 7, "javax.swing.SwingConstants.WEST"}); + p[iValue] = pdValue; + + // other + PropertyDescriptor pdOther = new PropertyDescriptor( + "other", TestClass.class, "getOther", "setOther"); + pdOther.setBound(false); + pdOther.setConstrained(false); + pdOther.setExpert(false); + pdOther.setHidden(false); + pdOther.setPreferred(false); + pdOther.setValue("required", false); + pdOther.setValue("visualUpdate", false); + pdOther.setShortDescription("user-defined-other"); + pdOther.setValue("enumerationValues", new Object[]{ + "TOP", 1, "javax.swing.SwingConstants.TOP"}); + p[iOther] = pdOther; + + } catch(IntrospectionException e) { + e.printStackTrace(); + } + + return p; + } + + @Override + public EventSetDescriptor[] getEventSetDescriptors() { + EventSetDescriptor[] es = new EventSetDescriptor[2]; + try { + es[iAction] = new EventSetDescriptor( + TestClass.class, + "actionListener", + java.awt.event.ActionListener.class, + new String[] {"actionPerformed"}, + "addActionListener", + "removeActionListener"); + es[iMouse] = new EventSetDescriptor( + TestClass.class, + "mouseListener", + java.awt.event.MouseListener.class, + new String[] {"mouseClicked", "mousePressed", "mouseReleased", "mouseEntered", "mouseExited"}, + "addMouseListener", + "removeMouseListener"); + } catch(IntrospectionException e) { + e.printStackTrace(); + } + return es; + } + + @Override + public MethodDescriptor[] getMethodDescriptors() { + MethodDescriptor[] m = new MethodDescriptor[0]; + return m; + } + + @Override + public int getDefaultPropertyIndex() { return iValue; } // default: value + + @Override + public int getDefaultEventIndex() { return iAction; } // default: action + + @Override + public java.awt.Image getIcon(int iconKind) { return null; } + } + + // ========== auxiliary functions ========== + + static void checkEq(String what, Object v, Object ref) throws Exception { + + if ((v != null) && v.equals(ref)) { + System.out.println(what + ": ok (" + ref.toString() + ")"); + } else { + throw new Exception( + "invalid " + what + ", expected: \"" + ref + "\", got: \"" + v + "\""); + } + } + + static void checkEnumEq(String what, Object v, Object ref[]) throws Exception { + + what = "\"" + what + "\""; + if (v == null) { + throw new Exception("null " + what + " enumeration values"); + } + + String msg = "invalid " + what + " enumeration values"; + if (!(v instanceof Object[])) { throw new Exception(msg); } + + if (Arrays.equals((Object []) v, ref)) { + System.out.println(what + " enumeration values: ok"); + } else { throw new Exception(msg); } + } + + + // ========== test ========== + + + public static void main(String[] args) throws Exception { + + BeanInfo i = Introspector.getBeanInfo(TestClass.class, Object.class); + BeanDescriptor bd = i.getBeanDescriptor(); + + checkEq("description", bd.getShortDescription(), "user-defined-description"); + checkEq("default property index", i.getDefaultPropertyIndex(), 1); + checkEq("default event index", i.getDefaultEventIndex(), 0); + + checkEq("isContainer", i.getBeanDescriptor().getValue("isContainer"), true); + checkEq("containerDelegate", + i.getBeanDescriptor().getValue("containerDelegate"), "user-defined-delegate"); + System.out.println(""); + + PropertyDescriptor[] pds = i.getPropertyDescriptors(); + for (PropertyDescriptor pd: pds) { + String name = pd.getName(); + switch (name) { + case "value": + checkEq("\"value\" isBound", pd.isBound(), true); + checkEq("\"value\" isConstrained", pd.isConstrained(), true); + checkEq("\"value\" isExpert", pd.isExpert(), true); + checkEq("\"value\" isHidden", pd.isHidden(), true); + checkEq("\"value\" isPreferred", pd.isPreferred(), true); + checkEq("\"value\" required", pd.getValue("required"), true); + checkEq("\"value\" visualUpdate", pd.getValue("visualUpdate"), true); + + checkEq("\"value\" description", pd.getShortDescription(), "user-defined-value"); + + checkEnumEq(pd.getName(), pd.getValue("enumerationValues"), + new Object[]{ + "EAST", 3, "javax.swing.SwingConstants.EAST", + "WEST", 7, "javax.swing.SwingConstants.WEST"}); + System.out.println(""); + break; + case "other": + checkEq("\"other\" isBound", pd.isBound(), false); + checkEq("\"other\" isConstrained", pd.isConstrained(), false); + checkEq("\"other\" isExpert", pd.isExpert(), false); + checkEq("\"other\" isHidden", pd.isHidden(), false); + checkEq("\"other\" isPreferred", pd.isPreferred(), false); + checkEq("\"other\" required", pd.getValue("required"), false); + checkEq("\"other\" visualUpdate", pd.getValue("visualUpdate"), false); + + checkEq("\"other\" description", pd.getShortDescription(), "user-defined-other"); + + checkEnumEq(pd.getName(), pd.getValue("enumerationValues"), + new Object[]{"TOP", 1, "javax.swing.SwingConstants.TOP"}); + System.out.println(""); + break; + default: + throw new Exception("invalid property descriptor: " + name); + } + } + } +} diff --git a/jdk/test/java/beans/Introspector/8130937/TestBooleanBeanProperties.java b/jdk/test/java/beans/Introspector/8130937/TestBooleanBeanProperties.java new file mode 100644 index 00000000000..494985cde68 --- /dev/null +++ b/jdk/test/java/beans/Introspector/8130937/TestBooleanBeanProperties.java @@ -0,0 +1,380 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import java.beans.BeanProperty; +import java.beans.PropertyChangeListener; +import java.beans.PropertyChangeSupport; +import java.beans.PropertyDescriptor; + +/** + * @test + * @bug 8130937 + * @summary Tests the booleans properties of the BeanProperty annotation + * @library .. + */ +public final class TestBooleanBeanProperties { + + public static void main(final String[] args) { + test(Empty.class, false, false, false, false, false, false); + test(BoundTrue.class, false, false, false, false, false, false); + test(BoundFalse.class, false, false, false, false, false, false); + test(BoundListener.class, true, false, false, false, false, false); + test(BoundFalseListener.class, false, false, false, false, false, false); + test(BoundTrueListener.class, true, false, false, false, false, false); + test(ExpertTrue.class, false, true, false, false, false, false); + test(ExpertFalse.class, false, false, false, false, false, false); + test(HiddenTrue.class, false, false, true, false, false, false); + test(HiddenFalse.class, false, false, false, false, false, false); + test(PreferredTrue.class, false, false, false, true, false, false); + test(PreferredFalse.class, false, false, false, false, false, false); + test(RequiredTrue.class, false, false, false, false, true, false); + test(RequiredFalse.class, false, false, false, false, false, false); + test(VisualUpdateTrue.class, false, false, false, false, false, true); + test(VisualUpdateFalse.class, false, false, false, false, false, false); + test(All.class, true, true, true, true, true, true); + } + + private static void test(Class cls, boolean isBound, boolean isExpert, + boolean isHidden, boolean isPref, boolean isReq, + boolean isVS) { + PropertyDescriptor pd = BeanUtils.getPropertyDescriptor(cls, "value"); + if (pd.isBound() != isBound) { + throw new RuntimeException("isBound should be: " + isBound); + } + if (pd.isExpert() != isExpert || getValue(pd, "expert") != isExpert) { + throw new RuntimeException("isExpert should be:" + isExpert); + } + if (pd.isHidden() != isHidden || getValue(pd, "hidden") != isHidden) { + throw new RuntimeException("isHidden should be: " + isHidden); + } + if (pd.isPreferred() != isPref) { + throw new RuntimeException("isPreferred should be: " + isPref); + } + if (getValue(pd, "required") != isReq) { + throw new RuntimeException("required should be: " + isReq); + } + if (getValue(pd, "visualUpdate") != isVS) { + throw new RuntimeException("required should be: " + isVS); + } + } + + private static boolean getValue(PropertyDescriptor pd, String value) { + return (boolean) pd.getValue(value); + } + //////////////////////////////////////////////////////////////////////////// + + public static final class Empty { + + private int value; + + public int getValue() { + return value; + } + + public void setValue(int value) { + this.value = value; + } + } + + public static final class All { + + private int value; + + private PropertyChangeSupport pcs = new PropertyChangeSupport(this); + + public int getValue() { + return value; + } + + @BeanProperty(bound = true, expert = true, hidden = true, + preferred = true, required = true, visualUpdate = true) + public void setValue(int value) { + this.value = value; + } + + public void addPropertyChangeListener(PropertyChangeListener l) { + pcs.addPropertyChangeListener(l); + } + + public void removePropertyChangeListener(PropertyChangeListener l) { + pcs.removePropertyChangeListener(l); + } + } + //////////////////////////////////////////////////////////////////////////// + // bound property + //////////////////////////////////////////////////////////////////////////// + + public static final class BoundTrue { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(bound = true) + public void setValue(int value) { + this.value = value; + } + } + + public static final class BoundFalse { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(bound = false) + public void setValue(int value) { + this.value = value; + } + } + + public static final class BoundListener { + + private PropertyChangeSupport pcs = new PropertyChangeSupport(this); + + private int value; + + public int getValue() { + return value; + } + + public void setValue(int value) { + this.value = value; + } + + public void addPropertyChangeListener(PropertyChangeListener l) { + pcs.addPropertyChangeListener(l); + } + + public void removePropertyChangeListener(PropertyChangeListener l) { + pcs.removePropertyChangeListener(l); + } + } + + public static final class BoundFalseListener { + + private PropertyChangeSupport pcs = new PropertyChangeSupport(this); + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(bound = false) + public void setValue(int value) { + this.value = value; + } + + public void addPropertyChangeListener(PropertyChangeListener l) { + pcs.addPropertyChangeListener(l); + } + + public void removePropertyChangeListener(PropertyChangeListener l) { + pcs.removePropertyChangeListener(l); + } + } + + public static final class BoundTrueListener { + + private PropertyChangeSupport pcs = new PropertyChangeSupport(this); + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(bound = true) + public void setValue(int value) { + this.value = value; + } + + public void addPropertyChangeListener(PropertyChangeListener l) { + pcs.addPropertyChangeListener(l); + } + + public void removePropertyChangeListener(PropertyChangeListener l) { + pcs.removePropertyChangeListener(l); + } + } + //////////////////////////////////////////////////////////////////////////// + // expert property + //////////////////////////////////////////////////////////////////////////// + + public static final class ExpertTrue { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(expert = true) + public void setValue(int value) { + this.value = value; + } + } + + public static final class ExpertFalse { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(expert = false) + public void setValue(int value) { + this.value = value; + } + } + //////////////////////////////////////////////////////////////////////////// + // hidden property + //////////////////////////////////////////////////////////////////////////// + + public static final class HiddenTrue { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(hidden = true) + public void setValue(int value) { + this.value = value; + } + } + + public static final class HiddenFalse { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(hidden = false) + public void setValue(int value) { + this.value = value; + } + } + //////////////////////////////////////////////////////////////////////////// + // preferred property + //////////////////////////////////////////////////////////////////////////// + + public static final class PreferredTrue { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(preferred = true) + public void setValue(int value) { + this.value = value; + } + } + + public static final class PreferredFalse { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(preferred = false) + public void setValue(int value) { + this.value = value; + } + } + //////////////////////////////////////////////////////////////////////////// + // required property + //////////////////////////////////////////////////////////////////////////// + + public static final class RequiredTrue { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(required = true) + public void setValue(int value) { + this.value = value; + } + } + + public static final class RequiredFalse { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(required = false) + public void setValue(int value) { + this.value = value; + } + } + //////////////////////////////////////////////////////////////////////////// + // visualUpdate property + //////////////////////////////////////////////////////////////////////////// + + public static final class VisualUpdateTrue { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(visualUpdate = true) + public void setValue(int value) { + this.value = value; + } + } + + public static final class VisualUpdateFalse { + + private int value; + + public int getValue() { + return value; + } + + @BeanProperty(visualUpdate = false) + public void setValue(int value) { + this.value = value; + } + } +} diff --git a/jdk/test/java/beans/Performance/Test4058433.java b/jdk/test/java/beans/Performance/Test4058433.java index 71f6cc8f06c..bba0e3b6fdc 100644 --- a/jdk/test/java/beans/Performance/Test4058433.java +++ b/jdk/test/java/beans/Performance/Test4058433.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, 2015, 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,6 +33,14 @@ import java.beans.ParameterDescriptor; import java.beans.PropertyDescriptor; import java.lang.reflect.Array; import java.lang.reflect.Method; +import java.net.URI; +import java.nio.file.FileSystem; +import java.nio.file.FileSystems; +import java.nio.file.FileVisitResult; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.SimpleFileVisitor; +import java.nio.file.attribute.BasicFileAttributes; import java.util.Arrays; import java.util.Comparator; import java.util.Enumeration; @@ -40,19 +48,13 @@ import java.util.Map.Entry; import java.util.Objects; import java.util.TreeMap; import java.util.TreeSet; -import java.util.jar.JarEntry; -import java.util.jar.JarFile; -import java.util.regex.Matcher; -import java.util.regex.Pattern; /* * @test * @bug 4058433 * @summary Generates BeanInfo for public classes in AWT, Accessibility, and Swing * @author Sergey Malenkov - * @run main/manual Test4058433 */ - public class Test4058433 implements Comparator { @Override public int compare(Object one, Object two) { @@ -76,31 +78,41 @@ public class Test4058433 implements Comparator { } public static void main(String[] args) throws Exception { - String resource = ClassLoader.getSystemResource("java/lang/Object.class").toString(); - - Pattern pattern = Pattern.compile("jar:file:(.*)!.*"); - Matcher matcher = pattern.matcher(resource); - matcher.matches(); - resource = matcher.group(1); + FileSystem fs = FileSystems.getFileSystem(URI.create("jrt:/")); + fs.getFileStores(); TreeSet> types = new TreeSet<>(new Test4058433()); - try (JarFile jarFile = new JarFile(resource.replaceAll("%20", " "))) { - Enumeration entries = jarFile.entries(); - while (entries.hasMoreElements()) { - String name = entries.nextElement().getName(); - if (name.startsWith("java/awt/") || name.startsWith("javax/accessibility/") || name.startsWith("javax/swing/")) { + Files.walkFileTree(fs.getPath("/modules/java.desktop"), new SimpleFileVisitor() { + @Override + public FileVisitResult visitFile(Path file, + BasicFileAttributes attrs) { + file = file.subpath(2, file.getNameCount()); + if (file.startsWith("java/awt/") + || file.startsWith("javax/accessibility/") + || file.startsWith("javax/swing/")) { + String name =file.toString(); if (name.endsWith(".class")) { name = name.substring(0, name.indexOf(".")).replace('/', '.'); - Class type = Class.forName(name); - if (!type.isInterface() && !type.isEnum() && !type.isAnnotation() && !type.isAnonymousClass()) { + + final Class type; + try { + type = Class.forName(name); + } catch (ClassNotFoundException e) { + throw new RuntimeException(e); + } + if (!BeanInfo.class.isAssignableFrom(type) && !type.isInterface() + && !type.isEnum() && !type.isAnnotation() + && !type.isAnonymousClass()) { if (null == type.getDeclaringClass()) { types.add(type); } } } } + return FileVisitResult.CONTINUE; } - } + }); + System.out.println("found " + types.size() + " classes"); long time = -System.currentTimeMillis(); for (Class type : types) { diff --git a/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest.java b/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest.java index 7c6eb0bb5b8..5e8bda4cd86 100644 --- a/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest.java +++ b/jdk/test/java/lang/management/MemoryMXBean/LowMemoryTest.java @@ -33,7 +33,7 @@ * @library /lib/testlibrary/ * @modules java.management * @build jdk.testlibrary.* LowMemoryTest MemoryUtil RunUtil - * @run main/timeout=600 LowMemoryTest + * @run main/timeout=600 LowMemoryTest * @requires vm.opt.ExplicitGCInvokesConcurrent != "true" * @requires vm.opt.ExplicitGCInvokesConcurrentAndUnloadsClasses != "true" * @requires vm.opt.DisableExplicitGC != "true" @@ -44,6 +44,9 @@ import java.util.*; import java.util.concurrent.Phaser; import javax.management.*; import javax.management.openmbean.CompositeData; +import jdk.testlibrary.ProcessTools; +import jdk.testlibrary.JDKToolFinder; +import jdk.testlibrary.Utils; public class LowMemoryTest { private static final MemoryMXBean mm = ManagementFactory.getMemoryMXBean(); @@ -56,6 +59,7 @@ public class LowMemoryTest { private static final int NUM_CHUNKS = 2; private static final int YOUNG_GEN_SIZE = 8 * 1024 * 1024; private static long chunkSize; + private static final String classMain = "LowMemoryTest$TestMain"; /** * Run the test multiple times with different GC versions. @@ -63,7 +67,6 @@ public class LowMemoryTest { * Then with GC versions specified by the test. */ public static void main(String a[]) throws Throwable { - final String main = "LowMemoryTest$TestMain"; // Use a low young gen size to ensure that the // allocated objects are put in the old gen. final String nmFlag = "-Xmn" + YOUNG_GEN_SIZE; @@ -73,12 +76,75 @@ public class LowMemoryTest { // Prevent G1 from selecting a large heap region size, // since that would change the young gen size. final String g1Flag = "-XX:G1HeapRegionSize=1m"; - RunUtil.runTestClearGcOpts(main, nmFlag, lpFlag, "-XX:+UseSerialGC"); - RunUtil.runTestClearGcOpts(main, nmFlag, lpFlag, "-XX:+UseParallelGC"); - RunUtil.runTestClearGcOpts(main, nmFlag, lpFlag, "-XX:+UseG1GC", g1Flag); - RunUtil.runTestClearGcOpts(main, nmFlag, lpFlag, "-XX:+UseConcMarkSweepGC"); + + // Runs the test collecting subprocess I/O while it's running. + traceTest(classMain + ", -XX:+UseSerialGC", nmFlag, lpFlag, "-XX:+UseSerialGC"); + traceTest(classMain + ", -XX:+UseParallelGC", nmFlag, lpFlag, "-XX:+UseParallelGC"); + traceTest(classMain + ", -XX:+UseG1GC", nmFlag, lpFlag, "-XX:+UseG1GC", g1Flag); + traceTest(classMain + ", -XX:+UseConcMarkSweepGC", nmFlag, lpFlag, "-XX:+UseConcMarkSweepGC"); } + /* + * Creating command-line for running subprocess JVM: + * + * JVM command line is like: + * {test_jdk}/bin/java {defaultopts} -cp {test.class.path} {testopts} main + * + * {defaultopts} are the default java options set by the framework. + * + * @param testOpts java options specified by the test. + */ + private static List buildCommandLine(String... testOpts) { + List opts = new ArrayList<>(); + opts.add(JDKToolFinder.getJDKTool("java")); + opts.addAll(Arrays.asList(Utils.getTestJavaOpts())); + opts.add("-cp"); + opts.add(System.getProperty("test.class.path", "test.class.path")); + opts.add("-XX:+PrintGCDetails"); + opts.addAll(Arrays.asList(testOpts)); + opts.add(classMain); + + return opts; + } + + /** + * Runs LowMemoryTest$TestMain with the passed options and redirects subprocess + * standard I/O to the current (parent) process. This provides a trace of what + * happens in the subprocess while it is runnning (and before it terminates). + * + * @param prefixName the prefix string for redirected outputs + * @param testOpts java options specified by the test. + */ + private static void traceTest(String prefixName, + String... testOpts) + throws Throwable { + + // Building command-line + List opts = buildCommandLine(testOpts); + + // We activate all tracing in subprocess + opts.add("trace"); + + // Launch separate JVM subprocess + String[] optsArray = opts.toArray(new String[0]); + ProcessBuilder pb = new ProcessBuilder(optsArray); + System.out.println("\n========= Tracing of subprocess " + prefixName + " ========="); + Process p = ProcessTools.startProcess(prefixName, pb); + + // Handling end of subprocess + try { + int exitCode = p.waitFor(); + if (exitCode != 0) { + throw new RuntimeException( + "Subprocess unexpected exit value of [" + exitCode + "]. Expected 0.\n"); + } + } catch (InterruptedException e) { + throw new RuntimeException("Parent process interrupted with exception : \n " + e + " :" ); + } + + + } + private static volatile boolean listenerInvoked = false; static class SensorListener implements NotificationListener { @Override @@ -204,6 +270,7 @@ public class LowMemoryTest { System.out.println("Setting threshold for " + mpool.getName() + " from " + mpool.getUsageThreshold() + " to " + newThreshold + ". Current used = " + mu.getUsed()); + mpool.setUsageThreshold(newThreshold); if (mpool.getUsageThreshold() != newThreshold) { @@ -236,7 +303,6 @@ public class LowMemoryTest { throw new RuntimeException("TEST FAILED."); System.out.println(RunUtil.successMessage); - } } @@ -298,28 +364,42 @@ public class LowMemoryTest { static class SweeperThread extends Thread { private void doTask() { + int iterations = 0; + if (trace) { + System.out.println("SweeperThread clearing allocated objects."); + } + for (; mpool.getUsage().getUsed() >= mpool.getUsageThreshold();) { // clear all allocated objects and invoke GC objectPool.clear(); mm.gc(); + + if (trace) { + iterations++; + System.out.println("SweeperThread called " + iterations + + " time(s) MemoryMXBean.gc()."); + } + goSleep(100); } } + @Override public void run() { for (int i = 1; i <= NUM_TRIGGERS; i++) { // Sync with AllocatorThread's first phase. phaser.arriveAndAwaitAdvance(); - System.out.println("SweepThread is doing task " + i + + System.out.println("SweeperThread is doing task " + i + " phase " + phaser.getPhase()); + doTask(); listenerInvoked = false; // Sync with AllocatorThread's second phase. phaser.arriveAndAwaitAdvance(); - System.out.println("SweepThread done task " + i + + System.out.println("SweeperThread done task " + i + " phase " + phaser.getPhase()); if (testFailed) return; } diff --git a/jdk/test/java/lang/ref/FinalizerHistogramTest.java b/jdk/test/java/lang/ref/FinalizerHistogramTest.java new file mode 100644 index 00000000000..a201331f47a --- /dev/null +++ b/jdk/test/java/lang/ref/FinalizerHistogramTest.java @@ -0,0 +1,104 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import java.util.concurrent.TimeUnit; +import java.util.concurrent.locks.Condition; +import java.util.concurrent.locks.ReentrantLock; + +import java.lang.reflect.Method; +import java.lang.reflect.Field; + +/* + * @test + * @summary Unit test for FinalizerHistogram + * @run main FinalizerHistogramTest + */ + +public class FinalizerHistogramTest { + static ReentrantLock lock = new ReentrantLock(); + static volatile int wasInitialized = 0; + static volatile int wasTrapped = 0; + static final int objectsCount = 1000; + + static class MyObject { + public MyObject() { + // Make sure object allocation/deallocation is not optimized out + wasInitialized += 1; + } + + protected void finalize() { + // Trap the object in a finalization queue + wasTrapped += 1; + lock.lock(); + } + } + + public static void main(String[] argvs) { + try { + lock.lock(); + for(int i = 0; i < objectsCount; ++i) { + new MyObject(); + } + System.out.println("Objects intialized: " + objectsCount); + System.gc(); + while(wasTrapped < 1); + + Class klass = Class.forName("java.lang.ref.FinalizerHistogram"); + + Method m = klass.getDeclaredMethod("getFinalizerHistogram"); + m.setAccessible(true); + Object entries[] = (Object[]) m.invoke(null); + + Class entryKlass = Class.forName("java.lang.ref.FinalizerHistogram$Entry"); + Field name = entryKlass.getDeclaredField("className"); + name.setAccessible(true); + Field count = entryKlass.getDeclaredField("instanceCount"); + count.setAccessible(true); + + System.out.println("Unreachable instances waiting for finalization"); + System.out.println("#instances class name"); + System.out.println("-----------------------"); + + boolean found = false; + for (Object entry : entries) { + Object e = entryKlass.cast(entry); + System.out.printf("%10d %s\n", count.get(e), name.get(e)); + if (((String) name.get(e)).indexOf("MyObject") != -1 ) { + found = true; + } + } + + if (!found) { + throw new RuntimeException("MyObject is not found in test output"); + } + + System.out.println("Test PASSED"); + } catch(Exception e) { + System.err.println("Test failed with " + e); + e.printStackTrace(System.err); + throw new RuntimeException("Test failed"); + } finally { + lock.unlock(); + } + } +} diff --git a/jdk/test/java/nio/file/FileSystem/Basic.java b/jdk/test/java/nio/file/FileSystem/Basic.java index 89903611b4f..481392929ce 100644 --- a/jdk/test/java/nio/file/FileSystem/Basic.java +++ b/jdk/test/java/nio/file/FileSystem/Basic.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2008, 2015, 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 @@ -22,17 +22,23 @@ */ /* @test - * @bug 4313887 6838333 + * @bug 4313887 6838333 8132497 * @summary Unit test for java.nio.file.FileSystem - * @library .. + * @library .. /lib/testlibrary + * @build jdk.testlibrary.FileUtils + * @run main/othervm Basic */ +import java.io.File; import java.nio.file.*; -import java.nio.file.attribute.*; import java.io.IOException; +import java.net.URI; +import java.net.URISyntaxException; +import java.util.HashMap; +import jdk.testlibrary.FileUtils; /** - * Simple santity checks for java.nio.file.FileSystem + * Simple sanity checks for java.nio.file.FileSystem */ public class Basic { @@ -48,7 +54,25 @@ public class Basic { } } - public static void main(String[] args) throws IOException { + static void checkNoUOE() throws IOException, URISyntaxException { + String dir = System.getProperty("test.dir", "."); + String fileName = dir + File.separator + "foo.bar"; + Path path = Paths.get(fileName); + Path file = Files.createFile(path); + try { + URI uri = new URI("jar", file.toUri().toString(), null); + System.out.println(uri); + FileSystem fs = FileSystems.newFileSystem(uri, new HashMap()); + fs.close(); + } catch (ProviderNotFoundException pnfe) { + System.out.println("Expected ProviderNotFoundException caught: " + + "\"" + pnfe.getMessage() + "\""); + } finally { + FileUtils.deleteFileWithRetry(path); + } + } + + public static void main(String[] args) throws IOException, URISyntaxException { FileSystem fs = FileSystems.getDefault(); // close should throw UOE @@ -80,5 +104,9 @@ public class Basic { checkSupported(fs, "posix", "unix", "owner"); if (os.equals("Windows")) checkSupported(fs, "owner", "dos", "acl", "user"); + + // sanity check non-throwing of UnsupportedOperationException by + // FileSystems.newFileSystem(URI, ..) + checkNoUOE(); } } diff --git a/jdk/test/java/nio/file/Files/StreamTest.java b/jdk/test/java/nio/file/Files/StreamTest.java index 0259fac221a..c21faf96627 100644 --- a/jdk/test/java/nio/file/Files/StreamTest.java +++ b/jdk/test/java/nio/file/Files/StreamTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2015, 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 @@ -22,7 +22,7 @@ */ /* @test - * @bug 8006884 8019526 + * @bug 8006884 8019526 8132539 * @library .. * @build PassThroughFileSystem FaultyFileSystem * @run testng StreamTest @@ -685,4 +685,18 @@ public class StreamTest { // expected } } + + public void testProcFile() throws IOException { + if (System.getProperty("os.name").equals("Linux")) { + Path path = Paths.get("/proc/cpuinfo"); + if (Files.exists(path)) { + String NEW_LINE = System.getProperty("line.separator"); + String s = + Files.lines(path).collect(Collectors.joining(NEW_LINE)); + if (s.length() == 0) { + fail("Files.lines(\"" + path + "\") returns no data"); + } + } + } + } } diff --git a/jdk/test/java/nio/file/Files/probeContentType/ParallelProbes.java b/jdk/test/java/nio/file/Files/probeContentType/ParallelProbes.java new file mode 100644 index 00000000000..afed44efbc5 --- /dev/null +++ b/jdk/test/java/nio/file/Files/probeContentType/ParallelProbes.java @@ -0,0 +1,97 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.util.ArrayList; + +/* @test + * @summary Test probing content type simultaneously from multiple threads. + * @requires (os.family == "linux") | (os.family == "solaris") + * @build ParallelProbes SimpleFileTypeDetector + * @run main/othervm ParallelProbes 10 + */ +public class ParallelProbes { + + private static final int REPEATS = 1000; + + private int numThreads = 0; + private ArrayList threads; + + public ParallelProbes(int numThreads) { + System.out.println("Using <" + numThreads + "> threads."); + this.numThreads = numThreads; + this.threads = new ArrayList(numThreads); + } + + private Path createTmpFile() throws IOException { + final Path p = Files.createTempFile("prefix", ".json"); + Files.write(p, "{\"test\"}".getBytes()); + System.out.println("Write test file <" + p + ">"); + return p; + } + + private Runnable createRunnable(final Path p) { + Runnable r = new Runnable() { + public void run() { + for (int i = 0; i < REPEATS; i++) { + try { + System.out.println(Thread.currentThread().getName() + + " -> " + Files.probeContentType(p)); + } catch (IOException ioException) { + ioException.printStackTrace(); + } + } + } + }; + return r; + } + + public void start() throws IOException { + for (int i = 0; i < numThreads; i++) { + final Path p = createTmpFile(); + Runnable r = createRunnable(p); + Thread thread = new Thread(r, "thread-" + i); + thread.start(); + threads.add(thread); + } + } + + public void join() { + for (Thread thread : threads) { + try { + thread.join(); + } catch (InterruptedException e) { + // ignore it and proceed to the next one + } + } + } + + public static void main(String[] args) throws Exception { + ParallelProbes probes = + new ParallelProbes(args.length < 1 ? 1 : Integer.parseInt(args[0])); + probes.start(); + probes.join(); + } +} diff --git a/jdk/test/java/util/TimeZone/CLDRDisplayNamesTest.java b/jdk/test/java/util/TimeZone/CLDRDisplayNamesTest.java index aae1c639d73..b6038ac90b2 100644 --- a/jdk/test/java/util/TimeZone/CLDRDisplayNamesTest.java +++ b/jdk/test/java/util/TimeZone/CLDRDisplayNamesTest.java @@ -109,9 +109,6 @@ public class CLDRDisplayNamesTest { fmtROOT.parse("Thu Nov 13 04:35:51 AKST 2008"); fmtUS.parse("Thu Nov 13 04:35:51 AKST 2008"); fmtUK.parse("Thu Nov 13 04:35:51 GMT-09:00 2008"); - String dateString = new Date().toString(); - System.out.println("Date: "+dateString); - System.out.println("Parsed Date: "+new Date(Date.parse(dateString)).toString()); } catch (ParseException pe) { System.err.println(pe); errors++; diff --git a/jdk/test/java/util/concurrent/locks/ReentrantLock/TimeoutLockLoops.java b/jdk/test/java/util/concurrent/locks/ReentrantLock/TimeoutLockLoops.java index 575a7bf47f3..464f1f84cb1 100644 --- a/jdk/test/java/util/concurrent/locks/ReentrantLock/TimeoutLockLoops.java +++ b/jdk/test/java/util/concurrent/locks/ReentrantLock/TimeoutLockLoops.java @@ -35,6 +35,7 @@ * @test * @bug 4486658 5031862 * @run main TimeoutLockLoops + * @key intermittent * @summary Checks for responsiveness of locks to timeouts. * Runs under the assumption that ITERS computations require more than * TIMEOUT msecs to complete, which seems to be a safe assumption for diff --git a/jdk/test/javax/crypto/SealedObject/TestSealedObjectNull.java b/jdk/test/javax/crypto/SealedObject/TestSealedObjectNull.java new file mode 100644 index 00000000000..4b6eff27cfb --- /dev/null +++ b/jdk/test/javax/crypto/SealedObject/TestSealedObjectNull.java @@ -0,0 +1,57 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import java.io.IOException; +import javax.crypto.BadPaddingException; +import javax.crypto.Cipher; +import javax.crypto.IllegalBlockSizeException; +import javax.crypto.NullCipher; +import javax.crypto.SealedObject; + +/* + * @test + * @bug 8048624 + * @summary This test instantiate a NullCipher, seal and unseal a String + * object using the SealedObject with the initialized NullCipher, + * and then compare the String content. + */ +public class TestSealedObjectNull { + + private static final String SEAL_STR = "Any String!@#$%^"; + + public static void main(String[] args) throws IOException, + IllegalBlockSizeException, ClassNotFoundException, + BadPaddingException { + Cipher nullCipher = new NullCipher(); + + // Seal + SealedObject so = new SealedObject(SEAL_STR, nullCipher); + + // Unseal and compare + if (!(SEAL_STR.equals(so.getObject(nullCipher)))) { + throw new RuntimeException("Unseal and compare failed."); + } + + System.out.println("Test passed."); + } +} diff --git a/jdk/test/javax/sound/sampled/FileReader/AudioFileClose.java b/jdk/test/javax/sound/sampled/FileReader/AudioFileClose.java new file mode 100644 index 00000000000..3655f9e1c82 --- /dev/null +++ b/jdk/test/javax/sound/sampled/FileReader/AudioFileClose.java @@ -0,0 +1,54 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import java.io.File; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.InputStream; +import java.io.OutputStream; +import java.nio.file.Files; +import java.nio.file.Paths; + +import javax.sound.sampled.AudioSystem; +import javax.sound.sampled.UnsupportedAudioFileException; + +/** + * @test + * @bug 8013586 + * @author Sergey Bylokhov + */ +public final class AudioFileClose { + + public static void main(final String[] args) throws Exception { + final File file = Files.createTempFile("JavaSound", "Test").toFile(); + try (OutputStream fos = new FileOutputStream(file)) { + fos.write(new byte[200]); + } + try { + final InputStream stream = AudioSystem.getAudioInputStream(file); + stream.close(); + } catch (final IOException | UnsupportedAudioFileException ignored) { + } + Files.delete(Paths.get(file.getAbsolutePath())); + } +} diff --git a/jdk/test/javax/sound/sampled/FileReader/ReadersExceptions.java b/jdk/test/javax/sound/sampled/FileReader/ReadersExceptions.java index e0a386ed9f6..604c703423a 100644 --- a/jdk/test/javax/sound/sampled/FileReader/ReadersExceptions.java +++ b/jdk/test/javax/sound/sampled/FileReader/ReadersExceptions.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2015, 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 @@ -21,17 +21,19 @@ * questions. */ - import java.io.ByteArrayInputStream; import java.io.IOException; import java.io.InputStream; import javax.sound.sampled.AudioSystem; import javax.sound.sampled.UnsupportedAudioFileException; +import javax.sound.sampled.spi.AudioFileReader; + +import static java.util.ServiceLoader.load; /** * @test - * @bug 7058662 7058666 7058672 + * @bug 7058662 7058666 7058672 8130305 * @author Sergey Bylokhov */ public final class ReadersExceptions { @@ -111,16 +113,18 @@ public final class ReadersExceptions { 0, 0, 0, 0, // dataLength }; + static byte[][] data = {wrongAIFFCh, wrongAIFFSSL, wrongAIFFSSH, wrongAUCh, + wrongWAVCh, wrongWAVSSB}; + public static void main(final String[] args) throws IOException { - test(wrongAIFFCh); - test(wrongAIFFSSL); - test(wrongAIFFSSH); - test(wrongAUCh); - test(wrongWAVCh); - test(wrongWAVSSB); + for (final byte[] bytes : data) { + testAS(bytes); + testAFR(bytes); + } } - private static void test(final byte[] buffer) throws IOException { + private static void testAS(final byte[] buffer) throws IOException { + // AudioSystem API final InputStream is = new ByteArrayInputStream(buffer); try { AudioSystem.getAudioFileFormat(is); @@ -130,4 +134,19 @@ public final class ReadersExceptions { } throw new RuntimeException("Test Failed"); } + + private static void testAFR(final byte[] buffer) throws IOException { + // AudioFileReader API + final InputStream is = new ByteArrayInputStream(buffer); + for (final AudioFileReader afr : load(AudioFileReader.class)) { + for (int i = 0; i < 10; ++i) { + try { + afr.getAudioFileFormat(is); + throw new RuntimeException("UAFE expected"); + } catch (final UnsupportedAudioFileException ignored) { + // Expected. + } + } + } + } } diff --git a/jdk/test/javax/swing/JInternalFrame/SetLayerNPE/SetLayerNPE.java b/jdk/test/javax/swing/JInternalFrame/SetLayerNPE/SetLayerNPE.java new file mode 100644 index 00000000000..728c560589d --- /dev/null +++ b/jdk/test/javax/swing/JInternalFrame/SetLayerNPE/SetLayerNPE.java @@ -0,0 +1,55 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ + +import java.awt.EventQueue; + +import javax.swing.JDesktopPane; +import javax.swing.JInternalFrame; + +/** + * @test + * @bug 6206439 + */ +public final class SetLayerNPE { + + public static void main(final String[] args) throws Exception { + EventQueue.invokeAndWait(() -> { + try { + // JInternalFrame without parent + new JInternalFrame("My Frame").setLayer(null); + throw new AssertionError("expected NPE was not thrown"); + } catch (final NullPointerException ignored) { + } + }); + EventQueue.invokeAndWait(() -> { + try { + // JInternalFrame with parent + JInternalFrame jif = new JInternalFrame("My Frame"); + new JDesktopPane().add(jif); + jif.setLayer(null); + throw new AssertionError("expected NPE was not thrown"); + } catch (final NullPointerException ignored) { + } + }); + } +} diff --git a/jdk/test/javax/swing/JSplitPane/8132123/bug8132123.html b/jdk/test/javax/swing/JSplitPane/8132123/bug8132123.html new file mode 100644 index 00000000000..d65bd7bb4e1 --- /dev/null +++ b/jdk/test/javax/swing/JSplitPane/8132123/bug8132123.html @@ -0,0 +1,38 @@ + + + + +Verify that JSplitPane uses high-resolution system icons for the one-touch expanding +buttons on HiDPI displays. + +If the display does not support HiDPI mode press PASS. + +1. Run the test on HiDPI Display. +2. Check that the one-touch expanding buttons on the JSplitPane are painted +correctly. If so, press PASS, else press FAIL. + + + + + diff --git a/jdk/test/javax/swing/JSplitPane/8132123/bug8132123.java b/jdk/test/javax/swing/JSplitPane/8132123/bug8132123.java new file mode 100644 index 00000000000..75b651de776 --- /dev/null +++ b/jdk/test/javax/swing/JSplitPane/8132123/bug8132123.java @@ -0,0 +1,51 @@ +/* + * Copyright (c) 2015, 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 + * 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. + */ +import java.awt.Color; +import javax.swing.JApplet; +import javax.swing.JPanel; +import javax.swing.JSplitPane; +import javax.swing.SwingUtilities; + +/* @test + * @bug 8132123 + * @summary MultiResolutionCachedImage unnecessarily creates base image + * to get its size + * @author Alexander Scherbatiy + * @run applet/manual=yesno bug8132123.html + */ +public class bug8132123 extends JApplet { + + @Override + public void init() { + SwingUtilities.invokeLater(() -> { + JPanel left = new JPanel(); + left.setBackground(Color.GRAY); + JPanel right = new JPanel(); + right.setBackground(Color.GRAY); + JSplitPane splitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, + left, right); + splitPane.setOneTouchExpandable(true); + getContentPane().add(splitPane); + }); + } +} diff --git a/jdk/test/javax/swing/JTextPane/JTextPaneDocumentAlignment.java b/jdk/test/javax/swing/JTextPane/JTextPaneDocumentAlignment.java new file mode 100644 index 00000000000..f75d1c08a28 --- /dev/null +++ b/jdk/test/javax/swing/JTextPane/JTextPaneDocumentAlignment.java @@ -0,0 +1,99 @@ +/* + * Copyright (c) 2015, 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 + * 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 8132136 + @summary [PIT] RTL orientation in JEditorPane is broken + @author Semyon Sadetsky + */ + +import javax.swing.*; +import javax.swing.text.BadLocationException; +import javax.swing.text.SimpleAttributeSet; +import javax.swing.text.StyleConstants; +import java.awt.*; + +public class JTextPaneDocumentAlignment { + + private static JFrame frame; + private static JTextPane jTextPane; + private static int position; + + public static void main(String[] args) throws Exception{ + SwingUtilities.invokeAndWait(new Runnable() { + @Override + public void run() { + frame = new JFrame(); + frame.setUndecorated(true); + frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); + frame.setSize(200, 200); + jTextPane = new JTextPane(); + jTextPane.setContentType("text/html"); + jTextPane.setText( + "Test"); + SimpleAttributeSet right = new SimpleAttributeSet(); + StyleConstants.setAlignment(right, StyleConstants.ALIGN_RIGHT); + jTextPane.getStyledDocument() + .setParagraphAttributes(0, 10, right, true); + frame.getContentPane().add(jTextPane); + frame.setVisible(true); + } + }); + Robot robot = new Robot(); + robot.waitForIdle(); + robot.delay(200); + SwingUtilities.invokeAndWait(new Runnable() { + @Override + public void run() { + try { + position = jTextPane.modelToView(1).x; + SimpleAttributeSet center = new SimpleAttributeSet(); + StyleConstants.setAlignment(center, + StyleConstants.ALIGN_CENTER); + jTextPane.getStyledDocument() + .setParagraphAttributes(0, 10, center, true); + } catch (BadLocationException e) { + e.printStackTrace(); + } + } + }); + if(position < 100) { + throw new RuntimeException("Text is not right aligned " + position); + } + SwingUtilities.invokeAndWait(new Runnable() { + @Override + public void run() { + try { + position = jTextPane.modelToView(1).x; + } catch (BadLocationException e) { + e.printStackTrace(); + } + frame.dispose(); + } + }); + if(position < 20) { + throw new RuntimeException("Text is not center aligned " + position); + } + System.out.println("ok"); + } +} diff --git a/jdk/test/sun/security/pkcs11/PKCS11Test.java b/jdk/test/sun/security/pkcs11/PKCS11Test.java index 14238ac641d..1b4c281048a 100644 --- a/jdk/test/sun/security/pkcs11/PKCS11Test.java +++ b/jdk/test/sun/security/pkcs11/PKCS11Test.java @@ -630,4 +630,18 @@ public abstract class PKCS11Test { return algorithms; } + /** + * Get the identifier for the operating system distribution + */ + public String getDistro() { + + try (BufferedReader in = + new BufferedReader(new InputStreamReader( + Runtime.getRuntime().exec("uname -v").getInputStream()))) { + + return in.readLine(); + } catch (Exception e) { + return ""; + } + } } diff --git a/jdk/test/sun/security/pkcs11/Signature/ByteBuffers.java b/jdk/test/sun/security/pkcs11/Signature/ByteBuffers.java index 8a76866f73f..d45063a8eda 100644 --- a/jdk/test/sun/security/pkcs11/Signature/ByteBuffers.java +++ b/jdk/test/sun/security/pkcs11/Signature/ByteBuffers.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2015, 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 @@ -42,6 +42,22 @@ public class ByteBuffers extends PKCS11Test { } public void main(Provider p) throws Exception { + + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris provider (8044554) + */ + if (p.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + Random random = new Random(); int n = 10 * 1024; byte[] t = new byte[n]; diff --git a/jdk/test/sun/security/pkcs11/Signature/ReinitSignature.java b/jdk/test/sun/security/pkcs11/Signature/ReinitSignature.java index d5ace8b9602..0f51ffaa096 100644 --- a/jdk/test/sun/security/pkcs11/Signature/ReinitSignature.java +++ b/jdk/test/sun/security/pkcs11/Signature/ReinitSignature.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2015, 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,6 +28,306 @@ * @author Andreas Sterbenz * @library .. * @key randomness + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature + * @run main ReinitSignature */ import java.util.*; @@ -41,6 +341,22 @@ public class ReinitSignature extends PKCS11Test { } public void main(Provider p) throws Exception { + + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris (8044554) + */ + if (p.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + KeyPairGenerator kpg = KeyPairGenerator.getInstance("RSA", p); kpg.initialize(512); KeyPair kp = kpg.generateKeyPair(); diff --git a/jdk/test/sun/security/pkcs11/Signature/TestDSA.java b/jdk/test/sun/security/pkcs11/Signature/TestDSA.java index 9f8c099f4c2..2b81bb3a333 100644 --- a/jdk/test/sun/security/pkcs11/Signature/TestDSA.java +++ b/jdk/test/sun/security/pkcs11/Signature/TestDSA.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2005, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2015, 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 @@ -110,6 +110,21 @@ public class TestDSA extends PKCS11Test { System.out.println("Testing provider " + provider + "..."); + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris (8044554) + */ + if (provider.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + if (provider.getService("Signature", "SHA1withDSA") == null) { System.out.println("DSA not supported, skipping"); return; diff --git a/jdk/test/sun/security/pkcs11/Signature/TestDSAKeyLength.java b/jdk/test/sun/security/pkcs11/Signature/TestDSAKeyLength.java index 0287e7d028f..efe97077628 100644 --- a/jdk/test/sun/security/pkcs11/Signature/TestDSAKeyLength.java +++ b/jdk/test/sun/security/pkcs11/Signature/TestDSAKeyLength.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2015, 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 @@ -46,6 +46,21 @@ public class TestDSAKeyLength extends PKCS11Test { return; } + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris (8044554) + */ + if (provider.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + KeyPairGenerator kpg = KeyPairGenerator.getInstance("DSA", "SUN"); kpg.initialize(2048, new SecureRandom()); KeyPair pair = kpg.generateKeyPair(); diff --git a/jdk/test/sun/security/pkcs11/Signature/TestRSAKeyLength.java b/jdk/test/sun/security/pkcs11/Signature/TestRSAKeyLength.java index 9d6f62a8a1c..0b79e68d20c 100644 --- a/jdk/test/sun/security/pkcs11/Signature/TestRSAKeyLength.java +++ b/jdk/test/sun/security/pkcs11/Signature/TestRSAKeyLength.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2015, 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,6 +36,22 @@ public class TestRSAKeyLength extends PKCS11Test { main(new TestRSAKeyLength()); } public void main(Provider p) throws Exception { + + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris (8044554) + */ + if (p.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + boolean isValidKeyLength[] = { true, true, true, false, false }; String algos[] = { "SHA1withRSA", "SHA224withRSA", "SHA256withRSA", "SHA384withRSA", "SHA512withRSA" }; diff --git a/jdk/test/sun/security/pkcs11/ec/TestCurves.java b/jdk/test/sun/security/pkcs11/ec/TestCurves.java index 6451e41514b..3ada7788cf9 100644 --- a/jdk/test/sun/security/pkcs11/ec/TestCurves.java +++ b/jdk/test/sun/security/pkcs11/ec/TestCurves.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2006, 2013, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2006, 2015, 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 @@ -58,6 +58,21 @@ public class TestCurves extends PKCS11Test { return; } + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris (8044554) + */ + if (p.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + // Check if this is sparc for later failure avoidance. boolean sparc = false; if (System.getProperty("os.arch").equals("sparcv9")) { diff --git a/jdk/test/sun/security/pkcs11/ec/TestECDSA.java b/jdk/test/sun/security/pkcs11/ec/TestECDSA.java index b811b44c6ef..b1bd35f4783 100644 --- a/jdk/test/sun/security/pkcs11/ec/TestECDSA.java +++ b/jdk/test/sun/security/pkcs11/ec/TestECDSA.java @@ -123,6 +123,21 @@ public class TestECDSA extends PKCS11Test { return; } + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris (8044554) + */ + if (provider.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + /* * PKCS11Test.main will remove this provider if needed */ diff --git a/jdk/test/sun/security/pkcs11/rsa/TestCACerts.java b/jdk/test/sun/security/pkcs11/rsa/TestCACerts.java index 32f3a4677ac..cd845c68201 100644 --- a/jdk/test/sun/security/pkcs11/rsa/TestCACerts.java +++ b/jdk/test/sun/security/pkcs11/rsa/TestCACerts.java @@ -47,6 +47,22 @@ public class TestCACerts extends PKCS11Test { } public void main(Provider p) throws Exception { + + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris (8044554) + */ + if (p.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + long start = System.currentTimeMillis(); Providers.setAt(p, 1); try { diff --git a/jdk/test/sun/security/pkcs11/rsa/TestSignatures.java b/jdk/test/sun/security/pkcs11/rsa/TestSignatures.java index b27de0a9b77..a6070ea675d 100644 --- a/jdk/test/sun/security/pkcs11/rsa/TestSignatures.java +++ b/jdk/test/sun/security/pkcs11/rsa/TestSignatures.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2015, 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 @@ -97,6 +97,22 @@ public class TestSignatures extends PKCS11Test { } public void main(Provider p) throws Exception { + + /* + * Use Solaris SPARC 11.2 or later to avoid an intermittent failure + * when running SunPKCS11-Solaris (8044554) + */ + if (p.getName().equals("SunPKCS11-Solaris") && + System.getProperty("os.name").equals("SunOS") && + System.getProperty("os.arch").equals("sparcv9") && + System.getProperty("os.version").compareTo("5.11") <= 0 && + getDistro().compareTo("11.2") < 0) { + + System.out.println("SunPKCS11-Solaris provider requires " + + "Solaris SPARC 11.2 or later, skipping"); + return; + } + long start = System.currentTimeMillis(); provider = p; data = new byte[2048]; diff --git a/jdk/test/tools/pack200/PackTestZip64.java b/jdk/test/tools/pack200/PackTestZip64.java index 2c7d1a93e8f..d952549cc20 100644 --- a/jdk/test/tools/pack200/PackTestZip64.java +++ b/jdk/test/tools/pack200/PackTestZip64.java @@ -37,10 +37,13 @@ import java.util.zip.ZipEntry; * @compile -XDignore.symbol.file Utils.java PackTestZip64.java * @run main PackTestZip64 * @author kizune - * @key intermittent */ public class PackTestZip64 { + + private static final boolean bigJarEnabled + = Boolean.getBoolean("PackTestZip64.enableBigJar"); + public static void main(String... args) throws Exception { testPacking(); Utils.cleanup(); @@ -50,10 +53,14 @@ public class PackTestZip64 { private static final byte[] BUFFER = new byte[1024]; static void testPacking() throws IOException { - // make a copy of the test specimen to local directory File testFile = new File("tools_java.jar"); - // Add a large number of small files to the golden jar - generateLargeJar(testFile, Utils.getGoldenJar()); + if (bigJarEnabled) { + // Add a large number of small files to the golden jar + generateLargeJar(testFile, Utils.getGoldenJar()); + } else { + // make a copy of the test specimen to local directory + Utils.copyFile(Utils.getGoldenJar(), testFile); + } List cmdsList = new ArrayList<>(); diff --git a/jdk/test/tools/pack200/PackTestZip64Manual.java b/jdk/test/tools/pack200/PackTestZip64Manual.java new file mode 100644 index 00000000000..38e4101ac3b --- /dev/null +++ b/jdk/test/tools/pack200/PackTestZip64Manual.java @@ -0,0 +1,33 @@ +/* + * Copyright (c) 2015, 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 + * 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 8029646 + * @summary tests that native unpacker produces the same result as Java one + * @compile -XDignore.symbol.file Utils.java PackTestZip64.java + * @run main/manual/othervm -DPackTestZip64.enableBigJar=true PackTestZip64 + */ + +public class PackTestZip64Manual { +} diff --git a/make/CompileJavaModules.gmk b/make/CompileJavaModules.gmk index ea48c7f40f1..a68908c9cb6 100644 --- a/make/CompileJavaModules.gmk +++ b/make/CompileJavaModules.gmk @@ -491,6 +491,7 @@ SHARE_SRC_DIRS += \ $(CORBA_TOPDIR)/src/$1/share/classes \ $(JAXP_TOPDIR)/src/$1/share/classes \ $(JAXWS_TOPDIR)/src/$1/share/classes \ + $(NASHORN_TOPDIR)/src/$1/share/classes \ # ALL_SRC_DIRS = \ @@ -512,8 +513,8 @@ JAVA_MODULES := $(ALL_JAVA_MODULES) JDK_USER_DEFINED_FILTER := $(strip $(subst $(COMMA),$(SPACE), $(JDK_FILTER))) # Create an empty directory to set the bootclasspath to. -EMPTY_BOOTCLASSPATH := $(SUPPORT_OUTPUTDIR)/empty-dir -$(call MakeDir, $(EMPTY_BOOTCLASSPATH)) +EMPTY_DIR := $(SUPPORT_OUTPUTDIR)/empty-dir +$(call MakeDir, $(EMPTY_DIR)) # This macro sets up compilation of a module and declares dependencies for it. # Param 1 - module name @@ -534,7 +535,7 @@ define SetupModuleCompilation $1_CLASSPATH := $$($1_CLASSPATH) $$(addprefix $(JDK_OUTPUTDIR)/modules/,jdk.hotspot.agent) endif $1_CLASSPATH := $$(subst $$(SPACE),$$(PATH_SEP),$$($1_CLASSPATH)) - $1_JAVAC_FLAGS := -bootclasspath $(EMPTY_BOOTCLASSPATH) -classpath "$$($1_CLASSPATH)" $$($1_ADD_JAVAC_FLAGS) + $1_JAVAC_FLAGS := -bootclasspath $(EMPTY_DIR) -extdirs $(EMPTY_DIR) -endorseddirs $(EMPTY_DIR) -classpath "$$($1_CLASSPATH)" $$($1_ADD_JAVAC_FLAGS) $$(eval $$(call SetupJavaCompilation,$1, \ SETUP := $$(if $$($1_SETUP), $$($1_SETUP), GENERATE_JDKBYTECODE), \ diff --git a/make/Images.gmk b/make/Images.gmk index 0dfba0f509e..d3b60a22e6b 100644 --- a/make/Images.gmk +++ b/make/Images.gmk @@ -46,9 +46,9 @@ PROVIDER_MODULES += jdk.charsets jdk.crypto.ec jdk.crypto.pkcs11 jdk.jvmstat jdk jdk.naming.dns jdk.naming.rmi jdk.scripting.nashorn jdk.zipfs # tools -TOOLS_MODULES += jdk.attach jdk.compiler jdk.dev jdk.internal.le jdk.javadoc jdk.jcmd jdk.jconsole \ - jdk.hotspot.agent jdk.hprof.agent jdk.jartool jdk.jdeps jdk.jdi jdk.jdwp.agent \ - jdk.policytool jdk.rmic jdk.xml.bind jdk.xml.ws +TOOLS_MODULES += jdk.attach jdk.compiler jdk.dev jdk.internal.le jdk.scripting.nashorn.shell \ + jdk.javadoc jdk.jcmd jdk.jconsole jdk.hotspot.agent jdk.hprof.agent jdk.jartool \ + jdk.jdeps jdk.jdi jdk.jdwp.agent jdk.policytool jdk.rmic jdk.xml.bind jdk.xml.ws ifeq ($(OPENJDK_TARGET_OS), windows) PROVIDER_MODULES += jdk.crypto.mscapi diff --git a/modules.xml b/modules.xml index 5188fd4c42e..0445602d877 100644 --- a/modules.xml +++ b/modules.xml @@ -1799,6 +1799,25 @@ java.base java.logging java.scripting + + jdk.nashorn.internal.runtime + jdk.scripting.nashorn.shell + + + jdk.nashorn.internal.objects + jdk.scripting.nashorn.shell + + + jdk.nashorn.tools + jdk.scripting.nashorn.shell + + + + jdk.scripting.nashorn.shell + java.base + java.prefs + jdk.scripting.nashorn + jdk.internal.le jdk.sctp diff --git a/nashorn/.hgtags b/nashorn/.hgtags index bd520db026d..c929021d887 100644 --- a/nashorn/.hgtags +++ b/nashorn/.hgtags @@ -310,3 +310,4 @@ d017877b3b8cd39337f1bdc00d958f821433c4c3 jdk9-b72 2e8bb16872d7b15dc0a4f8e45c6ad65f762c1b04 jdk9-b74 f884dff432a7ac349153f3d1ea1eb222f3764c6c jdk9-b75 ab231613d7206431ba31917a02e7cedd70e88e70 jdk9-b76 +33cecbc59f2ad78ac0934cbc3e014d346077e848 jdk9-b77 diff --git a/nashorn/make/BuildNashorn.gmk b/nashorn/make/BuildNashorn.gmk index 044ee4eddf5..45b8f27284d 100644 --- a/nashorn/make/BuildNashorn.gmk +++ b/nashorn/make/BuildNashorn.gmk @@ -53,7 +53,10 @@ $(eval $(call SetupJavaCompiler,GENERATE_NEWBYTECODE_DEBUG, \ SERVER_JVM := $(SJAVAC_SERVER_JAVA))) # Build nashorn into intermediate directory -$(eval $(call SetupJavaCompilation,BUILD_NASHORN, \ +# Name the compilation setup the same as the module, as is done in the global +# CompileJavaModules.gmk, to make dependency checking with other modules work +# seamlessly. +$(eval $(call SetupJavaCompilation,jdk.scripting.nashorn, \ SETUP := GENERATE_NEWBYTECODE_DEBUG, \ SRC := $(NASHORN_TOPDIR)/src/jdk.scripting.nashorn/share/classes, \ EXCLUDE_FILES := META-INF/MANIFEST.MF, \ @@ -71,7 +74,7 @@ $(eval $(call SetupJavaCompilation,BUILD_NASGEN, \ ADD_JAVAC_FLAGS := -Xbootclasspath/p:"$(SUPPORT_OUTPUTDIR)/special_classes/jdk.scripting.nashorn/classes")) # Nasgen needs nashorn classes -$(BUILD_NASGEN): $(BUILD_NASHORN) +$(BUILD_NASGEN): $(jdk.scripting.nashorn) NASHORN_CLASSES_DIR := $(JDK_OUTPUTDIR)/modules/jdk.scripting.nashorn NASGEN_RUN_FILE := $(NASHORN_CLASSES_DIR)/_the.nasgen.run diff --git a/nashorn/make/build.xml b/nashorn/make/build.xml index b3190b092bf..f8f8e7fbb8c 100644 --- a/nashorn/make/build.xml +++ b/nashorn/make/build.xml @@ -147,16 +147,16 @@ - + - + - + - - + + ${line.separator} @@ -165,7 +165,14 @@ - + + + + @@ -230,13 +237,14 @@ - - + + diff --git a/nashorn/make/project.properties b/nashorn/make/project.properties index aab32c62a83..d3730d8cdd6 100644 --- a/nashorn/make/project.properties +++ b/nashorn/make/project.properties @@ -26,6 +26,9 @@ application.title=nashorn # location of JDK embedded ASM sources jdk.asm.src.dir=../jdk/src/java.base/share/classes/jdk/internal/org/objectweb/asm +# location of JDK embedded jline sources +jdk.jline.src.dir=../jdk/src/jdk.internal.le/share/classes + # source and target levels build.compiler=modern javac.source=1.8 @@ -112,7 +115,7 @@ javac.test.classpath=\ ${build.test.classes.dir}${path.separator}\ ${file.reference.testng.jar} -meta.inf.dir=${src.dir}/META-INF +meta.inf.dir=${nashorn.module.src.dir}/META-INF run.classpath=\ ${build.classes.dir} @@ -266,7 +269,13 @@ run.test.classpath=\ ${nashorn.internal.tests.jar}${path.separator}\ ${nashorn.api.tests.jar} -src.dir=src/jdk.scripting.nashorn/share/classes +nashorn.module.src.dir=src/jdk.scripting.nashorn/share/classes +nashorn.shell.module.src.dir=src/jdk.scripting.nashorn.shell/share/classes + +src.dir=${nashorn.module.src.dir}${path.separator}\ + ${nashorn.shell.module.src.dir}${path.separator}\ + ${jdk.jline.src.dir} + test.src.dir=test/src # -Xmx is used for all tests, -Xms only for octane benchmark diff --git a/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Console.java b/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Console.java new file mode 100644 index 00000000000..932eb7ab055 --- /dev/null +++ b/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Console.java @@ -0,0 +1,103 @@ +/* + * Copyright (c) 2015, 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 + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package jdk.nashorn.tools.jjs; + +import java.io.IOException; +import java.io.InputStream; +import java.io.PrintStream; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collections; +import java.util.Iterator; +import java.util.List; +import java.util.prefs.BackingStoreException; +import java.util.prefs.Preferences; +import jdk.internal.jline.console.ConsoleReader; +import jdk.internal.jline.console.history.History.Entry; +import jdk.internal.jline.console.history.MemoryHistory; + +class Console implements AutoCloseable { + private final ConsoleReader in; + private final PersistentHistory history; + + Console(InputStream cmdin, PrintStream cmdout, Preferences prefs) throws IOException { + in = new ConsoleReader(cmdin, cmdout); + in.setExpandEvents(false); + in.setHandleUserInterrupt(true); + in.setHistory(history = new PersistentHistory(prefs)); + Runtime.getRuntime().addShutdownHook(new Thread(()->close())); + } + + String readLine(String prompt) throws IOException { + return in.readLine(prompt); + } + + + @Override + public void close() { + history.save(); + } + + public static class PersistentHistory extends MemoryHistory { + + private final Preferences prefs; + + protected PersistentHistory(Preferences prefs) { + this.prefs = prefs; + load(); + } + + private static final String HISTORY_LINE_PREFIX = "HISTORY_LINE_"; + + public final void load() { + try { + List keys = new ArrayList<>(Arrays.asList(prefs.keys())); + Collections.sort(keys); + for (String key : keys) { + if (!key.startsWith(HISTORY_LINE_PREFIX)) + continue; + CharSequence line = prefs.get(key, ""); + add(line); + } + } catch (BackingStoreException ex) { + throw new IllegalStateException(ex); + } + } + + public void save() { + Iterator entries = iterator(); + if (entries.hasNext()) { + int len = (int) Math.ceil(Math.log10(size()+1)); + String format = HISTORY_LINE_PREFIX + "%0" + len + "d"; + while (entries.hasNext()) { + Entry entry = entries.next(); + prefs.put(String.format(format, entry.index()), entry.value().toString()); + } + } + } + + } +} diff --git a/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Main.java b/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Main.java new file mode 100644 index 00000000000..9bc4b56638e --- /dev/null +++ b/nashorn/src/jdk.scripting.nashorn.shell/share/classes/jdk/nashorn/tools/jjs/Main.java @@ -0,0 +1,150 @@ +/* + * Copyright (c) 2015, 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 + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. Oracle designates this + * particular file as subject to the "Classpath" exception as provided + * by Oracle in the LICENSE file that accompanied this code. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +package jdk.nashorn.tools.jjs; + +import java.io.BufferedReader; +import java.io.InputStream; +import java.io.InputStreamReader; +import java.io.IOException; +import java.io.OutputStream; +import java.io.PrintWriter; +import java.util.prefs.Preferences; +import jdk.nashorn.internal.objects.Global; +import jdk.nashorn.internal.runtime.Context; +import jdk.nashorn.internal.runtime.ErrorManager; +import jdk.nashorn.internal.runtime.JSType; +import jdk.nashorn.internal.runtime.ScriptEnvironment; +import jdk.nashorn.internal.runtime.ScriptRuntime; +import jdk.nashorn.tools.Shell; +import jdk.internal.jline.console.UserInterruptException; + +/** + * Interactive command line Shell for Nashorn. + */ +public final class Main extends Shell { + private Main() {} + + static final Preferences PREFS = Preferences.userRoot().node("tool/jjs"); + + /** + * Main entry point with the default input, output and error streams. + * + * @param args The command line arguments + */ + public static void main(final String[] args) { + try { + final int exitCode = main(System.in, System.out, System.err, args); + if (exitCode != SUCCESS) { + System.exit(exitCode); + } + } catch (final IOException e) { + System.err.println(e); //bootstrapping, Context.err may not exist + System.exit(IO_ERROR); + } + } + + /** + * Starting point for executing a {@code Shell}. Starts a shell with the + * given arguments and streams and lets it run until exit. + * + * @param in input stream for Shell + * @param out output stream for Shell + * @param err error stream for Shell + * @param args arguments to Shell + * + * @return exit code + * + * @throws IOException if there's a problem setting up the streams + */ + public static int main(final InputStream in, final OutputStream out, final OutputStream err, final String[] args) throws IOException { + return new Main().run(in, out, err, args); + } + + /** + * read-eval-print loop for Nashorn shell. + * + * @param context the nashorn context + * @param global global scope object to use + * @return return code + */ + protected int readEvalPrint(final Context context, final Global global) { + final ScriptEnvironment env = context.getEnv(); + final String prompt = bundle.getString("shell.prompt"); + final PrintWriter err = context.getErr(); + final Global oldGlobal = Context.getGlobal(); + final boolean globalChanged = (oldGlobal != global); + + try (final Console in = new Console(System.in, System.out, PREFS)) { + if (globalChanged) { + Context.setGlobal(global); + } + + global.addShellBuiltins(); + + while (true) { + String source = ""; + try { + source = in.readLine(prompt); + } catch (final IOException ioe) { + err.println(ioe.toString()); + if (env._dump_on_error) { + ioe.printStackTrace(err); + } + return IO_ERROR; + } catch (final UserInterruptException ex) { + break; + } + + if (source.isEmpty()) { + continue; + } + + try { + final Object res = context.eval(global, source, global, ""); + if (res != ScriptRuntime.UNDEFINED) { + err.println(JSType.toString(res)); + } + } catch (final Exception e) { + err.println(e); + if (env._dump_on_error) { + e.printStackTrace(err); + } + } + } + } catch (final Exception e) { + err.println(e); + if (env._dump_on_error) { + e.printStackTrace(err); + } + } finally { + if (globalChanged) { + Context.setGlobal(oldGlobal); + } + } + + return SUCCESS; + } +} diff --git a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/tools/Shell.java b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/tools/Shell.java index 3d2a67172eb..ec0397a7b37 100644 --- a/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/tools/Shell.java +++ b/nashorn/src/jdk.scripting.nashorn/share/classes/jdk/nashorn/tools/Shell.java @@ -68,7 +68,7 @@ public class Shell { /** * Shell message bundle. */ - private static final ResourceBundle bundle = ResourceBundle.getBundle(MESSAGE_RESOURCE, Locale.getDefault()); + protected static final ResourceBundle bundle = ResourceBundle.getBundle(MESSAGE_RESOURCE, Locale.getDefault()); /** * Exit code for command line tool - successful @@ -403,7 +403,7 @@ public class Shell { * @param global global scope object to use * @return return code */ - private static int readEvalPrint(final Context context, final Global global) { + protected int readEvalPrint(final Context context, final Global global) { final String prompt = bundle.getString("shell.prompt"); final BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); final PrintWriter err = context.getErr();