释义 |
nio 基本例句 尼奥 It is actually possible to handle many thousands of clients with a single thread using the NIO selector event-driven approach, although we'll see later that threads still have a role to play. 使用 NIO选择器事件驱动方法,实际上可以用单个线程处理成千上万的客户机,不过,我们还会在后面看到线程仍有一个角色要扮演。 ibm The objective was to determine if NIO gives any considerable performance benefits and under what conditions. 目标是要确定 NIO是否给出了大量的性能优势,以及是在什么条件下给出的。 ibm The provided API is higher-level than the plain NIO API, but it's still cumbersome to use. 所提供的 API要比普通 NIO API更加高级,但是使用起来仍然很枯燥。 ibm The NIO framework can be used to build powerful server side application. NIO框架可用来构建强大的服务器端应用。 infoq We have an NIO- based server module on the roadmap. 路线图中包含了一个基于 NIO的服务器模块。 infoq Although the NIO server can be configured to listen on port80, it typically resides on a separate port. 尽管我们可以通过配置的方式让 NIO服务器监听80端口,但通常它却驻留在其它端口上。 infoq As I'm writing, I am under the impression that NIO will be particularly relevant for developers of high-performance applications such as database engines, servers, and high-performance clients. 当我在写这篇专栏文章时,我对 NIO的印象是,它将对开发诸如数据库引擎、服务器和高性能客户机的高性能应用程序的人员特别有用。 ibm Because of NIO on the server side, much better scalability can be achieved. 由于服务器端具有 NIO,因而可实现更高的可伸缩性。 ibm Before going any further, I must confess that I'm not sure I have fully grasped the logic behind the NIO. 在进一步讨论之前,我必须承认我不能确定我已经充分掌握了 NIO背后的逻辑。 ibm By defining classes to hold data, and by processing that data in blocks, NIO takes advantage of low-level optimizations in a way that the original I/ O package could not, without using native code. 通过定义包含数据的类,以及通过以块的形式处理这些数据, NIO不用使用本机代码就可以利用低级优化,这是原来的 I/ O包所无法做到的。 ibm First, you need to know a little about NIO. 首先,您需要对 NIO有一定的了解。 ibm From what I understand, it appears the goal of the NIO is to give you more control and more flexibility over regular I/ O. 就我所理解, NIO的目的似乎是为了给您比常规 I/ O更多的控制和更大的灵活性。 ibm Generally, the new asynchronous NIO API is more usable than the selector-based one from the previous- generation API. 一般来讲,新的异步 NIO API要比上一代 API中基于选择器的 API更加易用。 ibm If NIO is configured as an additional listener, use the port that is configured for NIO. 如果 NIO被作为一个附加监听器配置,使用为 NIO配置的端口。 ibm In contrast, the NIO-based server's performance degraded in a linear fashion. 相反,基于 NIO的服务器的性能则以线性方式下降。 ibm Look for more information on the NIO packages in next month's column. 请在下个月的专栏文章中查阅有关 NIO包的更多信息。 ibm Many articles followed, explaining the basics of NIO and how to leverage the benefits of nonblocking channels. 下面的许多文章阐述了 NIO的基本知识及如何利用非阻塞通道的好处。 ibm Nonblocking reads and writes are essential to NIO, but they don't come trouble free. 对于 NIO,非阻塞读写是必要的,但它们并不是完全没有麻烦。 ibm Parallel delivery allows to send a message to multiple destinations in parallel using one thread NIO. 平行传递则允许一个线程发送消息给多个目的地 NIO。 infoq The bottom line is that NIO servers still need threads, just not quite as many. 最后的结果是 NIO服务器仍然需要线程,只是不需要那么多。 ibm The client cannot access a NIO endpoint through a client side proxy. 客户端无法通过客户端代理访问 NIO端点。 infoq They share the same method and argument structures, and most operations available to the NIO channel classes are also available in the new asynchronous versions. 他们共享相同的方法与参数结构体,并且大多数对于 NIO通道类可用的参数,对于新的异步版本仍然可用。 ibm This is the first difference from NIO. 这是与 NIO的第一个不同之处。 ibm This tutorial is intended for any programmer who wants to learn more about the JDK1.4 NIO library. 本教程是为希望学习更多关于 JDK1.4 NIO库的知识的所有程序员而写的。 ibm Throughout the tutorial, we'll work with code samples that illustrate different aspects of the NIO library. 在本教程中,我们将使用展示 NIO库的不同方面的代码示例。 ibm We will first delete the BIO connector that runs on port8080, and then create a new NIO connector to run on the same port. 我们将首先删除在8080端口上运行的 BIO连接器,然后创建在此端口运行的新 NIO连接器。 ibm You'll also learn about things you can only do with NIO, such as asynchronous I/ O and direct buffers. 您还会了解只能通过 NIO来完成的工作,如异步 I/ O和直接缓冲区。 ibm NIO channels can be asynchronously closed and interrupted. 可以异步地关闭和中断 NIO通道。 ibm NIO lets you return to the connection later and send additional data. NIO允许随后再返回到这个连接并发送额外的数据。 ibm NIO servers are relieved of this and therefore can scale to larger numbers of users. NIO服务器完全不用担心这一点,因此它们可以扩展到大量用户。 ibm |