簡體   English   中英

無法在Eclipse中使用GWTQuery編譯GWT項目

[英]Can't compile GWT project with GWTQuery in Eclipse

我正在嘗試開始在GWT項目中使用GWTQuery。

  • 我已經在Eclipse中創建了示例GWT項目
  • 在war / WEB-INF / lib中添加了gwtquery-1.3.2.jar
  • 編輯了Myproject.gwt.xml(添加了<inherits name ='com.google.gwt.query.Query'/>)

當我編譯項目時,它會寫很多延遲的錯誤,但是最后附帶了:

   Scanning for additional dependencies: jar:file:/C:/eclipseBacklog/Backlog/war/WEB-INF/lib/gwtquery-1.3.2.jar!/com/google/gwt/query/client/GQuery.java
      Computing all possible rebind results for 'com.google.gwt.query.client.GQuery'
         Rebinding com.google.gwt.query.client.GQuery
            Checking rule <replace-with class='com.google.gwt.query.client.impl.SelectorEngineNativeIE8'/>
               [ERROR] Errors in 'jar:file:/C:/eclipseBacklog/Backlog/war/WEB-INF/lib/gwtquery-1.3.2.jar!/com/google/gwt/query/client/Properties.java'
                  [ERROR] Line 20: The import com.google.gwt.core.shared cannot be resolved
                  [ERROR] Line 39: GWT cannot be resolved
               [ERROR] Unable to find type 'com.google.gwt.query.client.GQuery'
                  [ERROR] Hint: Previous compiler errors may have made this type unavailable
                  [ERROR] Hint: Check the inheritance chain from your module; it may not be inheriting a required module or a module may not be adding its source path entries properly
   [ERROR] Errors in 'jar:file:/C:/eclipseBacklog/Backlog/war/WEB-INF/lib/gwtquery-1.3.2.jar!/com/google/gwt/query/client/GQuery.java'
      [ERROR] Line 1483:  Failed to resolve 'com.google.gwt.query.client.GQuery' via deferred binding

我做錯了什么?

檢查您的gwt版本,您必須更新到GWT-2.5.x。 因為gquery的這種工件具有不期望的依賴性。 2.5中有兩個GWT.java類,而gquery錯誤地依賴於新的com.google.gwt.core.shared

在gwtquery網站上打開一個問題,因為此版本也應與較早的gwt版本一起使用。

您還可以將gquery版本更改為1.3.1或1.4.0-SNAPSHOT

更新:我剛剛棄用了1.3.2版 ,並發布了1.3.3 ,該版本可以與以前的gwt版本一起編譯

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM