项目在eclipse中编译,但maven安装会出错

时间:2014-11-19 09:10:27

标签: java eclipse maven compiler-errors vaadin7

欢迎, 我有2个项目,项目A是我的主项目的库(maven项目)。 Eclipse能够编译和运行主项目,但当我尝试清理安装时,maven会抱怨。我尝试了一切:  在A上清理安装然后在所有组合中清理安装,将默认maven编译器更改为eclipse编译器,但在主项目上仍然存在编译错误。 Pom for a project:

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>self.project</groupId>
<artifactId>A</artifactId>
<version>7.3.002.001</version>
<properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <!-- <vaadin.version>7.1.8</vaadin.version> -->
    <vaadin.version>7.3.0</vaadin.version>
</properties>
<build>
    <finalName>A</finalName>
    <plugins>
        <plugin>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.1</version>
            <configuration>
                <source>1.7</source>
                <target>1.7</target>
            </configuration>
        </plugin>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <version>2.2.1</version>
            <executions>
                <execution>
                    <id>attach-sources</id>
                    <goals>
                        <goal>jar</goal>
                    </goals>
                </execution>
            </executions>
        </plugin>
    </plugins>
</build>
<dependencies>
    <dependency>
        <groupId>javax</groupId>
        <artifactId>javaee-api</artifactId>
        <version>6.0</version>
        <scope>provided</scope>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-archetype-application</artifactId>
        <version>${vaadin.version}</version>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-push</artifactId>
        <version>${vaadin.version}</version>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-client</artifactId>
        <version>${vaadin.version}</version>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-client-compiled</artifactId>
        <version>${vaadin.version}</version>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-client-compiler</artifactId>
        <version>${vaadin.version}</version>
        <exclusions>
            <exclusion>
                <artifactId>commons-codec</artifactId>
                <groupId>commons-codec</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-themes</artifactId>
        <version>${vaadin.version}</version>
    </dependency>
    <dependency>
        <groupId>org.eclipse.persistence</groupId>
        <artifactId>eclipselink</artifactId>
        <version>2.5.0</version>
    </dependency>
    <dependency>
        <groupId>org.eclipse.persistence</groupId>
        <artifactId>javax.persistence</artifactId>
        <version>2.0.3</version>
    </dependency>
    <dependency>
        <groupId>org.apache.poi</groupId>
        <artifactId>poi</artifactId>
        <version>3.9</version>
    </dependency>
    <dependency>
        <groupId>org.apache.poi</groupId>
        <artifactId>poi-ooxml</artifactId>
        <version>3.9</version>
    </dependency>
    <dependency>
        <groupId>org.quartz-scheduler</groupId>
        <artifactId>quartz</artifactId>
        <version>2.1.6</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>MultiButton</artifactId>
        <version>3.0</version>
    </dependency>
    <dependency>
        <groupId>net.sourceforge.jtds</groupId>
        <artifactId>jtds</artifactId>
        <version>1.3.1</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>ContextMenu</artifactId>
        <version>4.2.1</version>
    </dependency>
    <dependency>
        <groupId>de.steinwedel.vaadin.addon</groupId>
        <artifactId>messagebox</artifactId>
        <version>2.0.6</version>
    </dependency>
    <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>1.6.1</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>wizards-for-vaadin</artifactId>
        <version>1.0.0-beta1</version>
    </dependency>
    <dependency>
        <groupId>joda-time</groupId>
        <artifactId>joda-time</artifactId>
        <version>2.1</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>dragdroplayouts</artifactId>
        <version>1.0</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>popupbutton</artifactId>
        <version>2.3.0</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>listbuilder</artifactId>
        <version>0.7.3.v7</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>TableExport</artifactId>
        <version>1.4.0</version>
    </dependency>

    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>stepper</artifactId>
        <version>2.1.2</version>
    </dependency>
    <dependency>
        <groupId>com.itextpdf</groupId>
        <artifactId>itextpdf</artifactId>
        <version>5.3.4</version>
    </dependency>
    <dependency>
        <groupId>net.java.dev.stax-utils</groupId>
        <artifactId>stax-utils</artifactId>
        <version>20070216</version>
        <exclusions>
            <exclusion>
                <groupId>com.bea.xml</groupId>
                <artifactId>jsr173-ri</artifactId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>commons-collections</groupId>
        <artifactId>commons-collections</artifactId>
        <version>3.2.1</version>
    </dependency>
    <dependency>
        <groupId>xml-apis</groupId>
        <artifactId>xml-apis</artifactId>
        <version>1.4.01</version>
    </dependency>
    <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>4.11</version>
        <scope>test</scope>
    </dependency>
</dependencies>

主要主题:

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>self.project</groupId>
<artifactId>Main</artifactId>
<version>7.3.119</version>
<packaging>war</packaging>
<properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <vaadin.version>7.3.0</vaadin.version>
    <spring.version>3.1.2.RELEASE</spring.version>
