5362N/A * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. 5362N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5362N/A * This code is free software; you can redistribute it and/or modify it 5362N/A * under the terms of the GNU General Public License version 2 only, as 5362N/A * published by the Free Software Foundation. 5362N/A * This code is distributed in the hope that it will be useful, but WITHOUT 5362N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 5362N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 5362N/A * version 2 for more details (a copy is included in the LICENSE file that 5362N/A * You should have received a copy of the GNU General Public License version 5362N/A * 2 along with this work; if not, write to the Free Software Foundation, 5362N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 5362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5362N/A * or visit www.oracle.com if you need additional information or have any 5362N/A * @summary Test that Selector doesn't spin when changing interest ops 5362N/A // give time for other end to be readable 5362N/A * Changes the given key's interest set from one set to another and then 5362N/A * checks the selected key set and the key's channel. 5362N/A // ensure that channel is registered with the "from" interest set 5362N/A // change to the "to" interest set 5362N/A * Tests that given Selector's select method blocks. 5362N/A // create loopback connection 5362N/A // ensure that channel "sc" is readable 5362N/A // if the interst ops is now 0 then Selector should not spin 5362N/A // if interest ops is now OP_READ then make non-readable 5362N/A // and test that Selector does not spin.