<bdo id='cIqsF'></bdo><ul id='cIqsF'></ul>

<small id='cIqsF'></small><noframes id='cIqsF'>

  • <tfoot id='cIqsF'></tfoot>
    1. <legend id='cIqsF'><style id='cIqsF'><dir id='cIqsF'><q id='cIqsF'></q></dir></style></legend>

      <i id='cIqsF'><tr id='cIqsF'><dt id='cIqsF'><q id='cIqsF'><span id='cIqsF'><b id='cIqsF'><form id='cIqsF'><ins id='cIqsF'></ins><ul id='cIqsF'></ul><sub id='cIqsF'></sub></form><legend id='cIqsF'></legend><bdo id='cIqsF'><pre id='cIqsF'><center id='cIqsF'></center></pre></bdo></b><th id='cIqsF'></th></span></q></dt></tr></i><div id='cIqsF'><tfoot id='cIqsF'></tfoot><dl id='cIqsF'><fieldset id='cIqsF'></fieldset></dl></div>

        当我使用 NetBeans 6.8 和 Eclipse 运行此代码时,为什么输出会有所不同?

        Why do the outputs differ when I run this code using NetBeans 6.8 and Eclipse?(当我使用 NetBeans 6.8 和 Eclipse 运行此代码时,为什么输出会有所不同?)

            <tfoot id='2v8fv'></tfoot>

              <small id='2v8fv'></small><noframes id='2v8fv'>

            1. <legend id='2v8fv'><style id='2v8fv'><dir id='2v8fv'><q id='2v8fv'></q></dir></style></legend>
                <bdo id='2v8fv'></bdo><ul id='2v8fv'></ul>
                  <tbody id='2v8fv'></tbody>
                • <i id='2v8fv'><tr id='2v8fv'><dt id='2v8fv'><q id='2v8fv'><span id='2v8fv'><b id='2v8fv'><form id='2v8fv'><ins id='2v8fv'></ins><ul id='2v8fv'></ul><sub id='2v8fv'></sub></form><legend id='2v8fv'></legend><bdo id='2v8fv'><pre id='2v8fv'><center id='2v8fv'></center></pre></bdo></b><th id='2v8fv'></th></span></q></dt></tr></i><div id='2v8fv'><tfoot id='2v8fv'></tfoot><dl id='2v8fv'><fieldset id='2v8fv'></fieldset></dl></div>
                  本文介绍了当我使用 NetBeans 6.8 和 Eclipse 运行此代码时,为什么输出会有所不同?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  当我使用 Eclipse 和 NetBeans 6.8 运行以下代码时.我想查看计算机上可用的 COM 端口.在 Eclipse 中运行时,它会返回所有可用的 COM 端口,但在 NetBeans 中运行时,它似乎没有找到任何端口..

                  When I am running the following code using Eclipse and NetBeans 6.8. I want to see the available COM ports on my computer. When running in Eclipse it is returning me all available COM ports but when running it in NetBeans, it does not seem to find any ports ..

                  public static void test(){
                      Enumeration lists=CommPortIdentifier.getPortIdentifiers();
                  
                      System.out.println(lists.hasMoreElements());
                      while (lists.hasMoreElements()) {
                          CommPortIdentifier cn=(CommPortIdentifier)lists.nextElement();
                  
                          if ((CommPortIdentifier.PORT_SERIAL==cn.getPortType())) {
                              System.out.println(
                                "Name is serail portzzzz " +
                                cn.getName() +
                                " Owned status " +
                                cn.isCurrentlyOwned());
                  
                              try{
                                  SerialPort port1=(SerialPort)cn.open("ComControl",800000);
                                  port1.setSerialPortParams(
                                    9600,
                                    SerialPort.DATABITS_8,
                                    SerialPort.STOPBITS_1,
                                    SerialPort.PARITY_NONE);
                                  System.out.println("Before get stream");
                                  OutputStream out=port1.getOutputStream();
                                  InputStream input=port1.getInputStream();
                                  System.out.println("Before write");
                                  out.write("AT".getBytes());
                                  System.out.println("After write");
                                  int sample=0;
                                  //while((( sample=input.read())!=-1)){
                                  System.out.println("Before read");
                                  //System.out.println(input.read() + "TEsting ");
                                  /
                                  
                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  How to send data to COM PORT using JAVA?(如何使用 JAVA 向 COM PORT 发送数据?)
                  How to make a report page direction to change to quot;rtlquot;?(如何使报表页面方向更改为“rtl?)
                  Use cyrillic .properties file in eclipse project(在 Eclipse 项目中使用西里尔文 .properties 文件)
                  Is there any way to detect an RTL language in Java?(有没有办法在 Java 中检测 RTL 语言?)
                  How to load resource bundle messages from DB in Java?(如何在 Java 中从 DB 加载资源包消息?)
                  How do I change the default locale settings in Java to make them consistent?(如何更改 Java 中的默认语言环境设置以使其保持一致?)

                      <small id='F0BAt'></small><noframes id='F0BAt'>

                    1. <legend id='F0BAt'><style id='F0BAt'><dir id='F0BAt'><q id='F0BAt'></q></dir></style></legend>

                          <bdo id='F0BAt'></bdo><ul id='F0BAt'></ul>
                          <i id='F0BAt'><tr id='F0BAt'><dt id='F0BAt'><q id='F0BAt'><span id='F0BAt'><b id='F0BAt'><form id='F0BAt'><ins id='F0BAt'></ins><ul id='F0BAt'></ul><sub id='F0BAt'></sub></form><legend id='F0BAt'></legend><bdo id='F0BAt'><pre id='F0BAt'><center id='F0BAt'></center></pre></bdo></b><th id='F0BAt'></th></span></q></dt></tr></i><div id='F0BAt'><tfoot id='F0BAt'></tfoot><dl id='F0BAt'><fieldset id='F0BAt'></fieldset></dl></div>
                          <tfoot id='F0BAt'></tfoot>
                              <tbody id='F0BAt'></tbody>