Package java.nio.channels

Examples of java.nio.channels.AsynchronousCloseException


    /**
     * @tests serialization/deserialization compatibility.
     */
    public void testSerializationSelf() throws Exception {

        SerializationTest.verifySelf(new AsynchronousCloseException());
    }
View Full Code Here


    /**
     * @tests serialization/deserialization compatibility with RI.
     */
    public void testSerializationCompatibility() throws Exception {

        SerializationTest.verifyGolden(this, new AsynchronousCloseException());
    }
View Full Code Here

     */
    void unreference(boolean checkClosed) throws AsynchronousCloseException {
      int newCount = bits.decrementAndGet();
      assert (newCount & ~STATUS_CLOSED_MASK) >= 0;
      if (checkClosed && ((newCount & STATUS_CLOSED_MASK) != 0)) {
        throw new AsynchronousCloseException();
      }
    }
View Full Code Here

        return exchanges.remove(exchange);
    }

    public void close()
    {
        abort(new AsynchronousCloseException());
        LOG.debug("Closed {}", this);
    }
View Full Code Here

                }
                else if (bytes == CLOSED)
                {
                    if (index < 0)
                        return -1;
                    throw new AsynchronousCloseException();
                }
                else if (bytes != null)
                {
                    int result = bytes[index] & 0xFF;
                    if (++index == bytes.length)
View Full Code Here

     */
    void unreference(boolean checkClosed) throws AsynchronousCloseException {
      int newCount = bits.decrementAndGet();
      assert (newCount & ~STATUS_CLOSED_MASK) >= 0;
      if (checkClosed && ((newCount & STATUS_CLOSED_MASK) != 0)) {
        throw new AsynchronousCloseException();
      }
    }
View Full Code Here

                public SocketAddress call() throws IOException {
                    try {
                        return channel.receive(dst);
                    } catch (ClosedChannelException e) {
                        throw Util.initCause(
                            new AsynchronousCloseException(), e);
                    }
                } });
    }
View Full Code Here

                public Integer call() throws IOException {
                    try {
                        return channel.send(src, target);
                    } catch (ClosedChannelException e) {
                        throw Util.initCause(
                            new AsynchronousCloseException(), e);
                    }
                } });
    }
View Full Code Here

                public Integer call() throws IOException {
                    try {
                        return channel.read(dst);
                    } catch (ClosedChannelException e) {
                        throw Util.initCause(
                            new AsynchronousCloseException(), e);
                    }
                } });
    }
View Full Code Here

                public Integer call() throws IOException {
                    try {
                        return channel.write(src);
                    } catch (ClosedChannelException e) {
                        throw Util.initCause(
                            new AsynchronousCloseException(), e);
                    }
                } });
    }
View Full Code Here

TOP

Related Classes of java.nio.channels.AsynchronousCloseException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.