</properties>
<build>
    <sourceDirectory>src</sourceDirectory>
    <resources>
        <resource>
            <directory>src</directory>
            <excludes>
                <exclude>**/*.java</exclude>
            </excludes>
        </resource>
    </resources>
    <plugins>
        <plugin>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.1</version>
            <configuration>
                <source>1.7</source>
                <target>1.7</target>
            </configuration>
        </plugin>
        <plugin>
            <artifactId>maven-war-plugin</artifactId>
            <version>2.3</version>
            <configuration>
                <outputDirectory>${project.build.directory}/Deploy</outputDirectory>
                <warName>${project.artifactId}OpenSource</warName>
                <warSourceDirectory>WebContent</warSourceDirectory>
                <failOnMissingWebXml>false</failOnMissingWebXml>
                <packagingExcludes>WEB-INF/lib/commons-codec-1.3.jar</packagingExcludes>


            </configuration>
        </plugin>

    </plugins>
</build>
<dependencies>
   <! here is reference to A project >
    <dependency>
        <groupId>self.project</groupId>
        <artifactId>A</artifactId>
        <version>7.3.002.001</version>
    </dependency>
    <dependency>
        <groupId>com.vaadin</groupId>
        <artifactId>vaadin-client-compiler</artifactId>
        <version>${vaadin.version}</version>
        <scope>provided</scope>
        <exclusions>
            <exclusion>
                <artifactId>commons-codec</artifactId>
                <groupId>commons-codec</groupId>

            </exclusion>
        </exclusions>
    </dependency>

    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>animator</artifactId>
        <version>1.7.3</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>dcharts-widget</artifactId>
        <version>1.7.0</version>
    </dependency>
    <dependency>
        <groupId>org.vaadin.addons</groupId>
        <artifactId>timefield</artifactId>
        <version>0.9</version>
    </dependency>
    <dependency>
        <groupId>ru.xpoft.vaadin</groupId>
        <artifactId>spring-vaadin-integration</artifactId>
        <version>2.0.2</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-web</artifactId>
        <version>${spring.version}</version>
        <type>jar</type>
        <scope>compile</scope>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-core</artifactId>
        <version>${spring.version}</version>
        <type>jar</type>
        <scope>compile</scope>
    </dependency>
    <dependency>
        <groupId>javax.mail</groupId>
        <artifactId>mail</artifactId>
        <version>1.4.3</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context</artifactId>
        <version>${spring.version}</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-beans</artifactId>
        <version>${spring.version}</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context-support</artifactId>
        <version>${spring.version}</version>
    </dependency>
    <dependency>
        <groupId>com.vaadin.addon</groupId>
        <artifactId>vaadin-charts</artifactId>
        <version>1.1.6</version>
    </dependency>
    <dependency>
        <groupId>batik</groupId>
        <artifactId>batik-transcoder</artifactId>
        <version>1.6-1</version>
        <scope>compile</scope>
        <exclusions>
            <exclusion>
                <artifactId>fop</artifactId>
                <groupId>fop</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>com.lowagie</groupId>
        <artifactId>itext</artifactId>
        <version>4.2.1</version>
    </dependency>
    <dependency>
        <groupId>net.sf.jasperreports</groupId>
        <artifactId>jasperreports</artifactId>
        <version>5.2.0</version>
    </dependency>
    <dependency>
        <groupId>net.sourceforge.dynamicreports</groupId>
        <artifactId>dynamicreports-core</artifactId>
        <version>3.1.4</version>
    </dependency>
    <dependency>
        <groupId>net.sourceforge.dynamicreports</groupId>
        <artifactId>dynamicreports-adhoc</artifactId>
        <version>3.1.4</version>
    </dependency>
    <dependency>
        <groupId>net.sourceforge.dynamicreports</groupId>
        <artifactId>dynamicreports-googlecharts</artifactId>
        <version>3.1.4</version>
    </dependency>
</dependencies>

错误:

    [ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[69,17] cyclic inheritance involving self.project.main.ui.views.standard.TAbstractReportView
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[72,35] modifier private,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[73,38] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[73,53] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[74,25] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[74,46] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[74,65] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[75,25] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[75,45] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[75,69] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[76,25] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[76,41] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[77,25] modifier protected,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[78,36] modifier public,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[79,25] modifier public,static not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[80,23] modifier private not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[81,29] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[82,27] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[83,23] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[84,21] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[85,37] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[86,26] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[87,38] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[88,38] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[89,24] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[90,28] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[90,42] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TAbstractReportView.java:[91,23] modifier protected not allowed here
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/chart/TVaadinChartPanel.java:[74,19] cannot find symbol
  symbol:   class IChartRefreshListener
  location: class self.project.main.ui.chart.TVaadinChartPanel
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/chart/TVaadinChartPanel.java:[101,16] cannot find symbol
  symbol:   class IChartRefreshListener
  location: class self.project.main.ui.chart.TVaadinChartPanel
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/chart/TVaadinChartPanel.java:[105,40] cannot find symbol
  symbol:   class IChartRefreshListener
  location: class self.project.main.ui.chart.TVaadinChartPanel
/C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/margin/TViewMarginReportGroupParent.java:[185,47] cannot find symbol
[ERROR] symbol:   class BackgroundProcessData
[ERROR] location: class self.project.main.ui.views.margin.TViewMarginReportGroupParent
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/valo/TDWChartPanel.java:[65,25] cannot find symbol
[ERROR] symbol:   class ITableVisibilityChangeListener
[ERROR] location: class self.project.main.ui.valo.TDWChartPanel
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/valo/TDWChartPanel.java:[66,25] cannot find symbol
[ERROR] symbol:   class IChartRefreshListener
[ERROR] location: class self.project.main.ui.valo.TDWChartPanel
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/freesql/TFreeSQLChartPanel.java:[14,75] cannot find symbol
[ERROR] symbol:   class ITableVisibilityChangeListener
[ERROR] location: class self.project.main.ui.views.freesql.TFreeSQLChartPanel
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/freesql/TFreeSQLChartPanel.java:[21,75] cannot find symbol
[ERROR] symbol:   class ITableVisibilityChangeListener
[ERROR] location: class self.project.main.ui.views.freesql.TFreeSQLChartPanel
[ERROR] /C:/Users/projects/workspace/Main/src/main/java/self/project/main/ui/views/standard/TViewZbZestSp.java:[32,36] cannot find symbol
[ERROR] symbol: class TAbstractViewModule

请帮助我,我浪费了8个多小时。

0 个答案:

没有答案