2015-02-11 51 views
0

我有一個完美的動態web項目。然後我試圖使用mvn eclipse:eclipse -Dwtpversion=2.0命令將其更改爲mvn web項目,然後更改我的包結構。將main.java包添加到我的包中。我試圖在.classpath文件中加入封裝結構在eclipse中更改

<classpathentry kind="src" output="target/classes" path="src/main/java"> 
     <attributes> 
      <attribute name="optional" value="true"/> 
      <attribute name="maven.pomderived" value="true"/> 
     </attributes> 
    </classpathentry> 
    <classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"> 
     <attributes> 
      <attribute name="maven.pomderived" value="true"/> 
     </attributes> 
    </classpathentry> 

但是項目包沒有變化。 以下是我更改的項目結構。我怎樣才能把它恢復正常(刪除軟件包main.java) 預先感謝

enter image description here

編輯:

當我試圖編輯源文件夾它顯示以下錯誤: enter image description here

回答

1

你必須改變的源文件夾下的Java構建路徑項目配置

enter image description here