<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                企業??AI智能體構建引擎,智能編排和調試,一鍵部署,支持知識庫和私有化部署方案 廣告
                如已經看到的,不可能一次導入一個完整的包。為了克服這個限制,可以使用以一種快捷方式文件。文件會包含導入語句和一個小的對包中每個類型的 typedef 聲明,或者只是經常在一起使用的。然后當整個集合的類型被需要,一個導入語句可以用來調用快捷文件。 ~~~ // content of file GeomImport.hx import geom.Point; // the import is needed otherwise Point3D cannot be referenced // ... typedef Circle = geom.Circle typedef Point = geom.Point typedef Point3D = geom.Point3D // ... ~~~ 可以這樣使用: ~~~ // content of file Main.hx import GeomImport; class Main { static function main() { var p1 : Point = new Point(1,2); // ... var p2 : Point3D = new Point3D(1,2,3); // ... var c : Circle = new Circle(p1, 10); // ... } } ~~~ Point3D 實現不再例子中展示,但是它是一個類,擴展了Point,駐留在相同的 hx文件。它不是主要類型,因此,必須被顯式的導入或者如之前講的間接進行導入。 這種技術似乎加載輸出文件帶有額外的包袱對于新引入的 typedef ;在實踐中編譯的結果完全是和直接導入的一樣。因為 typedef 是聲明,僅僅用于檢查編譯時的類型,并不會實際傳輸到生成的字節碼輸出。 某些情況,它可以用來創建類的實例,使用它們的名稱和反射API。聽起來很明顯,在生成的實例上不會進行類型檢查,因為他們只能在運行時被識別。如果這些類只是通過反射使用,編譯器不能知道它們實際上需要,也不會包括他們到輸出文件。要使事情正確,類必須顯式的導入到代碼中的某個地方,通過 import 語句。
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看