2016-12-15 20 views
2

Eclipse Neonでエディタプラグインを開発しています。プロジェクトは、親プロジェクト、依存関係を管理する子プロジェクト、実際のソースコードを含む子プロジェクトに分かれています。私のプラグインをEclipse MarsからNeonに移行した後、メソッドIEditorDescriptor editorDescriptor = IDE.getEditorDescriptor(storage.getName(), true);IEditorDescriptor editorDescriptor = IDE.getEditorDescriptor(storage.getName(), true, true);に変更しました。最初のものは廃止されました。私はMavenを使用してプロジェクトを再構築しようとした場合、それは私のコンパイルの失敗を与える:Mavenコンパイルに失敗しましたが、Javaエラーなし

[ERROR] Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:0.22.0:compile (default-compile) on project language-editor-core: Compilation failure: Compilation failure: 
[ERROR] C:\Users\X\Documents\tfeditor\language-editor-core\src\main\java\de\se_rwth\langeditor\texteditor\hyperlinks\HyperlinkDetectorImpl.java:[228] 
[ERROR] IEditorDescriptor editorDescriptor = IDE.getEditorDescriptor(storage.getName(), true, true); 
[ERROR] ^^^^^^^^^^^^^^^^^^^ 
[ERROR] The method getEditorDescriptor(String, boolean) in the type IDE is not applicable for the arguments (String, boolean, boolean) 
[ERROR] 1 problem (1 error) 
[ERROR] -> [Help 1] 
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. 
[ERROR] Re-run Maven using the -X switch to enable full debug logging. 
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles: 
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException 
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command 
[ERROR] mvn <goals> -rf :language-editor-core 

親プロジェクトののpom.xmlは、このいずれかになります。

