久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

    • <bdo id='IG9UM'></bdo><ul id='IG9UM'></ul>

    1. <i id='IG9UM'><tr id='IG9UM'><dt id='IG9UM'><q id='IG9UM'><span id='IG9UM'><b id='IG9UM'><form id='IG9UM'><ins id='IG9UM'></ins><ul id='IG9UM'></ul><sub id='IG9UM'></sub></form><legend id='IG9UM'></legend><bdo id='IG9UM'><pre id='IG9UM'><center id='IG9UM'></center></pre></bdo></b><th id='IG9UM'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='IG9UM'><tfoot id='IG9UM'></tfoot><dl id='IG9UM'><fieldset id='IG9UM'></fieldset></dl></div>
      <tfoot id='IG9UM'></tfoot><legend id='IG9UM'><style id='IG9UM'><dir id='IG9UM'><q id='IG9UM'></q></dir></style></legend>

      1. <small id='IG9UM'></small><noframes id='IG9UM'>

        Java Switch 語句 - 是“或"/“和"可能的?

        Java Switch Statement - Is quot;orquot;/quot;andquot; possible?(Java Switch 語句 - 是“或/“和可能的?)
        <legend id='7EJhh'><style id='7EJhh'><dir id='7EJhh'><q id='7EJhh'></q></dir></style></legend>
              <tbody id='7EJhh'></tbody>
            <i id='7EJhh'><tr id='7EJhh'><dt id='7EJhh'><q id='7EJhh'><span id='7EJhh'><b id='7EJhh'><form id='7EJhh'><ins id='7EJhh'></ins><ul id='7EJhh'></ul><sub id='7EJhh'></sub></form><legend id='7EJhh'></legend><bdo id='7EJhh'><pre id='7EJhh'><center id='7EJhh'></center></pre></bdo></b><th id='7EJhh'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='7EJhh'><tfoot id='7EJhh'></tfoot><dl id='7EJhh'><fieldset id='7EJhh'></fieldset></dl></div>
              <bdo id='7EJhh'></bdo><ul id='7EJhh'></ul>

                1. <small id='7EJhh'></small><noframes id='7EJhh'>

                2. <tfoot id='7EJhh'></tfoot>
                3. 本文介紹了Java Switch 語句 - 是“或"/“和"可能的?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  我實現了一個字體系統,它通過 char switch 語句找出要使用的字母.我的字體圖像中只有大寫字母.我需要做到這一點,例如,'a' 和 'A' 都具有相同的輸出.與其將案件數量增加 2 倍,不如說是以下內容:

                  I implemented a font system that finds out which letter to use via char switch statements. There are only capital letters in my font image. I need to make it so that, for example, 'a' and 'A' both have the same output. Instead of having 2x the amount of cases, could it be something like the following:

                  char c;
                  
                  switch(c){
                  case 'a' & 'A': /*get the 'A' image*/; break;
                  case 'b' & 'B': /*get the 'B' image*/; break;
                  ...
                  case 'z' & 'Z': /*get the 'Z' image*/; break;
                  }
                  

                  這在java中可能嗎?

                  Is this possible in java?

                  推薦答案

                  您可以通過省略 break; 語句來使用 switch-case fall through.

                  You can use switch-case fall through by omitting the break; statement.

                  char c = /* whatever */;
                  
                  switch(c) {
                      case 'a':
                      case 'A':
                          //get the 'A' image;
                          break;
                      case 'b':
                      case 'B':
                          //get the 'B' image;
                          break;
                      // (...)
                      case 'z':
                      case 'Z':
                          //get the 'Z' image;
                          break;
                  }
                  

                  ...或者您可以規范化為 小寫或大寫 切換之前.

                  ...or you could just normalize to lower case or upper case before switching.

                  char c = Character.toUpperCase(/* whatever */);
                  
                  switch(c) {
                      case 'A':
                          //get the 'A' image;
                          break;
                      case 'B':
                          //get the 'B' image;
                          break;
                      // (...)
                      case 'Z':
                          //get the 'Z' image;
                          break;
                  }
                  

                  這篇關于Java Switch 語句 - 是“或"/“和"可能的?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  quot;Char cannot be dereferencedquot; error(“Char 不能被取消引用錯誤)
                  Java Replace Character At Specific Position Of String?(Java替換字符串特定位置的字符?)
                  What is the type of a ternary expression with int and char operands?(具有 int 和 char 操作數的三元表達式的類型是什么?)
                  Read a text file and store every single character occurrence(讀取文本文件并存儲出現的每個字符)
                  Why do I need to explicitly cast char primitives on byte and short?(為什么我需要在 byte 和 short 上顯式轉換 char 原語?)
                  What#39;s the best way to check if a character is a vowel in Java?(在 Java 中檢查字符是否為元音的最佳方法是什么?)
                  <i id='rPdCX'><tr id='rPdCX'><dt id='rPdCX'><q id='rPdCX'><span id='rPdCX'><b id='rPdCX'><form id='rPdCX'><ins id='rPdCX'></ins><ul id='rPdCX'></ul><sub id='rPdCX'></sub></form><legend id='rPdCX'></legend><bdo id='rPdCX'><pre id='rPdCX'><center id='rPdCX'></center></pre></bdo></b><th id='rPdCX'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='rPdCX'><tfoot id='rPdCX'></tfoot><dl id='rPdCX'><fieldset id='rPdCX'></fieldset></dl></div>

                    <tbody id='rPdCX'></tbody>

                      • <legend id='rPdCX'><style id='rPdCX'><dir id='rPdCX'><q id='rPdCX'></q></dir></style></legend><tfoot id='rPdCX'></tfoot>

                        1. <small id='rPdCX'></small><noframes id='rPdCX'>

                            <bdo id='rPdCX'></bdo><ul id='rPdCX'></ul>
                            主站蜘蛛池模板: 国产色网 | 日韩在线视频一区 | 亚洲一区不卡 | 亚洲精品乱 | 久草成人网 | 神马影院一区二区三区 | 日本特黄a级高清免费大片 国产精品久久性 | 国产精品一区二区三区在线 | 性欧美精品一区二区三区在线播放 | 911精品美国片911久久久 | 久久久久久久久综合 | 国产欧美精品一区二区三区 | 精品国产一区二区三区久久 | 日韩成人在线播放 | 精品一区二区在线观看 | 美女久久 | 成人欧美| 欧美一级黄色网 | 欧美日韩久久 | 日本不卡一区 | 视频一区二区三区在线观看 | 1000部精品久久久久久久久 | 日韩精品视频在线 | 香蕉久久a毛片 | 日韩综合在线 | 97人人超碰 | 三级在线免费 | 观看av | 一区二区电影网 | 精品一区二区三区91 | 日韩午夜电影在线观看 | av中文字幕在线 | 国产1区| 国产精品视频999 | 国产日韩欧美另类 | 欧美成人精品二区三区99精品 | 亚洲成人av在线播放 | 中文字幕乱码一区二区三区 | 国产一区二区在线免费观看 | 国产精品一区二区久久 | 亚洲经典一区 |