<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>de.monticore</groupId> 
    <artifactId>language-editor</artifactId> 
    <version>1.0.0-SNAPSHOT</version> 

    <name>Language Editor</name> 

    <organization> 
     <name>Department of Software Engineering, RWTH Aachen University</name> 
     <url>http://www.se-rwth.de/</url> 
    </organization> 

    <packaging>pom</packaging> 

    <modules> 
     <module>language-editor-core</module> 
     <module>cdtrans-editor</module> 
     <module>matrans-editor</module> 
     <module>language-editor-updatesite</module> 
    </modules> 

    <properties> 
     <monticore.version>4.5.0</monticore.version> 
     <monticoreRuntime.version>4.5.0</monticoreRuntime.version> 
     <cd4a.version>1.3.7-SNAPSHOT</cd4a.version> 
     <cd4a-trans.version>0.0.3-SNAPSHOT</cd4a-trans.version> 
     <typestrans.version>0.0.3-SNAPSHOT</typestrans.version> 
     <literalstrans.version>0.0.3-SNAPSHOT</literalstrans.version> 
     <tfruntime.version>4.4.0-SNAPSHOT</tfruntime.version> 
     <odrules.version>4.4.0-SNAPSHOT</odrules.version> 
     <secommons.version>1.7.7</secommons.version> 
     <antlr.version>4.5</antlr.version> 
     <guava.version>18.0</guava.version> 
     <matrans.version>0.0.2.E-SNAPSHOT</matrans.version> 
     <macommontrans.version>0.0.2-SNAPSHOT</macommontrans.version> 


     <tycho.version>0.22.0</tycho.version> 
     <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
     <wagon.version>1.0</wagon.version> 
     <compiler.plugin>3.3</compiler.plugin> 
     <java.version>1.8</java.version> 
    </properties> 

    <dependencyManagement> 
     <dependencies> 
      <dependency> 
       <groupId>de.se_rwth.commons</groupId> 
       <artifactId>se-commons-utilities</artifactId> 
       <version>${secommons.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore</groupId> 
       <artifactId>monticore-runtime</artifactId> 
       <version>${monticoreRuntime.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore</groupId> 
       <artifactId>monticore-grammar</artifactId> 
       <version>${monticore.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore.lang</groupId> 
       <artifactId>cd4analysis</artifactId> 
       <version>${cd4a.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore.lang</groupId> 
       <artifactId>cd4a-trans</artifactId> 
       <version>${cd4a-trans.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore.lang</groupId> 
       <artifactId>literalstrans</artifactId> 
       <version>${literalstrans.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore.lang</groupId> 
       <artifactId>typestrans</artifactId> 
       <version>${typestrans.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore.lang.tf</groupId> 
       <artifactId>de.monticore.tf.runtime</artifactId> 
       <version>${tfruntime.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore.lang.tf</groupId> 
       <artifactId>de.monticore.tf.odrules</artifactId> 
       <version>${tfruntime.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>org.antlr</groupId> 
       <artifactId>antlr4</artifactId> 
       <version>${antlr.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>org.antlr</groupId> 
       <artifactId>antlr4-runtime</artifactId> 
       <version>${antlr.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>com.google.guava</groupId> 
       <artifactId>guava</artifactId> 
       <version>${guava.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore.lang.tf</groupId> 
       <artifactId>matrans</artifactId> 
       <version>${matrans.version}</version> 
      </dependency> 

      <dependency> 
       <groupId>de.monticore.lang.tf</groupId> 
       <artifactId>macommontrans</artifactId> 
       <version>${macommontrans.version}</version> 
      </dependency> 

     </dependencies> 
    </dependencyManagement> 

    <build> 
     <pluginManagement> 
      <plugins> 
       <plugin> 
        <groupId>org.eclipse.tycho</groupId> 
        <artifactId>tycho-maven-plugin</artifactId> 
        <version>${tycho.version}</version> 
        <extensions>true</extensions> 
       </plugin> 

       <plugin> 
        <groupId>org.eclipse.tycho</groupId> 
        <artifactId>target-platform-configuration</artifactId> 
        <version>${tycho.version}</version> 
        <configuration> 
         <target> 
          <artifact> 
           <groupId>de.se_rwth.eclipse</groupId> 
           <artifactId>de.se_rwth.eclipse.targetplatform.luna</artifactId> 
           <version>1.0.2-SNAPSHOT</version> 
          </artifact> 
         </target> 
         <pomDependencies>consider</pomDependencies> 
         <environments> 
          <environment> 
           <os>linux</os> 
           <ws>gtk</ws> 
           <arch>x86</arch> 
          </environment> 
          <environment> 
           <os>linux</os> 
           <ws>gtk</ws> 
           <arch>x86_64</arch> 
          </environment> 
          <environment> 
           <os>win32</os> 
           <ws>win32</ws> 
           <arch>x86</arch> 
          </environment> 
          <environment> 
           <os>win32</os> 
           <ws>win32</ws> 
           <arch>x86_64</arch> 
          </environment> 
          <environment> 
           <os>macosx</os> 
           <ws>cocoa</ws> 
           <arch>x86_64</arch> 
          </environment> 
         </environments> 
        </configuration> 
       </plugin> 

       <plugin> 
        <groupId>org.codehaus.mojo</groupId> 
        <artifactId>wagon-maven-plugin</artifactId> 
        <version>${wagon.version}</version> 
        <executions> 
         <execution> 
          <id>deploy-repository</id> 
          <phase>deploy</phase> 
          <goals> 
           <goal>upload-single</goal> 
          </goals> 
          <configuration> 
           <fromFile>${project.build.directory}/${project.build.finalName}.zip</fromFile> 
           <serverId>se-nexus</serverId> 
           <url>https://nexus.se.rwth-aachen.de/service/local/repositories/monticore-snapshots/content-compressed</url> 
          </configuration> 
         </execution> 
        </executions> 
       </plugin> 

       <plugin> 
        <groupId>org.apache.felix</groupId> 
        <artifactId>maven-bundle-plugin</artifactId> 
        <version>3.0.1</version> 
       </plugin> 
      </plugins> 
     </pluginManagement> 
    </build> 

    <distributionManagement> 
     <repository> 
      <id>se-nexus</id> 
      <url>http://nexus.se.rwth-aachen.de/content/repositories/monticore-releases/</url> 
     </repository> 
     <snapshotRepository> 
      <id>se-nexus</id> 
      <url>http://nexus.se.rwth-aachen.de/content/repositories/monticore-snapshots/</url> 
     </snapshotRepository> 
     <site> 
      <id>se-nexus</id> 
      <url>dav:http://nexus.se.rwth-aachen.de/content/sites/se-sites/monticore/${project.version}/</url> 
     </site> 
    </distributionManagement> 

    <repositories> 
     <repository> 
      <id>se-public</id> 
      <url>http://nexus.se.rwth-aachen.de/content/groups/public</url> 
     </repository> 
    </repositories> 

    <pluginRepositories> 
     <pluginRepository> 
      <id>se-public</id> 
      <url>http://nexus.se.rwth-aachen.de/content/groups/public</url> 
     </pluginRepository> 
    </pluginRepositories> 

</project> 

コード内の特定の行がされEclipseで間違っているとマークされておらず、コードの実行もうまくいくので、どこに問題がありますか?

+1

'IDE.getEditorDescriptor'を提供する依存関係のバージョンを再確認してください。 – lexicore

答えて

0

を構築しよう:

<repositories> 
     <repository> 
      <id>eclipse-neon</id> 
      <url>http://download.eclipse.org/releases/neon</url> 
      <layout>p2</layout> 
     </repository> 
    </repositories> 

、Mavenビルドは動作し、をマークしませんをエラーとして解決する - >問題を解決しました

-1

クリーン

MVNを行い、これとのpom.xmlにEclipseのネオンリポジトリを追加した後、実際にもう一度

+0

は動作しません。私は常に 'mvn clean install 'で再構築しています。 – Noltibus

+0

はIDE.getEditorDescriptor(storage.getName()、true、true);です。親プロジェクトで定義されたAPI? – bullzeye

+0

の場合は、まず親プロジェクトにmvnをインストールしてから、子プロジェクトにmvn installを実行します – bullzeye

関連する問題